Commit 2ec38394 authored by H Hartley Sweeten's avatar H Hartley Sweeten Committed by Greg Kroah-Hartman

staging: comedi: amplc_pci230: remove use of DPRINTK

Use dev_dbg() instead of the DPRINTK macro to output the comedi
debugging information.

The dev_dbg() will prefix the messages appropriately so remove the
"comedi%d: amplc_pci230: " portion and use __func__ to show the
actual function name for debugging.
Signed-off-by: default avatarH Hartley Sweeten <hsweeten@visionengravers.com>
Reviewed-by: default avatarIan Abbott <abbotti@mev.co.uk>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 0a783410
...@@ -818,9 +818,9 @@ static int pci230_ai_rinsn(struct comedi_device *dev, ...@@ -818,9 +818,9 @@ static int pci230_ai_rinsn(struct comedi_device *dev,
if (aref == AREF_DIFF) { if (aref == AREF_DIFF) {
/* Differential. */ /* Differential. */
if (chan >= s->n_chan / 2) { if (chan >= s->n_chan / 2) {
DPRINTK("comedi%d: amplc_pci230: ai_rinsn: " dev_dbg(dev->class_dev,
"differential channel number out of range " "%s: differential channel number out of range 0 to %u\n",
"0 to %u\n", dev->minor, (s->n_chan / 2) - 1); __func__, (s->n_chan / 2) - 1);
return -EINVAL; return -EINVAL;
} }
} }
...@@ -1092,14 +1092,14 @@ static int pci230_ao_cmdtest(struct comedi_device *dev, ...@@ -1092,14 +1092,14 @@ static int pci230_ao_cmdtest(struct comedi_device *dev,
if (errors != 0) { if (errors != 0) {
err++; err++;
if ((errors & seq_err) != 0) { if ((errors & seq_err) != 0) {
DPRINTK("comedi%d: amplc_pci230: ao_cmdtest: " dev_dbg(dev->class_dev,
"channel numbers must increase\n", "%s: channel numbers must increase\n",
dev->minor); __func__);
} }
if ((errors & range_err) != 0) { if ((errors & range_err) != 0) {
DPRINTK("comedi%d: amplc_pci230: ao_cmdtest: " dev_dbg(dev->class_dev,
"channels must have the same range\n", "%s: channels must have the same range\n",
dev->minor); __func__);
} }
} }
} }
...@@ -1835,33 +1835,29 @@ static int pci230_ai_cmdtest(struct comedi_device *dev, ...@@ -1835,33 +1835,29 @@ static int pci230_ai_cmdtest(struct comedi_device *dev,
if (errors != 0) { if (errors != 0) {
err++; err++;
if ((errors & seq_err) != 0) { if ((errors & seq_err) != 0) {
DPRINTK("comedi%d: amplc_pci230: ai_cmdtest: " dev_dbg(dev->class_dev,
"channel numbers must increase or " "%s: channel numbers must increase or sequence must repeat exactly\n",
"sequence must repeat exactly\n", __func__);
dev->minor);
} }
if ((errors & rangepair_err) != 0) { if ((errors & rangepair_err) != 0) {
DPRINTK("comedi%d: amplc_pci230: ai_cmdtest: " dev_dbg(dev->class_dev,
"single-ended channel pairs must " "%s: single-ended channel pairs must have the same range\n",
"have the same range\n", dev->minor); __func__);
} }
if ((errors & polarity_err) != 0) { if ((errors & polarity_err) != 0) {
DPRINTK("comedi%d: amplc_pci230: ai_cmdtest: " dev_dbg(dev->class_dev,
"channel sequence ranges must be all " "%s: channel sequence ranges must be all bipolar or all unipolar\n",
"bipolar or all unipolar\n", __func__);
dev->minor);
} }
if ((errors & aref_err) != 0) { if ((errors & aref_err) != 0) {
DPRINTK("comedi%d: amplc_pci230: ai_cmdtest: " dev_dbg(dev->class_dev,
"channel sequence analogue references " "%s: channel sequence analogue references must be all the same (single-ended or differential)\n",
"must be all the same (single-ended " __func__);
"or differential)\n", dev->minor);
} }
if ((errors & diffchan_err) != 0) { if ((errors & diffchan_err) != 0) {
DPRINTK("comedi%d: amplc_pci230: ai_cmdtest: " dev_dbg(dev->class_dev,
"differential channel number out of " "%s: differential channel number out of range 0 to %u\n",
"range 0 to %u\n", dev->minor, __func__, (s->n_chan / 2) - 1);
(s->n_chan / 2) - 1);
} }
if ((errors & buggy_chan0_err) != 0) { if ((errors & buggy_chan0_err) != 0) {
dev_info(dev->class_dev, dev_info(dev->class_dev,
......
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