isa: Call isa_bus_init before dependent ISA bus drivers register
authorWilliam Breathitt Gray <vilhelm.gray@gmail.com>
Wed, 11 May 2016 21:01:40 +0000 (17:01 -0400)
committerBen Hutchings <ben@decadent.org.uk>
Mon, 22 Aug 2016 21:37:15 +0000 (22:37 +0100)
commitb7fd43a3690cc97d677010977c562fa5c3f556b6
treea3fc978c9b5b930cdc85b36ccc36a98a0e2dba6b
parent807e8c8101d068fe51e635243104933ae4beb458
isa: Call isa_bus_init before dependent ISA bus drivers register

commit 32a5a0c047343b11f581f663a2309cf43d13466f upstream.

The isa_bus_init function must be called before drivers which utilize
the ISA bus driver are registered. A race condition for initilization
exists if device_initcall is used (the isa_bus_init callback is placed
in the same initcall level as dependent drivers which use module_init).
This patch ensures that isa_bus_init is called first by utilizing
postcore_initcall in favor of device_initcall.

Fixes: a5117ba7da37 ("[PATCH] Driver model: add ISA bus")
Cc: Rene Herman <rene.herman@keyaccess.nl>
Signed-off-by: William Breathitt Gray <vilhelm.gray@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
drivers/base/isa.c