backlight: lcd: Fix race condition during register
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Wed, 6 Jul 2016 17:33:05 +0000 (19:33 +0200)
committerLee Jones <lee.jones@linaro.org>
Wed, 4 Jan 2017 11:37:31 +0000 (11:37 +0000)
commitcc21942bce652d1a92dae85b785378256e1df1f7
treebb6362458ce56f7781f052955e19beb9d2184e49
parent7ce7d89f48834cefece7804d38fc5d85382edf77
backlight: lcd: Fix race condition during register

Once device_register is called for a device its attributes might be
accessed. As the callbacks of a lcd device's attributes make use of the
lcd_ops, the respective member must be setup before calling
device_register.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Lee Jones <lee.jones@linaro.org>
drivers/video/backlight/lcd.c