diff options
author | Federico Fuga <fuga@studiofuga.com> | 2012-07-16 10:36:51 +0300 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-07-19 08:58:57 -0700 |
commit | c8ed7cf355f41b649524029c49f101d878499482 (patch) | |
tree | cac2bc33c83b69a8157c9f871b06e434232d1954 | |
parent | 1214b7852425b78a2b73b0a759ec55210340396d (diff) | |
download | kernel-adaptation-pc-c8ed7cf355f41b649524029c49f101d878499482.tar.gz kernel-adaptation-pc-c8ed7cf355f41b649524029c49f101d878499482.tar.bz2 kernel-adaptation-pc-c8ed7cf355f41b649524029c49f101d878499482.zip |
rpmsg: fix dependency on initialization order
commit 9634252617441991b01dacaf4040866feecaf36f upstream.
When rpmsg drivers are built into the kernel, they must not initialize
before the rpmsg bus does, otherwise they'd trigger a BUG() in
drivers/base/driver.c line 169 (driver_register()).
To fix that, and to stop depending on arbitrary linkage ordering of
those built-in rpmsg drivers, we make the rpmsg bus initialize at
subsys_initcall.
Signed-off-by: Federico Fuga <fuga@studiofuga.com>
[ohad: rewrite the commit log]
Signed-off-by: Ohad Ben-Cohen <ohad@wizery.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r-- | drivers/rpmsg/virtio_rpmsg_bus.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/rpmsg/virtio_rpmsg_bus.c b/drivers/rpmsg/virtio_rpmsg_bus.c index 39d3aa41add..f56c8ba3a86 100644 --- a/drivers/rpmsg/virtio_rpmsg_bus.c +++ b/drivers/rpmsg/virtio_rpmsg_bus.c @@ -1085,7 +1085,7 @@ static int __init rpmsg_init(void) return ret; } -module_init(rpmsg_init); +subsys_initcall(rpmsg_init); static void __exit rpmsg_fini(void) { |