linux-pci.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] PCI: dra7xx: Add __init annotation to dra7xx_add_pcie_port()
@ 2014-11-06  5:37 Jingoo Han
  2014-11-13 16:51 ` Bjorn Helgaas
  0 siblings, 1 reply; 3+ messages in thread
From: Jingoo Han @ 2014-11-06  5:37 UTC (permalink / raw)
  To: 'Bjorn Helgaas'
  Cc: linux-pci, 'Kishon Vijay Abraham I', 'Jingoo Han'

Add __init annotation to dra7xx_add_pcie_port(), because
the dra7xx_add_pcie_port() is called only by dra7xx_pcie_probe()
that was already marked as __init. Also, this patch fixes
section mismatch warning.

WARNING: drivers/pci/host/built-in.o(.text.unlikely+0xcc): Section mismatch in reference from the function dra7xx_add_pcie_port() to
the function .init.text:dw_pcie_host_init()
The function dra7xx_add_pcie_port() references
the function __init dw_pcie_host_init().
This is often because dra7xx_add_pcie_port lacks a __init
annotation or the annotation of dw_pcie_host_init is wrong.

Signed-off-by: Jingoo Han <jg1.han@samsung.com>
---
This patch is based on the submitted patch "[PATCH V2] PCI:
dra7xx: Add dra7xx prefix before add_pcie_port".

 drivers/pci/host/pci-dra7xx.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/pci/host/pci-dra7xx.c b/drivers/pci/host/pci-dra7xx.c
index 5b4a644..8c69697 100644
--- a/drivers/pci/host/pci-dra7xx.c
+++ b/drivers/pci/host/pci-dra7xx.c
@@ -270,8 +270,8 @@ static irqreturn_t dra7xx_pcie_irq_handler(int irq, void *arg)
 	return IRQ_HANDLED;
 }
 
-static int dra7xx_add_pcie_port(struct dra7xx_pcie *dra7xx,
-				struct platform_device *pdev)
+static int __init dra7xx_add_pcie_port(struct dra7xx_pcie *dra7xx,
+				       struct platform_device *pdev)
 {
 	int ret;
 	struct pcie_port *pp;
-- 
1.7.9.5



^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2014-11-14  5:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-11-06  5:37 [PATCH] PCI: dra7xx: Add __init annotation to dra7xx_add_pcie_port() Jingoo Han
2014-11-13 16:51 ` Bjorn Helgaas
2014-11-14  5:10   ` Kishon Vijay Abraham I

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).