Merge branch 'for-linus' of git://git.o-hand.com/linux-rpurdie-backlight
* 'for-linus' of git://git.o-hand.com/linux-rpurdie-backlight: leds: cr_bllcd.c: build fix backlight: Convert from struct class_device to struct device backlight: Fix order of Kconfig entries
This commit is contained in:
@@ -69,8 +69,8 @@ struct backlight_device {
|
||||
|
||||
/* The framebuffer notifier block */
|
||||
struct notifier_block fb_notif;
|
||||
/* The class device structure */
|
||||
struct class_device class_dev;
|
||||
|
||||
struct device dev;
|
||||
};
|
||||
|
||||
static inline void backlight_update_status(struct backlight_device *bd)
|
||||
@@ -85,6 +85,11 @@ extern struct backlight_device *backlight_device_register(const char *name,
|
||||
struct device *dev, void *devdata, struct backlight_ops *ops);
|
||||
extern void backlight_device_unregister(struct backlight_device *bd);
|
||||
|
||||
#define to_backlight_device(obj) container_of(obj, struct backlight_device, class_dev)
|
||||
#define to_backlight_device(obj) container_of(obj, struct backlight_device, dev)
|
||||
|
||||
static inline void * bl_get_data(struct backlight_device *bl_dev)
|
||||
{
|
||||
return dev_get_drvdata(&bl_dev->dev);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
+10
-4
@@ -62,8 +62,8 @@ struct lcd_device {
|
||||
struct mutex update_lock;
|
||||
/* The framebuffer notifier block */
|
||||
struct notifier_block fb_notif;
|
||||
/* The class device structure */
|
||||
struct class_device class_dev;
|
||||
|
||||
struct device dev;
|
||||
};
|
||||
|
||||
static inline void lcd_set_power(struct lcd_device *ld, int power)
|
||||
@@ -75,9 +75,15 @@ static inline void lcd_set_power(struct lcd_device *ld, int power)
|
||||
}
|
||||
|
||||
extern struct lcd_device *lcd_device_register(const char *name,
|
||||
void *devdata, struct lcd_ops *ops);
|
||||
struct device *parent, void *devdata, struct lcd_ops *ops);
|
||||
extern void lcd_device_unregister(struct lcd_device *ld);
|
||||
|
||||
#define to_lcd_device(obj) container_of(obj, struct lcd_device, class_dev)
|
||||
#define to_lcd_device(obj) container_of(obj, struct lcd_device, dev)
|
||||
|
||||
static inline void * lcd_get_data(struct lcd_device *ld_dev)
|
||||
{
|
||||
return dev_get_drvdata(&ld_dev->dev);
|
||||
}
|
||||
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user