[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20150207114534.GR2079@lukather>
Date: Sat, 7 Feb 2015 12:45:34 +0100
From: Maxime Ripard <maxime.ripard@...e-electrons.com>
To: niederp@...sik.uni-kl.de
Cc: linux-fbdev@...r.kernel.org, plagnioj@...osoft.com,
tomi.valkeinen@...com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 8/8] fbdev: ssd1307fb: Turn off display on driver unload.
On Fri, Feb 06, 2015 at 11:28:14PM +0100, niederp@...sik.uni-kl.de wrote:
> From: Thomas Niederprüm <niederp@...sik.uni-kl.de>
>
A commit log is always nice :)
> Signed-off-by: Thomas Niederprüm <niederp@...sik.uni-kl.de>
> ---
> drivers/video/fbdev/ssd1307fb.c | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/drivers/video/fbdev/ssd1307fb.c b/drivers/video/fbdev/ssd1307fb.c
> index 02931c7..be91dfc 100644
> --- a/drivers/video/fbdev/ssd1307fb.c
> +++ b/drivers/video/fbdev/ssd1307fb.c
> @@ -762,6 +762,11 @@ static int ssd1307fb_remove(struct i2c_client *client)
> {
> struct fb_info *info = i2c_get_clientdata(client);
> struct ssd1307fb_par *par = info->par;
> + int ret = 0;
> +
> + ret = ssd1307fb_write_cmd(par->client, SSD1307FB_DISPLAY_OFF);
> + if (ret < 0)
> + return ret;
I don't think we really care about the return value here.
It might be even worse actually, since you'll end up in a intermediate
state, where you won't have freed everything, but your remove method
has been called still.
Maxime
--
Maxime Ripard, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
Download attachment "signature.asc" of type "application/pgp-signature" (820 bytes)
Powered by blists - more mailing lists