xref: /linux-6.15/include/linux/pwm_backlight.h (revision 257462db)
142796d37Seric miao /*
242796d37Seric miao  * Generic PWM backlight driver data - see drivers/video/backlight/pwm_bl.c
342796d37Seric miao  */
442796d37Seric miao #ifndef __LINUX_PWM_BACKLIGHT_H
542796d37Seric miao #define __LINUX_PWM_BACKLIGHT_H
642796d37Seric miao 
7ef0a5e80SRobert Morell #include <linux/backlight.h>
8ef0a5e80SRobert Morell 
942796d37Seric miao struct platform_pwm_backlight_data {
1042796d37Seric miao 	int pwm_id;
1142796d37Seric miao 	unsigned int max_brightness;
1242796d37Seric miao 	unsigned int dft_brightness;
13fef7764fSArun Murthy 	unsigned int lth_brightness;
1442796d37Seric miao 	unsigned int pwm_period_ns;
153e3ed6cdSThierry Reding 	unsigned int *levels;
16*257462dbSAlexandre Courbot 	/* TODO remove once all users are switched to gpiod_* API */
172b9b1620SThierry Reding 	int enable_gpio;
183b73125aSPhilipp Zabel 	int (*init)(struct device *dev);
19cfc3899fSBen Dooks 	int (*notify)(struct device *dev, int brightness);
20cc7993f6SDilan Lee 	void (*notify_after)(struct device *dev, int brightness);
213b73125aSPhilipp Zabel 	void (*exit)(struct device *dev);
22ef0a5e80SRobert Morell 	int (*check_fb)(struct device *dev, struct fb_info *info);
2342796d37Seric miao };
2442796d37Seric miao 
2542796d37Seric miao #endif
26