summaryrefslogtreecommitdiffstats
path: root/drivers/char/mwave
diff options
context:
space:
mode:
authorJeff Garzik <jeff@garzik.org>2007-10-31 05:20:49 -0400
committerJeff Garzik <jgarzik@redhat.com>2008-04-20 19:03:43 -0400
commita6f97b293b08877d945ea3f28926aa446dd7ca2e (patch)
tree8e2c2e585ef056d36023dfb384b2806bebf312d3 /drivers/char/mwave
parente8f39549580e04e0b8edd11bae834ae7f8322fc8 (diff)
downloadop-kernel-dev-a6f97b293b08877d945ea3f28926aa446dd7ca2e.zip
op-kernel-dev-a6f97b293b08877d945ea3f28926aa446dd7ca2e.tar.gz
drivers/char: minor irq handler cleanups
- remove always-false tests - don't overload 'irq' argument, pass data properly via dev_id - remove pointless casts from void* Signed-off-by: Jeff Garzik <jgarzik@redhat.com>
Diffstat (limited to 'drivers/char/mwave')
-rw-r--r--drivers/char/mwave/tp3780i.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/drivers/char/mwave/tp3780i.c b/drivers/char/mwave/tp3780i.c
index f282976..37fe80d 100644
--- a/drivers/char/mwave/tp3780i.c
+++ b/drivers/char/mwave/tp3780i.c
@@ -97,20 +97,24 @@ static void EnableSRAM(THINKPAD_BD_DATA * pBDData)
static irqreturn_t UartInterrupt(int irq, void *dev_id)
{
+ int irqno = (int)(unsigned long) dev_id;
+
PRINTK_3(TRACE_TP3780I,
- "tp3780i::UartInterrupt entry irq %x dev_id %p\n", irq, dev_id);
+ "tp3780i::UartInterrupt entry irq %x dev_id %p\n", irqno, dev_id);
return IRQ_HANDLED;
}
static irqreturn_t DspInterrupt(int irq, void *dev_id)
{
+ int irqno = (int)(unsigned long) dev_id;
+
pMWAVE_DEVICE_DATA pDrvData = &mwave_s_mdd;
DSP_3780I_CONFIG_SETTINGS *pSettings = &pDrvData->rBDData.rDspSettings;
unsigned short usDspBaseIO = pSettings->usDspBaseIO;
unsigned short usIPCSource = 0, usIsolationMask, usPCNum;
PRINTK_3(TRACE_TP3780I,
- "tp3780i::DspInterrupt entry irq %x dev_id %p\n", irq, dev_id);
+ "tp3780i::DspInterrupt entry irq %x dev_id %p\n", irqno, dev_id);
if (dsp3780I_GetIPCSource(usDspBaseIO, &usIPCSource) == 0) {
PRINTK_2(TRACE_TP3780I,
@@ -361,14 +365,16 @@ int tp3780I_EnableDSP(THINKPAD_BD_DATA * pBDData)
pSettings->bPllBypass = TP_CFG_PllBypass;
pSettings->usChipletEnable = TP_CFG_ChipletEnable;
- if (request_irq(pSettings->usUartIrq, &UartInterrupt, 0, "mwave_uart", NULL)) {
+ if (request_irq(pSettings->usUartIrq, &UartInterrupt, 0, "mwave_uart",
+ (void *)(unsigned long) pSettings->usUartIrq)) {
PRINTK_ERROR(KERN_ERR_MWAVE "tp3780i::tp3780I_EnableDSP: Error: Could not get UART IRQ %x\n", pSettings->usUartIrq);
goto exit_cleanup;
} else { /* no conflict just release */
free_irq(pSettings->usUartIrq, NULL);
}
- if (request_irq(pSettings->usDspIrq, &DspInterrupt, 0, "mwave_3780i", NULL)) {
+ if (request_irq(pSettings->usDspIrq, &DspInterrupt, 0, "mwave_3780i",
+ (void *)(unsigned long) pSettings->usDspIrq)) {
PRINTK_ERROR("tp3780i::tp3780I_EnableDSP: Error: Could not get 3780i IRQ %x\n", pSettings->usDspIrq);
goto exit_cleanup;
} else {
OpenPOWER on IntegriCloud