On Wed, Apr 21, 2010 at 09:00:11PM -0700, Joe Perches wrote: > > @@ -374,8 +362,8 @@ static int dt2801_writecmd(struct comedi_device *dev, int command) > > > > stat = inb_p(dev->iobase + DT2801_STATUS); > > if (stat & DT_S_COMPOSITE_ERROR) { > > - printk > > - ("dt2801: composite-error in dt2801_writecmd(), ignoring\n"); > > + printk(KERN_INFO "dt2801: composite-error in dt2801_writecmd()" > > + ", ignoring\n"); > > It's good to preface with KERN_, but better might be to use > #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt > and strip the "dt2801: " intro and use > pr_<level>("%s(): composite-error, ignoring\n", __func__) > > It's a bit shorter, always gets the appropriate prefix, and > would emit the proper function name if ever refactored. What about dev_* in case there are more than one of those devices? Also, KERN_INFO doesn't look right, KERN_WARN? -- Pengutronix e.K. | Wolfram Sang | Industrial Linux Solutions | http://www.pengutronix.de/ |
Attachment:
signature.asc
Description: Digital signature
_______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/devel