View | Details | Raw Unified | Return to bug 5749 | Differences between
and this patch

Collapse All | Expand All

(-)a/drivers/video/backlight/backlight.c (-1 / +2 lines)
Lines 190-196 static int fb_notifier_callback(struct n Link Here
190
 * Creates and registers new backlight class_device. Returns either an
190
 * Creates and registers new backlight class_device. Returns either an
191
 * ERR_PTR() or a pointer to the newly allocated device.
191
 * ERR_PTR() or a pointer to the newly allocated device.
192
 */
192
 */
193
struct backlight_device *backlight_device_register(const char *name, void *devdata,
193
struct backlight_device *backlight_device_register(const char *name,struct device *dev,  void *devdata,
194
						   struct backlight_properties *bp)
194
						   struct backlight_properties *bp)
195
{
195
{
196
	int i, rc;
196
	int i, rc;
Lines 206-211 struct backlight_device *backlight_devic Link Here
206
	new_bd->props = bp;
206
	new_bd->props = bp;
207
	memset(&new_bd->class_dev, 0, sizeof(new_bd->class_dev));
207
	memset(&new_bd->class_dev, 0, sizeof(new_bd->class_dev));
208
	new_bd->class_dev.class = &backlight_class;
208
	new_bd->class_dev.class = &backlight_class;
209
	new_bd->class_dev.dev = dev;
209
	strlcpy(new_bd->class_dev.class_id, name, KOBJ_NAME_LEN);
210
	strlcpy(new_bd->class_dev.class_id, name, KOBJ_NAME_LEN);
210
	class_set_devdata(&new_bd->class_dev, devdata);
211
	class_set_devdata(&new_bd->class_dev, devdata);
211
212
(-)a/include/linux/backlight.h (-1 / +1 lines)
Lines 54-60 struct backlight_device { Link Here
54
};
54
};
55
55
56
extern struct backlight_device *backlight_device_register(const char *name,
56
extern struct backlight_device *backlight_device_register(const char *name,
57
	void *devdata, struct backlight_properties *bp);
57
	struct device *dev, void *devdata, struct backlight_properties *bp);
58
extern void backlight_device_unregister(struct backlight_device *bd);
58
extern void backlight_device_unregister(struct backlight_device *bd);
59
59
60
#define to_backlight_device(obj) container_of(obj, struct backlight_device, class_dev)
60
#define to_backlight_device(obj) container_of(obj, struct backlight_device, class_dev)

Return to bug 5749