diff mbox series

[-next] PCI: dwc: fix compile err for pcie-tagra194

Message ID 1584621380-21152-1-git-send-email-hqjagain@gmail.com (mailing list archive)
State Superseded, archived
Delegated to: Lorenzo Pieralisi
Headers show
Series [-next] PCI: dwc: fix compile err for pcie-tagra194 | expand

Commit Message

Qiujun Huang March 19, 2020, 12:36 p.m. UTC
make allmodconfig
ERROR: modpost: "dw_pcie_ep_init_notify" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
ERROR: modpost: "dw_pcie_ep_init_complete" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
ERROR: modpost: "dw_pcie_ep_linkup" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
make[2]: *** [__modpost] Error 1
make[1]: *** [modules] Error 2
make: *** [sub-make] Error 2

need to export the symbols.

Signed-off-by: Qiujun Huang <hqjagain@gmail.com>
---
 drivers/pci/controller/dwc/pcie-designware-ep.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Lorenzo Pieralisi March 19, 2020, 5:37 p.m. UTC | #1
On Thu, Mar 19, 2020 at 08:36:20PM +0800, Qiujun Huang wrote:
> make allmodconfig
> ERROR: modpost: "dw_pcie_ep_init_notify" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
> ERROR: modpost: "dw_pcie_ep_init_complete" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
> ERROR: modpost: "dw_pcie_ep_linkup" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
> make[2]: *** [__modpost] Error 1
> make[1]: *** [modules] Error 2
> make: *** [sub-make] Error 2
> 
> need to export the symbols.
> 
> Signed-off-by: Qiujun Huang <hqjagain@gmail.com>
> ---
>  drivers/pci/controller/dwc/pcie-designware-ep.c | 3 +++
>  1 file changed, 3 insertions(+)

I have squashed this in with the original patch.

@Vidya: is this something we missed in the review cycle ? Asking just
to make sure it was not me who made a mistake while merging the code.

Thanks,
Lorenzo

