diff options
author | Johan Hovold <johan@hovoldconsulting.com> | 2015-12-03 19:18:04 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@google.com> | 2015-12-03 17:25:28 -0800 |
commit | c5e6b05ce4a18e7d6b73be0579c0698c8cc31b6c (patch) | |
tree | 07041f725ffb3c2f4b3768e706095cbe5d0a91bb /drivers/staging/greybus/core.c | |
parent | f0960d05f5ece96a7b2539e0adb92bfbfc83bf3e (diff) |
greybus: core: add interface id to interface and bundle uevents
Add the interface id to interface and bundle uevents.
This is needed to identify interfaces that are being removed (e.g. at
hot-unplug).
Signed-off-by: Johan Hovold <johan@hovoldconsulting.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@google.com>
Diffstat (limited to 'drivers/staging/greybus/core.c')
-rw-r--r-- | drivers/staging/greybus/core.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/drivers/staging/greybus/core.c b/drivers/staging/greybus/core.c index 3d8b7ef589bb..4ec7988eea26 100644 --- a/drivers/staging/greybus/core.c +++ b/drivers/staging/greybus/core.c @@ -102,6 +102,11 @@ static int greybus_uevent(struct device *dev, struct kobj_uevent_env *env) if (add_uevent_var(env, "BUS=%u", hd->bus_id)) return -ENOMEM; + if (intf) { + if (add_uevent_var(env, "INTERFACE=%u", intf->interface_id)) + return -ENOMEM; + } + if (bundle) { // FIXME // add a uevent that can "load" a bundle type |