Re: [PATCH] Added backlight driver for Acer Aspire 4736

From: Joe Perches
Date: Mon Mar 12 2012 - 19:07:56 EST


On Mon, 2012-03-12 at 23:12 -0400, Pradeep Subrahmanion wrote:
> Hi ,

Hello yourself.

Just some trivial comments:

> diff --git a/drivers/video/backlight/acer4736_bl.c b/drivers/video/backlight/acer4736_bl.c
[]
Please add
#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
before any include

> +static int update_brightness(struct backlight_device *bd)
> +{
> + u8 intensity = bd->props.brightness;
> + if (intensity > max_brightness) {
> + printk(KERN_INFO "Acer4736_bl: Invalid parameter. Maximum value is %d"
> + , max_brightness);

Beginning a line with a comma is not at all common and
should be avoided. printks need newline terminations,
and this would be better as pr_info. Maybe:

pr_info("Invalid parameter %u: Maximum allowed value: %u\n",
intensity, max_brightness);

> + printk(KERN_INFO "Loading Acer 4736 backlight driver\n");

pr_info("Loading backlight driver\n");



--
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/