All of lore.kernel.org
 help / color / mirror / Atom feed
* netconsole over USB net not working
@ 2021-11-10 19:47 Andy Shevchenko
  2021-11-17  8:50 ` Andy Shevchenko
  0 siblings, 1 reply; 3+ messages in thread
From: Andy Shevchenko @ 2021-11-10 19:47 UTC (permalink / raw)
  To: U-Boot Mailing List, Ferry Toth, Simon Glass
  Cc: Tom Rini, Marek Vasut, Bin Meng, Joe Hershberger, Ramon Fried,
	Lukasz Majewski

Hi!

What is the Best Known Method to enable NetConsole over USB ethernet
gadget on DWC3?

Currently I have a "blinking" type of network interface (from the host
side) and it's too hard to understand all the mysterious ways of this
setup.

I have set std* to "nc,serial" (*) to be able to have the network
console be set up and running.

*) "serial" is just for the initial boot strap, this is a product
ready Android tablet that users are not supposed to solder wires on
its PCB. No need to say that I have another similar device
(https://lore.kernel.org/u-boot/CAHp75VdPTU-THtHi3eRiD7rd_tC90fC66AiUvzMnoF2Ky0J_HQ@mail.gmail.com/T/#u)
that has no serial interface at all, and I can't do anything about it
due to lack of support from U-Boot.

Unfortunately it goes this direction (in net_loop() call)
       net_init();
       if (eth_is_on_demand_init()) {
               eth_halt();
               eth_set_current();
               ret = eth_init();
               if (ret < 0) {
                       eth_halt();
                       return ret;
               }

The problem here is that the gadget timeouts for some reason and of
course for the default 3 seconds I may not have enough time to set up
the network on the host side. Moreover, if by luck I manage to achieve
that, it still doesn't work.

--- net_loop Entry
Trying usb_ether
0
  - 0 'dwc3'
  - found
using dwc3-gadget, OUT ep2out IN ep2in STATUS ep3in
MAC de:ad:be:ef:00:01
HOST MAC de:ad:be:ef:00:00
...
dwc3-generic-peripheral dwc3: Transfer Not Ready while ep0out in state
'Data Phase'dwc3-generic-peripheral dwc3:
Transfer Complete while ep0out in state 'Status Phase'The remote end
did not respond in time.eth_reset_config
dwc3-generic-peripheral dwc3: request 36561380 from ep3in completed
0/8 ===> -108
event 00 --> -108
eth_unbind...
FAIL

...and repeat...

Conclusion it is not working at all.

Expectations:
the USB gadget leaves UDC in state that the host would be able to set
up the link and the netconsole would be able to send data to it.

How to achieve that?

Alternative: serial function of the composite device. As of today not
an option — it simply does not exist in the U-Boot. Anybody is working
on that?

-- 
With Best Regards,
Andy Shevchenko

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

* Re: netconsole over USB net not working
  2021-11-10 19:47 netconsole over USB net not working Andy Shevchenko
@ 2021-11-17  8:50 ` Andy Shevchenko
  2021-11-17 20:36   ` Simon Glass
  0 siblings, 1 reply; 3+ messages in thread
From: Andy Shevchenko @ 2021-11-17  8:50 UTC (permalink / raw)
  To: U-Boot Mailing List, Ferry Toth, Simon Glass
  Cc: Tom Rini, Marek Vasut, Bin Meng, Joe Hershberger, Ramon Fried,
	Lukasz Majewski

On Wed, Nov 10, 2021 at 9:47 PM Andy Shevchenko
<andy.shevchenko@gmail.com> wrote:
>
> Hi!
>
> What is the Best Known Method to enable NetConsole over USB ethernet
> gadget on DWC3?

Any insight anyone? v2022.01-rc2 behaves the same way.
It was checked that in USB host mode and external card the netconsole
setup works.

> Currently I have a "blinking" type of network interface (from the host
> side) and it's too hard to understand all the mysterious ways of this
> setup.
>
> I have set std* to "nc,serial" (*) to be able to have the network
> console be set up and running.
>
> *) "serial" is just for the initial boot strap, this is a product
> ready Android tablet that users are not supposed to solder wires on
> its PCB. No need to say that I have another similar device
> (https://lore.kernel.org/u-boot/CAHp75VdPTU-THtHi3eRiD7rd_tC90fC66AiUvzMnoF2Ky0J_HQ@mail.gmail.com/T/#u)
> that has no serial interface at all, and I can't do anything about it
> due to lack of support from U-Boot.
>
> Unfortunately it goes this direction (in net_loop() call)
>        net_init();
>        if (eth_is_on_demand_init()) {
>                eth_halt();
>                eth_set_current();
>                ret = eth_init();
>                if (ret < 0) {
>                        eth_halt();
>                        return ret;
>                }
>
> The problem here is that the gadget timeouts for some reason and of
> course for the default 3 seconds I may not have enough time to set up
> the network on the host side. Moreover, if by luck I manage to achieve
> that, it still doesn't work.
>
> --- net_loop Entry
> Trying usb_ether
> 0
>   - 0 'dwc3'
>   - found
> using dwc3-gadget, OUT ep2out IN ep2in STATUS ep3in
> MAC de:ad:be:ef:00:01
> HOST MAC de:ad:be:ef:00:00
> ...
> dwc3-generic-peripheral dwc3: Transfer Not Ready while ep0out in state
> 'Data Phase'dwc3-generic-peripheral dwc3:
> Transfer Complete while ep0out in state 'Status Phase'The remote end
> did not respond in time.eth_reset_config
> dwc3-generic-peripheral dwc3: request 36561380 from ep3in completed
> 0/8 ===> -108
> event 00 --> -108
> eth_unbind...
> FAIL
>
> ...and repeat...
>
> Conclusion it is not working at all.
>
> Expectations:
> the USB gadget leaves UDC in state that the host would be able to set
> up the link and the netconsole would be able to send data to it.
>
> How to achieve that?
>
> Alternative: serial function of the composite device. As of today not
> an option — it simply does not exist in the U-Boot. Anybody is working
> on that?
>
> --
> With Best Regards,
> Andy Shevchenko



-- 
With Best Regards,
Andy Shevchenko

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

* Re: netconsole over USB net not working
  2021-11-17  8:50 ` Andy Shevchenko
