* [PATCH 5.4] PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()
@ 2023-11-29 0:35 Nathan Chancellor
2023-11-29 9:46 ` Uwe Kleine-König
` (2 more replies)
0 siblings, 3 replies; 4+ messages in thread
From: Nathan Chancellor @ 2023-11-29 0:35 UTC (permalink / raw)
To: gregkh, sashal
Cc: u.kleine-koenig, bhelgaas, llvm, stable, Naresh Kamboju,
Nathan Chancellor
This commit has no upstream equivalent.
After commit 012dba0ab814 ("PCI: keystone: Don't discard .probe()
callback") in 5.4, there are two modpost warnings when building with
clang:
WARNING: modpost: vmlinux.o(.text+0x5aa6dc): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_port()
The function ks_pcie_probe() references
the function __init ks_pcie_add_pcie_port().
This is often because ks_pcie_probe lacks a __init
annotation or the annotation of ks_pcie_add_pcie_port is wrong.
WARNING: modpost: vmlinux.o(.text+0x5aa6f4): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_ep()
The function ks_pcie_probe() references
the function __init ks_pcie_add_pcie_ep().
This is often because ks_pcie_probe lacks a __init
annotation or the annotation of ks_pcie_add_pcie_ep is wrong.
ks_pcie_add_pcie_ep() was removed in upstream commit a0fd361db8e5 ("PCI:
dwc: Move "dbi", "dbi2", and "addr_space" resource setup into common
code") and ks_pcie_add_pcie_port() was removed in upstream
commit 60f5b73fa0f2 ("PCI: dwc: Remove unnecessary wrappers around
dw_pcie_host_init()"), both of which happened before upstream
commit 7994db905c0f ("PCI: keystone: Don't discard .probe() callback").
As neither of these removal changes are really suitable for stable, just
remove __init from these functions in stable, as it is no longer a
correct annotation after dropping __init from ks_pcie_probe().
Fixes: 012dba0ab814 ("PCI: keystone: Don't discard .probe() callback")
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
---
This is not an issue in mainline but I still cc'd the author and
committer of 7994db905c0f in case they would like to check my analysis.
---
drivers/pci/controller/dwc/pci-keystone.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/pci/controller/dwc/pci-keystone.c b/drivers/pci/controller/dwc/pci-keystone.c
index ddbb2b3db74a..920444b1cfc7 100644
--- a/drivers/pci/controller/dwc/pci-keystone.c
+++ b/drivers/pci/controller/dwc/pci-keystone.c
@@ -861,8 +861,8 @@ static irqreturn_t ks_pcie_err_irq_handler(int irq, void *priv)
return ks_pcie_handle_error_irq(ks_pcie);
}
-static int __init ks_pcie_add_pcie_port(struct keystone_pcie *ks_pcie,
- struct platform_device *pdev)
+static int ks_pcie_add_pcie_port(struct keystone_pcie *ks_pcie,
+ struct platform_device *pdev)
{
struct dw_pcie *pci = ks_pcie->pci;
struct pcie_port *pp = &pci->pp;
@@ -992,8 +992,8 @@ static const struct dw_pcie_ep_ops ks_pcie_am654_ep_ops = {
.get_features = &ks_pcie_am654_get_features,
};
-static int __init ks_pcie_add_pcie_ep(struct keystone_pcie *ks_pcie,
- struct platform_device *pdev)
+static int ks_pcie_add_pcie_ep(struct keystone_pcie *ks_pcie,
+ struct platform_device *pdev)
{
int ret;
struct dw_pcie_ep *ep;
---
base-commit: 8e221b47173d59e1b2877f6d8dc91e8be2031746
change-id: 20231128-5-4-fix-pci-keystone-modpost-warning-2a8a9c3fa1ca
Best regards,
--
Nathan Chancellor <nathan@kernel.org>
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH 5.4] PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()
2023-11-29 0:35 [PATCH 5.4] PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}() Nathan Chancellor
@ 2023-11-29 9:46 ` Uwe Kleine-König
2023-11-30 13:28 ` Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.4-stable tree gregkh
2023-11-30 13:29 ` Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.10-stable tree gregkh
2 siblings, 0 replies; 4+ messages in thread
From: Uwe Kleine-König @ 2023-11-29 9:46 UTC (permalink / raw)
To: Nathan Chancellor; +Cc: gregkh, sashal, bhelgaas, llvm, stable, Naresh Kamboju
[-- Attachment #1: Type: text/plain, Size: 2144 bytes --]
On Tue, Nov 28, 2023 at 05:35:17PM -0700, Nathan Chancellor wrote:
> This commit has no upstream equivalent.
>
> After commit 012dba0ab814 ("PCI: keystone: Don't discard .probe()
> callback") in 5.4, there are two modpost warnings when building with
I'd do s/5.4/5.4.262/ here.
> clang:
>
> WARNING: modpost: vmlinux.o(.text+0x5aa6dc): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_port()
> The function ks_pcie_probe() references
> the function __init ks_pcie_add_pcie_port().
> This is often because ks_pcie_probe lacks a __init
> annotation or the annotation of ks_pcie_add_pcie_port is wrong.
>
> WARNING: modpost: vmlinux.o(.text+0x5aa6f4): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_ep()
> The function ks_pcie_probe() references
> the function __init ks_pcie_add_pcie_ep().
> This is often because ks_pcie_probe lacks a __init
> annotation or the annotation of ks_pcie_add_pcie_ep is wrong.
>
> ks_pcie_add_pcie_ep() was removed in upstream commit a0fd361db8e5 ("PCI:
> dwc: Move "dbi", "dbi2", and "addr_space" resource setup into common
> code") and ks_pcie_add_pcie_port() was removed in upstream
> commit 60f5b73fa0f2 ("PCI: dwc: Remove unnecessary wrappers around
> dw_pcie_host_init()"), both of which happened before upstream
> commit 7994db905c0f ("PCI: keystone: Don't discard .probe() callback").
>
> As neither of these removal changes are really suitable for stable, just
> remove __init from these functions in stable, as it is no longer a
> correct annotation after dropping __init from ks_pcie_probe().
>
> Fixes: 012dba0ab814 ("PCI: keystone: Don't discard .probe() callback")
> Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
> Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Reviewed-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thanks
Uwe
--
Pengutronix e.K. | Uwe Kleine-König |
Industrial Linux Solutions | https://www.pengutronix.de/ |
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
^ permalink raw reply [flat|nested] 4+ messages in thread
* Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.4-stable tree
2023-11-29 0:35 [PATCH 5.4] PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}() Nathan Chancellor
2023-11-29 9:46 ` Uwe Kleine-König
@ 2023-11-30 13:28 ` gregkh
2023-11-30 13:29 ` Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.10-stable tree gregkh
2 siblings, 0 replies; 4+ messages in thread
From: gregkh @ 2023-11-30 13:28 UTC (permalink / raw)
To: bhelgaas, gregkh, llvm, naresh.kamboju, nathan, sashal,
u.kleine-koenig
Cc: stable-commits
This is a note to let you know that I've just added the patch titled
PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()
to the 5.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
pci-keystone-drop-__init-from-ks_pcie_add_pcie_-ep-port.patch
and it can be found in the queue-5.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
From nathan@kernel.org Thu Nov 30 13:23:28 2023
From: Nathan Chancellor <nathan@kernel.org>
Date: Tue, 28 Nov 2023 17:35:17 -0700
Subject: PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()
To: gregkh@linuxfoundation.org, sashal@kernel.org
Cc: u.kleine-koenig@pengutronix.de, bhelgaas@google.com, llvm@lists.linux.dev, stable@vger.kernel.org, Naresh Kamboju <naresh.kamboju@linaro.org>, Nathan Chancellor <nathan@kernel.org>
Message-ID: <20231128-5-4-fix-pci-keystone-modpost-warning-v1-1-a999b944ac81@kernel.org>
From: Nathan Chancellor <nathan@kernel.org>
This commit has no upstream equivalent.
After commit 012dba0ab814 ("PCI: keystone: Don't discard .probe()
callback") in 5.4.262, there are two modpost warnings when building with
clang:
WARNING: modpost: vmlinux.o(.text+0x5aa6dc): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_port()
The function ks_pcie_probe() references
the function __init ks_pcie_add_pcie_port().
This is often because ks_pcie_probe lacks a __init
annotation or the annotation of ks_pcie_add_pcie_port is wrong.
WARNING: modpost: vmlinux.o(.text+0x5aa6f4): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_ep()
The function ks_pcie_probe() references
the function __init ks_pcie_add_pcie_ep().
This is often because ks_pcie_probe lacks a __init
annotation or the annotation of ks_pcie_add_pcie_ep is wrong.
ks_pcie_add_pcie_ep() was removed in upstream commit a0fd361db8e5 ("PCI:
dwc: Move "dbi", "dbi2", and "addr_space" resource setup into common
code") and ks_pcie_add_pcie_port() was removed in upstream
commit 60f5b73fa0f2 ("PCI: dwc: Remove unnecessary wrappers around
dw_pcie_host_init()"), both of which happened before upstream
commit 7994db905c0f ("PCI: keystone: Don't discard .probe() callback").
As neither of these removal changes are really suitable for stable, just
remove __init from these functions in stable, as it is no longer a
correct annotation after dropping __init from ks_pcie_probe().
Fixes: 012dba0ab814 ("PCI: keystone: Don't discard .probe() callback")
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Reviewed-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/pci/controller/dwc/pci-keystone.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
--- a/drivers/pci/controller/dwc/pci-keystone.c
+++ b/drivers/pci/controller/dwc/pci-keystone.c
@@ -861,8 +861,8 @@ static irqreturn_t ks_pcie_err_irq_handl
return ks_pcie_handle_error_irq(ks_pcie);
}
-static int __init ks_pcie_add_pcie_port(struct keystone_pcie *ks_pcie,
- struct platform_device *pdev)
+static int ks_pcie_add_pcie_port(struct keystone_pcie *ks_pcie,
+ struct platform_device *pdev)
{
struct dw_pcie *pci = ks_pcie->pci;
struct pcie_port *pp = &pci->pp;
@@ -992,8 +992,8 @@ static const struct dw_pcie_ep_ops ks_pc
.get_features = &ks_pcie_am654_get_features,
};
-static int __init ks_pcie_add_pcie_ep(struct keystone_pcie *ks_pcie,
- struct platform_device *pdev)
+static int ks_pcie_add_pcie_ep(struct keystone_pcie *ks_pcie,
+ struct platform_device *pdev)
{
int ret;
struct dw_pcie_ep *ep;
Patches currently in stable-queue which might be from nathan@kernel.org are
queue-5.4/pci-keystone-drop-__init-from-ks_pcie_add_pcie_-ep-port.patch
^ permalink raw reply [flat|nested] 4+ messages in thread
* Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.10-stable tree
2023-11-29 0:35 [PATCH 5.4] PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}() Nathan Chancellor
2023-11-29 9:46 ` Uwe Kleine-König
2023-11-30 13:28 ` Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.4-stable tree gregkh
@ 2023-11-30 13:29 ` gregkh
2 siblings, 0 replies; 4+ messages in thread
From: gregkh @ 2023-11-30 13:29 UTC (permalink / raw)
To: bhelgaas, gregkh, llvm, naresh.kamboju, nathan, sashal,
u.kleine-koenig
Cc: stable-commits
This is a note to let you know that I've just added the patch titled
PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()
to the 5.10-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
pci-keystone-drop-__init-from-ks_pcie_add_pcie_-ep-port.patch
and it can be found in the queue-5.10 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree,
please let <stable@vger.kernel.org> know about it.
From nathan@kernel.org Thu Nov 30 13:23:28 2023
From: Nathan Chancellor <nathan@kernel.org>
Date: Tue, 28 Nov 2023 17:35:17 -0700
Subject: PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()
To: gregkh@linuxfoundation.org, sashal@kernel.org
Cc: u.kleine-koenig@pengutronix.de, bhelgaas@google.com, llvm@lists.linux.dev, stable@vger.kernel.org, Naresh Kamboju <naresh.kamboju@linaro.org>, Nathan Chancellor <nathan@kernel.org>
Message-ID: <20231128-5-4-fix-pci-keystone-modpost-warning-v1-1-a999b944ac81@kernel.org>
From: Nathan Chancellor <nathan@kernel.org>
This commit has no upstream equivalent.
After commit db5ebaeb8fda ("PCI: keystone: Don't discard .probe()
callback") in 5.10.202, there are two modpost warnings when building with
clang:
WARNING: modpost: vmlinux.o(.text+0x5aa6dc): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_port()
The function ks_pcie_probe() references
the function __init ks_pcie_add_pcie_port().
This is often because ks_pcie_probe lacks a __init
annotation or the annotation of ks_pcie_add_pcie_port is wrong.
WARNING: modpost: vmlinux.o(.text+0x5aa6f4): Section mismatch in reference from the function ks_pcie_probe() to the function .init.text:ks_pcie_add_pcie_ep()
The function ks_pcie_probe() references
the function __init ks_pcie_add_pcie_ep().
This is often because ks_pcie_probe lacks a __init
annotation or the annotation of ks_pcie_add_pcie_ep is wrong.
ks_pcie_add_pcie_ep() was removed in upstream commit a0fd361db8e5 ("PCI:
dwc: Move "dbi", "dbi2", and "addr_space" resource setup into common
code") and ks_pcie_add_pcie_port() was removed in upstream
commit 60f5b73fa0f2 ("PCI: dwc: Remove unnecessary wrappers around
dw_pcie_host_init()"), both of which happened before upstream
commit 7994db905c0f ("PCI: keystone: Don't discard .probe() callback").
As neither of these removal changes are really suitable for stable, just
remove __init from these functions in stable, as it is no longer a
correct annotation after dropping __init from ks_pcie_probe().
Fixes: 012dba0ab814 ("PCI: keystone: Don't discard .probe() callback")
Reported-by: Naresh Kamboju <naresh.kamboju@linaro.org>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Reviewed-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
drivers/pci/controller/dwc/pci-keystone.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
--- a/drivers/pci/controller/dwc/pci-keystone.c
+++ b/drivers/pci/controller/dwc/pci-keystone.c
@@ -865,8 +865,8 @@ static irqreturn_t ks_pcie_err_irq_handl
return ks_pcie_handle_error_irq(ks_pcie);
}
-static int __init ks_pcie_add_pcie_port(struct keystone_pcie *ks_pcie,
- struct platform_device *pdev)
+static int ks_pcie_add_pcie_port(struct keystone_pcie *ks_pcie,
+ struct platform_device *pdev)
{
struct dw_pcie *pci = ks_pcie->pci;
struct pcie_port *pp = &pci->pp;
@@ -978,8 +978,8 @@ static const struct dw_pcie_ep_ops ks_pc
.get_features = &ks_pcie_am654_get_features,
};
-static int __init ks_pcie_add_pcie_ep(struct keystone_pcie *ks_pcie,
- struct platform_device *pdev)
+static int ks_pcie_add_pcie_ep(struct keystone_pcie *ks_pcie,
+ struct platform_device *pdev)
{
int ret;
struct dw_pcie_ep *ep;
Patches currently in stable-queue which might be from nathan@kernel.org are
queue-5.10/pci-keystone-drop-__init-from-ks_pcie_add_pcie_-ep-port.patch
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-11-30 13:29 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-11-29 0:35 [PATCH 5.4] PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}() Nathan Chancellor
2023-11-29 9:46 ` Uwe Kleine-König
2023-11-30 13:28 ` Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.4-stable tree gregkh
2023-11-30 13:29 ` Patch "PCI: keystone: Drop __init from ks_pcie_add_pcie_{ep,port}()" has been added to the 5.10-stable tree gregkh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox