summaryrefslogtreecommitdiffstats
path: root/drivers/hid
diff options
context:
space:
mode:
authorJiri Kosina <jkosina@suse.cz>2008-12-04 16:16:46 +0100
committerJiri Kosina <jkosina@suse.cz>2009-01-04 01:00:52 +0100
commitaae6c286dad33c7f2c6992b9e310a371f2ae377e (patch)
tree797315ece85368c2ed1e646dfeebb79d4823b3f8 /drivers/hid
parent3a6f82f7a22cf19687f556997c6978b31c109360 (diff)
downloadop-kernel-dev-aae6c286dad33c7f2c6992b9e310a371f2ae377e.zip
op-kernel-dev-aae6c286dad33c7f2c6992b9e310a371f2ae377e.tar.gz
HID: set proper dev.parent in hidraw
We need to properly set parent of the hidraw device (which is the corresponding physical device itself) in order to hidraw devices not end up under virtual device tree. Reported-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid')
-rw-r--r--drivers/hid/hidraw.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hid/hidraw.c b/drivers/hid/hidraw.c
index 975edd8..aab5911 100644
--- a/drivers/hid/hidraw.c
+++ b/drivers/hid/hidraw.c
@@ -357,7 +357,7 @@ int hidraw_connect(struct hid_device *hid)
goto out;
}
- dev->dev = device_create(hidraw_class, NULL, MKDEV(hidraw_major, minor),
+ dev->dev = device_create(hidraw_class, &hid->dev, MKDEV(hidraw_major, minor),
NULL, "%s%d", "hidraw", minor);
if (IS_ERR(dev->dev)) {
OpenPOWER on IntegriCloud