@ 2021-11-17 20:36   ` Simon Glass
  0 siblings, 0 replies; 3+ messages in thread
From: Simon Glass @ 2021-11-17 20:36 UTC (permalink / raw)
  To: Andy Shevchenko
  Cc: U-Boot Mailing List, Ferry Toth, Tom Rini, Marek Vasut, Bin Meng,
	Joe Hershberger, Ramon Fried, Lukasz Majewski

Hi Andy,

On Wed, 17 Nov 2021 at 01:50, Andy Shevchenko <andy.shevchenko@gmail.com> wrote:
>
> On Wed, Nov 10, 2021 at 9:47 PM Andy Shevchenko
> <andy.shevchenko@gmail.com> wrote:
> >
> > Hi!
> >
> > What is the Best Known Method to enable NetConsole over USB ethernet
> > gadget on DWC3?
>
> Any insight anyone? v2022.01-rc2 behaves the same way.
> It was checked that in USB host mode and external card the netconsole
> setup works.

I haven't tried it, but it would be nice it it worked!


- Simon

>
> > Currently I have a "blinking" type of network interface (from the host
> > side) and it's too hard to understand all the mysterious ways of this
> > setup.
> >
> > I have set std* to "nc,serial" (*) to be able to have the network
> > console be set up and running.
> >
> > *) "serial" is just for the initial boot strap, this is a product
> > ready Android tablet that users are not supposed to solder wires on
> > its PCB. No need to say that I have another similar device
> > (https://lore.kernel.org/u-boot/CAHp75VdPTU-THtHi3eRiD7rd_tC90fC66AiUvzMnoF2Ky0J_HQ@mail.gmail.com/T/#u)
> > that has no serial interface at all, and I can't do anything about it
> > due to lack of support from U-Boot.
> >
> > Unfortunately it goes this direction (in net_loop() call)
> >        net_init();
> >        if (eth_is_on_demand_init()) {
> >                eth_halt();
> >                eth_set_current();
> >                ret = eth_init();
> >                if (ret < 0) {
> >                        eth_halt();
> >                        return ret;
> >                }
> >
> > The problem here is that the gadget timeouts for some reason and of
> > course for the default 3 seconds I may not have enough time to set up
> > the network on the host side. Moreover, if by luck I manage to achieve
> > that, it still doesn't work.
> >
> > --- net_loop Entry
> > Trying usb_ether
> > 0
> >   - 0 'dwc3'
> >   - found
> > using dwc3-gadget, OUT ep2out IN ep2in STATUS ep3in
> > MAC de:ad:be:ef:00:01
> > HOST MAC de:ad:be:ef:00:00
> > ...
> > dwc3-generic-peripheral dwc3: Transfer Not Ready while ep0out in state
> > 'Data Phase'dwc3-generic-peripheral dwc3:
> > Transfer Complete while ep0out in state 'Status Phase'The remote end
> > did not respond in time.eth_reset_config
> > dwc3-generic-peripheral dwc3: request 36561380 from ep3in completed
> > 0/8 ===> -108
> > event 00 --> -108
> > eth_unbind...
> > FAIL
> >
> > ...and repeat...
> >
> > Conclusion it is not working at all.
> >
> > Expectations:
> > the USB gadget leaves UDC in state that the host would be able to set
> > up the link and the netconsole would be able to send data to it.
> >
> > How to achieve that?
> >
> > Alternative: serial function of the composite device. As of today not
> > an option — it simply does not exist in the U-Boot. Anybody is working
> > on that?
> >
> > --
> > With Best Regards,
> > Andy Shevchenko
>
>
>
> --
> With Best Regards,
> Andy Shevchenko

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

end of thread, other threads:[~2021-11-17 20:36 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-11-10 19:47 netconsole over USB net not working Andy Shevchenko
2021-11-17  8:50 ` Andy Shevchenko
2021-11-17 20:36   ` Simon Glass

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.