]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/input/misc/sparcspkr.c
Merge branches 'release', 'acpi_pm_device_sleep_state' and 'battery' into release
[linux-2.6-omap-h63xx.git] / drivers / input / misc / sparcspkr.c
index 106c94f33b93ebb86847c4c10cc1897a4d122a39..fed3c375ccf39ff34ecb2a23fb720da5538fa153 100644 (file)
@@ -28,7 +28,7 @@ struct sparcspkr_state {
 
 static int ebus_spkr_event(struct input_dev *dev, unsigned int type, unsigned int code, int value)
 {
-       struct sparcspkr_state *state = dev_get_drvdata(dev->cdev.dev);
+       struct sparcspkr_state *state = dev_get_drvdata(dev->dev.parent);
        unsigned int count = 0;
        unsigned long flags;
 
@@ -61,7 +61,7 @@ static int ebus_spkr_event(struct input_dev *dev, unsigned int type, unsigned in
 
 static int isa_spkr_event(struct input_dev *dev, unsigned int type, unsigned int code, int value)
 {
-       struct sparcspkr_state *state = dev_get_drvdata(dev->cdev.dev);
+       struct sparcspkr_state *state = dev_get_drvdata(dev->dev.parent);
        unsigned int count = 0;
        unsigned long flags;
 
@@ -113,10 +113,10 @@ static int __devinit sparcspkr_probe(struct device *dev)
        input_dev->id.vendor = 0x001f;
        input_dev->id.product = 0x0001;
        input_dev->id.version = 0x0100;
-       input_dev->cdev.dev = dev;
+       input_dev->dev.parent = dev;
 
-       input_dev->evbit[0] = BIT(EV_SND);
-       input_dev->sndbit[0] = BIT(SND_BELL) | BIT(SND_TONE);
+       input_dev->evbit[0] = BIT_MASK(EV_SND);
+       input_dev->sndbit[0] = BIT_MASK(SND_BELL) | BIT_MASK(SND_TONE);
 
        input_dev->event = state->event;
 
@@ -195,7 +195,7 @@ static struct of_platform_driver ebus_beep_driver = {
        .name           = "beep",
        .match_table    = ebus_beep_match,
        .probe          = ebus_beep_probe,
-       .remove         = sparcspkr_remove,
+       .remove         = __devexit_p(sparcspkr_remove),
        .shutdown       = sparcspkr_shutdown,
 };
 
@@ -236,7 +236,7 @@ static struct of_platform_driver isa_beep_driver = {
        .name           = "beep",
        .match_table    = isa_beep_match,
        .probe          = isa_beep_probe,
-       .remove         = sparcspkr_remove,
+       .remove         = __devexit_p(sparcspkr_remove),
        .shutdown       = sparcspkr_shutdown,
 };