[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1409569440-10979-21-git-send-email-abbotti@mev.co.uk>
Date: Mon, 1 Sep 2014 12:03:52 +0100
From: Ian Abbott <abbotti@....co.uk>
To: driverdev-devel@...uxdriverproject.org
Cc: Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
Ian Abbott <abbotti@....co.uk>,
H Hartley Sweeten <hartleys@...ionengravers.com>,
linux-kernel@...r.kernel.org
Subject: [PATCH 20/28] staging: comedi: amplc_pci230: make `intr_running` a bitfield
Change the `intr_running` member of `struct pci230_private` into a
single-bit bitfield of type `bool` to save a bit of space.
Signed-off-by: Ian Abbott <abbotti@....co.uk>
---
drivers/staging/comedi/drivers/amplc_pci230.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/comedi/drivers/amplc_pci230.c b/drivers/staging/comedi/drivers/amplc_pci230.c
index 8959820..29e6016 100644
--- a/drivers/staging/comedi/drivers/amplc_pci230.c
+++ b/drivers/staging/comedi/drivers/amplc_pci230.c
@@ -507,8 +507,8 @@ struct pci230_private {
unsigned short adcg; /* ADCG register value */
unsigned char int_en; /* Interrupt enable bits */
unsigned char ier; /* Copy of interrupt enable register */
- unsigned char intr_running; /* Flag set in interrupt routine */
unsigned char res_owner[NUM_RESOURCES]; /* Shared resource owners */
+ bool intr_running:1; /* Flag set in interrupt routine */
bool ai_bipolar:1; /* Flag AI range is bipolar */
bool ao_bipolar:1; /* Flag AO range is bipolar */
};
@@ -2451,7 +2451,7 @@ static irqreturn_t pci230_interrupt(int irq, void *d)
*/
devpriv->ier = devpriv->int_en & ~status_int;
outb(devpriv->ier, dev->iobase + PCI230_INT_SCE);
- devpriv->intr_running = 1;
+ devpriv->intr_running = true;
devpriv->intr_cpuid = THISCPU;
spin_unlock_irqrestore(&devpriv->isr_spinlock, irqflags);
@@ -2487,7 +2487,7 @@ static irqreturn_t pci230_interrupt(int irq, void *d)
devpriv->ier = devpriv->int_en;
outb(devpriv->ier, dev->iobase + PCI230_INT_SCE);
}
- devpriv->intr_running = 0;
+ devpriv->intr_running = false;
spin_unlock_irqrestore(&devpriv->isr_spinlock, irqflags);
return IRQ_HANDLED;
--
2.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists