Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 614bd02f authored by Chase Southwood's avatar Chase Southwood Committed by Greg Kroah-Hartman
Browse files

Staging: comedi: addi-data: replace printk() with dev_err() in hwdrv_apci1564.c



There were a small handful of printk() calls in hwdrv_apci1564.c.  It is
generally better to use dev_err() for error messages instead, so I
switched all the printk() calls out, as well as cleaned up the error
strings.

Signed-off-by: default avatarChase Southwood <chase.southwood@yahoo.com>
Reviewed-by: default avatarIan Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 988bcffd
Loading
Loading
Loading
Loading
+4 −4
Original line number Original line Diff line number Diff line
@@ -414,7 +414,7 @@ static int i_APCI1564_ConfigTimerCounterWatchdog(struct comedi_device *dev,
			devpriv->iobase + ((data[5] - 1) * 0x20) +
			devpriv->iobase + ((data[5] - 1) * 0x20) +
			APCI1564_TCW_PROG);
			APCI1564_TCW_PROG);
	} else {
	} else {
		printk(" Invalid subdevice.");
		dev_err(dev->class_dev, "Invalid subdevice.\n");
	}
	}


	return insn->n;
	return insn->n;
@@ -472,7 +472,7 @@ static int i_APCI1564_StartStopWriteTimerCounterWatchdog(struct comedi_device *d
				APCI1564_TCW_PROG);
				APCI1564_TCW_PROG);
			break;
			break;
		default:
		default:
			printk("\nSpecified functionality does not exist\n");
			dev_err(dev->class_dev, "Specified functionality does not exist.\n");
			return -EINVAL;
			return -EINVAL;
		}
		}
	}
	}
@@ -591,7 +591,7 @@ static int i_APCI1564_ReadTimerCounterWatchdog(struct comedi_device *dev,
	} else if ((devpriv->b_TimerSelectMode != ADDIDATA_TIMER)
	} else if ((devpriv->b_TimerSelectMode != ADDIDATA_TIMER)
		&& (devpriv->b_TimerSelectMode != ADDIDATA_WATCHDOG)
		&& (devpriv->b_TimerSelectMode != ADDIDATA_WATCHDOG)
		&& (devpriv->b_TimerSelectMode != ADDIDATA_COUNTER)) {
		&& (devpriv->b_TimerSelectMode != ADDIDATA_COUNTER)) {
		printk("\n Invalid Subdevice !!!\n");
		dev_err(dev->class_dev, "Invalid Subdevice!\n");
	}
	}
	return insn->n;
	return insn->n;
}
}
@@ -665,7 +665,7 @@ static void v_APCI1564_Interrupt(int irq, void *d)
		APCI1564_TCW_IRQ) & 0x1;
		APCI1564_TCW_IRQ) & 0x1;
	if (ui_DI == 0 && ui_DO == 0 && ui_Timer == 0 && ui_C1 == 0
	if (ui_DI == 0 && ui_DO == 0 && ui_Timer == 0 && ui_C1 == 0
		&& ui_C2 == 0 && ui_C3 == 0 && ui_C4 == 0) {
		&& ui_C2 == 0 && ui_C3 == 0 && ui_C4 == 0) {
		printk("\nInterrupt from unknown source\n");
		dev_err(dev->class_dev, "Interrupt from unknown source.\n");
	}
	}


	if (ui_DI == 1) {
	if (ui_DI == 1) {