* [Buildroot] [Bug 9541] New: Platform drivers autoloading from info in device tree does not work
@ 2016-12-30 14:42 bugzilla at busybox.net
2016-12-30 20:44 ` [Buildroot] [Bug 9541] " bugzilla at busybox.net
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: bugzilla at busybox.net @ 2016-12-30 14:42 UTC (permalink / raw)
To: buildroot
https://bugs.busybox.net/show_bug.cgi?id=9541
Bug ID: 9541
Summary: Platform drivers autoloading from info in device tree
does not work
Product: buildroot
Version: unspecified
Hardware: All
OS: Linux
Status: NEW
Severity: normal
Priority: P5
Component: Other
Assignee: unassigned at buildroot.uclibc.org
Reporter: a.synytsyn at gmail.com
CC: buildroot at uclibc.org
Target Milestone: ---
Hello everyone! What is going on with autoloading modules for platform devices
from device tree? I've build image for raspberry pi, added device tree overlay
for enc28j60. I've checked: device tree node with this device exists in
/proc/device-tree/soc/spi at 7e204000. But lsmod does not shows that enc28j60.ko
is not loaded. In contrast of, raspbian distro successfully managed with this -
module loaded successfully.
Also, I've read this thread:
http://lists.busybox.net/pipermail/buildroot/2016-December/178779.html. As I
understand, command
find /sys/ -name modalias -print0 | xargs -0 sort -u -z | xargs -0
modprobe -abq
does not work.
Regards,
Artem Synytsyn
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 6+ messages in thread* [Buildroot] [Bug 9541] Platform drivers autoloading from info in device tree does not work
2016-12-30 14:42 [Buildroot] [Bug 9541] New: Platform drivers autoloading from info in device tree does not work bugzilla at busybox.net
@ 2016-12-30 20:44 ` bugzilla at busybox.net
2016-12-30 22:26 ` bugzilla at busybox.net
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: bugzilla at busybox.net @ 2016-12-30 20:44 UTC (permalink / raw)
To: buildroot
https://bugs.busybox.net/show_bug.cgi?id=9541
Peter Korsgaard <jacmet@uclibc.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |ASSIGNED
--- Comment #1 from Peter Korsgaard <jacmet@uclibc.org> ---
It is hard to know what is going on without more details.
For drivers to load automatically, you need:
- Device tree snippet according to the defined bindings (in your case it sounds
like Documentation/devicetree/bindings/net/microchip,enc28j60.txt)
- Driver enabled as a module in the kernel
- A user space kernel module loader, E.G. mdev or (e)udev
If you still have problems, please provide more details about the above.
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 6+ messages in thread* [Buildroot] [Bug 9541] Platform drivers autoloading from info in device tree does not work
2016-12-30 14:42 [Buildroot] [Bug 9541] New: Platform drivers autoloading from info in device tree does not work bugzilla at busybox.net
2016-12-30 20:44 ` [Buildroot] [Bug 9541] " bugzilla at busybox.net
@ 2016-12-30 22:26 ` bugzilla at busybox.net
2016-12-31 8:55 ` bugzilla at busybox.net
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: bugzilla at busybox.net @ 2016-12-30 22:26 UTC (permalink / raw)
To: buildroot
https://bugs.busybox.net/show_bug.cgi?id=9541
--- Comment #2 from Artem Synytsyn <a.synytsyn@gmail.com> ---
Hello, Peter,
First of all I'll describe steps, which I've made.
1. Clone buildroot from official repo
2. make raspberrypi_defconfig
3. Add enc28j60.dtbo into overlays directory on boot partition
4. Add dtoverlay=enc28j60 into config.txt
After boot lsmod command output is empty(except ipv6 module, which is marked as
"permanent").
- I've used device tree overlay from the firmware, which was built by buildroot
itself. As for the snippet it is standard also, here is its code:
https://github.com/raspberrypi/linux/blob/rpi-4.4.y/arch/arm/boot/dts/overlays/enc28j60-overlay.dts.
Also, as I said, device tree node with this device is exposed in
/proc/device-tree, so I think it is ok.
- driver enc28j60.ko is enabled in kernel configuration as loadable, it is
present in /lib/modules filesystem. I can load it manually and it is ok too.
- mdev is present in system. And I think it is root of the problem, because
Raspbian distro has udev instead mdev and it successfully loads kernel module
based on info from device tree.
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 6+ messages in thread* [Buildroot] [Bug 9541] Platform drivers autoloading from info in device tree does not work
2016-12-30 14:42 [Buildroot] [Bug 9541] New: Platform drivers autoloading from info in device tree does not work bugzilla at busybox.net
2016-12-30 20:44 ` [Buildroot] [Bug 9541] " bugzilla at busybox.net
2016-12-30 22:26 ` bugzilla at busybox.net
@ 2016-12-31 8:55 ` bugzilla at busybox.net
2017-01-01 13:51 ` bugzilla at busybox.net
2017-01-02 11:03 ` bugzilla at busybox.net
4 siblings, 0 replies; 6+ messages in thread
From: bugzilla at busybox.net @ 2016-12-31 8:55 UTC (permalink / raw)
To: buildroot
https://bugs.busybox.net/show_bug.cgi?id=9541
--- Comment #3 from Peter Korsgaard <jacmet@uclibc.org> ---
I take it that you somewhere in that sequence enabled mdev? (E.G. System
configuration->/dev management (Dynamic using devtmpfs+mdev)
The module specifies the following aliases:
modinfo
target/lib/modules/4.4.36-v7/kernel/drivers/net/ethernet/microchip/enc28j60.ko
| grep alias
alias: spi:enc28j60
alias: of:N*T*Cmicrochip,enc28j60*
Can you first of all verify that you can load the module with these wildcards?
E.G.
modprobe 'spi:enc28j60'
lsmod | grep enc28j60
rmmod enc28j60.ko
modprobe 'of:N*T*Cmicrochip,enc28j60*'
lsmod | grep enc28j60
rmmod enc28j60.ko
And check what the modalias is for the /sys/bus/spi/* device?
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Buildroot] [Bug 9541] Platform drivers autoloading from info in device tree does not work
2016-12-30 14:42 [Buildroot] [Bug 9541] New: Platform drivers autoloading from info in device tree does not work bugzilla at busybox.net
` (2 preceding siblings ...)
2016-12-31 8:55 ` bugzilla at busybox.net
@ 2017-01-01 13:51 ` bugzilla at busybox.net
2017-01-02 11:03 ` bugzilla at busybox.net
4 siblings, 0 replies; 6+ messages in thread
From: bugzilla at busybox.net @ 2017-01-01 13:51 UTC (permalink / raw)
To: buildroot
https://bugs.busybox.net/show_bug.cgi?id=9541
--- Comment #4 from Artem Synytsyn <a.synytsyn@gmail.com> ---
Now it works! Really, problem was in BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV=y
option. Thank you very much!
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 6+ messages in thread* [Buildroot] [Bug 9541] Platform drivers autoloading from info in device tree does not work
2016-12-30 14:42 [Buildroot] [Bug 9541] New: Platform drivers autoloading from info in device tree does not work bugzilla at busybox.net
` (3 preceding siblings ...)
2017-01-01 13:51 ` bugzilla at busybox.net
@ 2017-01-02 11:03 ` bugzilla at busybox.net
4 siblings, 0 replies; 6+ messages in thread
From: bugzilla at busybox.net @ 2017-01-02 11:03 UTC (permalink / raw)
To: buildroot
https://bugs.busybox.net/show_bug.cgi?id=9541
Peter Korsgaard <jacmet@uclibc.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |WORKSFORME
Status|ASSIGNED |RESOLVED
--- Comment #5 from Peter Korsgaard <jacmet@uclibc.org> ---
Great, I'll close the issue then. Perhaps it makes sense to enable mdev for the
rpi*_defconfigs to make it easier to use?
--
You are receiving this mail because:
You are on the CC list for the bug.
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2017-01-02 11:03 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-12-30 14:42 [Buildroot] [Bug 9541] New: Platform drivers autoloading from info in device tree does not work bugzilla at busybox.net
2016-12-30 20:44 ` [Buildroot] [Bug 9541] " bugzilla at busybox.net
2016-12-30 22:26 ` bugzilla at busybox.net
2016-12-31 8:55 ` bugzilla at busybox.net
2017-01-01 13:51 ` bugzilla at busybox.net
2017-01-02 11:03 ` bugzilla at busybox.net
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox