Skip to content

Commit

Permalink
staging: comedi: addi_eeprom: cleanup v_EepromClock76()
Browse files Browse the repository at this point in the history
Add namespace to the function by renaming the CamelCase function to
addi_eeprom_clk_93c76().

Rename the CamelCase parameter, dw_RegisterValue, to simply 'val'.

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>
  • Loading branch information
H Hartley Sweeten authored and Greg Kroah-Hartman committed Oct 30, 2012
1 parent d615de2 commit 7522e09
Showing 1 changed file with 5 additions and 8 deletions.
13 changes: 5 additions & 8 deletions drivers/staging/comedi/drivers/addi-data/addi_eeprom.c
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,12 @@ struct str_AnalogInputHeader {
unsigned char b_Resolution;
};

static void v_EepromClock76(unsigned long iobase,
unsigned int dw_RegisterValue)
static void addi_eeprom_clk_93c76(unsigned long iobase, unsigned int val)
{
outl(dw_RegisterValue & ~EE93C76_CLK_BIT, iobase);
outl(val & ~EE93C76_CLK_BIT, iobase);
udelay(100);

outl(dw_RegisterValue | EE93C76_CLK_BIT, iobase);
outl(val | EE93C76_CLK_BIT, iobase);
udelay(100);
}

Expand All @@ -144,8 +143,7 @@ static void v_EepromSendCommand76(unsigned long iobase,
outl(dw_RegisterValue, iobase);
udelay(100);

/* Trigger the EEPROM clock */
v_EepromClock76(iobase, dw_RegisterValue);
addi_eeprom_clk_93c76(iobase, dw_RegisterValue);
}
}

Expand All @@ -169,8 +167,7 @@ static void v_EepromCs76Read(unsigned long iobase,

/* Get the 16-bit value */
for (c_BitPos = 0; c_BitPos < 16; c_BitPos++) {
/* Trigger the EEPROM clock */
v_EepromClock76(iobase, dw_RegisterValue);
addi_eeprom_clk_93c76(iobase, dw_RegisterValue);

/* Get the result bit */
dw_RegisterValueRead = inl(iobase);
Expand Down

0 comments on commit 7522e09

Please sign in to comment.