staging: comedi: addi_eeprom: cleanup v_EepromCs76Read()
authorH Hartley Sweeten <hartleys@visionengravers.com>
Tue, 30 Oct 2012 00:05:43 +0000 (17:05 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 30 Oct 2012 17:50:13 +0000 (10:50 -0700)
commitc9535c8b235f1071e695838407887460a5ca6ab7
tree64296ac926462eb5b22d3e892e134844701ad40f
parent6311e135dff98d956a175f7bf3ad4431c17f3785
staging: comedi: addi_eeprom: cleanup v_EepromCs76Read()

Add namespace to the function by renaming the CamelCase function to
addi_eeprom_read_93c76().

Change the return type of the function to unsigned short and just
return the read value instead of passing it through a pointer.

Rename the CamelCase parameters and local variables.

Make addi_eeprom_cmd_93c76() return the last value so it does not
need to be calculated.

Rename the EE_READ and EE76_CMD_LEN defines so they have namespace
associated with the other 93c76 defines.

Cleanup the loop that reads the eeprom bits so it's a bit more concise.

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Ian Abbott <abbotti@mev.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/comedi/drivers/addi-data/addi_eeprom.c