[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <B567DBAB974C0544994013492B949F8E3812C6D0C1@EXMAIL03.scwf.nsc.com>
Date: Thu, 19 Jan 2012 17:42:03 -0800
From: "Kim, Milo" <Milo.Kim@...com>
To: "Linus Walleij" <linus.walleij@...aro.org>
cc: "shreshthakumar.sahu@...ricsson.com"
<shreshthakumar.sahu@...ricsson.com>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
"rpurdie@...ys.net" <rpurdie@...ys.net>
Subject: RE: [PATCH] leds-lm3530: support pwm input mode and add
platform data
Thanks for your advice.
OK, I'll re-patch them separately.
Best Regard,
Milo -
-----Original Message-----
From: Linus Walleij [mailto:linus.walleij@...aro.org]
Sent: Friday, January 20, 2012 2:58 AM
To: Kim, Milo
Cc: shreshthakumar.sahu@...ricsson.com; linux-kernel@...r.kernel.org; D.Murphy@...orola.com; rpurdie@...ys.net
Subject: Re: [PATCH] leds-lm3530: support pwm input mode and add platform data
On Thu, Jan 19, 2012 at 5:36 AM, Kim, Milo <Milo.Kim@...com> wrote:
> (a) support pwm control mode
> (1) add 'struct lm3530_pwm_data' in the platform data
> The pwm data is the platform specific functions which generate the pwm.
> The pwm data is only valid when brightness is pwm input mode.
> Functions should be implemented by the pwm driver.
> pwm_set_intensity() : set duty of pwm.
> pwm_get_intensity() : get current duty of pwm.
>
> (2) brightness control by pwm
> If the control mode is pwm, then brightness is changed by the duty of pwm.
> So pwm platform function should be called in lm3530_brightness_set().
>
> (3) do not update brightness register when pwm input mode
> In pwm input mode, brightness register is not used.
> If any value is updated in this register, then the led will be off.
>
> (b) add 'name' in the lm3530_platform_data
> : The led device name can be configurable.
> For the compatibility, the name is set to default value(LM3530_LED_DEV)
> when 'name' is not defined.
>
> (c) add 'is_vin_always_on' in the lm3530_platform_data
> : The 'IN' pin(Input voltage connection) can be always turned on
> in case it is connected with VBATT.
> To support this case, 'is_vin_always_on' is added.
> If VIN is always on, then we don't need to control the regulator for IN pin.
>
> (d) add 'lm3530_mode_get()' in the lm3530 device attribute
> : To get information about brightness control mode.
>
> (e) use 'struct led_classdev' rather than 'struct i2c_client'
> to get members of lm3530_data
> : in lm3530_mode_set()
>
> (f) use 'pdata' rather than 'pltfm' in lm3530_init_registers()
>
> (g) for less arithmetic operation, replace 'divide-by-2' with
> 'shift-right-by 1 bit'
> : in lm3530_brightness_set()
Very nice patch, but please split it into one patch per subject
(a) through (g) as per Documentation/SubmittingPatches,
this makes it easier to review and git bisect.
Yours,
Linus Walleij
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists