summaryrefslogtreecommitdiff
path: root/drivers/staging/comedi/drivers/8253.h
diff options
context:
space:
mode:
authorBill Pemberton <wfp5p@virginia.edu>2009-03-27 11:29:18 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2009-06-19 11:00:27 -0700
commit67d83b4fb96ab304a47ba5af9a99818b38c9fd3e (patch)
tree1896e0878b546646c33991374d0db724c6569c02 /drivers/staging/comedi/drivers/8253.h
parent6a037d5f655fbf1853d28cd8a02ffe5c466d81a5 (diff)
Staging: comedi: remove C99 comments in 8253.h
Signed-off-by: Bill Pemberton <wfp5p@virginia.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/comedi/drivers/8253.h')
-rw-r--r--drivers/staging/comedi/drivers/8253.h46
1 files changed, 23 insertions, 23 deletions
diff --git a/drivers/staging/comedi/drivers/8253.h b/drivers/staging/comedi/drivers/8253.h
index 08a11a5a16e6..bcf0170e93d7 100644
--- a/drivers/staging/comedi/drivers/8253.h
+++ b/drivers/staging/comedi/drivers/8253.h
@@ -205,7 +205,7 @@ static inline void i8253_cascade_ns_to_timer_2div(int i8253_osc_base,
}
*nanosec = div1 * div2 * i8253_osc_base;
- *d1 = div1 & 0xffff; // masking is done since counter maps zero to 0x10000
+ *d1 = div1 & 0xffff; /* masking is done since counter maps zero to 0x10000 */
*d2 = div2 & 0xffff;
return;
}
@@ -247,12 +247,12 @@ static inline int i8254_load(unsigned long base_address, unsigned int regshift,
return -1;
byte = counter_number << 6;
- byte |= 0x30; // load low then high byte
- byte |= (mode << 1); // set counter mode
+ byte |= 0x30; /* load low then high byte */
+ byte |= (mode << 1); /* set counter mode */
outb(byte, base_address + (i8254_control_reg << regshift));
- byte = count & 0xff; // lsb of counter value
+ byte = count & 0xff; /* lsb of counter value */
outb(byte, base_address + (counter_number << regshift));
- byte = (count >> 8) & 0xff; // msb of counter value
+ byte = (count >> 8) & 0xff; /* msb of counter value */
outb(byte, base_address + (counter_number << regshift));
return 0;
@@ -273,12 +273,12 @@ static inline int i8254_mm_load(void *base_address, unsigned int regshift,
return -1;
byte = counter_number << 6;
- byte |= 0x30; // load low then high byte
- byte |= (mode << 1); // set counter mode
+ byte |= 0x30; /* load low then high byte */
+ byte |= (mode << 1); /* set counter mode */
writeb(byte, base_address + (i8254_control_reg << regshift));
- byte = count & 0xff; // lsb of counter value
+ byte = count & 0xff; /* lsb of counter value */
writeb(byte, base_address + (counter_number << regshift));
- byte = (count >> 8) & 0xff; // msb of counter value
+ byte = (count >> 8) & 0xff; /* msb of counter value */
writeb(byte, base_address + (counter_number << regshift));
return 0;
@@ -294,13 +294,13 @@ static inline int i8254_read(unsigned long base_address, unsigned int regshift,
if (counter_number > 2)
return -1;
- // latch counter
+ /* latch counter */
byte = counter_number << 6;
outb(byte, base_address + (i8254_control_reg << regshift));
- // read lsb
+ /* read lsb */
ret = inb(base_address + (counter_number << regshift));
- // read msb
+ /* read msb */
ret += inb(base_address + (counter_number << regshift)) << 8;
return ret;
@@ -315,13 +315,13 @@ static inline int i8254_mm_read(void *base_address, unsigned int regshift,
if (counter_number > 2)
return -1;
- // latch counter
+ /* latch counter */
byte = counter_number << 6;
writeb(byte, base_address + (i8254_control_reg << regshift));
- // read lsb
+ /* read lsb */
ret = readb(base_address + (counter_number << regshift));
- // read msb
+ /* read msb */
ret += readb(base_address + (counter_number << regshift)) << 8;
return ret;
@@ -336,9 +336,9 @@ static inline void i8254_write(unsigned long base_address,
if (counter_number > 2)
return;
- byte = count & 0xff; // lsb of counter value
+ byte = count & 0xff; /* lsb of counter value */
outb(byte, base_address + (counter_number << regshift));
- byte = (count >> 8) & 0xff; // msb of counter value
+ byte = (count >> 8) & 0xff; /* msb of counter value */
outb(byte, base_address + (counter_number << regshift));
}
@@ -350,9 +350,9 @@ static inline void i8254_mm_write(void *base_address,
if (counter_number > 2)
return;
- byte = count & 0xff; // lsb of counter value
+ byte = count & 0xff; /* lsb of counter value */
writeb(byte, base_address + (counter_number << regshift));
- byte = (count >> 8) & 0xff; // msb of counter value
+ byte = (count >> 8) & 0xff; /* msb of counter value */
writeb(byte, base_address + (counter_number << regshift));
}
@@ -374,8 +374,8 @@ static inline int i8254_set_mode(unsigned long base_address,
return -1;
byte = counter_number << 6;
- byte |= 0x30; // load low then high byte
- byte |= mode; // set counter mode and BCD|binary
+ byte |= 0x30; /* load low then high byte */
+ byte |= mode; /* set counter mode and BCD|binary */
outb(byte, base_address + (i8254_control_reg << regshift));
return 0;
@@ -392,8 +392,8 @@ static inline int i8254_mm_set_mode(void *base_address,
return -1;
byte = counter_number << 6;
- byte |= 0x30; // load low then high byte
- byte |= mode; // set counter mode and BCD|binary
+ byte |= 0x30; /* load low then high byte */
+ byte |= mode; /* set counter mode and BCD|binary */
writeb(byte, base_address + (i8254_control_reg << regshift));
return 0;