Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

Merge tag 'backlight-next-6.15' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight

Pull backlight updates from Lee Jones:

- Apple DWI Backlight:
- Added devicetree bindings for backlight controllers on Apple's DWI
interface.
- Added a new driver (apple_dwi_bl) for these controllers found on
some Apple mobile devices.
- Added MAINTAINERS entries for the new driver.

- led_bl: Fixed a locking issue by holding the led_access lock when
calling led_sysfs_disable() during device removal to prevent
potential warnings.

- Removed unnecessary <linux/fb.h> includes from a bunch of drivers.

- tdo24m: Removed redundant whitespace in Kconfig description.

- pcf50633-backlight: Removed the driver as the underlying pcf50633 MFD
and s3c24xx platform support were removed.

* tag 'backlight-next-6.15' of git://git.kernel.org/pub/scm/linux/kernel/git/lee/backlight: (22 commits)
backlight: pcf50633-backlight: Remove unused driver
backlight: tdo24m: Eliminate redundant whitespace
MAINTAINERS: Add entries for Apple DWI backlight controller
backlight: apple_dwi_bl: Add Apple DWI backlight driver
dt-bindings: leds: backlight: apple,dwi-bl: Add Apple DWI backlight
backlight: led_bl: Hold led_access lock when calling led_sysfs_disable()
backlight: wm831x_bl: Do not include <linux/fb.h>
backlight: vgg2432a4: Do not include <linux/fb.h>
backlight: tps65217_bl: Do not include <linux/fb.h>
backlight: max8925_bl: Do not include <linux/fb.h>
backlight: lv5207lp: Do not include <linux/fb.h>
backlight: locomolcd: Do not include <linux/fb.h>
backlight: hp680_bl: Do not include <linux/fb.h>
backlight: ep93xx_bl: Do not include <linux/fb.h>
backlight: da9052_bl: Do not include <linux/fb.h>
backlight: da903x_bl: Do not include <linux/fb.h>
backlight: bd6107_bl: Do not include <linux/fb.h>
backlight: as3711_bl: Do not include <linux/fb.h>
backlight: adp8870_bl: Do not include <linux/fb.h>
backlight: adp8860_bl: Do not include <linux/fb.h>
...

+199 -225
+57
Documentation/devicetree/bindings/leds/backlight/apple,dwi-bl.yaml
··· 1 + # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 2 + %YAML 1.2 3 + --- 4 + $id: http://devicetree.org/schemas/leds/backlight/apple,dwi-bl.yaml# 5 + $schema: http://devicetree.org/meta-schemas/core.yaml# 6 + 7 + title: Apple DWI 2-Wire Interface Backlight Controller 8 + 9 + maintainers: 10 + - Nick Chan <towinchenmi@gmail.com> 11 + 12 + description: 13 + Apple SoCs contain a 2-wire interface called DWI. On some Apple iPhones, 14 + iPads and iPod touches with a LCD display, 1-2 backlight controllers 15 + are connected via DWI. Interfacing with DWI controls all backlight 16 + controllers at the same time. As such, the backlight controllers are 17 + treated as a single controller regardless of the underlying 18 + configuration. 19 + 20 + allOf: 21 + - $ref: common.yaml# 22 + 23 + properties: 24 + compatible: 25 + items: 26 + - enum: 27 + - apple,s5l8960x-dwi-bl 28 + - apple,t7000-dwi-bl 29 + - apple,s8000-dwi-bl 30 + - apple,t8010-dwi-bl 31 + - apple,t8015-dwi-bl 32 + - const: apple,dwi-bl 33 + 34 + reg: 35 + maxItems: 1 36 + 37 + power-domains: 38 + maxItems: 1 39 + 40 + required: 41 + - compatible 42 + - reg 43 + 44 + unevaluatedProperties: false 45 + 46 + examples: 47 + - | 48 + soc { 49 + #address-cells = <2>; 50 + #size-cells = <2>; 51 + 52 + dwi_bl: backlight@20e200010 { 53 + compatible = "apple,s5l8960x-dwi-bl", "apple,dwi-bl"; 54 + reg = <0x2 0x0e200010 0x0 0x8>; 55 + power-domains = <&ps_dwi>; 56 + }; 57 + };
+2
MAINTAINERS
··· 2232 2232 F: Documentation/devicetree/bindings/interrupt-controller/apple,* 2233 2233 F: Documentation/devicetree/bindings/iommu/apple,dart.yaml 2234 2234 F: Documentation/devicetree/bindings/iommu/apple,sart.yaml 2235 + F: Documentation/devicetree/bindings/leds/backlight/apple,dwi-bl.yaml 2235 2236 F: Documentation/devicetree/bindings/mailbox/apple,mailbox.yaml 2236 2237 F: Documentation/devicetree/bindings/net/bluetooth/brcm,bcm4377-bluetooth.yaml 2237 2238 F: Documentation/devicetree/bindings/nvme/apple,nvme-ans.yaml ··· 2260 2259 F: drivers/pwm/pwm-apple.c 2261 2260 F: drivers/soc/apple/* 2262 2261 F: drivers/spi/spi-apple.c 2262 + F: drivers/video/backlight/apple_dwi_bl.c 2263 2263 F: drivers/watchdog/apple_wdt.c 2264 2264 F: include/dt-bindings/interrupt-controller/apple-aic.h 2265 2265 F: include/dt-bindings/pinctrl/apple.h
-1
drivers/video/backlight/88pm860x_bl.c
··· 11 11 #include <linux/of.h> 12 12 #include <linux/platform_device.h> 13 13 #include <linux/slab.h> 14 - #include <linux/fb.h> 15 14 #include <linux/i2c.h> 16 15 #include <linux/backlight.h> 17 16 #include <linux/mfd/88pm860x.h>
+12 -8
drivers/video/backlight/Kconfig
··· 70 70 then say y to include a power driver for it. 71 71 72 72 config LCD_TDO24M 73 - tristate "Toppoly TDO24M and TDO35S LCD Panels support" 73 + tristate "Toppoly TDO24M and TDO35S LCD Panels support" 74 74 depends on SPI_MASTER 75 75 help 76 76 If you have a Toppoly TDO24M/TDO35S series LCD panel, say y here to ··· 290 290 If you have an Intel-based Apple say Y to enable a driver for its 291 291 backlight. 292 292 293 + config BACKLIGHT_APPLE_DWI 294 + tristate "Apple DWI 2-Wire Interface Backlight Driver" 295 + depends on ARCH_APPLE || COMPILE_TEST 296 + help 297 + Say Y to enable the backlight driver for backlight controllers 298 + attached via the Apple DWI 2-wire interface which is found in some 299 + Apple iPhones, iPads and iPod touches. 300 + 301 + To compile this driver as a module, choose M here: the module will 302 + be called apple_dwi_bl. 303 + 293 304 config BACKLIGHT_QCOM_WLED 294 305 tristate "Qualcomm PMIC WLED Driver" 295 306 select REGMAP ··· 369 358 depends on MFD_88PM860X 370 359 help 371 360 Say Y to enable the backlight driver for Marvell 88PM8606. 372 - 373 - config BACKLIGHT_PCF50633 374 - tristate "Backlight driver for NXP PCF50633 MFD" 375 - depends on MFD_PCF50633 376 - help 377 - If you have a backlight driven by a NXP PCF50633 MFD, say Y here to 378 - enable its driver. 379 361 380 362 config BACKLIGHT_AAT2870 381 363 tristate "AnalogicTech AAT2870 Backlight"
+1 -1
drivers/video/backlight/Makefile
··· 23 23 obj-$(CONFIG_BACKLIGHT_ADP8860) += adp8860_bl.o 24 24 obj-$(CONFIG_BACKLIGHT_ADP8870) += adp8870_bl.o 25 25 obj-$(CONFIG_BACKLIGHT_APPLE) += apple_bl.o 26 + obj-$(CONFIG_BACKLIGHT_APPLE_DWI) += apple_dwi_bl.o 26 27 obj-$(CONFIG_BACKLIGHT_AS3711) += as3711_bl.o 27 28 obj-$(CONFIG_BACKLIGHT_BD6107) += bd6107.o 28 29 obj-$(CONFIG_BACKLIGHT_CLASS_DEVICE) += backlight.o ··· 50 49 obj-$(CONFIG_BACKLIGHT_MT6370) += mt6370-backlight.o 51 50 obj-$(CONFIG_BACKLIGHT_OMAP1) += omap1_bl.o 52 51 obj-$(CONFIG_BACKLIGHT_PANDORA) += pandora_bl.o 53 - obj-$(CONFIG_BACKLIGHT_PCF50633) += pcf50633-backlight.o 54 52 obj-$(CONFIG_BACKLIGHT_PWM) += pwm_bl.o 55 53 obj-$(CONFIG_BACKLIGHT_QCOM_WLED) += qcom-wled.o 56 54 obj-$(CONFIG_BACKLIGHT_RT4831) += rt4831-backlight.o
-1
drivers/video/backlight/adp5520_bl.c
··· 8 8 #include <linux/kernel.h> 9 9 #include <linux/init.h> 10 10 #include <linux/platform_device.h> 11 - #include <linux/fb.h> 12 11 #include <linux/backlight.h> 13 12 #include <linux/mfd/adp5520.h> 14 13 #include <linux/slab.h>
-1
drivers/video/backlight/adp8860_bl.c
··· 11 11 #include <linux/pm.h> 12 12 #include <linux/platform_device.h> 13 13 #include <linux/i2c.h> 14 - #include <linux/fb.h> 15 14 #include <linux/backlight.h> 16 15 #include <linux/leds.h> 17 16 #include <linux/slab.h>
-1
drivers/video/backlight/adp8870_bl.c
··· 11 11 #include <linux/pm.h> 12 12 #include <linux/platform_device.h> 13 13 #include <linux/i2c.h> 14 - #include <linux/fb.h> 15 14 #include <linux/backlight.h> 16 15 #include <linux/leds.h> 17 16 #include <linux/workqueue.h>
+123
drivers/video/backlight/apple_dwi_bl.c
··· 1 + // SPDX-License-Identifier: GPL-2.0 OR MIT 2 + /* 3 + * Driver for backlight controllers attached via Apple DWI 2-wire interface 4 + * 5 + * Copyright (c) 2024 Nick Chan <towinchenmi@gmail.com> 6 + */ 7 + 8 + #include <linux/backlight.h> 9 + #include <linux/bitfield.h> 10 + #include <linux/device.h> 11 + #include <linux/io.h> 12 + #include <linux/module.h> 13 + #include <linux/platform_device.h> 14 + 15 + #define DWI_BL_CTL 0x0 16 + #define DWI_BL_CTL_SEND1 BIT(0) 17 + #define DWI_BL_CTL_SEND2 BIT(4) 18 + #define DWI_BL_CTL_SEND3 BIT(5) 19 + #define DWI_BL_CTL_LE_DATA BIT(6) 20 + /* Only used on Apple A9 and later */ 21 + #define DWI_BL_CTL_SEND4 BIT(12) 22 + 23 + #define DWI_BL_CMD 0x4 24 + #define DWI_BL_CMD_TYPE GENMASK(31, 28) 25 + #define DWI_BL_CMD_TYPE_SET_BRIGHTNESS 0xa 26 + #define DWI_BL_CMD_DATA GENMASK(10, 0) 27 + 28 + #define DWI_BL_CTL_SEND (DWI_BL_CTL_SEND1 | \ 29 + DWI_BL_CTL_SEND2 | \ 30 + DWI_BL_CTL_SEND3 | \ 31 + DWI_BL_CTL_LE_DATA | \ 32 + DWI_BL_CTL_SEND4) 33 + 34 + #define DWI_BL_MAX_BRIGHTNESS 2047 35 + 36 + struct apple_dwi_bl { 37 + void __iomem *base; 38 + }; 39 + 40 + static int dwi_bl_update_status(struct backlight_device *bl) 41 + { 42 + struct apple_dwi_bl *dwi_bl = bl_get_data(bl); 43 + 44 + int brightness = backlight_get_brightness(bl); 45 + 46 + u32 cmd = 0; 47 + 48 + cmd |= FIELD_PREP(DWI_BL_CMD_DATA, brightness); 49 + cmd |= FIELD_PREP(DWI_BL_CMD_TYPE, DWI_BL_CMD_TYPE_SET_BRIGHTNESS); 50 + 51 + writel(cmd, dwi_bl->base + DWI_BL_CMD); 52 + writel(DWI_BL_CTL_SEND, dwi_bl->base + DWI_BL_CTL); 53 + 54 + return 0; 55 + } 56 + 57 + static int dwi_bl_get_brightness(struct backlight_device *bl) 58 + { 59 + struct apple_dwi_bl *dwi_bl = bl_get_data(bl); 60 + 61 + u32 cmd = readl(dwi_bl->base + DWI_BL_CMD); 62 + 63 + return FIELD_GET(DWI_BL_CMD_DATA, cmd); 64 + } 65 + 66 + static const struct backlight_ops dwi_bl_ops = { 67 + .options = BL_CORE_SUSPENDRESUME, 68 + .get_brightness = dwi_bl_get_brightness, 69 + .update_status = dwi_bl_update_status 70 + }; 71 + 72 + static int dwi_bl_probe(struct platform_device *dev) 73 + { 74 + struct apple_dwi_bl *dwi_bl; 75 + struct backlight_device *bl; 76 + struct backlight_properties props; 77 + struct resource *res; 78 + 79 + dwi_bl = devm_kzalloc(&dev->dev, sizeof(*dwi_bl), GFP_KERNEL); 80 + if (!dwi_bl) 81 + return -ENOMEM; 82 + 83 + dwi_bl->base = devm_platform_get_and_ioremap_resource(dev, 0, &res); 84 + if (IS_ERR(dwi_bl->base)) 85 + return PTR_ERR(dwi_bl->base); 86 + 87 + memset(&props, 0, sizeof(struct backlight_properties)); 88 + props.type = BACKLIGHT_PLATFORM; 89 + props.max_brightness = DWI_BL_MAX_BRIGHTNESS; 90 + props.scale = BACKLIGHT_SCALE_LINEAR; 91 + 92 + bl = devm_backlight_device_register(&dev->dev, dev->name, &dev->dev, 93 + dwi_bl, &dwi_bl_ops, &props); 94 + if (IS_ERR(bl)) 95 + return PTR_ERR(bl); 96 + 97 + platform_set_drvdata(dev, dwi_bl); 98 + 99 + bl->props.brightness = dwi_bl_get_brightness(bl); 100 + 101 + return 0; 102 + } 103 + 104 + static const struct of_device_id dwi_bl_of_match[] = { 105 + { .compatible = "apple,dwi-bl" }, 106 + {}, 107 + }; 108 + 109 + MODULE_DEVICE_TABLE(of, dwi_bl_of_match); 110 + 111 + static struct platform_driver dwi_bl_driver = { 112 + .driver = { 113 + .name = "apple-dwi-bl", 114 + .of_match_table = dwi_bl_of_match 115 + }, 116 + .probe = dwi_bl_probe, 117 + }; 118 + 119 + module_platform_driver(dwi_bl_driver); 120 + 121 + MODULE_DESCRIPTION("Apple DWI Backlight Driver"); 122 + MODULE_AUTHOR("Nick Chan <towinchenmi@gmail.com>"); 123 + MODULE_LICENSE("Dual MIT/GPL");
-1
drivers/video/backlight/as3711_bl.c
··· 10 10 #include <linux/delay.h> 11 11 #include <linux/device.h> 12 12 #include <linux/err.h> 13 - #include <linux/fb.h> 14 13 #include <linux/kernel.h> 15 14 #include <linux/mfd/as3711.h> 16 15 #include <linux/module.h>
-1
drivers/video/backlight/bd6107.c
··· 10 10 #include <linux/backlight.h> 11 11 #include <linux/delay.h> 12 12 #include <linux/err.h> 13 - #include <linux/fb.h> 14 13 #include <linux/gpio/consumer.h> 15 14 #include <linux/i2c.h> 16 15 #include <linux/module.h>
-1
drivers/video/backlight/da903x_bl.c
··· 12 12 #include <linux/kernel.h> 13 13 #include <linux/init.h> 14 14 #include <linux/platform_device.h> 15 - #include <linux/fb.h> 16 15 #include <linux/backlight.h> 17 16 #include <linux/mfd/da903x.h> 18 17 #include <linux/slab.h>
-1
drivers/video/backlight/da9052_bl.c
··· 9 9 10 10 #include <linux/backlight.h> 11 11 #include <linux/delay.h> 12 - #include <linux/fb.h> 13 12 #include <linux/module.h> 14 13 #include <linux/platform_device.h> 15 14
-1
drivers/video/backlight/ep93xx_bl.c
··· 11 11 #include <linux/module.h> 12 12 #include <linux/platform_device.h> 13 13 #include <linux/io.h> 14 - #include <linux/fb.h> 15 14 #include <linux/backlight.h> 16 15 17 16 #define EP93XX_MAX_COUNT 255
-1
drivers/video/backlight/hp680_bl.c
··· 15 15 #include <linux/init.h> 16 16 #include <linux/platform_device.h> 17 17 #include <linux/spinlock.h> 18 - #include <linux/fb.h> 19 18 #include <linux/backlight.h> 20 19 21 20 #include <cpu/dac.h>
+4 -1
drivers/video/backlight/led_bl.c
··· 229 229 backlight_device_unregister(bl); 230 230 231 231 led_bl_power_off(priv); 232 - for (i = 0; i < priv->nb_leds; i++) 232 + for (i = 0; i < priv->nb_leds; i++) { 233 + mutex_lock(&priv->leds[i]->led_access); 233 234 led_sysfs_enable(priv->leds[i]); 235 + mutex_unlock(&priv->leds[i]->led_access); 236 + } 234 237 } 235 238 236 239 static const struct of_device_id led_bl_of_match[] = {
-1
drivers/video/backlight/locomolcd.c
··· 16 16 #include <linux/delay.h> 17 17 #include <linux/device.h> 18 18 #include <linux/interrupt.h> 19 - #include <linux/fb.h> 20 19 #include <linux/backlight.h> 21 20 22 21 #include <asm/hardware/locomo.h>
-1
drivers/video/backlight/lv5207lp.c
··· 9 9 10 10 #include <linux/backlight.h> 11 11 #include <linux/err.h> 12 - #include <linux/fb.h> 13 12 #include <linux/i2c.h> 14 13 #include <linux/module.h> 15 14 #include <linux/platform_data/lv5207lp.h>
-1
drivers/video/backlight/max8925_bl.c
··· 9 9 #include <linux/init.h> 10 10 #include <linux/kernel.h> 11 11 #include <linux/platform_device.h> 12 - #include <linux/fb.h> 13 12 #include <linux/i2c.h> 14 13 #include <linux/backlight.h> 15 14 #include <linux/mfd/max8925.h>
-154
drivers/video/backlight/pcf50633-backlight.c
··· 1 - // SPDX-License-Identifier: GPL-2.0-or-later 2 - /* 3 - * Copyright (C) 2009-2010, Lars-Peter Clausen <lars@metafoo.de> 4 - * PCF50633 backlight device driver 5 - */ 6 - 7 - #include <linux/kernel.h> 8 - #include <linux/module.h> 9 - #include <linux/slab.h> 10 - #include <linux/platform_device.h> 11 - 12 - #include <linux/backlight.h> 13 - 14 - #include <linux/mfd/pcf50633/core.h> 15 - #include <linux/mfd/pcf50633/backlight.h> 16 - 17 - struct pcf50633_bl { 18 - struct pcf50633 *pcf; 19 - struct backlight_device *bl; 20 - 21 - unsigned int brightness; 22 - unsigned int brightness_limit; 23 - }; 24 - 25 - /* 26 - * pcf50633_bl_set_brightness_limit 27 - * 28 - * Update the brightness limit for the pc50633 backlight. The actual brightness 29 - * will not go above the limit. This is useful to limit power drain for example 30 - * on low battery. 31 - * 32 - * @dev: Pointer to a pcf50633 device 33 - * @limit: The brightness limit. Valid values are 0-63 34 - */ 35 - int pcf50633_bl_set_brightness_limit(struct pcf50633 *pcf, unsigned int limit) 36 - { 37 - struct pcf50633_bl *pcf_bl = platform_get_drvdata(pcf->bl_pdev); 38 - 39 - if (!pcf_bl) 40 - return -ENODEV; 41 - 42 - pcf_bl->brightness_limit = limit & 0x3f; 43 - backlight_update_status(pcf_bl->bl); 44 - 45 - return 0; 46 - } 47 - 48 - static int pcf50633_bl_update_status(struct backlight_device *bl) 49 - { 50 - struct pcf50633_bl *pcf_bl = bl_get_data(bl); 51 - unsigned int new_brightness; 52 - 53 - 54 - if (bl->props.state & (BL_CORE_SUSPENDED | BL_CORE_FBBLANK) || 55 - bl->props.power != BACKLIGHT_POWER_ON) 56 - new_brightness = 0; 57 - else if (bl->props.brightness < pcf_bl->brightness_limit) 58 - new_brightness = bl->props.brightness; 59 - else 60 - new_brightness = pcf_bl->brightness_limit; 61 - 62 - 63 - if (pcf_bl->brightness == new_brightness) 64 - return 0; 65 - 66 - if (new_brightness) { 67 - pcf50633_reg_write(pcf_bl->pcf, PCF50633_REG_LEDOUT, 68 - new_brightness); 69 - if (!pcf_bl->brightness) 70 - pcf50633_reg_write(pcf_bl->pcf, PCF50633_REG_LEDENA, 1); 71 - } else { 72 - pcf50633_reg_write(pcf_bl->pcf, PCF50633_REG_LEDENA, 0); 73 - } 74 - 75 - pcf_bl->brightness = new_brightness; 76 - 77 - return 0; 78 - } 79 - 80 - static int pcf50633_bl_get_brightness(struct backlight_device *bl) 81 - { 82 - struct pcf50633_bl *pcf_bl = bl_get_data(bl); 83 - 84 - return pcf_bl->brightness; 85 - } 86 - 87 - static const struct backlight_ops pcf50633_bl_ops = { 88 - .get_brightness = pcf50633_bl_get_brightness, 89 - .update_status = pcf50633_bl_update_status, 90 - .options = BL_CORE_SUSPENDRESUME, 91 - }; 92 - 93 - static int pcf50633_bl_probe(struct platform_device *pdev) 94 - { 95 - struct pcf50633_bl *pcf_bl; 96 - struct device *parent = pdev->dev.parent; 97 - struct pcf50633_platform_data *pcf50633_data = dev_get_platdata(parent); 98 - struct pcf50633_bl_platform_data *pdata = pcf50633_data->backlight_data; 99 - struct backlight_properties bl_props; 100 - 101 - pcf_bl = devm_kzalloc(&pdev->dev, sizeof(*pcf_bl), GFP_KERNEL); 102 - if (!pcf_bl) 103 - return -ENOMEM; 104 - 105 - memset(&bl_props, 0, sizeof(bl_props)); 106 - bl_props.type = BACKLIGHT_RAW; 107 - bl_props.max_brightness = 0x3f; 108 - bl_props.power = BACKLIGHT_POWER_ON; 109 - 110 - if (pdata) { 111 - bl_props.brightness = pdata->default_brightness; 112 - pcf_bl->brightness_limit = pdata->default_brightness_limit; 113 - } else { 114 - bl_props.brightness = 0x3f; 115 - pcf_bl->brightness_limit = 0x3f; 116 - } 117 - 118 - pcf_bl->pcf = dev_to_pcf50633(pdev->dev.parent); 119 - 120 - pcf_bl->bl = devm_backlight_device_register(&pdev->dev, pdev->name, 121 - &pdev->dev, pcf_bl, 122 - &pcf50633_bl_ops, &bl_props); 123 - 124 - if (IS_ERR(pcf_bl->bl)) 125 - return PTR_ERR(pcf_bl->bl); 126 - 127 - platform_set_drvdata(pdev, pcf_bl); 128 - 129 - pcf50633_reg_write(pcf_bl->pcf, PCF50633_REG_LEDDIM, pdata->ramp_time); 130 - 131 - /* 132 - * Should be different from bl_props.brightness, so we do not exit 133 - * update_status early the first time it's called 134 - */ 135 - pcf_bl->brightness = pcf_bl->bl->props.brightness + 1; 136 - 137 - backlight_update_status(pcf_bl->bl); 138 - 139 - return 0; 140 - } 141 - 142 - static struct platform_driver pcf50633_bl_driver = { 143 - .probe = pcf50633_bl_probe, 144 - .driver = { 145 - .name = "pcf50633-backlight", 146 - }, 147 - }; 148 - 149 - module_platform_driver(pcf50633_bl_driver); 150 - 151 - MODULE_AUTHOR("Lars-Peter Clausen <lars@metafoo.de>"); 152 - MODULE_DESCRIPTION("PCF50633 backlight driver"); 153 - MODULE_LICENSE("GPL"); 154 - MODULE_ALIAS("platform:pcf50633-backlight");
-1
drivers/video/backlight/tps65217_bl.c
··· 11 11 #include <linux/kernel.h> 12 12 #include <linux/backlight.h> 13 13 #include <linux/err.h> 14 - #include <linux/fb.h> 15 14 #include <linux/mfd/tps65217.h> 16 15 #include <linux/module.h> 17 16 #include <linux/platform_device.h>
-1
drivers/video/backlight/vgg2432a4.c
··· 10 10 11 11 #include <linux/delay.h> 12 12 #include <linux/err.h> 13 - #include <linux/fb.h> 14 13 #include <linux/init.h> 15 14 #include <linux/lcd.h> 16 15 #include <linux/module.h>
-1
drivers/video/backlight/wm831x_bl.c
··· 9 9 #include <linux/init.h> 10 10 #include <linux/platform_device.h> 11 11 #include <linux/module.h> 12 - #include <linux/fb.h> 13 12 #include <linux/backlight.h> 14 13 #include <linux/slab.h> 15 14
-42
include/linux/mfd/pcf50633/backlight.h
··· 1 - /* SPDX-License-Identifier: GPL-2.0-or-later */ 2 - /* 3 - * Copyright (C) 2009-2010, Lars-Peter Clausen <lars@metafoo.de> 4 - * PCF50633 backlight device driver 5 - */ 6 - 7 - #ifndef __LINUX_MFD_PCF50633_BACKLIGHT 8 - #define __LINUX_MFD_PCF50633_BACKLIGHT 9 - 10 - /* 11 - * @default_brightness: Backlight brightness is initialized to this value 12 - * 13 - * Brightness to be used after the driver has been probed. 14 - * Valid range 0-63. 15 - * 16 - * @default_brightness_limit: The actual brightness is limited by this value 17 - * 18 - * Brightness limit to be used after the driver has been probed. This is useful 19 - * when it is not known how much power is available for the backlight during 20 - * probe. 21 - * Valid range 0-63. Can be changed later with pcf50633_bl_set_brightness_limit. 22 - * 23 - * @ramp_time: Display ramp time when changing brightness 24 - * 25 - * When changing the backlights brightness the change is not instant, instead 26 - * it fades smooth from one state to another. This value specifies how long 27 - * the fade should take. The lower the value the higher the fade time. 28 - * Valid range 0-255 29 - */ 30 - struct pcf50633_bl_platform_data { 31 - unsigned int default_brightness; 32 - unsigned int default_brightness_limit; 33 - uint8_t ramp_time; 34 - }; 35 - 36 - 37 - struct pcf50633; 38 - 39 - int pcf50633_bl_set_brightness_limit(struct pcf50633 *pcf, unsigned int limit); 40 - 41 - #endif 42 -
-3
include/linux/mfd/pcf50633/core.h
··· 15 15 #include <linux/regulator/machine.h> 16 16 #include <linux/pm.h> 17 17 #include <linux/power_supply.h> 18 - #include <linux/mfd/pcf50633/backlight.h> 19 18 20 19 struct pcf50633; 21 20 struct regmap; ··· 41 42 void (*force_shutdown)(struct pcf50633 *); 42 43 43 44 u8 resumers[5]; 44 - 45 - struct pcf50633_bl_platform_data *backlight_data; 46 45 }; 47 46 48 47 struct pcf50633_irq {