]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.4-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 8 Dec 2013 20:18:03 +0000 (12:18 -0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 8 Dec 2013 20:18:03 +0000 (12:18 -0800)
added patches:
irq-enable-all-irqs-unconditionally-in-irq_resume.patch
net-update-consumers-of-msg_more-to-recognize-msg_sendpage_notlast.patch
nfsv4-update-list-of-irrecoverable-errors-on-delegreturn.patch
powerpc-gpio-fix-the-wrong-gpio-input-data-on-mpc8572-mpc8536.patch

queue-3.4/irq-enable-all-irqs-unconditionally-in-irq_resume.patch [new file with mode: 0644]
queue-3.4/net-update-consumers-of-msg_more-to-recognize-msg_sendpage_notlast.patch [new file with mode: 0644]
queue-3.4/nfsv4-update-list-of-irrecoverable-errors-on-delegreturn.patch [new file with mode: 0644]
queue-3.4/powerpc-gpio-fix-the-wrong-gpio-input-data-on-mpc8572-mpc8536.patch [new file with mode: 0644]
queue-3.4/series

diff --git a/queue-3.4/irq-enable-all-irqs-unconditionally-in-irq_resume.patch b/queue-3.4/irq-enable-all-irqs-unconditionally-in-irq_resume.patch
new file mode 100644 (file)
index 0000000..7be5c32
--- /dev/null
@@ -0,0 +1,58 @@
+From ac01810c9d2814238f08a227062e66a35a0e1ea2 Mon Sep 17 00:00:00 2001
+From: Laxman Dewangan <ldewangan@nvidia.com>
+Date: Mon, 25 Nov 2013 19:39:47 +0530
+Subject: irq: Enable all irqs unconditionally in irq_resume
+
+From: Laxman Dewangan <ldewangan@nvidia.com>
+
+commit ac01810c9d2814238f08a227062e66a35a0e1ea2 upstream.
+
+When the system enters suspend, it disables all interrupts in
+suspend_device_irqs(), including the interrupts marked EARLY_RESUME.
+
+On the resume side things are different. The EARLY_RESUME interrupts
+are reenabled in sys_core_ops->resume and the non EARLY_RESUME
+interrupts are reenabled in the normal system resume path.
+
+When suspend_noirq() failed or suspend is aborted for any other
+reason, we might omit the resume side call to sys_core_ops->resume()
+and therefor the interrupts marked EARLY_RESUME are not reenabled and
+stay disabled forever.
+
+To solve this, enable all irqs unconditionally in irq_resume()
+regardless whether interrupts marked EARLY_RESUMEhave been already
+enabled or not.
+
+This might try to reenable already enabled interrupts in the non
+failure case, but the only affected platform is XEN and it has been
+confirmed that it does not cause any side effects.
+
+[ tglx: Massaged changelog. ]
+
+Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
+Acked-by-and-tested-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
+Acked-by: Heiko Stuebner <heiko@sntech.de>
+Reviewed-by: Pavel Machek <pavel@ucw.cz>
+Cc: <ian.campbell@citrix.com>
+Cc: <rjw@rjwysocki.net>
+Cc: <len.brown@intel.com>
+Cc: <gregkh@linuxfoundation.org>
+Link: http://lkml.kernel.org/r/1385388587-16442-1-git-send-email-ldewangan@nvidia.com
+Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ kernel/irq/pm.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/kernel/irq/pm.c
++++ b/kernel/irq/pm.c
+@@ -50,7 +50,7 @@ static void resume_irqs(bool want_early)
+               bool is_early = desc->action &&
+                       desc->action->flags & IRQF_EARLY_RESUME;
+-              if (is_early != want_early)
++              if (!is_early && want_early)
+                       continue;
+               raw_spin_lock_irqsave(&desc->lock, flags);
diff --git a/queue-3.4/net-update-consumers-of-msg_more-to-recognize-msg_sendpage_notlast.patch b/queue-3.4/net-update-consumers-of-msg_more-to-recognize-msg_sendpage_notlast.patch
new file mode 100644 (file)
index 0000000..872865b
--- /dev/null
@@ -0,0 +1,71 @@
+From d3f7d56a7a4671d395e8af87071068a195257bf6 Mon Sep 17 00:00:00 2001
+From: Shawn Landden <shawn@churchofgit.com>
+Date: Sun, 24 Nov 2013 22:36:28 -0800
+Subject: net: update consumers of MSG_MORE to recognize MSG_SENDPAGE_NOTLAST
+
+From: Shawn Landden <shawn@churchofgit.com>
+
+commit d3f7d56a7a4671d395e8af87071068a195257bf6 upstream.
+
+Commit 35f9c09fe (tcp: tcp_sendpages() should call tcp_push() once)
+added an internal flag MSG_SENDPAGE_NOTLAST, similar to
+MSG_MORE.
+
+algif_hash, algif_skcipher, and udp used MSG_MORE from tcp_sendpages()
+and need to see the new flag as identical to MSG_MORE.
+
+This fixes sendfile() on AF_ALG.
+
+v3: also fix udp
+
+Cc: Tom Herbert <therbert@google.com>
+Cc: Eric Dumazet <eric.dumazet@gmail.com>
+Cc: David S. Miller <davem@davemloft.net>
+Reported-and-tested-by: Shawn Landden <shawnlandden@gmail.com>
+Original-patch: Richard Weinberger <richard@nod.at>
+Signed-off-by: Shawn Landden <shawn@churchofgit.com>
+Signed-off-by: David S. Miller <davem@davemloft.net>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ crypto/algif_hash.c     |    3 +++
+ crypto/algif_skcipher.c |    3 +++
+ net/ipv4/udp.c          |    3 +++
+ 3 files changed, 9 insertions(+)
+
+--- a/crypto/algif_hash.c
++++ b/crypto/algif_hash.c
+@@ -117,6 +117,9 @@ static ssize_t hash_sendpage(struct sock
+       if (flags & MSG_SENDPAGE_NOTLAST)
+               flags |= MSG_MORE;
++      if (flags & MSG_SENDPAGE_NOTLAST)
++              flags |= MSG_MORE;
++
+       lock_sock(sk);
+       sg_init_table(ctx->sgl.sg, 1);
+       sg_set_page(ctx->sgl.sg, page, size, offset);
+--- a/crypto/algif_skcipher.c
++++ b/crypto/algif_skcipher.c
+@@ -381,6 +381,9 @@ static ssize_t skcipher_sendpage(struct
+       if (flags & MSG_SENDPAGE_NOTLAST)
+               flags |= MSG_MORE;
++      if (flags & MSG_SENDPAGE_NOTLAST)
++              flags |= MSG_MORE;
++
+       lock_sock(sk);
+       if (!ctx->more && ctx->used)
+               goto unlock;
+--- a/net/ipv4/udp.c
++++ b/net/ipv4/udp.c
+@@ -1042,6 +1042,9 @@ int udp_sendpage(struct sock *sk, struct
+       if (flags & MSG_SENDPAGE_NOTLAST)
+               flags |= MSG_MORE;
++      if (flags & MSG_SENDPAGE_NOTLAST)
++              flags |= MSG_MORE;
++
+       if (!up->pending) {
+               struct msghdr msg = {   .msg_flags = flags|MSG_MORE };
diff --git a/queue-3.4/nfsv4-update-list-of-irrecoverable-errors-on-delegreturn.patch b/queue-3.4/nfsv4-update-list-of-irrecoverable-errors-on-delegreturn.patch
new file mode 100644 (file)
index 0000000..40e2464
--- /dev/null
@@ -0,0 +1,44 @@
+From c97cf606e43b85a6cf158b810375dd77312024db Mon Sep 17 00:00:00 2001
+From: Trond Myklebust <Trond.Myklebust@netapp.com>
+Date: Tue, 19 Nov 2013 16:34:14 -0500
+Subject: NFSv4: Update list of irrecoverable errors on DELEGRETURN
+
+From: Trond Myklebust <Trond.Myklebust@netapp.com>
+
+commit c97cf606e43b85a6cf158b810375dd77312024db upstream.
+
+If the DELEGRETURN errors out with something like NFS4ERR_BAD_STATEID
+then there is no recovery possible. Just quit without returning an error.
+
+Also, note that the client must not assume that the NFSv4 lease has been
+renewed when it sees an error on DELEGRETURN.
+
+Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ fs/nfs/nfs4proc.c |   10 ++++++++--
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
+--- a/fs/nfs/nfs4proc.c
++++ b/fs/nfs/nfs4proc.c
+@@ -4041,11 +4041,17 @@ static void nfs4_delegreturn_done(struct
+               return;
+       switch (task->tk_status) {
+-      case -NFS4ERR_STALE_STATEID:
+-      case -NFS4ERR_EXPIRED:
+       case 0:
+               renew_lease(data->res.server, data->timestamp);
+               break;
++      case -NFS4ERR_ADMIN_REVOKED:
++      case -NFS4ERR_DELEG_REVOKED:
++      case -NFS4ERR_BAD_STATEID:
++      case -NFS4ERR_OLD_STATEID:
++      case -NFS4ERR_STALE_STATEID:
++      case -NFS4ERR_EXPIRED:
++              task->tk_status = 0;
++              break;
+       default:
+               if (nfs4_async_handle_error(task, data->res.server, NULL) ==
+                               -EAGAIN) {
diff --git a/queue-3.4/powerpc-gpio-fix-the-wrong-gpio-input-data-on-mpc8572-mpc8536.patch b/queue-3.4/powerpc-gpio-fix-the-wrong-gpio-input-data-on-mpc8572-mpc8536.patch
new file mode 100644 (file)
index 0000000..0b7efcb
--- /dev/null
@@ -0,0 +1,57 @@
+From 1aeef303b5d9e243c41d5b80f8bb059366514a10 Mon Sep 17 00:00:00 2001
+From: Liu Gang <Gang.Liu@freescale.com>
+Date: Fri, 22 Nov 2013 16:12:40 +0800
+Subject: powerpc/gpio: Fix the wrong GPIO input data on MPC8572/MPC8536
+
+From: Liu Gang <Gang.Liu@freescale.com>
+
+commit 1aeef303b5d9e243c41d5b80f8bb059366514a10 upstream.
+
+For MPC8572/MPC8536, the status of GPIOs defined as output
+cannot be determined by reading GPDAT register, so the code
+use shadow data register instead. But the code may give the
+wrong status of GPIOs defined as input under some scenarios:
+
+1. If some pins were configured as inputs and were asserted
+high before booting the kernel, the shadow data has been
+initialized with those pin values.
+2. Some pins have been configured as output first and have
+been set to the high value, then reconfigured as input.
+
+The above cases will make the shadow data for those input
+pins to be set to high. Then reading the pin status will
+always return high even if the actual pin status is low.
+
+The code should eliminate the effects of the shadow data to
+the input pins, and the status of those pins should be
+read directly from GPDAT.
+
+Acked-by: Scott Wood <scottwood@freescale.com>
+Acked-by: Anatolij Gustschin <agust@denx.de>
+Signed-off-by: Liu Gang <Gang.Liu@freescale.com>
+Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/gpio/gpio-mpc8xxx.c |    8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
+
+--- a/drivers/gpio/gpio-mpc8xxx.c
++++ b/drivers/gpio/gpio-mpc8xxx.c
+@@ -69,10 +69,14 @@ static int mpc8572_gpio_get(struct gpio_
+       u32 val;
+       struct of_mm_gpio_chip *mm = to_of_mm_gpio_chip(gc);
+       struct mpc8xxx_gpio_chip *mpc8xxx_gc = to_mpc8xxx_gpio_chip(mm);
++      u32 out_mask, out_shadow;
+-      val = in_be32(mm->regs + GPIO_DAT) & ~in_be32(mm->regs + GPIO_DIR);
++      out_mask = in_be32(mm->regs + GPIO_DIR);
+-      return (val | mpc8xxx_gc->data) & mpc8xxx_gpio2mask(gpio);
++      val = in_be32(mm->regs + GPIO_DAT) & ~out_mask;
++      out_shadow = mpc8xxx_gc->data & out_mask;
++
++      return (val | out_shadow) & mpc8xxx_gpio2mask(gpio);
+ }
+ static int mpc8xxx_gpio_get(struct gpio_chip *gc, unsigned int gpio)
index 2133c8dea2f465bbfa7479e58f9c361691e51ee2..d55b216e7f0c94a2a3c9ef8657fef304bc770ac0 100644 (file)
@@ -8,3 +8,7 @@ scsi-libsas-fix-usage-of-ata_tf_to_fis.patch
 scsi-hpsa-do-not-discard-scsi-status-on-aborted-commands.patch
 scsi-hpsa-return-0-from-driver-probe-function-on-success-not-1.patch
 net-smc91-fix-crash-regression-on-the-versatile.patch
+nfsv4-update-list-of-irrecoverable-errors-on-delegreturn.patch
+powerpc-gpio-fix-the-wrong-gpio-input-data-on-mpc8572-mpc8536.patch
+irq-enable-all-irqs-unconditionally-in-irq_resume.patch
+net-update-consumers-of-msg_more-to-recognize-msg_sendpage_notlast.patch