Re: [PATCH 30/30 v2] Staging: comedi: fix printk() issue indas16m1.c

From: Jesper Juhl
Date: Mon Jul 18 2011 - 05:43:51 EST


On Mon, 18 Jul 2011, Ravishankar wrote:

> From: Ravishankar <ravi.shankar@xxxxxxxxxxxxxxx>
>
> This is a patch to the das16m1.c file that fixes up a printk() warning found by the checkpatch.pl tool
>
> Signed-off-by: Ravishankar <ravishankarkm32@xxxxxxxxx>
> ---
>
> After understanding code I have changed 8 printk statement in int das16m1_attach function.
>
> drivers/staging/comedi/drivers/das16m1.c | 16 +++++++++-------
> 1 files changed, 9 insertions(+), 7 deletions(-)
>
> diff --git a/drivers/staging/comedi/drivers/das16m1.c b/drivers/staging/comedi/drivers/das16m1.c
> index efc6132..d737ed2 100644
> --- a/drivers/staging/comedi/drivers/das16m1.c
> +++ b/drivers/staging/comedi/drivers/das16m1.c
> @@ -680,17 +680,19 @@ static int das16m1_attach(struct comedi_device *dev,
>
> dev->board_name = thisboard->name;
>
> - printk(" io 0x%lx-0x%lx 0x%lx-0x%lx",
> + printk(KERN_INFO " requesing the I/O region from 0x%lx-0x%lx 0x%lx-0x%lx",

Correct spelling is "requesting" and the "from" should either have a
matching "to" or just be dropped IMHO.

Personally I'd just make it:
" requesting I/O region 0x%lx-0x%lx 0x%lx-0x%lx"


> iobase, iobase + DAS16M1_SIZE,
> iobase + DAS16M1_82C55, iobase + DAS16M1_82C55 + DAS16M1_SIZE2);
> if (!request_region(iobase, DAS16M1_SIZE, driver_das16m1.driver_name)) {
> - printk(" I/O port conflict\n");
> - return -EIO;
> + printk(KERN_INFO "the IO REGION is busy, quitting\n");
> + return -EBUSY;
> }
> if (!request_region(iobase + DAS16M1_82C55, DAS16M1_SIZE2,
> driver_das16m1.driver_name)) {
> release_region(iobase, DAS16M1_SIZE);
> - printk(" I/O port conflict\n");
> + printk(KERN_INFO " releasing the I/O port region\n");

I think the original text was better.


--
Jesper Juhl <jj@xxxxxxxxxxxxx> http://www.chaosbits.net/
Don't top-post http://www.catb.org/jargon/html/T/top-post.html
Plain text mails only, please.

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