]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
drop some 5.10 patches and refresh others
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Sep 2021 09:06:53 +0000 (11:06 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 22 Sep 2021 09:06:53 +0000 (11:06 +0200)
queue-5.10/gpio-mpc8xxx-fix-a-potential-double-iounmap-call-in-.patch [deleted file]
queue-5.10/gpio-mpc8xxx-fix-a-resources-leak-in-the-error-handl.patch
queue-5.10/gpio-mpc8xxx-use-devm_gpiochip_add_data-to-simplify-.patch
queue-5.10/net-phylink-add-suspend-resume-support.patch [deleted file]
queue-5.10/series

diff --git a/queue-5.10/gpio-mpc8xxx-fix-a-potential-double-iounmap-call-in-.patch b/queue-5.10/gpio-mpc8xxx-fix-a-potential-double-iounmap-call-in-.patch
deleted file mode 100644 (file)
index aa4066b..0000000
+++ /dev/null
@@ -1,80 +0,0 @@
-From d3901a8c18684cfbe6927a99776907163fe9e36f Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Fri, 20 Aug 2021 17:38:03 +0200
-Subject: gpio: mpc8xxx: Fix a potential double iounmap call in
- 'mpc8xxx_probe()'
-
-From: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
-
-[ Upstream commit 7d6588931ccd4c09e70a08175cf2e0cf7fc3b869 ]
-
-Commit 76c47d1449fc ("gpio: mpc8xxx: Add ACPI support") has switched to a
-managed version when dealing with 'mpc8xxx_gc->regs'. So the corresponding
-'iounmap()' call in the error handling path and in the remove should be
-removed to avoid a double unmap.
-
-This also allows some simplification in the probe. All the error handling
-paths related to managed resources can be direct returns and a NULL check
-in what remains in the error handling path can be removed.
-
-Fixes: 76c47d1449fc ("gpio: mpc8xxx: Add ACPI support")
-Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
-Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- drivers/gpio/gpio-mpc8xxx.c | 11 ++++-------
- 1 file changed, 4 insertions(+), 7 deletions(-)
-
-diff --git a/drivers/gpio/gpio-mpc8xxx.c b/drivers/gpio/gpio-mpc8xxx.c
-index 5b2a919a6644..a4983c5d1f16 100644
---- a/drivers/gpio/gpio-mpc8xxx.c
-+++ b/drivers/gpio/gpio-mpc8xxx.c
-@@ -329,7 +329,7 @@ static int mpc8xxx_probe(struct platform_device *pdev)
-                                mpc8xxx_gc->regs + GPIO_DIR, NULL,
-                                BGPIOF_BIG_ENDIAN);
-               if (ret)
--                      goto err;
-+                      return ret;
-               dev_dbg(&pdev->dev, "GPIO registers are LITTLE endian\n");
-       } else {
-               ret = bgpio_init(gc, &pdev->dev, 4,
-@@ -339,7 +339,7 @@ static int mpc8xxx_probe(struct platform_device *pdev)
-                                BGPIOF_BIG_ENDIAN
-                                | BGPIOF_BIG_ENDIAN_BYTE_ORDER);
-               if (ret)
--                      goto err;
-+                      return ret;
-               dev_dbg(&pdev->dev, "GPIO registers are BIG endian\n");
-       }
-@@ -378,7 +378,7 @@ static int mpc8xxx_probe(struct platform_device *pdev)
-       if (ret) {
-               pr_err("%pOF: GPIO chip registration failed with status %d\n",
-                      np, ret);
--              goto err;
-+              return ret;
-       }
-       mpc8xxx_gc->irqn = irq_of_parse_and_map(np, 0);
-@@ -406,9 +406,7 @@ static int mpc8xxx_probe(struct platform_device *pdev)
-       return 0;
- err:
--      if (mpc8xxx_gc->irq)
--              irq_domain_remove(mpc8xxx_gc->irq);
--      iounmap(mpc8xxx_gc->regs);
-+      irq_domain_remove(mpc8xxx_gc->irq);
-       return ret;
- }
-@@ -422,7 +420,6 @@ static int mpc8xxx_remove(struct platform_device *pdev)
-       }
-       gpiochip_remove(&mpc8xxx_gc->gc);
--      iounmap(mpc8xxx_gc->regs);
-       return 0;
- }
--- 
-2.30.2
-
index df3996ffb2d3a8f8b7c2c02f56f90527aa31978f..fca52fee187d9da87ac19ac8d170e262b3c82ef2 100644 (file)
@@ -20,14 +20,12 @@ Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
 Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
 Signed-off-by: Sasha Levin <sashal@kernel.org>
 ---
