summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJulian Scheel <julian@jusst.de>2016-03-24 22:14:23 +0100
committerTomi Valkeinen <tomi.valkeinen@ti.com>2016-05-10 13:29:36 +0300
commit80403b232b7af033bb5a2043fc4d60f16e46519f (patch)
tree74ae6b8794e20718074e66cb6a6bf18aeb1a54c7
parentad6a2d0f8d2991102e89a0b24a0a49fa7b0ec844 (diff)
fbdev: ssd1307fb: Fix charge pump setting
Make sure bit 4 is set for the charge pump setting. It is required according to SSD1306 App Note. Signed-off-by: Julian Scheel <julian@jusst.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
-rw-r--r--drivers/video/fbdev/ssd1307fb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/video/fbdev/ssd1307fb.c b/drivers/video/fbdev/ssd1307fb.c
index fa3480815cdb..21dafe53ca49 100644
--- a/drivers/video/fbdev/ssd1307fb.c
+++ b/drivers/video/fbdev/ssd1307fb.c
@@ -389,7 +389,7 @@ static int ssd1307fb_init(struct ssd1307fb_par *par)
return ret;
ret = ssd1307fb_write_cmd(par->client,
- (par->device_info->need_chargepump & 0x1 << 2) & 0x14);
+ BIT(4) | (par->device_info->need_chargepump ? BIT(2) : 0));
if (ret < 0)
return ret;