summaryrefslogtreecommitdiffstats
path: root/drivers/ipack/ipack.c
diff options
context:
space:
mode:
authorFederico Vaga <federico.vaga@cern.ch>2014-09-02 17:31:40 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-09-24 08:13:13 +0200
commit36c53b3cc3fac6952af68f43609b15ae050c9318 (patch)
treebf265c1d5992290869d0d4caee7f7f398467dfa2 /drivers/ipack/ipack.c
parentipoctal: reset function istead of duplicate code (diff)
downloadlinux-36c53b3cc3fac6952af68f43609b15ae050c9318.tar.xz
linux-36c53b3cc3fac6952af68f43609b15ae050c9318.zip
ipack: save carrier owner to allow device to get it
There was not any kind of protection against carrier driver removal. In this way, device driver can 'get' the carrier driver when it is using it. Signed-off-by: Federico Vaga <federico.vaga@cern.ch> Acked-by: Samuel Iglesias Gonsalvez <siglesias@igalia.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/ipack/ipack.c')
-rw-r--r--drivers/ipack/ipack.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/ipack/ipack.c b/drivers/ipack/ipack.c
index d0016ba469ed..c0e7b624ce54 100644
--- a/drivers/ipack/ipack.c
+++ b/drivers/ipack/ipack.c
@@ -206,7 +206,8 @@ static struct bus_type ipack_bus_type = {
};
struct ipack_bus_device *ipack_bus_register(struct device *parent, int slots,
- const struct ipack_bus_ops *ops)
+ const struct ipack_bus_ops *ops,
+ struct module *owner)
{
int bus_nr;
struct ipack_bus_device *bus;
@@ -225,6 +226,7 @@ struct ipack_bus_device *ipack_bus_register(struct device *parent, int slots,
bus->parent = parent;
bus->slots = slots;
bus->ops = ops;
+ bus->owner = owner;
return bus;
}
EXPORT_SYMBOL_GPL(ipack_bus_register);