- drivers/gpio/gpio-mpc8xxx.c | 2 ++
+ drivers/gpio/gpio-mpc8xxx.c |    2 ++
  1 file changed, 2 insertions(+)
 
-diff --git a/drivers/gpio/gpio-mpc8xxx.c b/drivers/gpio/gpio-mpc8xxx.c
-index 3c2fa44d9279..5b2a919a6644 100644
 --- a/drivers/gpio/gpio-mpc8xxx.c
 +++ b/drivers/gpio/gpio-mpc8xxx.c
-@@ -406,6 +406,8 @@ static int mpc8xxx_probe(struct platform_device *pdev)
+@@ -406,6 +406,8 @@ static int mpc8xxx_probe(struct platform
  
        return 0;
  err:
@@ -36,6 +34,3 @@ index 3c2fa44d9279..5b2a919a6644 100644
        iounmap(mpc8xxx_gc->regs);
        return ret;
  }
--- 
-2.30.2
-
index b82d768764bd94f6ec239481c9e49d420c9939fa..36ecfa2ac3d636cf198ccaee43ace93d0730672b 100644 (file)
@@ -19,14 +19,12 @@ Signed-off-by: Christophe JAILLET <christophe.jaillet@wanadoo.fr>
 Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
 Signed-off-by: Sasha Levin <sashal@kernel.org>
 ---
- drivers/gpio/gpio-mpc8xxx.c | 4 +---
- 1 file changed, 1 insertion(+), 3 deletions(-)
+ drivers/gpio/gpio-mpc8xxx.c |    3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
 
-diff --git a/drivers/gpio/gpio-mpc8xxx.c b/drivers/gpio/gpio-mpc8xxx.c
-index a4983c5d1f16..023b99bf098d 100644
 --- a/drivers/gpio/gpio-mpc8xxx.c
 +++ b/drivers/gpio/gpio-mpc8xxx.c
-@@ -374,7 +374,7 @@ static int mpc8xxx_probe(struct platform_device *pdev)
+@@ -374,7 +374,7 @@ static int mpc8xxx_probe(struct platform
            of_device_is_compatible(np, "fsl,ls1088a-gpio"))
                gc->write_reg(mpc8xxx_gc->regs + GPIO_IBE, 0xffffffff);
  
@@ -35,15 +33,11 @@ index a4983c5d1f16..023b99bf098d 100644
        if (ret) {
                pr_err("%pOF: GPIO chip registration failed with status %d\n",
                       np, ret);
-@@ -419,8 +419,6 @@ static int mpc8xxx_remove(struct platform_device *pdev)
+@@ -421,7 +421,6 @@ static int mpc8xxx_remove(struct platfor
                irq_domain_remove(mpc8xxx_gc->irq);
        }
  
 -      gpiochip_remove(&mpc8xxx_gc->gc);
--
-       return 0;
- }
+       iounmap(mpc8xxx_gc->regs);
  
--- 
-2.30.2
-
+       return 0;
diff --git a/queue-5.10/net-phylink-add-suspend-resume-support.patch b/queue-5.10/net-phylink-add-suspend-resume-support.patch
deleted file mode 100644 (file)
index 6d588db..0000000
+++ /dev/null
@@ -1,153 +0,0 @@
-From eacd3bf0ecf7e9adc1b1e573394e77907b7b4eb4 Mon Sep 17 00:00:00 2001
-From: Sasha Levin <sashal@kernel.org>
-Date: Tue, 7 Sep 2021 18:56:46 +0800
-Subject: net: phylink: add suspend/resume support
-
-From: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
-
-[ Upstream commit f97493657c6372eeefe70faadd214bf31488c44e ]
-
-Joakim Zhang reports that Wake-on-Lan with the stmmac ethernet driver broke
-when moving the incorrect handling of mac link state out of mac_config().
-This reason this breaks is because the stmmac's WoL is handled by the MAC
-rather than the PHY, and phylink doesn't cater for that scenario.
-
-This patch adds the necessary phylink code to handle suspend/resume events
-according to whether the MAC still needs a valid link or not. This is the
-barest minimum for this support.
-
-Reported-by: Joakim Zhang <qiangqing.zhang@nxp.com>
-Tested-by: Joakim Zhang <qiangqing.zhang@nxp.com>
-Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
-Signed-off-by: Joakim Zhang <qiangqing.zhang@nxp.com>
-Signed-off-by: David S. Miller <davem@davemloft.net>
-Signed-off-by: Sasha Levin <sashal@kernel.org>
----
- drivers/net/phy/phylink.c | 82 +++++++++++++++++++++++++++++++++++++++
- include/linux/phylink.h   |  3 ++
- 2 files changed, 85 insertions(+)
-
-diff --git a/drivers/net/phy/phylink.c b/drivers/net/phy/phylink.c
-index 6072e87ed6c3..42826ce0e0bf 100644
---- a/drivers/net/phy/phylink.c
-+++ b/drivers/net/phy/phylink.c
-@@ -32,6 +32,7 @@
- enum {
-       PHYLINK_DISABLE_STOPPED,
-       PHYLINK_DISABLE_LINK,
-+      PHYLINK_DISABLE_MAC_WOL,
- };
- /**
-@@ -1251,6 +1252,9 @@ EXPORT_SYMBOL_GPL(phylink_start);
-  * network device driver's &struct net_device_ops ndo_stop() method.  The
-  * network device's carrier state should not be changed prior to calling this
-  * function.
-+ *
-+ * This will synchronously bring down the link if the link is not already
-+ * down (in other words, it will trigger a mac_link_down() method call.)
-  */
- void phylink_stop(struct phylink *pl)
- {
-@@ -1270,6 +1274,84 @@ void phylink_stop(struct phylink *pl)
- }
- EXPORT_SYMBOL_GPL(phylink_stop);
-+/**
-+ * phylink_suspend() - handle a network device suspend event
-+ * @pl: a pointer to a &struct phylink returned from phylink_create()
-+ * @mac_wol: true if the MAC needs to receive packets for Wake-on-Lan
-+ *
-+ * Handle a network device suspend event. There are several cases:
-+ * - If Wake-on-Lan is not active, we can bring down the link between
-+ *   the MAC and PHY by calling phylink_stop().
-+ * - If Wake-on-Lan is active, and being handled only by the PHY, we
-+ *   can also bring down the link between the MAC and PHY.
-+ * - If Wake-on-Lan is active, but being handled by the MAC, the MAC
-+ *   still needs to receive packets, so we can not bring the link down.
-+ */
-+void phylink_suspend(struct phylink *pl, bool mac_wol)
-+{
-+      ASSERT_RTNL();
-+
-+      if (mac_wol && (!pl->netdev || pl->netdev->wol_enabled)) {
-+              /* Wake-on-Lan enabled, MAC handling */
-+              mutex_lock(&pl->state_mutex);
-+
-+              /* Stop the resolver bringing the link up */
-+              __set_bit(PHYLINK_DISABLE_MAC_WOL, &pl->phylink_disable_state);
-+
-+              /* Disable the carrier, to prevent transmit timeouts,
-+               * but one would hope all packets have been sent. This
-+               * also means phylink_resolve() will do nothing.
-+               */
-+              netif_carrier_off(pl->netdev);
-+
-+              /* We do not call mac_link_down() here as we want the
-+               * link to remain up to receive the WoL packets.
-+               */
-+              mutex_unlock(&pl->state_mutex);
-+      } else {
-+              phylink_stop(pl);
-+      }
-+}
-+EXPORT_SYMBOL_GPL(phylink_suspend);
-+
-+/**
-+ * phylink_resume() - handle a network device resume event
-+ * @pl: a pointer to a &struct phylink returned from phylink_create()
-+ *
-+ * Undo the effects of phylink_suspend(), returning the link to an
-+ * operational state.
-+ */
-+void phylink_resume(struct phylink *pl)
-+{
-+      ASSERT_RTNL();
-+
-+      if (test_bit(PHYLINK_DISABLE_MAC_WOL, &pl->phylink_disable_state)) {
-+              /* Wake-on-Lan enabled, MAC handling */
-+
-+              /* Call mac_link_down() so we keep the overall state balanced.
-+               * Do this under the state_mutex lock for consistency. This
-+               * will cause a "Link Down" message to be printed during
-+               * resume, which is harmless - the true link state will be
-+               * printed when we run a resolve.
-+               */
-+              mutex_lock(&pl->state_mutex);
-+              phylink_link_down(pl);
-+              mutex_unlock(&pl->state_mutex);
-+
-+              /* Re-apply the link parameters so that all the settings get
-+               * restored to the MAC.
-+               */
-+              phylink_mac_initial_config(pl, true);
-+
-+              /* Re-enable and re-resolve the link parameters */
-+              clear_bit(PHYLINK_DISABLE_MAC_WOL, &pl->phylink_disable_state);
-+              phylink_run_resolve(pl);
-+      } else {
-+              phylink_start(pl);
-+      }
-+}
-+EXPORT_SYMBOL_GPL(phylink_resume);
-+
- /**
-  * phylink_ethtool_get_wol() - get the wake on lan parameters for the PHY
-  * @pl: a pointer to a &struct phylink returned from phylink_create()
-diff --git a/include/linux/phylink.h b/include/linux/phylink.h
-index d81a714cfbbd..ff56e3e373f0 100644
---- a/include/linux/phylink.h
-+++ b/include/linux/phylink.h
-@@ -446,6 +446,9 @@ void phylink_mac_change(struct phylink *, bool up);
- void phylink_start(struct phylink *);
- void phylink_stop(struct phylink *);
-+void phylink_suspend(struct phylink *pl, bool mac_wol);
-+void phylink_resume(struct phylink *pl);
-+
- void phylink_ethtool_get_wol(struct phylink *, struct ethtool_wolinfo *);
- int phylink_ethtool_set_wol(struct phylink *, struct ethtool_wolinfo *);
--- 
-2.30.2
-
index cdbc6e1da6ff30acdf4fb9255b21554023f774ab..56ccfffa876c4e95e9c8da935d85e0ef078b5107 100644 (file)
@@ -76,7 +76,6 @@ pci-ibmphp-fix-double-unmap-of-io_mem.patch
 ethtool-fix-an-error-code-in-cxgb2.c.patch
 ntb-fix-an-error-code-in-ntb_msit_probe.patch
 ntb-perf-fix-an-error-code-in-perf_setup_inbuf.patch
-net-phylink-add-suspend-resume-support.patch
 s390-bpf-fix-optimizing-out-zero-extensions.patch
 s390-bpf-fix-64-bit-subtraction-of-the-0x80000000-constant.patch
 s390-bpf-fix-branch-shortening-during-codegen-pass.patch
@@ -100,7 +99,6 @@ arc-export-clear_user_page-for-modules.patch
 perf-unwind-do-not-overwrite-feature_check_ldflags-l.patch
 perf-bench-inject-buildid-handle-writen-errors.patch
 gpio-mpc8xxx-fix-a-resources-leak-in-the-error-handl.patch
-gpio-mpc8xxx-fix-a-potential-double-iounmap-call-in-.patch
 gpio-mpc8xxx-use-devm_gpiochip_add_data-to-simplify-.patch
 net-dsa-tag_rtl4_a-fix-egress-tags.patch
 selftests-mptcp-clean-tmp-files-in-simult_flows.patch