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 |
|