summaryrefslogtreecommitdiff
path: root/drivers/staging/comedi
diff options
context:
space:
mode:
authorIan Abbott <abbotti@mev.co.uk>2017-03-08 18:44:25 +0000
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2017-03-12 14:57:00 +0100
commitef3ab9f85c9c3ed3eb2ef8c07ce969a5ce861ec6 (patch)
tree8dbdb94640fa32940b7a6393cabee37e7ba25c61 /drivers/staging/comedi
parent713eab88c66de4ef0a851f30f24ea8b922f6791b (diff)
staging: comedi: jr3_pci: rename data to sensor
Rename the `channel[x].data` member of `struct jr3_t` to `channel[x].sensor` to match its type `struct jr3_sensor`. Also rename local variable `ch0data` in `jr3_pci_show_copyright()` to `sensor0` for consistency. It points to the `struct jr3_sensor` embedded in the registers for "channel" 0. Signed-off-by: Ian Abbott <abbotti@mev.co.uk> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/comedi')
-rw-r--r--drivers/staging/comedi/drivers/jr3_pci.c10
-rw-r--r--drivers/staging/comedi/drivers/jr3_pci.h2
2 files changed, 6 insertions, 6 deletions
diff --git a/drivers/staging/comedi/drivers/jr3_pci.c b/drivers/staging/comedi/drivers/jr3_pci.c
index 12edced1ee54..e8f0b08198d9 100644
--- a/drivers/staging/comedi/drivers/jr3_pci.c
+++ b/drivers/staging/comedi/drivers/jr3_pci.c
@@ -639,7 +639,7 @@ jr3_pci_alloc_spriv(struct comedi_device *dev, struct comedi_subdevice *s)
if (!spriv)
return NULL;
- spriv->sensor = &iobase->channel[s->index].data;
+ spriv->sensor = &iobase->channel[s->index].sensor;
for (j = 0; j < 8; j++) {
spriv->range[j].l.length = 1;
@@ -671,12 +671,12 @@ jr3_pci_alloc_spriv(struct comedi_device *dev, struct comedi_subdevice *s)
static void jr3_pci_show_copyright(struct comedi_device *dev)
{
struct jr3_t __iomem *iobase = dev->mmio;
- struct jr3_sensor __iomem *ch0data = &iobase->channel[0].data;
- char copy[ARRAY_SIZE(ch0data->copyright) + 1];
+ struct jr3_sensor __iomem *sensor0 = &iobase->channel[0].sensor;
+ char copy[ARRAY_SIZE(sensor0->copyright) + 1];
int i;
- for (i = 0; i < ARRAY_SIZE(ch0data->copyright); i++)
- copy[i] = (char)(get_u16(&ch0data->copyright[i]) >> 8);
+ for (i = 0; i < ARRAY_SIZE(sensor0->copyright); i++)
+ copy[i] = (char)(get_u16(&sensor0->copyright[i]) >> 8);
copy[i] = '\0';
dev_dbg(dev->class_dev, "Firmware copyright: %s\n", copy);
}
diff --git a/drivers/staging/comedi/drivers/jr3_pci.h b/drivers/staging/comedi/drivers/jr3_pci.h
index bde2047039e7..b4d333d57185 100644
--- a/drivers/staging/comedi/drivers/jr3_pci.h
+++ b/drivers/staging/comedi/drivers/jr3_pci.h
@@ -727,7 +727,7 @@ struct jr3_sensor {
struct jr3_t {
struct {
u32 program_lo[0x4000]; /* 0x00000 - 0x10000 */
- struct jr3_sensor data; /* 0x10000 - 0x10c00 */
+ struct jr3_sensor sensor; /* 0x10000 - 0x10c00 */
char pad2[0x30000 - 0x00c00]; /* 0x10c00 - 0x40000 */
u32 program_hi[0x8000]; /* 0x40000 - 0x60000 */
u32 reset; /* 0x60000 - 0x60004 */