Commit bcd9a1e9 authored by Johannes Thumshirn's avatar Johannes Thumshirn Committed by Greg Kroah-Hartman

staging: comedi: Added log subjects to printk()s in pcmmio

Added log subject to printk()s in drivers/staging/comedi/drivers/pcmmio.c.
Signed-off-by: default avatarJohannes Thumshirn <morbidrsa@googlemail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent de0920b1
...@@ -371,7 +371,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it) ...@@ -371,7 +371,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
iobase = it->options[0]; iobase = it->options[0];
irq[0] = it->options[1]; irq[0] = it->options[1];
printk("comedi%d: %s: io: %lx ", dev->minor, driver.driver_name, printk(KERN_INFO "comedi%d: %s: io: %lx ", dev->minor, driver.driver_name,
iobase); iobase);
dev->iobase = iobase; dev->iobase = iobase;
...@@ -379,7 +379,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it) ...@@ -379,7 +379,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
if (!iobase || !request_region(iobase, if (!iobase || !request_region(iobase,
thisboard->total_iosize, thisboard->total_iosize,
driver.driver_name)) { driver.driver_name)) {
printk("I/O port conflict\n"); printk(KERN_ERR "I/O port conflict\n");
return -EIO; return -EIO;
} }
...@@ -394,7 +394,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it) ...@@ -394,7 +394,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
* convenient macro defined in comedidev.h. * convenient macro defined in comedidev.h.
*/ */
if (alloc_private(dev, sizeof(struct pcmmio_private)) < 0) { if (alloc_private(dev, sizeof(struct pcmmio_private)) < 0) {
printk("cannot allocate private data structure\n"); printk(KERN_ERR "cannot allocate private data structure\n");
return -ENOMEM; return -ENOMEM;
} }
...@@ -417,7 +417,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it) ...@@ -417,7 +417,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
kcalloc(n_subdevs, sizeof(struct pcmmio_subdev_private), kcalloc(n_subdevs, sizeof(struct pcmmio_subdev_private),
GFP_KERNEL); GFP_KERNEL);
if (!devpriv->sprivs) { if (!devpriv->sprivs) {
printk("cannot allocate subdevice private data structures\n"); printk(KERN_ERR "cannot allocate subdevice private data structures\n");
return -ENOMEM; return -ENOMEM;
} }
/* /*
...@@ -427,7 +427,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it) ...@@ -427,7 +427,7 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
* Allocate 1 AI + 1 AO + 2 DIO subdevs (24 lines per DIO) * Allocate 1 AI + 1 AO + 2 DIO subdevs (24 lines per DIO)
*/ */
if (alloc_subdevices(dev, n_subdevs) < 0) { if (alloc_subdevices(dev, n_subdevs) < 0) {
printk("cannot allocate subdevice data structures\n"); printk(KERN_ERR "cannot allocate subdevice data structures\n");
return -ENOMEM; return -ENOMEM;
} }
...@@ -557,14 +557,14 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it) ...@@ -557,14 +557,14 @@ static int pcmmio_attach(struct comedi_device *dev, struct comedi_devconfig *it)
*/ */
if (irq[0]) { if (irq[0]) {
printk("irq: %u ", irq[0]); printk(KERN_DEBUG "irq: %u ", irq[0]);
if (thisboard->dio_num_asics == 2 && irq[1]) if (thisboard->dio_num_asics == 2 && irq[1])
printk("second ASIC irq: %u ", irq[1]); printk(KERN_DEBUG "second ASIC irq: %u ", irq[1]);
} else { } else {
printk("(IRQ mode disabled) "); printk(KERN_INFO "(IRQ mode disabled) ");
} }
printk("attached\n"); printk(KERN_INFO "attached\n");
return 1; return 1;
} }
...@@ -581,7 +581,7 @@ static int pcmmio_detach(struct comedi_device *dev) ...@@ -581,7 +581,7 @@ static int pcmmio_detach(struct comedi_device *dev)
{ {
int i; int i;
printk("comedi%d: %s: remove\n", dev->minor, driver.driver_name); printk(KERN_INFO "comedi%d: %s: remove\n", dev->minor, driver.driver_name);
if (dev->iobase) if (dev->iobase)
release_region(dev->iobase, thisboard->total_iosize); release_region(dev->iobase, thisboard->total_iosize);
...@@ -622,7 +622,7 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev, ...@@ -622,7 +622,7 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
#ifdef DAMMIT_ITS_BROKEN #ifdef DAMMIT_ITS_BROKEN
/* DEBUG */ /* DEBUG */
printk("write mask: %08x data: %08x\n", data[0], data[1]); printk(KERN_DEBUG "write mask: %08x data: %08x\n", data[0], data[1]);
#endif #endif
s->state = 0; s->state = 0;
...@@ -644,9 +644,9 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev, ...@@ -644,9 +644,9 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
#ifdef DAMMIT_ITS_BROKEN #ifdef DAMMIT_ITS_BROKEN
/* DEBUG */ /* DEBUG */
printk printk
("byte %d wmb %02x db %02x offset %02d io %04x, data_in %02x ", (KERN_DEBUG "byte %d wmb %02x db %02x offset %02d io %04x,"
byte_no, (unsigned)write_mask_byte, (unsigned)data_byte, " data_in %02x ", byte_no, (unsigned)write_mask_byte,
offset, ioaddr, (unsigned)byte); (unsigned)data_byte, offset, ioaddr, (unsigned)byte);
#endif #endif
if (write_mask_byte) { if (write_mask_byte) {
...@@ -663,7 +663,7 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev, ...@@ -663,7 +663,7 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
} }
#ifdef DAMMIT_ITS_BROKEN #ifdef DAMMIT_ITS_BROKEN
/* DEBUG */ /* DEBUG */
printk("data_out_byte %02x\n", (unsigned)byte); printk(KERN_DEBUG "data_out_byte %02x\n", (unsigned)byte);
#endif #endif
/* save the digital input lines for this byte.. */ /* save the digital input lines for this byte.. */
s->state |= ((unsigned int)byte) << offset; s->state |= ((unsigned int)byte) << offset;
...@@ -674,7 +674,7 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev, ...@@ -674,7 +674,7 @@ static int pcmmio_dio_insn_bits(struct comedi_device *dev,
#ifdef DAMMIT_ITS_BROKEN #ifdef DAMMIT_ITS_BROKEN
/* DEBUG */ /* DEBUG */
printk("s->state %08x data_out %08x\n", s->state, data[1]); printk(KERN_DEBUG "s->state %08x data_out %08x\n", s->state, data[1]);
#endif #endif
return 2; return 2;
...@@ -886,7 +886,7 @@ static irqreturn_t interrupt_pcmmio(int irq, void *d) ...@@ -886,7 +886,7 @@ static irqreturn_t interrupt_pcmmio(int irq, void *d)
* with commands.. * with commands..
*/ */
printk printk
("PCMMIO DEBUG: got edge detect interrupt %d asic %d which_chans: %06x\n", (KERN_DEBUG "got edge detect interrupt %d asic %d which_chans: %06x\n",
irq, asic, triggered); irq, asic, triggered);
for (s = dev->subdevices + 2; for (s = dev->subdevices + 2;
s < dev->subdevices + dev->n_subdevices; s < dev->subdevices + dev->n_subdevices;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment