diff options
author | Axel Lin <axel.lin@gmail.com> | 2012-09-13 02:10:34 -0400 |
---|---|---|
committer | Jiri Kosina <jkosina@suse.cz> | 2012-09-17 07:08:30 -0400 |
commit | 372d297b8c8968d7a05e4a63911bea8ec335e031 (patch) | |
tree | bc413752bc0fae9f254fb0fb0e3c66a906933f21 /drivers/hid/hid-prodikeys.c | |
parent | 4629fd160f7da96b9e6b5abf3f65dbf53642467b (diff) |
HID: prodikeys: Remove unnecessary casts of void pointers
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers/hid/hid-prodikeys.c')
-rw-r--r-- | drivers/hid/hid-prodikeys.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/hid/hid-prodikeys.c b/drivers/hid/hid-prodikeys.c index b71b77ab0dc7..ec8ca3336315 100644 --- a/drivers/hid/hid-prodikeys.c +++ b/drivers/hid/hid-prodikeys.c | |||
@@ -105,7 +105,7 @@ static ssize_t show_channel(struct device *dev, | |||
105 | struct device_attribute *attr, char *buf) | 105 | struct device_attribute *attr, char *buf) |
106 | { | 106 | { |
107 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); | 107 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); |
108 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 108 | struct pk_device *pk = hid_get_drvdata(hdev); |
109 | 109 | ||
110 | dbg_hid("pcmidi sysfs read channel=%u\n", pk->pm->midi_channel); | 110 | dbg_hid("pcmidi sysfs read channel=%u\n", pk->pm->midi_channel); |
111 | 111 | ||
@@ -118,7 +118,7 @@ static ssize_t store_channel(struct device *dev, | |||
118 | struct device_attribute *attr, const char *buf, size_t count) | 118 | struct device_attribute *attr, const char *buf, size_t count) |
119 | { | 119 | { |
120 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); | 120 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); |
121 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 121 | struct pk_device *pk = hid_get_drvdata(hdev); |
122 | 122 | ||
123 | unsigned channel = 0; | 123 | unsigned channel = 0; |
124 | 124 | ||
@@ -142,7 +142,7 @@ static ssize_t show_sustain(struct device *dev, | |||
142 | struct device_attribute *attr, char *buf) | 142 | struct device_attribute *attr, char *buf) |
143 | { | 143 | { |
144 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); | 144 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); |
145 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 145 | struct pk_device *pk = hid_get_drvdata(hdev); |
146 | 146 | ||
147 | dbg_hid("pcmidi sysfs read sustain=%u\n", pk->pm->midi_sustain); | 147 | dbg_hid("pcmidi sysfs read sustain=%u\n", pk->pm->midi_sustain); |
148 | 148 | ||
@@ -155,7 +155,7 @@ static ssize_t store_sustain(struct device *dev, | |||
155 | struct device_attribute *attr, const char *buf, size_t count) | 155 | struct device_attribute *attr, const char *buf, size_t count) |
156 | { | 156 | { |
157 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); | 157 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); |
158 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 158 | struct pk_device *pk = hid_get_drvdata(hdev); |
159 | 159 | ||
160 | unsigned sustain = 0; | 160 | unsigned sustain = 0; |
161 | 161 | ||
@@ -181,7 +181,7 @@ static ssize_t show_octave(struct device *dev, | |||
181 | struct device_attribute *attr, char *buf) | 181 | struct device_attribute *attr, char *buf) |
182 | { | 182 | { |
183 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); | 183 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); |
184 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 184 | struct pk_device *pk = hid_get_drvdata(hdev); |
185 | 185 | ||
186 | dbg_hid("pcmidi sysfs read octave=%d\n", pk->pm->midi_octave); | 186 | dbg_hid("pcmidi sysfs read octave=%d\n", pk->pm->midi_octave); |
187 | 187 | ||
@@ -194,7 +194,7 @@ static ssize_t store_octave(struct device *dev, | |||
194 | struct device_attribute *attr, const char *buf, size_t count) | 194 | struct device_attribute *attr, const char *buf, size_t count) |
195 | { | 195 | { |
196 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); | 196 | struct hid_device *hdev = container_of(dev, struct hid_device, dev); |
197 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 197 | struct pk_device *pk = hid_get_drvdata(hdev); |
198 | 198 | ||
199 | int octave = 0; | 199 | int octave = 0; |
200 | 200 | ||
@@ -759,7 +759,7 @@ static int pk_input_mapping(struct hid_device *hdev, struct hid_input *hi, | |||
759 | struct hid_field *field, struct hid_usage *usage, | 759 | struct hid_field *field, struct hid_usage *usage, |
760 | unsigned long **bit, int *max) | 760 | unsigned long **bit, int *max) |
761 | { | 761 | { |
762 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 762 | struct pk_device *pk = hid_get_drvdata(hdev); |
763 | struct pcmidi_snd *pm; | 763 | struct pcmidi_snd *pm; |
764 | 764 | ||
765 | pm = pk->pm; | 765 | pm = pk->pm; |
@@ -777,7 +777,7 @@ static int pk_input_mapping(struct hid_device *hdev, struct hid_input *hi, | |||
777 | static int pk_raw_event(struct hid_device *hdev, struct hid_report *report, | 777 | static int pk_raw_event(struct hid_device *hdev, struct hid_report *report, |
778 | u8 *data, int size) | 778 | u8 *data, int size) |
779 | { | 779 | { |
780 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 780 | struct pk_device *pk = hid_get_drvdata(hdev); |
781 | int ret = 0; | 781 | int ret = 0; |
782 | 782 | ||
783 | if (1 == pk->pm->ifnum) { | 783 | if (1 == pk->pm->ifnum) { |
@@ -858,7 +858,7 @@ err_free_pk: | |||
858 | 858 | ||
859 | static void pk_remove(struct hid_device *hdev) | 859 | static void pk_remove(struct hid_device *hdev) |
860 | { | 860 | { |
861 | struct pk_device *pk = (struct pk_device *)hid_get_drvdata(hdev); | 861 | struct pk_device *pk = hid_get_drvdata(hdev); |
862 | struct pcmidi_snd *pm; | 862 | struct pcmidi_snd *pm; |
863 | 863 | ||
864 | pm = pk->pm; | 864 | pm = pk->pm; |