02 Apr, 2013

2 commits

  • Now LP55xx provides automatic clock detection API, lp55xx_is_extclk_used().
    The clock configuration can be done by the driver itself.

    (a) Concept
    The default value is set by each driver with clock selection.
    The internal clock selection bit is updated in case that the external clock
    is not detected or clock rate is not 32KHz.

    (b) Change on LP55xx platform data
    The clock configuration is done automatically, so no need to define
    'update_config' in the platform side.
    Correlated information are removed in the documentations and header.

    (c) Definitions moved from header to driver files
    CONFIG register values are moved each driver, LP5521 and LP5562.
    Not necessary definitions are removed also.

    Signed-off-by: Milo(Woogyom) Kim
    Signed-off-by: Bryan Wu

    Kim, Milo
     
  • LP5562 can drive up to 4 channels, RGB and White.
    LEDs can be controlled directly via the led class control interface.

    LP55xx common driver
    LP5562 is one of LP55xx family device, so LP55xx common code are used.
    On the other hand, chip specific configuration is defined in the structure
    'lp55xx_device_config'

    LED pattern data
    LP5562 has also internal program memory which is used for running various LED
    patterns. LP5562 driver supports the firmware interface and the predefined
    pattern data as well.

    LP5562 device attributes: 'led_pattern' and 'engine_mux'
    A 'led_pattern' is an index code which runs the predefined pattern data.
    And 'engine_mux' is updated with the firmware interface is activated.
    Detailed description has been updated in the documentation files,
    'leds-lp55xx.txt' and 'leds-lp5562.txt'.

    Changes on the header file
    LP5562 configurable definitions are added.
    Pattern RGB data is fixed as constant value.
    (No side effect on other devices, LP5521 or LP5523.)

    (cooloney@gmail.com: remove redundant mutex_unlock(). Reported by Dan
    Carpenter )

    Signed-off-by: Milo(Woogyom) Kim
    Signed-off-by: Bryan Wu

    Kim, Milo
     

07 Feb, 2013

1 commit


11 Sep, 2012

1 commit


24 Jul, 2012

3 commits

  • Add driver for BlinkM device to drivers/leds/.
    Add entry to MAINTAINERS file.
    Add documentation in Documentation/leds/.

    A BlinkM is a RGB LED controlled through I2C.

    This driver implements an interface to the LED framework
    and another sysfs group to access the internal options
    of the BlinkM.

    rev6: Use module_i2c_driver().
    rev5: Removed own workqueue in favor of events wq.
    rev4: Fixed comments by Bryan Wu.
    rev3: Fixed issues found by Jonathan Neuschäfer.

    (bryan.wu@canonical.com: remove 2 trailing whitespace)

    Signed-off-by: Jan-Simon Möller
    Signed-off-by: Bryan Wu

    Jan-Simon Möller
     
  • LM3556 :
    The LM3556 is a 4 MHz fixed-frequency synchronous boost
    converter plus 1.5A constant current driver for a high-current white LED.
    Datasheet: www.national.com/ds/LM/LM3556.pdf

    Tested on OMAP4430

    (bryan.wu@canonical.com: use module_i2c_driver() rather than
    lm3556_init/lm3556_exit for code simplicity; fixed some typo
    pointed out by Rob Landley)

    Signed-off-by: G.Shark Jeong
    Reviewed-by: Axel Lin
    Reviewed-by: Kim, Milo
    Acked-by: Rob Landley
    Signed-off-by: Bryan Wu

    G.Shark Jeong
     
  • Add oneshot trigger to blink a led with configurale parameters via
    sysfs.

    Signed-off-by: Fabio Baltieri
    Cc: Shuah Khan
    Signed-off-by: Bryan Wu

    Fabio Baltieri
     

30 May, 2012

