Skip to content
Snippets Groups Projects
Commit efc4f241 authored by Helmut Stult's avatar Helmut Stult
Browse files

[pkg-upd] 5.7.9-1

- add 0002-pinctrl-amd.patch
parent 90aadb59
No related branches found
No related tags found
No related merge requests found
File moved
diff --git a/drivers/pinctrl/pinctrl-amd.c b/drivers/pinctrl/pinctrl-amd.c
index 1fe62a35bb12..c34e6a950b3f 100644
--- a/drivers/pinctrl/pinctrl-amd.c
+++ b/drivers/pinctrl/pinctrl-amd.c
@@ -417,22 +417,13 @@ static int amd_gpio_irq_set_type(struct irq_data *d, unsigned int type)
{
int ret = 0;
u32 pin_reg, pin_reg_irq_en, mask;
- unsigned long flags, irq_flags;
+ unsigned long flags;
struct gpio_chip *gc = irq_data_get_irq_chip_data(d);
struct amd_gpio *gpio_dev = gpiochip_get_data(gc);
raw_spin_lock_irqsave(&gpio_dev->lock, flags);
pin_reg = readl(gpio_dev->base + (d->hwirq)*4);
- /* Ignore the settings coming from the client and
- * read the values from the ACPI tables
- * while setting the trigger type
- */
-
- irq_flags = irq_get_trigger_type(d->irq);
- if (irq_flags != IRQ_TYPE_NONE)
- type = irq_flags;
-
switch (type & IRQ_TYPE_SENSE_MASK) {
case IRQ_TYPE_EDGE_RISING:
pin_reg &= ~BIT(LEVEL_TRIG_OFF);
......@@ -11,8 +11,8 @@ _kernelname=-MANJARO
_basekernel=5.7
_basever=57
_aufs=20200622
pkgver=5.7.8
pkgrel=8
pkgver=5.7.9
pkgrel=1
arch=('x86_64')
url="http://www.kernel.org/"
license=('GPL2')
......@@ -40,19 +40,20 @@ source=("https://www.kernel.org/pub/linux/kernel/v5.x/linux-${_basekernel}.tar.x
# ARCH Patches
'0001-ZEN-Add-sysctl-and-CONFIG-to-disallow-unprivileged-CLONE_NEWUSER.patch'
# MANJARO Patches
'0001-nonupstream-navi10-vfio-reset.patch'
'0001-i2c-nuvoton-nc677x-hwmon-driver.patch'
'0001-iomap-iomap_bmap-should-accept-unwritten-maps.patch'
'0001-futex.patch'
'0001-apparmor-patch-to-provide-compatibility-with-v2-net-rules.patch'
'0002-apparmor-af_unix-mediation.patch'
'0003-apparmor-fix-use-after-free-in-sk_peer_label.patch'
'0004-apparmor-fix-apparmor-mediating-locking-non-fs-unix-sockets.patch'
# Lenovo P50 multiple fans
'0005-thinkpad_acpi_dual_fan_control.patch::https://github.com/dvhart/linux-pdx86/commit/26c16f9d956f269bbc32e034e3ec11c4831137de.patch'
"$pkgname-ath9k-fix-general-protection-fault-in-ath9k_hif_usb_rx_cb.patch::https://git.kernel.org/pub/scm/linux/kernel/git/stable/stable-queue.git/plain/releases/5.7.3/ath9k-fix-general-protection-fault-in-ath9k_hif_usb_rx_cb.patch"
# Lenovo LEGION 5
# Lenovo + AMD
'0001-nonupstream-navi10-vfio-reset.patch'
'0001-lenovo-wmi1.patch'
'0001-lenovo-wmi2.patch'
'0002-pinctrl-amd.patch'
# Bootsplash
'0001-bootsplash.patch'
'0002-bootsplash.patch'
......@@ -66,13 +67,12 @@ source=("https://www.kernel.org/pub/linux/kernel/v5.x/linux-${_basekernel}.tar.x
'0010-bootsplash.patch'
'0011-bootsplash.patch'
'0012-bootsplash.patch'
'0013-bootsplash.patch'
futex-patches.patch)
'0013-bootsplash.patch')
sha256sums=('de8163bb62f822d84f7a3983574ec460060bf013a78ff79cd7c979ff1ec1d7e0'
'eea2cb4ea7c2014b0daa6d702fc7087d017c55e6ea479434b1269626eda9fde5'
'8acfa6bcdff16c55cf8ecb6fdd831b8d865b064c7df1ae0ec9043a143ec78a52'
'63e25e02432839714a3173154792930d0d80940d31cef0f4370081538f6c2bbc'
'4999143d190933b59cf9460d50ced4eacf39696ccda86cb6db4f3243bde41fde'
'b44d81446d8b53d5637287c30ae3eb64cae0078c3fbc45fcf1081dd6699818b5'
'b3455e089e3ac499c0df4a47636aec6eed2b0be0a6e4c7af7aaccb7274dae5ce'
'd9a9d1a3410c82cfaa282dd139429bedf4fa07dde904eefcf3ac053d70ad2770'
'a320441bd4540eaf6ed10bbcfb9714bd6d358852aacf0da63330c40a1ad3732c'
'2ccc807cc6f0fc21f8e23e2e9fd080eb1bc12c3450779e7025ebeaeee2ecffb4'
'842d2cb05d5796479654634a3cc6623513cefbfdf135a1471dbbfa994166ec14'
......@@ -81,17 +81,18 @@ sha256sums=('de8163bb62f822d84f7a3983574ec460060bf013a78ff79cd7c979ff1ec1d7e0'
'9e7ce0431a786444e95e05dafde2d75387fb75d0709dcc807915d638879701cd'
'20abad2643c635210c925c3ce3a12eb31f813819d6e661c6d99d9cc3163fbef7'
'7685d526bbdbfa795986591a70071c960ff572f56d3501774861728a9df8664c'
'f1eec160ce5df5c2ea58d4e4fd44a6b1013863c6b3bf649414cd18c89ae500fa'
'0556859a8168c8f7da9af8e2059d33216d9e5378d2cac70ca54c5ff843fa5add'
'95745075edd597caa92b369cfbcd11a04c9e3c88c0c987c70114924e1e01df5c'
'78dde51123a21ec5efe9c420b309d03263001dafd8684f71c167f02e3f504f9e'
'98202b8ad70d02d86603294bae967874fa7b18704b5c7b867568b0fd33a08921'
'5cbbf3db9ea3205e9b89fe3049bea6dd626181db0cb0dc461e4cf5a400c68dd6'
'c7dbec875d0c1d6782c037a1dcefff2e5bdb5fc9dffac1beea07dd8c1bdef1d7'
'77746aea71ffb06c685e7769b49c78e29af9b2e28209cd245e95d9cbb0dba3c9'
'f93707e75ec6be5f289605f913e59d4f3514524a1aab3368f49bf6789723d443'
'715ee8cae71db82f31c486cc0a946a7e9f9eb8d7c69d8bb5c64c35400affef3c'
'f1eec160ce5df5c2ea58d4e4fd44a6b1013863c6b3bf649414cd18c89ae500fa'
'7d2af76b8dae73946379b967a493b927d76a68bb524b275b7c445bab90995687'
'1d58ef2991c625f6f0eb33b4cb8303932f53f1c4694e42bae24c9cd36d2ad013'
'ab22f6692c8e3f636b7d07f671d442416555bfc581d01b11ce35a4de0c74418f'
'a504f6cf84094e08eaa3cc5b28440261797bf4f06f04993ee46a20628ff2b53c'
'e096b127a5208f56d368d2cb938933454d7200d70c86b763aa22c38e0ddb8717'
'8c1c880f2caa9c7ae43281a35410203887ea8eae750fe8d360d0c8bf80fcc6e0'
......@@ -104,8 +105,7 @@ sha256sums=('de8163bb62f822d84f7a3983574ec460060bf013a78ff79cd7c979ff1ec1d7e0'
'e9f22cbb542591087d2d66dc6dc912b1434330ba3cd13d2df741d869a2c31e89'
'27471eee564ca3149dd271b0817719b5565a9594dc4d884fe3dc51a5f03832bc'
'60e295601e4fb33d9bf65f198c54c7eb07c0d1e91e2ad1e0dd6cd6e142cb266d'
'035ea4b2a7621054f4560471f45336b981538a40172d8f17285910d4e0e0b3ef'
'78dde51123a21ec5efe9c420b309d03263001dafd8684f71c167f02e3f504f9e')
'035ea4b2a7621054f4560471f45336b981538a40172d8f17285910d4e0e0b3ef')
prepare() {
cd "${srcdir}/linux-${_basekernel}"
......@@ -122,10 +122,6 @@ prepare() {
msg2 "PATCH: 0001-ZEN-Add-sysctl-and-CONFIG-to-disallow-unprivileged-CLONE_NEWUSER"
patch -Np1 -i "${srcdir}/0001-ZEN-Add-sysctl-and-CONFIG-to-disallow-unprivileged-CLONE_NEWUSER.patch"
msg "ath9k revert patch"
# https://forum.manjaro.org/t/testing-update-2020-06-26-kernels-mesa-20-1-2-haskell/150212/22
patch -Rp1 -i "${srcdir}/$pkgname-ath9k-fix-general-protection-fault-in-ath9k_hif_usb_rx_cb.patch"
# other fixes by Arch
# add patches for snapd
......@@ -140,23 +136,26 @@ prepare() {
msg2 "0004-apparmor-fix-apparmor-mediating-locking-non-fs-unix-sockets"
patch -Np1 -i "${srcdir}/0004-apparmor-fix-apparmor-mediating-locking-non-fs-unix-sockets.patch"
msg "navi10-vfio reset patch"
msg "nuvoton hwmon driver patch"
# https://twitter.com/vskye11/status/1216240051639791616
patch -Np1 -i '../0001-i2c-nuvoton-nc677x-hwmon-driver.patch'
# Lenovo + AMD
msg "Lenovo + AMD"
msg2 "navi10-vfio reset patch"
# TODO: remove when AMD properly fixes it!
# INFO: this is a hack and won't be upstreamed
# https://forum.level1techs.com/t/145666/86
# https://forum.manjaro.org/t/107820/11
patch -Np1 -i "${srcdir}/0001-nonupstream-navi10-vfio-reset.patch"
msg "nuvoton hwmon driver patch"
# https://twitter.com/vskye11/status/1216240051639791616
patch -Np1 -i '../0001-i2c-nuvoton-nc677x-hwmon-driver.patch'
# Lenovo LEGION 5
msg "Lenovo LEGION 5"
msg2 "0001-lenovo-wmi1"
patch -Np1 -i '../0001-lenovo-wmi1.patch'
msg2 "0001-lenovo-wmi2"
patch -Np1 -i '../0001-lenovo-wmi2.patch'
msg2 "0002-pinctrl-amd"
patch -Np1 -i '../0002-pinctrl-amd.patch'
# handling of multiple fans on Lenovo P50
# https://github.com/vmatare/thinkfan/issues/58
......@@ -168,6 +167,10 @@ prepare() {
msg "handling of multiple fans on Lenovo P50"
patch -Np1 -i "${srcdir}/0001-iomap-iomap_bmap-should-accept-unwritten-maps.patch"
# futex patch, https://lore.kernel.org/lkml/20200612185122.327860-1-andrealmeid@collabora.com/
msg2 "0001-futex.patch"
patch -Np1 -i "${srcdir}/0001-futex.patch"
# Add bootsplash - http://lkml.iu.edu/hypermail/linux/kernel/1710.3/01542.html
msg "Add bootsplash"
msg2 "0001-bootsplash."
......@@ -217,10 +220,6 @@ prepare() {
msg2 "vfs-ino"
patch -Np1 -i "${srcdir}/vfs-ino.patch"
# futex patch, https://lore.kernel.org/lkml/20200612185122.327860-1-andrealmeid@collabora.com/
msg2 "futex-patches.patch"
patch -Np1 -i "${srcdir}/futex-patches.patch"
cat "${srcdir}/config" > ./.config
cat "${srcdir}/config.aufs" >> ./.config
......
This diff is collapsed.
#
# Automatically generated file; DO NOT EDIT.
# Linux/x86 5.7.8-5 Kernel Configuration
# Linux/x86 5.7.9-1 Kernel Configuration
#
#
......
SPDX-License-Identifier: GPL-2.0
diff --git a/fs/mount.h b/fs/mount.h
index 711a4093e475..a5703d5c7205 100644
--- a/fs/mount.h
+++ b/fs/mount.h
@@ -133,9 +133,7 @@ struct proc_mounts {
struct mnt_namespace *ns;
struct path root;
int (*show)(struct seq_file *, struct vfsmount *);
- void *cached_mount;
- u64 cached_event;
- loff_t cached_index;
+ size_t filled;
};
extern const struct seq_operations mounts_op;
diff --git a/fs/namespace.c b/fs/namespace.c
index a28e4db075ed..14fdd03edd0a 100644
--- a/fs/namespace.c
+++ b/fs/namespace.c
@@ -1246,46 +1246,80 @@ struct vfsmount *mnt_clone_internal(const struct path *path)
#ifdef CONFIG_PROC_FS
/* iterator; we want it to have access to namespace_sem, thus here... */
-static void *m_start(struct seq_file *m, loff_t *pos)
+static int m_start_fill(struct seq_file *m)
{
+ int err;
+ size_t last_count;
+ char *buf;
+ struct mount *r;
struct proc_mounts *p = m->private;
+ err = -ENODATA;
+ m->count = 0;
down_read(&namespace_sem);
- if (p->cached_event == p->ns->event) {
- void *v = p->cached_mount;
- if (*pos == p->cached_index)
- return v;
- if (*pos == p->cached_index + 1) {
- v = seq_list_next(v, &p->ns->list, &p->cached_index);
- return p->cached_mount = v;
+ list_for_each_entry(r, &p->ns->list, mnt_list) {
+ last_count = m->count;
+ err = p->show(m, &r->mnt);
+ if (unlikely(err < 0))
+ break;
+ if (!seq_has_overflowed(m))
+ continue;
+
+ /* expand the buffer */
+ buf = kvmalloc(m->size + PAGE_SIZE, GFP_KERNEL);
+ if (unlikely(!buf)) {
+ err = -ENOMEM;
+ break;
+ }
+ memcpy(buf, m->buf, last_count);
+ kvfree(m->buf);
+ m->buf = buf;
+ m->size += PAGE_SIZE;
+ m->count = last_count;
+
+#if 0 /* todo: consider the limit */
+ err = p->show(m, &r->mnt);
+ if (unlikely(err < 0))
+ break;
+ else if (unlikely(seq_has_overflowed(m))) {
+ err = -EOVERFLOW;
+ break;
}
+#endif
}
+ up_read(&namespace_sem);
- p->cached_event = p->ns->event;
- p->cached_mount = seq_list_start(&p->ns->list, *pos);
- p->cached_index = *pos;
- return p->cached_mount;
+ if (!err)
+ p->filled = m->count;
+ return err;
}
-static void *m_next(struct seq_file *m, void *v, loff_t *pos)
+static void *m_start(struct seq_file *m, loff_t *pos)
{
- struct proc_mounts *p = m->private;
+ int err;
- p->cached_mount = seq_list_next(v, &p->ns->list, pos);
- p->cached_index = *pos;
- return p->cached_mount;
+ if (!*pos) {
+ err = m_start_fill(m);
+ if (unlikely(err))
+ return ERR_PTR(err);
+ }
+
+ return m_start; /* any valid pointer */
+}
+
+static void *m_next(struct seq_file *m, void *v, loff_t *pos)
+{
+ return NULL;
}
static void m_stop(struct seq_file *m, void *v)
{
- up_read(&namespace_sem);
+ /* empty */
}
static int m_show(struct seq_file *m, void *v)
{
- struct proc_mounts *p = m->private;
- struct mount *r = list_entry(v, struct mount, mnt_list);
- return p->show(m, &r->mnt);
+ return 0;
}
const struct seq_operations mounts_op = {
diff --git a/fs/proc_namespace.c b/fs/proc_namespace.c
index 273ee82d8aa9..e5b22c50ca59 100644
--- a/fs/proc_namespace.c
+++ b/fs/proc_namespace.c
@@ -279,7 +279,6 @@ static int mounts_open_common(struct inode *inode, struct file *file,
p->ns = ns;
p->root = root;
p->show = show;
- p->cached_event = ~0ULL;
return 0;
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment