mbox series

[0/4] pci: Fix some section mismatches

Message ID 20231001170254.2506508-1-u.kleine-koenig@pengutronix.de (mailing list archive)
Headers show
Series pci: Fix some section mismatches | expand

Message

Uwe Kleine-König Oct. 1, 2023, 5:02 p.m. UTC
Hello,

modpost checks about section mismatches are about to get stronger, see
https://lore.kernel.org/linux-kbuild/20230930165204.2478282-1-u.kleine-koenig@pengutronix.de
.

With the above patch applied, enabling the exynos and kirin drivers as
modules result in a warning about their remove functions that is fixed
here. The keystone driver is a bit special as it can only be enabled
built-in and used __refdata on its driver struct. It also had a similar
issue for .probe fixed in the last patch.

IMHO all four patches qualify for backporting to stable.

Best regards
Uwe

Uwe Kleine-König (4):
  PCI: exynos: Don't put .remove callback in .exit.text section
  PCI: kirin: Don't put .remove callback in .exit.text section
  PCI: keystone: Don't put .remove callback in .exit.text section
  PCI: keystone: Don't put .probe callback in .init.text section

 drivers/pci/controller/dwc/pci-exynos.c   | 4 ++--
 drivers/pci/controller/dwc/pci-keystone.c | 8 ++++----
 drivers/pci/controller/dwc/pcie-kirin.c   | 4 ++--
 3 files changed, 8 insertions(+), 8 deletions(-)

base-commit: 6465e260f48790807eef06b583b38ca9789b6072

Comments

Bjorn Helgaas Oct. 10, 2023, 5:23 p.m. UTC | #1
On Sun, Oct 01, 2023 at 07:02:50PM +0200, Uwe Kleine-König wrote:
> Hello,
> 
> modpost checks about section mismatches are about to get stronger, see
> https://lore.kernel.org/linux-kbuild/20230930165204.2478282-1-u.kleine-koenig@pengutronix.de
> .
> 
> With the above patch applied, enabling the exynos and kirin drivers as
> modules result in a warning about their remove functions that is fixed
> here. The keystone driver is a bit special as it can only be enabled
> built-in and used __refdata on its driver struct. It also had a similar
> issue for .probe fixed in the last patch.
> 
> IMHO all four patches qualify for backporting to stable.

I added stable tags and applied to pci/enumeration for v6.7, thanks!

> Uwe Kleine-König (4):
>   PCI: exynos: Don't put .remove callback in .exit.text section
>   PCI: kirin: Don't put .remove callback in .exit.text section
>   PCI: keystone: Don't put .remove callback in .exit.text section
>   PCI: keystone: Don't put .probe callback in .init.text section

I updated the subjects to be "Don't discard ... callback" to try to
give a little more semantic context.

>  drivers/pci/controller/dwc/pci-exynos.c   | 4 ++--
>  drivers/pci/controller/dwc/pci-keystone.c | 8 ++++----
>  drivers/pci/controller/dwc/pcie-kirin.c   | 4 ++--
>  3 files changed, 8 insertions(+), 8 deletions(-)
> 
> base-commit: 6465e260f48790807eef06b583b38ca9789b6072
> -- 
> 2.40.1
> 
> 
> _______________________________________________
> linux-arm-kernel mailing list
> linux-arm-kernel@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-arm-kernel