On Fri, 2013-05-31 at 22:44 +0300, Andy Shevchenko wrote:
> On Thu, May 30, 2013 at 11:57 PM, Joe Perches <[email protected]> wrote:
> > Use a more current logging style and add messages levels
> > to the logging messages.
> >
> > Convert bare printks to pr_cont where appropriate and
> > add a simple function to emit the sense string.
> 
> Few comments below.
> 
> Why not dev_dbg wherever it's possible?

Because dev_<level> conversions are not appropriate for a
first pass.  The "struct pktcdvd *" needs to be available
for more function calls and that's more work / less
automatic and this pass is more easily verified.

> > -       printk(DRIVER_NAME":");
> > +       pr_err("");
> >         for (i = 0; i < CDROM_PACKET_SIZE; i++)
> > -               printk(" %02x", cgc->cmd[i]);
> > -       printk(" - ");
> > +               pr_cont(" %02x", cgc->cmd[i]);
> 
> This one is actually %*ph.
> 
> Like: pr_info("%*ph", CDROM_PACKET_SIZE, cgc->cmd);
> 
> And what is the level of this message? debug?

pr_err and good point about %*ph, I've fixed it and
the stupid typo around the #include here.

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Reply via email to