Skip to content

Commit 293e639

Browse files
author
Dmitry Torokhov
committed
Input: misc devices - switch to using input_dev->dev.parent
In preparation for struct class_device -> struct device input core conversion, switch to using input_dev->dev.parent when specifying device position in sysfs tree. Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
1 parent 935e658 commit 293e639

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

‎drivers/input/misc/ixp4xx-beeper.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ static int __devinit ixp4xx_spkr_probe(struct platform_device *dev)
107107
input_dev->id.vendor = 0x001f;
108108
input_dev->id.product = 0x0001;
109109
input_dev->id.version = 0x0100;
110-
input_dev->cdev.dev = &dev->dev;
110+
input_dev->dev.parent = &dev->dev;
111111

112112
input_dev->evbit[0] = BIT(EV_SND);
113113
input_dev->sndbit[0] = BIT(SND_BELL) | BIT(SND_TONE);

‎drivers/input/misc/m68kspkr.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ static int __devinit m68kspkr_probe(struct platform_device *dev)
6363
input_dev->id.vendor = 0x001f;
6464
input_dev->id.product = 0x0001;
6565
input_dev->id.version = 0x0100;
66-
input_dev->cdev.dev = &dev->dev;
66+
input_dev->dev.parent = &dev->dev;
6767

6868
input_dev->evbit[0] = BIT(EV_SND);
6969
input_dev->sndbit[0] = BIT(SND_BELL) | BIT(SND_TONE);

‎drivers/input/misc/pcspkr.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ static int __devinit pcspkr_probe(struct platform_device *dev)
7878
pcspkr_dev->id.vendor = 0x001f;
7979
pcspkr_dev->id.product = 0x0001;
8080
pcspkr_dev->id.version = 0x0100;
81-
pcspkr_dev->cdev.dev = &dev->dev;
81+
pcspkr_dev->dev.parent = &dev->dev;
8282

8383
pcspkr_dev->evbit[0] = BIT(EV_SND);
8484
pcspkr_dev->sndbit[0] = BIT(SND_BELL) | BIT(SND_TONE);

‎drivers/input/misc/sparcspkr.c‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ struct sparcspkr_state {
2828

2929
static int ebus_spkr_event(struct input_dev *dev, unsigned int type, unsigned int code, int value)
3030
{
31-
struct sparcspkr_state *state = dev_get_drvdata(dev->cdev.dev);
31+
struct sparcspkr_state *state = dev_get_drvdata(dev->dev.parent);
3232
unsigned int count = 0;
3333
unsigned long flags;
3434

@@ -61,7 +61,7 @@ static int ebus_spkr_event(struct input_dev *dev, unsigned int type, unsigned in
6161

6262
static int isa_spkr_event(struct input_dev *dev, unsigned int type, unsigned int code, int value)
6363
{
64-
struct sparcspkr_state *state = dev_get_drvdata(dev->cdev.dev);
64+
struct sparcspkr_state *state = dev_get_drvdata(dev->dev.parent);
6565
unsigned int count = 0;
6666
unsigned long flags;
6767

@@ -113,7 +113,7 @@ static int __devinit sparcspkr_probe(struct device *dev)
113113
input_dev->id.vendor = 0x001f;
114114
input_dev->id.product = 0x0001;
115115
input_dev->id.version = 0x0100;
116-
input_dev->cdev.dev = dev;
116+
input_dev->dev.parent = dev;
117117

118118
input_dev->evbit[0] = BIT(EV_SND);
119119
input_dev->sndbit[0] = BIT(SND_BELL) | BIT(SND_TONE);

0 commit comments

Comments
 (0)