mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: "Prashant P. Shah" <pshah.mumbai@gmail.com>
Cc: gregkh@suse.de, devel@driverdev.osuosl.org,
	daniele.boncompagni@gmail.com, linux-kernel@vger.kernel.org,
	julia@diku.dk
Subject: Re: [PATCH 2/3] Staging: otus: added valid KERN_ loglevels to printk in wwrap.c
Date: Tue, 07 Sep 2010 08:09:53 -0700	[thread overview]
Message-ID: <1283872193.23280.123.camel@Joe-Laptop> (raw)
In-Reply-To: <7e1ccc28be954d553b6daddf54dbc149f27c709f.1283865137.git.pshah.mumbai@gmail.com>

On Tue, 2010-09-07 at 18:44 +0530, Prashant P. Shah wrote:
> This is a patch to the wwrap.c file that adds valid KERN_ loglevels
> to printk() statements
> 
> Signed-off-by: Prashant P. Shah <pshah.mumbai@gmail.com>
> ---
>  drivers/staging/otus/wwrap.c |   33 ++++++++++++++++-----------------
>  1 files changed, 16 insertions(+), 17 deletions(-)
> 
> diff --git a/drivers/staging/otus/wwrap.c b/drivers/staging/otus/wwrap.c
[]
> @@ -358,13 +357,13 @@ void zfLnxUsbDataIn_callback(urb_t *urb)
>  #if 0
>  			/* Dump data */
>  			for (ii = index; ii < pkt_len+4;) {
> -				printk("%02x ", (buf->data[ii] & 0xff));
> +				printk(KERN_INFO "%02x ", (buf->data[ii] & 0xff));
>  
>  				if ((++ii % 16) == 0)
> -					printk("\n");
> +					printk(KERN_INFO "\n");
>  			}
>  
> -			printk("\n");
> +			printk(KERN_INFO "\n");
>  #endif
>  
>  			pad_len = 4 - (pkt_len & 0x3);

and

> @@ -636,11 +635,11 @@ u32_t zfLnxUsbSubmitTxData(zdev_t *dev)
>  	if (TxData->hdrlen != 0) {
>  		puTxBuf = macp->txUsbBuf[freeTxUrb];
>  		for (i = 0; i < len; i++) {
> -			printk("%02x ", puTxBuf[i]);
> +			printk(KERN_INFO "%02x ", puTxBuf[i]);
>  			if (i % 16 == 15)
> -				printk("\n");
> +				printk(KERN_INFO "\n");
>  		}
> -		printk("\n");
> +		printk(KERN_INFO "\n");

These should use KERN_CONT.

It'd be better to use print_hex_dump() instead.



  parent reply	other threads:[~2010-09-07 15:10 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-09-07 13:14 [PATCH 1/3] Staging: otus: fixed style issues " Prashant P. Shah
2010-09-07 13:14 ` [PATCH 2/3] Staging: otus: added valid KERN_ loglevels to printk " Prashant P. Shah
2010-09-07 13:14   ` [PATCH 3/3] Staging: otus: removes global variable initialization to 0 " Prashant P. Shah
2010-09-07 15:09   ` Joe Perches [this message]
2010-09-08  2:38     ` [PATCH 2/3] Staging: otus: added valid KERN_ loglevels to printk " Greg KH
2010-09-08  2:38 ` [PATCH 1/3] Staging: otus: fixed style issues " Greg KH

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1283872193.23280.123.camel@Joe-Laptop \
    --to=joe@perches.com \
    --cc=daniele.boncompagni@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@suse.de \
    --cc=julia@diku.dk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pshah.mumbai@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®