* [U-Boot] [PATCH] h2200: Fix build error
@ 2015-08-21 5:32 Kishon Vijay Abraham I
2015-08-21 5:33 ` Marek Vasut
2015-08-24 18:42 ` Marek Vasut
0 siblings, 2 replies; 6+ messages in thread
From: Kishon Vijay Abraham I @ 2015-08-21 5:32 UTC (permalink / raw)
To: u-boot
Commit <8bfc288c3955> ("usb: gadget: ether: Perform board
initialization from ethernet gadget driver") added board_usb_init
and board_usb_cleanup in ethernet gadget driver. But h2200 board
didn't have board_usb_init and board_usb_cleanup implementations.
This introduced the following build errors
+drivers/usb/gadget/built-in.o: In function `usb_eth_halt':
+drivers/usb/gadget/ether.c:2498: undefined reference to `board_usb_cleanup'
+drivers/usb/gadget/built-in.o: In function `usb_eth_init':
+drivers/usb/gadget/ether.c:2316: undefined reference to `board_usb_init'
Fix it here by adding empty board_usb_init and board_usb_cleanup
functions in h2200.c.
Fixes: <8bfc288c3955> ("usb: gadget: ether: Perform board
initialization from ethernet gadget driver")
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
---
board/h2200/h2200.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/board/h2200/h2200.c b/board/h2200/h2200.c
index 66ae4b6..01f8e67 100644
--- a/board/h2200/h2200.c
+++ b/board/h2200/h2200.c
@@ -59,3 +59,15 @@ int dram_init(void)
gd->ram_size = CONFIG_SYS_SDRAM_SIZE;
return 0;
}
+
+#ifdef CONFIG_USB_GADGET_PXA2XX
+int board_usb_init(int index, enum usb_init_type init)
+{
+ return 0;
+}
+
+int board_usb_cleanup(int index, enum usb_init_type init)
+{
+ return 0;
+}
+#endif
--
1.7.9.5
^ permalink raw reply related [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] h2200: Fix build error
2015-08-21 5:32 [U-Boot] [PATCH] h2200: Fix build error Kishon Vijay Abraham I
@ 2015-08-21 5:33 ` Marek Vasut
2015-08-21 5:43 ` Kishon Vijay Abraham I
2015-08-24 18:42 ` Marek Vasut
1 sibling, 1 reply; 6+ messages in thread
From: Marek Vasut @ 2015-08-21 5:33 UTC (permalink / raw)
To: u-boot
On Friday, August 21, 2015 at 07:32:04 AM, Kishon Vijay Abraham I wrote:
> Commit <8bfc288c3955> ("usb: gadget: ether: Perform board
> initialization from ethernet gadget driver") added board_usb_init
> and board_usb_cleanup in ethernet gadget driver. But h2200 board
> didn't have board_usb_init and board_usb_cleanup implementations.
>
> This introduced the following build errors
> +drivers/usb/gadget/built-in.o: In function `usb_eth_halt':
> +drivers/usb/gadget/ether.c:2498: undefined reference to
> `board_usb_cleanup' +drivers/usb/gadget/built-in.o: In function
> `usb_eth_init':
> +drivers/usb/gadget/ether.c:2316: undefined reference to `board_usb_init'
>
> Fix it here by adding empty board_usb_init and board_usb_cleanup
> functions in h2200.c.
>
> Fixes: <8bfc288c3955> ("usb: gadget: ether: Perform board
> initialization from ethernet gadget driver")
>
> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
> ---
> board/h2200/h2200.c | 12 ++++++++++++
> 1 file changed, 12 insertions(+)
>
> diff --git a/board/h2200/h2200.c b/board/h2200/h2200.c
> index 66ae4b6..01f8e67 100644
> --- a/board/h2200/h2200.c
> +++ b/board/h2200/h2200.c
> @@ -59,3 +59,15 @@ int dram_init(void)
> gd->ram_size = CONFIG_SYS_SDRAM_SIZE;
> return 0;
> }
> +
> +#ifdef CONFIG_USB_GADGET_PXA2XX
> +int board_usb_init(int index, enum usb_init_type init)
> +{
> + return 0;
> +}
> +
> +int board_usb_cleanup(int index, enum usb_init_type init)
> +{
> + return 0;
> +}
> +#endif
Shouldn't this go into the PXA2xx UDC driver instead as a set of
__weak functions ?
Best regards,
Marek Vasut
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] h2200: Fix build error
2015-08-21 5:33 ` Marek Vasut
@ 2015-08-21 5:43 ` Kishon Vijay Abraham I
2015-08-21 5:45 ` Marek Vasut
0 siblings, 1 reply; 6+ messages in thread
From: Kishon Vijay Abraham I @ 2015-08-21 5:43 UTC (permalink / raw)
To: u-boot
Hi Marek,
On Friday 21 August 2015 11:03 AM, Marek Vasut wrote:
> On Friday, August 21, 2015 at 07:32:04 AM, Kishon Vijay Abraham I wrote:
>> Commit <8bfc288c3955> ("usb: gadget: ether: Perform board
>> initialization from ethernet gadget driver") added board_usb_init
>> and board_usb_cleanup in ethernet gadget driver. But h2200 board
>> didn't have board_usb_init and board_usb_cleanup implementations.
>>
>> This introduced the following build errors
>> +drivers/usb/gadget/built-in.o: In function `usb_eth_halt':
>> +drivers/usb/gadget/ether.c:2498: undefined reference to
>> `board_usb_cleanup' +drivers/usb/gadget/built-in.o: In function
>> `usb_eth_init':
>> +drivers/usb/gadget/ether.c:2316: undefined reference to `board_usb_init'
>>
>> Fix it here by adding empty board_usb_init and board_usb_cleanup
>> functions in h2200.c.
>>
>> Fixes: <8bfc288c3955> ("usb: gadget: ether: Perform board
>> initialization from ethernet gadget driver")
>>
>> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
>> ---
>> board/h2200/h2200.c | 12 ++++++++++++
>> 1 file changed, 12 insertions(+)
>>
>> diff --git a/board/h2200/h2200.c b/board/h2200/h2200.c
>> index 66ae4b6..01f8e67 100644
>> --- a/board/h2200/h2200.c
>> +++ b/board/h2200/h2200.c
>> @@ -59,3 +59,15 @@ int dram_init(void)
>> gd->ram_size = CONFIG_SYS_SDRAM_SIZE;
>> return 0;
>> }
>> +
>> +#ifdef CONFIG_USB_GADGET_PXA2XX
>> +int board_usb_init(int index, enum usb_init_type init)
>> +{
>> + return 0;
>> +}
>> +
>> +int board_usb_cleanup(int index, enum usb_init_type init)
>> +{
>> + return 0;
>> +}
>> +#endif
>
> Shouldn't this go into the PXA2xx UDC driver instead as a set of
> __weak functions ?
thought all board_* functions should be added in board files. but
I think whatever you are telling makes sense. Will post a new version.
Thanks
Kishon
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] h2200: Fix build error
2015-08-21 5:43 ` Kishon Vijay Abraham I
@ 2015-08-21 5:45 ` Marek Vasut
2015-08-21 5:47 ` Kishon Vijay Abraham I
0 siblings, 1 reply; 6+ messages in thread
From: Marek Vasut @ 2015-08-21 5:45 UTC (permalink / raw)
To: u-boot
On Friday, August 21, 2015 at 07:43:44 AM, Kishon Vijay Abraham I wrote:
> Hi Marek,
>
> On Friday 21 August 2015 11:03 AM, Marek Vasut wrote:
> > On Friday, August 21, 2015 at 07:32:04 AM, Kishon Vijay Abraham I wrote:
> >> Commit <8bfc288c3955> ("usb: gadget: ether: Perform board
> >> initialization from ethernet gadget driver") added board_usb_init
> >> and board_usb_cleanup in ethernet gadget driver. But h2200 board
> >> didn't have board_usb_init and board_usb_cleanup implementations.
> >>
> >> This introduced the following build errors
> >> +drivers/usb/gadget/built-in.o: In function `usb_eth_halt':
> >> +drivers/usb/gadget/ether.c:2498: undefined reference to
> >> `board_usb_cleanup' +drivers/usb/gadget/built-in.o: In function
> >> `usb_eth_init':
> >> +drivers/usb/gadget/ether.c:2316: undefined reference to
> >> `board_usb_init'
> >>
> >> Fix it here by adding empty board_usb_init and board_usb_cleanup
> >> functions in h2200.c.
> >>
> >> Fixes: <8bfc288c3955> ("usb: gadget: ether: Perform board
> >> initialization from ethernet gadget driver")
> >>
> >> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
> >> ---
> >>
> >> board/h2200/h2200.c | 12 ++++++++++++
> >> 1 file changed, 12 insertions(+)
> >>
> >> diff --git a/board/h2200/h2200.c b/board/h2200/h2200.c
> >> index 66ae4b6..01f8e67 100644
> >> --- a/board/h2200/h2200.c
> >> +++ b/board/h2200/h2200.c
> >> @@ -59,3 +59,15 @@ int dram_init(void)
> >>
> >> gd->ram_size = CONFIG_SYS_SDRAM_SIZE;
> >> return 0;
> >>
> >> }
> >>
> >> +
> >> +#ifdef CONFIG_USB_GADGET_PXA2XX
> >> +int board_usb_init(int index, enum usb_init_type init)
> >> +{
> >> + return 0;
> >> +}
> >> +
> >> +int board_usb_cleanup(int index, enum usb_init_type init)
> >> +{
> >> + return 0;
> >> +}
> >> +#endif
> >
> > Shouldn't this go into the PXA2xx UDC driver instead as a set of
> > __weak functions ?
>
> thought all board_* functions should be added in board files. but
> I think whatever you are telling makes sense. Will post a new version.
Ow, we don't even have a default implementation of these anywhere.
In that case, I think this patch is all right and if noone is opposed,
I'll pick it as is. Sorry for the noise.
Best regards,
Marek Vasut
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] h2200: Fix build error
2015-08-21 5:45 ` Marek Vasut
@ 2015-08-21 5:47 ` Kishon Vijay Abraham I
0 siblings, 0 replies; 6+ messages in thread
From: Kishon Vijay Abraham I @ 2015-08-21 5:47 UTC (permalink / raw)
To: u-boot
On Friday 21 August 2015 11:15 AM, Marek Vasut wrote:
> On Friday, August 21, 2015 at 07:43:44 AM, Kishon Vijay Abraham I wrote:
>> Hi Marek,
>>
>> On Friday 21 August 2015 11:03 AM, Marek Vasut wrote:
>>> On Friday, August 21, 2015 at 07:32:04 AM, Kishon Vijay Abraham I wrote:
>>>> Commit <8bfc288c3955> ("usb: gadget: ether: Perform board
>>>> initialization from ethernet gadget driver") added board_usb_init
>>>> and board_usb_cleanup in ethernet gadget driver. But h2200 board
>>>> didn't have board_usb_init and board_usb_cleanup implementations.
>>>>
>>>> This introduced the following build errors
>>>> +drivers/usb/gadget/built-in.o: In function `usb_eth_halt':
>>>> +drivers/usb/gadget/ether.c:2498: undefined reference to
>>>> `board_usb_cleanup' +drivers/usb/gadget/built-in.o: In function
>>>> `usb_eth_init':
>>>> +drivers/usb/gadget/ether.c:2316: undefined reference to
>>>> `board_usb_init'
>>>>
>>>> Fix it here by adding empty board_usb_init and board_usb_cleanup
>>>> functions in h2200.c.
>>>>
>>>> Fixes: <8bfc288c3955> ("usb: gadget: ether: Perform board
>>>> initialization from ethernet gadget driver")
>>>>
>>>> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
>>>> ---
>>>>
>>>> board/h2200/h2200.c | 12 ++++++++++++
>>>> 1 file changed, 12 insertions(+)
>>>>
>>>> diff --git a/board/h2200/h2200.c b/board/h2200/h2200.c
>>>> index 66ae4b6..01f8e67 100644
>>>> --- a/board/h2200/h2200.c
>>>> +++ b/board/h2200/h2200.c
>>>> @@ -59,3 +59,15 @@ int dram_init(void)
>>>>
>>>> gd->ram_size = CONFIG_SYS_SDRAM_SIZE;
>>>> return 0;
>>>>
>>>> }
>>>>
>>>> +
>>>> +#ifdef CONFIG_USB_GADGET_PXA2XX
>>>> +int board_usb_init(int index, enum usb_init_type init)
>>>> +{
>>>> + return 0;
>>>> +}
>>>> +
>>>> +int board_usb_cleanup(int index, enum usb_init_type init)
>>>> +{
>>>> + return 0;
>>>> +}
>>>> +#endif
>>>
>>> Shouldn't this go into the PXA2xx UDC driver instead as a set of
>>> __weak functions ?
>>
>> thought all board_* functions should be added in board files. but
>> I think whatever you are telling makes sense. Will post a new version.
>
> Ow, we don't even have a default implementation of these anywhere.
> In that case, I think this patch is all right and if noone is opposed,
> I'll pick it as is. Sorry for the noise.
ah.. alright.
Thanks
Kishon
^ permalink raw reply [flat|nested] 6+ messages in thread
* [U-Boot] [PATCH] h2200: Fix build error
2015-08-21 5:32 [U-Boot] [PATCH] h2200: Fix build error Kishon Vijay Abraham I
2015-08-21 5:33 ` Marek Vasut
@ 2015-08-24 18:42 ` Marek Vasut
1 sibling, 0 replies; 6+ messages in thread
From: Marek Vasut @ 2015-08-24 18:42 UTC (permalink / raw)
To: u-boot
On Friday, August 21, 2015 at 07:32:04 AM, Kishon Vijay Abraham I wrote:
> Commit <8bfc288c3955> ("usb: gadget: ether: Perform board
> initialization from ethernet gadget driver") added board_usb_init
> and board_usb_cleanup in ethernet gadget driver. But h2200 board
> didn't have board_usb_init and board_usb_cleanup implementations.
>
> This introduced the following build errors
> +drivers/usb/gadget/built-in.o: In function `usb_eth_halt':
> +drivers/usb/gadget/ether.c:2498: undefined reference to
> `board_usb_cleanup' +drivers/usb/gadget/built-in.o: In function
> `usb_eth_init':
> +drivers/usb/gadget/ether.c:2316: undefined reference to `board_usb_init'
>
> Fix it here by adding empty board_usb_init and board_usb_cleanup
> functions in h2200.c.
>
> Fixes: <8bfc288c3955> ("usb: gadget: ether: Perform board
> initialization from ethernet gadget driver")
>
> Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
Applied, thanks.
Best regards,
Marek Vasut
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2015-08-24 18:42 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-08-21 5:32 [U-Boot] [PATCH] h2200: Fix build error Kishon Vijay Abraham I
2015-08-21 5:33 ` Marek Vasut
2015-08-21 5:43 ` Kishon Vijay Abraham I
2015-08-21 5:45 ` Marek Vasut
2015-08-21 5:47 ` Kishon Vijay Abraham I
2015-08-24 18:42 ` Marek Vasut
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox