lp855x-driver.txt 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. Kernel driver lp855x
  2. ====================
  3. Backlight driver for LP855x ICs
  4. Supported chips:
  5. Texas Instruments LP8550, LP8551, LP8552, LP8553, LP8556 and LP8557
  6. Author: Milo(Woogyom) Kim <milo.kim@ti.com>
  7. Description
  8. -----------
  9. * Brightness control
  10. Brightness can be controlled by the pwm input or the i2c command.
  11. The lp855x driver supports both cases.
  12. * Device attributes
  13. 1) bl_ctl_mode
  14. Backlight control mode.
  15. Value : pwm based or register based
  16. 2) chip_id
  17. The lp855x chip id.
  18. Value : lp8550/lp8551/lp8552/lp8553/lp8556/lp8557
  19. Platform data for lp855x
  20. ------------------------
  21. For supporting platform specific data, the lp855x platform data can be used.
  22. * name : Backlight driver name. If it is not defined, default name is set.
  23. * device_control : Value of DEVICE CONTROL register.
  24. * initial_brightness : Initial value of backlight brightness.
  25. * period_ns : Platform specific PWM period value. unit is nano.
  26. Only valid when brightness is pwm input mode.
  27. * size_program : Total size of lp855x_rom_data.
  28. * rom_data : List of new eeprom/eprom registers.
  29. example 1) lp8552 platform data : i2c register mode with new eeprom data
  30. #define EEPROM_A5_ADDR 0xA5
  31. #define EEPROM_A5_VAL 0x4f /* EN_VSYNC=0 */
  32. static struct lp855x_rom_data lp8552_eeprom_arr[] = {
  33. {EEPROM_A5_ADDR, EEPROM_A5_VAL},
  34. };
  35. static struct lp855x_platform_data lp8552_pdata = {
  36. .name = "lcd-bl",
  37. .device_control = I2C_CONFIG(LP8552),
  38. .initial_brightness = INITIAL_BRT,
  39. .size_program = ARRAY_SIZE(lp8552_eeprom_arr),
  40. .rom_data = lp8552_eeprom_arr,
  41. };
  42. example 2) lp8556 platform data : pwm input mode with default rom data
  43. static struct lp855x_platform_data lp8556_pdata = {
  44. .device_control = PWM_CONFIG(LP8556),
  45. .initial_brightness = INITIAL_BRT,
  46. .period_ns = 1000000,
  47. };