diff options
author | Luca Ellero <luca.ellero@brickedbrain.com> | 2014-07-10 11:02:18 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-07-10 15:09:26 -0700 |
commit | 7692320c08a2f4ea255a2ab9cff66d7786f2a76d (patch) | |
tree | 95807226bb4344d70c00bf5f535b653a48118e03 /drivers/staging/ced1401 | |
parent | e62221f95e828ee90da811d402af25f2f03b4680 (diff) | |
download | blackbird-op-linux-7692320c08a2f4ea255a2ab9cff66d7786f2a76d.tar.gz blackbird-op-linux-7692320c08a2f4ea255a2ab9cff66d7786f2a76d.zip |
staging: ced1401: fix ced_line_count()
Rename camel case arguments and locals in function ced_line_count()
Signed-off-by: Luca Ellero <luca.ellero@brickedbrain.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/ced1401')
-rw-r--r-- | drivers/staging/ced1401/ced_ioc.c | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/drivers/staging/ced1401/ced_ioc.c b/drivers/staging/ced1401/ced_ioc.c index 414056f5d9bd..d7645c4d5cce 100644 --- a/drivers/staging/ced1401/ced_ioc.c +++ b/drivers/staging/ced1401/ced_ioc.c @@ -551,7 +551,7 @@ int ced_stat_1401(struct ced_data *ced) ****************************************************************************/ int ced_line_count(struct ced_data *ced) { - int iReturn = 0; /* will be count of line ends */ + int ret = 0; /* will be count of line ends */ mutex_lock(&ced->io_mutex); /* Protect disconnect from new i/o */ ced_allowi(ced); /* Make sure char reads are running */ @@ -559,21 +559,23 @@ int ced_line_count(struct ced_data *ced) spin_lock_irq(&ced->char_in_lock); /* Get protection */ if (ced->num_input > 0) { /* worth looking? */ - unsigned int dwIndex = ced->in_buff_get; /* start at first available */ - unsigned int dwEnd = ced->in_buff_put; /* Position for search end */ + /* start at first available */ + unsigned int index = ced->in_buff_get; + /* Position for search end */ + unsigned int end = ced->in_buff_put; do { - if (ced->input_buffer[dwIndex++] == CR_CHAR) - ++iReturn; /* inc count if CR */ + if (ced->input_buffer[index++] == CR_CHAR) + ++ret; /* inc count if CR */ - if (dwIndex >= INBUF_SZ) /* see if we fall off buff */ - dwIndex = 0; - } while (dwIndex != dwEnd); /* go to last available */ + if (index >= INBUF_SZ) /* see if we fall off buff */ + index = 0; + } while (index != end); /* go to last available */ } spin_unlock_irq(&ced->char_in_lock); - dev_dbg(&ced->interface->dev, "%s: returned %d\n", __func__, iReturn); + dev_dbg(&ced->interface->dev, "%s: returned %d\n", __func__, ret); mutex_unlock(&ced->io_mutex); /* Protect disconnect from new i/o */ - return iReturn; + return ret; } /**************************************************************************** |