> diff --git a/drivers/pci/controller/dwc/pcie-designware-ep.c b/drivers/pci/controller/dwc/pcie-designware-ep.c
> index 4233c43..60d62ef 100644
> --- a/drivers/pci/controller/dwc/pcie-designware-ep.c
> +++ b/drivers/pci/controller/dwc/pcie-designware-ep.c
> @@ -18,6 +18,7 @@ void dw_pcie_ep_linkup(struct dw_pcie_ep *ep)
>  
>  	pci_epc_linkup(epc);
>  }
> +EXPORT_SYMBOL_GPL(dw_pcie_ep_linkup);
>  
>  void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
>  {
> @@ -25,6 +26,7 @@ void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
>  
>  	pci_epc_init_notify(epc);
>  }
> +EXPORT_SYMBOL_GPL(dw_pcie_ep_init_notify);
>  
>  static void __dw_pcie_ep_reset_bar(struct dw_pcie *pci, enum pci_barno bar,
>  				   int flags)
> @@ -535,6 +537,7 @@ int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep)
>  
>  	return 0;
>  }
> +EXPORT_SYMBOL_GPL(dw_pcie_ep_init_complete);
>  
>  int dw_pcie_ep_init(struct dw_pcie_ep *ep)
>  {
> -- 
> 1.8.3.1
>
Vidya Sagar March 20, 2020, 5:15 a.m. UTC | #2
On 3/19/2020 11:07 PM, Lorenzo Pieralisi wrote:
> External email: Use caution opening links or attachments
> 
> 
> On Thu, Mar 19, 2020 at 08:36:20PM +0800, Qiujun Huang wrote:
>> make allmodconfig
>> ERROR: modpost: "dw_pcie_ep_init_notify" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
>> ERROR: modpost: "dw_pcie_ep_init_complete" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
>> ERROR: modpost: "dw_pcie_ep_linkup" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
>> make[2]: *** [__modpost] Error 1
>> make[1]: *** [modules] Error 2
>> make: *** [sub-make] Error 2
>>
>> need to export the symbols.
>>
>> Signed-off-by: Qiujun Huang <hqjagain@gmail.com>
>> ---
>>   drivers/pci/controller/dwc/pcie-designware-ep.c | 3 +++
>>   1 file changed, 3 insertions(+)
> 
> I have squashed this in with the original patch.
> 
> @Vidya: is this something we missed in the review cycle ? Asking just
> to make sure it was not me who made a mistake while merging the code.
My apologies. I wasn't compiling the driver as a module (instead built 
into the kernel image)
BTW, I see
ERROR: modpost: "dw_pcie_ep_init" 
[drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
also along with the above three. So I think even dw_pcie_ep_init() needs 
to be exported.

Thanks,
Vidya Sagar
> 
> Thanks,
> Lorenzo
> 
>> diff --git a/drivers/pci/controller/dwc/pcie-designware-ep.c b/drivers/pci/controller/dwc/pcie-designware-ep.c
>> index 4233c43..60d62ef 100644
>> --- a/drivers/pci/controller/dwc/pcie-designware-ep.c
>> +++ b/drivers/pci/controller/dwc/pcie-designware-ep.c
>> @@ -18,6 +18,7 @@ void dw_pcie_ep_linkup(struct dw_pcie_ep *ep)
>>
>>        pci_epc_linkup(epc);
>>   }
>> +EXPORT_SYMBOL_GPL(dw_pcie_ep_linkup);
>>
>>   void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
>>   {
>> @@ -25,6 +26,7 @@ void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
>>
>>        pci_epc_init_notify(epc);
>>   }
>> +EXPORT_SYMBOL_GPL(dw_pcie_ep_init_notify);
>>
>>   static void __dw_pcie_ep_reset_bar(struct dw_pcie *pci, enum pci_barno bar,
>>                                   int flags)
>> @@ -535,6 +537,7 @@ int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep)
>>
>>        return 0;
>>   }
>> +EXPORT_SYMBOL_GPL(dw_pcie_ep_init_complete);
>>
>>   int dw_pcie_ep_init(struct dw_pcie_ep *ep)
>>   {
>> --
>> 1.8.3.1
>>
Qiujun Huang March 20, 2020, 6 a.m. UTC | #3
On Fri, Mar 20, 2020 at 1:15 PM Vidya Sagar <vidyas@nvidia.com> wrote:
>
>
>
> On 3/19/2020 11:07 PM, Lorenzo Pieralisi wrote:
> > External email: Use caution opening links or attachments
> >
> >
> > On Thu, Mar 19, 2020 at 08:36:20PM +0800, Qiujun Huang wrote:
> >> make allmodconfig
> >> ERROR: modpost: "dw_pcie_ep_init_notify" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
> >> ERROR: modpost: "dw_pcie_ep_init_complete" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
> >> ERROR: modpost: "dw_pcie_ep_linkup" [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
> >> make[2]: *** [__modpost] Error 1
> >> make[1]: *** [modules] Error 2
> >> make: *** [sub-make] Error 2
> >>
> >> need to export the symbols.
> >>
> >> Signed-off-by: Qiujun Huang <hqjagain@gmail.com>
> >> ---
> >>   drivers/pci/controller/dwc/pcie-designware-ep.c | 3 +++
> >>   1 file changed, 3 insertions(+)
> >
> > I have squashed this in with the original patch.
> >
> > @Vidya: is this something we missed in the review cycle ? Asking just
> > to make sure it was not me who made a mistake while merging the code.
> My apologies. I wasn't compiling the driver as a module (instead built
> into the kernel image)
> BTW, I see
> ERROR: modpost: "dw_pcie_ep_init"
> [drivers/pci/controller/dwc/pcie-tegra194.ko] undefined!
> also along with the above three. So I think even dw_pcie_ep_init() needs
> to be exported.

OK, I'll send v2 to add dw_pcie_ep_init.

>
> Thanks,
> Vidya Sagar
> >
> > Thanks,
> > Lorenzo
> >
> >> diff --git a/drivers/pci/controller/dwc/pcie-designware-ep.c b/drivers/pci/controller/dwc/pcie-designware-ep.c
> >> index 4233c43..60d62ef 100644
> >> --- a/drivers/pci/controller/dwc/pcie-designware-ep.c
> >> +++ b/drivers/pci/controller/dwc/pcie-designware-ep.c
> >> @@ -18,6 +18,7 @@ void dw_pcie_ep_linkup(struct dw_pcie_ep *ep)
> >>
> >>        pci_epc_linkup(epc);
> >>   }
> >> +EXPORT_SYMBOL_GPL(dw_pcie_ep_linkup);
> >>
> >>   void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
> >>   {
> >> @@ -25,6 +26,7 @@ void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
> >>
> >>        pci_epc_init_notify(epc);
> >>   }
> >> +EXPORT_SYMBOL_GPL(dw_pcie_ep_init_notify);
> >>
> >>   static void __dw_pcie_ep_reset_bar(struct dw_pcie *pci, enum pci_barno bar,
> >>                                   int flags)
> >> @@ -535,6 +537,7 @@ int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep)
> >>
> >>        return 0;
> >>   }
> >> +EXPORT_SYMBOL_GPL(dw_pcie_ep_init_complete);
> >>
> >>   int dw_pcie_ep_init(struct dw_pcie_ep *ep)
> >>   {
> >> --
> >> 1.8.3.1
> >>
diff mbox series

Patch

diff --git a/drivers/pci/controller/dwc/pcie-designware-ep.c b/drivers/pci/controller/dwc/pcie-designware-ep.c
index 4233c43..60d62ef 100644
--- a/drivers/pci/controller/dwc/pcie-designware-ep.c
+++ b/drivers/pci/controller/dwc/pcie-designware-ep.c
@@ -18,6 +18,7 @@  void dw_pcie_ep_linkup(struct dw_pcie_ep *ep)
 
 	pci_epc_linkup(epc);
 }
+EXPORT_SYMBOL_GPL(dw_pcie_ep_linkup);
 
 void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
 {
@@ -25,6 +26,7 @@  void dw_pcie_ep_init_notify(struct dw_pcie_ep *ep)
 
 	pci_epc_init_notify(epc);
 }
+EXPORT_SYMBOL_GPL(dw_pcie_ep_init_notify);
 
 static void __dw_pcie_ep_reset_bar(struct dw_pcie *pci, enum pci_barno bar,
 				   int flags)
@@ -535,6 +537,7 @@  int dw_pcie_ep_init_complete(struct dw_pcie_ep *ep)
 
 	return 0;
 }
+EXPORT_SYMBOL_GPL(dw_pcie_ep_init_complete);
 
 int dw_pcie_ep_init(struct dw_pcie_ep *ep)
 {