Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Staging: comedi: addi-data: clean-up variable use in hwdrv_apci035.c

The variable ui_Command is as of right now being cleared to a
value of zero between everytime that it writes to a port and then takes a
new value from a port. Seems like this zeroing is unnecessary, so we can
just remove these lines.

Signed-off-by: Chase Southwood <chase.southwood@yahoo.com>
Reviewed-by: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Chase Southwood and committed by
Greg Kroah-Hartman
ea6ff788 c095fad3

+4 -8
+4 -8
drivers/staging/comedi/drivers/addi-data/hwdrv_apci035.c
··· 182 182 else 183 183 ui_Mode = 0; 184 184 185 - /* ui_Command = inl(devpriv->iobase+((i_WatchdogNbr-1)*32)+12); */ 186 185 ui_Command = 0; 187 - /* ui_Command = ui_Command & 0xFFFFF9FEUL; */ 188 186 outl(ui_Command, devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 189 - ui_Command = 0; 187 + 190 188 ui_Command = inl(devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 191 189 192 190 /* Set the reload value */ ··· 222 224 } 223 225 224 226 outl(ui_Command, devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 225 - ui_Command = 0; 227 + 226 228 ui_Command = inl(devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 227 229 228 230 /* Disable the hardware trigger */ ··· 233 235 ui_Command = ui_Command | (data[5] << 5); 234 236 } 235 237 outl(ui_Command, devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 236 - ui_Command = 0; 238 + 237 239 ui_Command = inl(devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 238 240 239 241 /* Disable the hardware gate */ ··· 244 246 ui_Command = ui_Command | (data[7] << 7); 245 247 } 246 248 outl(ui_Command, devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 247 - ui_Command = 0; 249 + 248 250 ui_Command = inl(devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 249 251 250 252 /* Disable the hardware output */ ··· 264 266 devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 28); 265 267 } 266 268 267 - ui_Command = 0; 268 269 ui_Command = inl(devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 269 270 270 271 /* Disable the hardware output */ ··· 274 277 outl(ui_Command, devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 275 278 276 279 /* Enable the watchdog interrupt */ 277 - ui_Command = 0; 278 280 ui_Command = inl(devpriv->iobase + ((i_WatchdogNbr - 1) * 32) + 12); 279 281 280 282 /* Set the interrupt selection */