summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorH Hartley Sweeten <hsweeten@visionengravers.com>2013-12-05 16:54:11 -0700
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-12-06 13:10:03 -0800
commit25ad998892c05cf1a3f14ac882af8edbb8f62cc8 (patch)
tree369ce88115f67496982f27d862b491024433992f /drivers
parent4344158f3ea32eefd4942915c76d35afdc11b76e (diff)
staging: comedi: pcmuio: document the spinlock_t variables
Add some comments about the two spinlock_t variables in the private data. Also, add come comments for the functions that do not need to lock/unlock the spinlock. 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>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/staging/comedi/drivers/pcmuio.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/staging/comedi/drivers/pcmuio.c b/drivers/staging/comedi/drivers/pcmuio.c
index 6ee876d9905a..c83f5bd686cc 100644
--- a/drivers/staging/comedi/drivers/pcmuio.c
+++ b/drivers/staging/comedi/drivers/pcmuio.c
@@ -128,8 +128,8 @@ static const struct pcmuio_board pcmuio_boards[] = {
};
struct pcmuio_asic {
- spinlock_t pagelock;
- spinlock_t spinlock;
+ spinlock_t pagelock; /* protects the page registers */
+ spinlock_t spinlock; /* protects member variables */
int enabled_mask;
int active;
int stop_count;
@@ -295,6 +295,7 @@ static void pcmuio_reset(struct comedi_device *dev)
}
}
+/* chip->spinlock is already locked */
static void pcmuio_stop_intr(struct comedi_device *dev,
struct comedi_subdevice *s)
{
@@ -403,6 +404,7 @@ static irqreturn_t pcmuio_interrupt(int irq, void *d)
return handled ? IRQ_HANDLED : IRQ_NONE;
}
+/* chip->spinlock is already locked */
static int pcmuio_start_intr(struct comedi_device *dev,
struct comedi_subdevice *s)
{