diff options
-rw-r--r-- | drivers/media/dvb/mantis/mantis_common.h | 2 | ||||
-rw-r--r-- | drivers/media/dvb/mantis/mantis_core.c | 11 |
2 files changed, 6 insertions, 7 deletions
diff --git a/drivers/media/dvb/mantis/mantis_common.h b/drivers/media/dvb/mantis/mantis_common.h index 0aa4001dea9c..75f07736e001 100644 --- a/drivers/media/dvb/mantis/mantis_common.h +++ b/drivers/media/dvb/mantis/mantis_common.h | |||
@@ -137,7 +137,7 @@ struct mantis_pci { | |||
137 | u32 sub_device_id; | 137 | u32 sub_device_id; |
138 | 138 | ||
139 | /* A12 A13 A14 */ | 139 | /* A12 A13 A14 */ |
140 | int gpio_status; | 140 | u32 gpio_status; |
141 | 141 | ||
142 | struct mantis_ca *mantis_ca; | 142 | struct mantis_ca *mantis_ca; |
143 | }; | 143 | }; |
diff --git a/drivers/media/dvb/mantis/mantis_core.c b/drivers/media/dvb/mantis/mantis_core.c index b94d0515de4b..3fd3b0801cf4 100644 --- a/drivers/media/dvb/mantis/mantis_core.c +++ b/drivers/media/dvb/mantis/mantis_core.c | |||
@@ -185,16 +185,15 @@ int mantis_core_exit(struct mantis_pci *mantis) | |||
185 | // Turn the given bit on or off. | 185 | // Turn the given bit on or off. |
186 | void gpio_set_bits(struct mantis_pci *mantis, u32 bitpos, u8 value) | 186 | void gpio_set_bits(struct mantis_pci *mantis, u32 bitpos, u8 value) |
187 | { | 187 | { |
188 | u32 currVal, newVal; | 188 | u32 cur; |
189 | |||
190 | currVal = mmread(MANTIS_GPIF_ADDR); | ||
191 | 189 | ||
190 | cur = mmread(MANTIS_GPIF_ADDR); | ||
192 | if (value) | 191 | if (value) |
193 | newVal = currVal | (1 << bitpos); | 192 | mantis->gpio_status = cur | (1 << bitpos); |
194 | else | 193 | else |
195 | newVal = currVal & (~(1 << bitpos)); | 194 | mantis->gpio_status = cur & (~(1 << bitpos)); |
196 | 195 | ||
197 | mmwrite(newVal, MANTIS_GPIF_ADDR); | 196 | mmwrite(mantis->gpio_status, MANTIS_GPIF_ADDR); |
198 | mmwrite(0x00, MANTIS_GPIF_DOUT); | 197 | mmwrite(0x00, MANTIS_GPIF_DOUT); |
199 | udelay(100); | 198 | udelay(100); |
200 | } | 199 | } |