Discussion:
USB Ethernet gadget on Nokia n900
Pavel Machek
2014-10-19 09:01:07 UTC
Permalink
Hi!
From 3.6 to 3.10, USB networking works on Nokia N900. With 3.11, it
fails with messages on the host. I also tried to get it to work on
3.14 and 3.17, with no luck.

Any ideas? Does it work for you? Any config options to watch for?

Best regards,
Pavel

Oct 19 10:10:52 amd kernel: [71388.656037] usb 4-1: new high-speed USB
device number 98 using ehci-pci
Oct 19 10:10:52 amd kernel: [71388.789842] usb 4-1: New USB device
found, idVendor=0525, idProduct=a4a2
Oct 19 10:10:52 amd kernel: [71388.789847] usb 4-1: New USB device
strings: Mfr=1, Product=2, SerialNumber=0
Oct 19 10:10:52 amd kernel: [71388.789851] usb 4-1: Product:
RNDIS/Ethernet Gadget
Oct 19 10:10:52 amd kernel: [71388.789854] usb 4-1: Manufacturer:
Linux 3.11.0-00115-g1b8e8c5-dirty with musb-hdrc
Oct 19 10:11:02 amd kernel: [71398.788300] cdc_subset: probe of
4-1:1.0 failed with error -22
Oct 19 10:11:05 amd systemd-udevd[167]: Network interface NamePolicy=
disabled on kernel commandline, ignoring.
Oct 19 10:11:07 amd kernel: [71403.788240] cdc_ether: probe of 4-1:1.0
failed with error -110
Oct 19 10:11:10 amd systemd-udevd[167]: Network interface NamePolicy=
disabled on kernel commandline, ignoring.
Oct 19 10:11:12 amd kernel: [71408.788237] cdc_subset: probe of
4-1:1.1 failed with error -110
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Pavel Machek
2014-10-19 10:07:39 UTC
Permalink
Hi!
From 3.6 to 3.10, USB networking works on Nokia N900. With 3.11, it
fails with messages on the host. I also tried to get it to work on
3.14 and 3.17, with no luck.
Any ideas? Does it work for you? Any config options to watch for?
With 3.17, I get

omap_musb_mailbox: musb core is not yet ready

message. It looks related...?
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Pali Rohár
2014-10-19 14:58:45 UTC
Permalink
Post by Pavel Machek
Hi!
From 3.6 to 3.10, USB networking works on Nokia N900. With
3.11, it fails with messages on the host. I also tried to
get it to work on 3.14 and 3.17, with no luck.
Any ideas? Does it work for you? Any config options to watch
for?
With 3.17, I get
omap_musb_mailbox: musb core is not yet ready
message. It looks related...?
Can you try tree https://gitorious.org/linux-n900/linux-n900/ ?

I think with rx51_defconfig from above tree it worked fine for
3.10 - 3.13 versions.
--
Pali Rohár
***@gmail.com
Pavel Machek
2014-10-19 20:50:36 UTC
Permalink
Post by Pali Rohár
Post by Pavel Machek
Hi!
=20
From 3.6 to 3.10, USB networking works on Nokia N900. With
3.11, it fails with messages on the host. I also tried to
get it to work on 3.14 and 3.17, with no luck.
=20
Any ideas? Does it work for you? Any config options to watch for?
=20
With 3.17, I get
=20
omap_musb_mailbox: musb core is not yet ready
=20
message. It looks related...?
=20
Can you try tree https://gitorious.org/linux-n900/linux-n900/ ?
=20
I think with rx51_defconfig from above tree it worked fine for=20
3.10 - 3.13 versions.
=46rom your tree, I am trying 815039686baffff6432b45028dd405b1981a9112
(3.16 based). I attempted to make gadget drivers build-in and enabled
nfsroot. I could not detect nokia on USB after bootup.

Are you sure about defconfig? AFAICT defconfig will always be
unsuitable for nfsroot, as it will not contain nfs support built-in...

I am trying c089e5f8ba2d44afd2db2c2042d43ca70205c536 (3.13
based). Same result :-(.

Do you have any tree where usb gadget works for you?

Thanks,
Pavel
--=20
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses=
/blog.html
Pali Rohár
2014-10-19 21:00:20 UTC
Permalink
Post by Pali Rohár
Post by Pavel Machek
Hi!
From 3.6 to 3.10, USB networking works on Nokia N900.
With 3.11, it fails with messages on the host. I also
tried to get it to work on 3.14 and 3.17, with no luck.
Any ideas? Does it work for you? Any config options to
watch for?
With 3.17, I get
omap_musb_mailbox: musb core is not yet ready
message. It looks related...?
Can you try tree
https://gitorious.org/linux-n900/linux-n900/ ?
I think with rx51_defconfig from above tree it worked fine
for 3.10 - 3.13 versions.
From your tree, I am trying
815039686baffff6432b45028dd405b1981a9112 (3.16 based). I
attempted to make gadget drivers build-in and enabled
nfsroot. I could not detect nokia on USB after bootup.
Are you sure about defconfig? AFAICT defconfig will always be
unsuitable for nfsroot, as it will not contain nfs support
built-in...
I am trying c089e5f8ba2d44afd2db2c2042d43ca70205c536 (3.13
based). Same result :-(.
Do you have any tree where usb gadget works for you?
Thanks,
Pavel
My N900 can boot kernel from v3.12-rc5-n900 branch compiled with
arch/arm/configs/rx51_defconfig. Also it can boot full Maemo5
system (with CSSU and some minor system changes) and usb network
via g_nokia.ko gadget working fine...

So if it does not working for you then kernel usb subsystem could
have problems with using gadgets directly from zimage.
--
Pali Rohár
***@gmail.com
Pavel Machek
2014-10-19 22:30:43 UTC
Permalink
Hi!
Post by Pali Rohár
Post by Pali Rohár
Post by Pavel Machek
omap_musb_mailbox: musb core is not yet ready
message. It looks related...?
Can you try tree
https://gitorious.org/linux-n900/linux-n900/ ?
I think with rx51_defconfig from above tree it worked fine
for 3.10 - 3.13 versions.
From your tree, I am trying
815039686baffff6432b45028dd405b1981a9112 (3.16 based). I
attempted to make gadget drivers build-in and enabled
nfsroot. I could not detect nokia on USB after bootup.
Are you sure about defconfig? AFAICT defconfig will always be
unsuitable for nfsroot, as it will not contain nfs support
built-in...
I am trying c089e5f8ba2d44afd2db2c2042d43ca70205c536 (3.13
based). Same result :-(.
Do you have any tree where usb gadget works for you?
My N900 can boot kernel from v3.12-rc5-n900 branch compiled with
arch/arm/configs/rx51_defconfig. Also it can boot full Maemo5
system (with CSSU and some minor system changes) and usb network
via g_nokia.ko gadget working fine...
Thanks for the info. Network seems to work on this one.
Post by Pali Rohár
So if it does not working for you then kernel usb subsystem could
have problems with using gadgets directly from zimage.
It seems to work with 3.12, but not with 3.13 (in similar config). If
you could test USB networking in 3.13, that would help...

Thanks,

Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Pavel Machek
2014-10-20 13:08:55 UTC
Permalink
Hi!
Post by Pali Rohár
My N900 can boot kernel from v3.12-rc5-n900 branch compiled with
arch/arm/configs/rx51_defconfig. Also it can boot full Maemo5
system (with CSSU and some minor system changes) and usb network
via g_nokia.ko gadget working fine...
So if it does not working for you then kernel usb subsystem could
have problems with using gadgets directly from zimage.
After some hand-bisecting and real-bisecting, I found two commits that
cause problems for 3.13: With these reverted, I get usb networking
back in 3.13 on nokia n900.

(Pali, if you revert these, you should get working usb networking in
your 3.13 branch, too.)

Any ideas?

Pavel

commit 3e3101d57c50f9e4fa1da947e4bd0bc5cbab4141
Author: Kishon Vijay Abraham I <***@ti.com>
Date: Fri Sep 27 11:53:30 2013 +0530

usb: musb: omap2430: use the new generic PHY framework

Use the generic PHY framework API to get the PHY. The
usb_phy_set_resume
and usb_phy_set_suspend is replaced with power_on and
power_off to align with the new PHY framework.

musb->xceiv can't be removed as of now because musb core uses
xceiv.state and
xceiv.otg. Once there is a separate state machine to handle otg,
these can be
moved out of xceiv and then we can start using the generic PHY
framework.

Signed-off-by: Kishon Vijay Abraham I <***@ti.com>
Reviewed-by: Sylwester Nawrocki <***@samsung.com>
Acked-by: Felipe Balbi <***@ti.com>
Signed-off-by: Greg Kroah-Hartman <***@linuxfoundation.org>

commit f1ddc24c9e33813f74b871d73e4d795dcdb95a3c
Author: Kishon Vijay Abraham I <***@ti.com>
Date: Fri Sep 27 11:53:31 2013 +0530

usb: phy: twl4030-usb: remove *set_suspend* and *phy_init* ops

Now that twl4030-usb is adapted to the new generic PHY framework,
*set_suspend* and *phy_init* ops can be removed from twl4030-usb
driver.

Signed-off-by: Kishon Vijay Abraham I <***@ti.com>
Acked-by: Felipe Balbi <***@ti.com>
Reviewed-by: Sylwester Nawrocki <***@samsung.com>
Signed-off-by: Greg Kroah-Hartman <***@linuxfoundation.org>
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Tony Lindgren
2014-10-20 16:45:42 UTC
Permalink
Post by Pavel Machek
Hi!
Post by Pali Rohár
My N900 can boot kernel from v3.12-rc5-n900 branch compiled with
arch/arm/configs/rx51_defconfig. Also it can boot full Maemo5
system (with CSSU and some minor system changes) and usb network
via g_nokia.ko gadget working fine...
So if it does not working for you then kernel usb subsystem could
have problems with using gadgets directly from zimage.
After some hand-bisecting and real-bisecting, I found two commits that
cause problems for 3.13: With these reverted, I get usb networking
back in 3.13 on nokia n900.
(Pali, if you revert these, you should get working usb networking in
your 3.13 branch, too.)
Any ideas?
Hmm maybe check if current stable kernels work for you without
reverting anything ? Few weeks ago I did the the following two fixes
with cc stable v3.13+:

96be39ab34b7 usb: phy: twl4030-usb: Fix regressions to runtime PM on omaps
85601b8d81e2 usb: phy: twl4030-usb: Fix lost interrupts after ID pin goes down

Regards,

Tony
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Felipe Balbi
2014-10-19 15:24:14 UTC
Permalink
Hi,
Post by Pavel Machek
Hi!
From 3.6 to 3.10, USB networking works on Nokia N900. With 3.11, it
fails with messages on the host. I also tried to get it to work on
3.14 and 3.17, with no luck.
Any ideas? Does it work for you? Any config options to watch for?
With 3.17, I get
omap_musb_mailbox: musb core is not yet ready
message. It looks related...?
is musbmhdrc.ko loaded ? Do you have a gadget driver loaded ?

+ Aaro
--
balbi
Pavel Machek
2014-10-19 19:19:37 UTC
Permalink
Hi!
Post by Felipe Balbi
Hi,
Post by Pavel Machek
Hi!
From 3.6 to 3.10, USB networking works on Nokia N900. With 3.11, it
fails with messages on the host. I also tried to get it to work on
3.14 and 3.17, with no luck.
Any ideas? Does it work for you? Any config options to watch for?
With 3.17, I get
omap_musb_mailbox: musb core is not yet ready
message. It looks related...?
is musbmhdrc.ko loaded ? Do you have a gadget driver loaded ?
+ Aaro
I am trying to use nfsroot, so I can't use modules. I can't find
musbmhdrc.ko; did you mean drivers/usb/musb/musb_hdrc? Yes, that
should be build-in:

CONFIG_USB_MUSB_HDRC=y
CONFIG_USB_MUSB_GADGET=y
CONFIG_USB_MUSB_OMAP2PLUS=y
CONFIG_MUSB_PIO_ONLY=y

Gadget options are:

CONFIG_USB_ULPI=y
CONFIG_USB_GADGET=y
CONFIG_USB_GADGET_DEBUG=y
CONFIG_USB_GADGET_VERBOSE=y
CONFIG_USB_GADGET_DEBUG_FILES=y
CONFIG_USB_GADGET_DEBUG_FS=y
CONFIG_USB_GADGET_VBUS_DRAW=2
CONFIG_USB_GADGET_STORAGE_NUM_BUFFERS=2

CONFIG_USB_LIBCOMPOSITE=y
CONFIG_USB_U_ETHER=y
CONFIG_USB_F_ECM=y
CONFIG_USB_F_EEM=y
CONFIG_USB_F_SUBSET=y
CONFIG_USB_F_RNDIS=y

(I am attaching full config, in case I missed something important).

Best regards,
Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Pavel Machek
2014-10-19 19:29:37 UTC
Permalink
Hi!
Hi,
Post by Pavel Machek
Hi!
From 3.6 to 3.10, USB networking works on Nokia N900. With 3.11, it
fails with messages on the host. I also tried to get it to work on
3.14 and 3.17, with no luck.
Any ideas? Does it work for you? Any config options to watch for?
With 3.17, I get
omap_musb_mailbox: musb core is not yet ready
For the record, I can't see the message in this try. Either it is not
there, or it scrolled away (there's unfortunately no way to scroll
back).

Pavel
--
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to ***@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Continue reading on narkive:
Search results for 'USB Ethernet gadget on Nokia n900' (Questions and Answers)
7
replies
What do you think of this laptop?
started 2009-08-13 04:20:24 UTC
laptops & notebooks
Loading...