diff options
author | Jingoo Han <jg1.han@samsung.com> | 2014-01-23 15:54:30 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-01-23 16:36:56 -0800 |
commit | 7dd78077369ebe7db031d9de1d6b4c766b3b4f7d (patch) | |
tree | 422e99bbad99d12be662f10f23a66e8b4aa2a117 /drivers/video/backlight/l4f00242t03.c | |
parent | 964598f239c37cd6df73d94458beaabec3dc6928 (diff) | |
download | op-kernel-dev-7dd78077369ebe7db031d9de1d6b4c766b3b4f7d.zip op-kernel-dev-7dd78077369ebe7db031d9de1d6b4c766b3b4f7d.tar.gz |
backlight: l4f00242t03: use devm_lcd_device_register()
Use devm_lcd_device_register() to make cleanup paths simpler.
Signed-off-by: Jingoo Han <jg1.han@samsung.com>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/video/backlight/l4f00242t03.c')
-rw-r--r-- | drivers/video/backlight/l4f00242t03.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/video/backlight/l4f00242t03.c b/drivers/video/backlight/l4f00242t03.c index b5fc13b..63e7638 100644 --- a/drivers/video/backlight/l4f00242t03.c +++ b/drivers/video/backlight/l4f00242t03.c @@ -223,8 +223,8 @@ static int l4f00242t03_probe(struct spi_device *spi) return PTR_ERR(priv->core_reg); } - priv->ld = lcd_device_register("l4f00242t03", - &spi->dev, priv, &l4f_ops); + priv->ld = devm_lcd_device_register(&spi->dev, "l4f00242t03", &spi->dev, + priv, &l4f_ops); if (IS_ERR(priv->ld)) return PTR_ERR(priv->ld); @@ -243,8 +243,6 @@ static int l4f00242t03_remove(struct spi_device *spi) struct l4f00242t03_priv *priv = spi_get_drvdata(spi); l4f00242t03_lcd_power_set(priv->ld, FB_BLANK_POWERDOWN); - lcd_device_unregister(priv->ld); - return 0; } |