Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 53432
b: refs/heads/master
c: 88a447a
h: refs/heads/master
v: v3
  • Loading branch information
Dmitry Torokhov committed Apr 12, 2007
1 parent d48592b commit 941ff59
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7791bdae71243050132ede7ea1558c828b69458f
refs/heads/master: 88a447a030bfec9f1e8666daf27d9d73c8c92448
3 changes: 3 additions & 0 deletions trunk/drivers/input/input.c
Original file line number Diff line number Diff line change
Expand Up @@ -1079,6 +1079,9 @@ int input_register_device(struct input_dev *dev)
snprintf(dev->cdev.class_id, sizeof(dev->cdev.class_id),
"input%ld", (unsigned long) atomic_inc_return(&input_no) - 1);

if (!dev->cdev.dev)
dev->cdev.dev = dev->dev.parent;

error = class_device_add(&dev->cdev);
if (error)
return error;
Expand Down
3 changes: 3 additions & 0 deletions trunk/include/linux/input.h
Original file line number Diff line number Diff line change
Expand Up @@ -972,6 +972,9 @@ struct input_dev {
unsigned int users;

struct class_device cdev;
union { /* temporarily so while we switching to struct device */
struct device *parent;
} dev;

struct list_head h_list;
struct list_head node;
Expand Down

0 comments on commit 941ff59

Please sign in to comment.