mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Eric Miao <eric.y.miao@gmail.com>
To: "庄浩坚 (Haojian)" <haojian.zhuang@gmail.com>, getarunks@gmail.com
Cc: linux-kernel@vger.kernel.org, rpurdie@rpsys.net,
	eric.miao@marvell.com, mike@compulab.co.il
Subject: Re: [PATCH] Adding LED1 & LED2 control for DA9034 backlight driver
Date: Fri, 18 Sep 2009 17:10:05 +0800	[thread overview]
Message-ID: <f17812d70909180210xdceaf22u7901befa23cd89c7@mail.gmail.com> (raw)
In-Reply-To: <1253215662-11404-1-git-send-email-getarunks@gmail.com>

Haojian,

Could you please help check if the patch below applies for micco?

Thanks
- eric

On Fri, Sep 18, 2009 at 3:27 AM,  <getarunks@gmail.com> wrote:
> From: Arun KS <getarunks@gmail.com>
>
> Signed-off-by: Arun KS <getarunks@gmail.com>
> ---
>  drivers/video/backlight/Kconfig     |    2 +-
>  drivers/video/backlight/da903x_bl.c |   12 ++++++++++++
>  2 files changed, 13 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/video/backlight/Kconfig b/drivers/video/backlight/Kconfig
> index 90861cd..1607bc9 100644
> --- a/drivers/video/backlight/Kconfig
> +++ b/drivers/video/backlight/Kconfig
> @@ -203,7 +203,7 @@ config BACKLIGHT_DA903X
>        depends on BACKLIGHT_CLASS_DEVICE && PMIC_DA903X
>        help
>          If you have a LCD backlight connected to the WLED output of DA9030
> -         or DA9034 WLED output, say Y here to enable this driver.
> +         or DA9034 WLED, LED1, LED2 outputs, say Y here to enable this driver.
>
>  config BACKLIGHT_MBP_NVIDIA
>        tristate "MacBook Pro Nvidia Backlight Driver"
> diff --git a/drivers/video/backlight/da903x_bl.c b/drivers/video/backlight/da903x_bl.c
> index 93bb434..c6ceb76 100644
> --- a/drivers/video/backlight/da903x_bl.c
> +++ b/drivers/video/backlight/da903x_bl.c
> @@ -23,6 +23,8 @@
>  #define DA9030_WLED_CP_EN      (1 << 6)
>  #define DA9030_WLED_TRIM(x)    ((x) & 0x7)
>
> +#define DA9034_LED1_CONTROL    0x35
> +#define DA9034_LED2_CONTROL    0x36
>  #define DA9034_WLED_CONTROL1   0x3C
>  #define DA9034_WLED_CONTROL2   0x3D
>
> @@ -66,6 +68,14 @@ static int da903x_backlight_set(struct backlight_device *bl, int brightness)
>                val |= brightness ? DA9030_WLED_CP_EN : 0;
>                ret = da903x_write(dev, DA9030_WLED_CONTROL, val);
>                break;
> +       case DA9034_ID_LED_1:
> +               ret = da903x_update(dev, DA9034_LED1_CONTROL,
> +                               brightness, 0x7f);
> +               break;
> +       case DA9034_ID_LED_2:
> +               ret = da903x_update(dev, DA9034_LED2_CONTROL,
> +                               brightness, 0x7f);
> +               break;
>        }
>
>        if (ret)
> @@ -114,6 +124,8 @@ static int da903x_backlight_probe(struct platform_device *pdev)
>                max_brightness = DA9030_MAX_BRIGHTNESS;
>                break;
>        case DA9034_ID_WLED:
> +       case DA9034_ID_LED_1:
> +       case DA9034_ID_LED_2:
>                max_brightness = DA9034_MAX_BRIGHTNESS;
>                break;
>        default:
> --
> 1.5.4.3
>
>

  reply	other threads:[~2009-09-18  9:10 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-17 19:27 getarunks
2009-09-18  9:10 ` Eric Miao [this message]
     [not found]   ` <771cded00909210049g6c7c8075pe4ca331184e39415@mail.gmail.com>
     [not found]     ` <dfeb90390909211003h3b16e984q1fdf94450bdb39@mail.gmail.com>
2009-09-21 17:08       ` Eric Miao
2009-09-21 18:07         ` Arun KS
2009-09-21 21:10   ` Richard Purdie
  -- strict thread matches above, loose matches on Subject: below --
2009-09-17 19:30 getarunks
2009-09-17 18:56 getarunks

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=f17812d70909180210xdceaf22u7901befa23cd89c7@mail.gmail.com \
    --to=eric.y.miao@gmail.com \
    --cc=eric.miao@marvell.com \
    --cc=getarunks@gmail.com \
    --cc=haojian.zhuang@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mike@compulab.co.il \
    --cc=rpurdie@rpsys.net \
    /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®