1 commit

  • The leds timer trigger does not currently have an interface to activate a
    one shot timer. The current support allows for setting two timers, one
    for specifying how long a state to be on, and the second for how long the
    state to be off. The delay_on value specifies the time period an LED
    should stay in on state, followed by a delay_off value that specifies how
    long the LED should stay in off state. The on and off cycle repeats until
    the trigger gets deactivated. There is no provision for one time
    activation to implement features that require an on or off state to be
    held just once and then stay in the original state forever.

    Without one shot timer interface, user space can still use timer trigger
    to set a timer to hold a state, however when user space application
    crashes or goes away without deactivating the timer, the hardware will be
    left in that state permanently.

    As a specific example of this use-case, let's look at vibrate feature on
    phones. Vibrate function on phones is implemented using PWM pins on SoC
    or PMIC. There is a need to activate one shot timer to control the
    vibrate feature, to prevent user space crashes leaving the phone in
    vibrate mode permanently causing the battery to drain.

    This trigger exports three properties, activate, state, and duration When
    transient trigger is activated these properties are set to default values.

    - duration allows setting timer value in msecs. The initial value is 0.
    - activate allows activating and deactivating the timer specified by
    duration as needed. The initial and default value is 0. This will allow
    duration to be set after trigger activation.
    - state allows user to specify a transient state to be held for the specified
    duration.

    Signed-off-by: Shuah Khan
    Cc: Jonas Bonn
    Cc: Richard Purdie
    Cc: NeilBrown
    Cc: Bryan Wu
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Shuah Khan
     

24 Mar, 2012

3 commits

  • The lp5521 has autonomous operation mode without external control.
    Using lp5521_platform_data, various led patterns can be configurable.
    For supporting this feature, new functions and device attribute are
    added.

    Structure of lp5521_led_pattern: 3 channels are supported - red, green
    and blue. Pattern(s) of each channel and numbers of pattern(s) are
    defined in the pla= tform data. Pattern data are hexa codes which
    include pattern commands such like set pwm, wait, ramp up/down, branch
    and so on.

    Pattern mode functions:
    * lp5521_clear_program_memory
    Before running new led pattern, program memory should be cleared.
    * lp5521_write_program_memory
    Pattern data updated in the program memory via the i2c.
    * lp5521_get_pattern
    Get pattern from predefined in the platform data.
    * lp5521_run_led_pattern
    Stop current pattern or run new pattern.
    Transition time is required between different operation mode.

    Device attribute - 'led_pattern': To load specific led pattern, new device
    attribute is added.

    When the lp5521 driver is unloaded, stop current led pattern mode.

    Documentation updated : description about how to define the led patterns
    and example.

    [akpm@linux-foundation.org: checkpatch fixes]
    Signed-off-by: Milo(Woogyom) Kim
    Acked-by: Linus Walleij
    Cc: Arun MURTHY
    Cc: Srinidhi Kasagar
    Cc: Richard Purdie
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kim, Milo
     
  • The value of CONFIG register(Addr 08h) is configurable. For supporting
    this feature, update_config is added in the platform data. If
    'update_config' is not defined, the default value is 'LP5521_PWRSAVE_EN |
    LP5521_CP_MODE_AUTO | LP5521_R_TO_BATT'.

    To define CONFIG register in the platform data, the bit definitions were
    mo= ved to the header file.

    Documentation updated : description about 'update_config' and example.

    Signed-off-by: Milo(Woogyom) Kim
    Acked-by: Linus Walleij
    Cc: Arun MURTHY
    Cc: Srinidhi Kasagar
    Cc: Richard Purdie
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kim, Milo
     
  • The name of each led channel can be configurable. For the compatibility,
    the name is set to default value(xx:channelN) when 'name' is not defined.

    Signed-off-by: Milo(Woogyom) Kim
    Acked-by: Linus Walleij
    Cc: Arun MURTHY
    Cc: Srinidhi Kasagar
    Cc: Richard Purdie
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Kim, Milo
     

05 Nov, 2011

1 commit


05 Apr, 2011

1 commit


12 Nov, 2010

1 commit