From patchwork Tue Feb 2 08:43:04 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Kai Ruhnau X-Patchwork-Id: 8187551 Return-Path: X-Original-To: patchwork-linux-fbdev@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id BA8189F4DD for ; Tue, 2 Feb 2016 08:58:22 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D70F820279 for ; Tue, 2 Feb 2016 08:58:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id D1C2E20270 for ; Tue, 2 Feb 2016 08:58:19 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754373AbcBBI6R (ORCPT ); Tue, 2 Feb 2016 03:58:17 -0500 Received: from mail-am1on0143.outbound.protection.outlook.com ([157.56.112.143]:6171 "EHLO emea01-am1-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1754368AbcBBI6M convert rfc822-to-8bit (ORCPT ); Tue, 2 Feb 2016 03:58:12 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=targetsg.onmicrosoft.com; s=selector1-targetsg-com01e; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=wKSqLj3ggbkv2FkxZgr3uR4n69oeOoOGKofbqrY9rCY=; b=GegxZxvqxbYNM1C9A0lXY3/QZi9eRJ3+RcVsauXH/7g/6t8ufLGa9XjiEdrKkKWA8s5XwGoLI/E7YalVWT8JcYH/w47e4lGYyczQ4c5wpZZ9cY2toeB4Wv55fbXTVPbogdmkm5kaFpUUden3pF/Yh0ZPsuPjUnSPQXDjbRYtNc8= Received: from AM2PR02MB0371.eurprd02.prod.outlook.com (10.160.33.150) by AM2PR02MB0371.eurprd02.prod.outlook.com (10.160.33.150) with Microsoft SMTP Server (TLS) id 15.1.390.13; Tue, 2 Feb 2016 08:43:05 +0000 Received: from AM2PR02MB0371.eurprd02.prod.outlook.com ([10.160.33.150]) by AM2PR02MB0371.eurprd02.prod.outlook.com ([10.160.33.150]) with mapi id 15.01.0390.019; Tue, 2 Feb 2016 08:43:05 +0000 From: Kai Ruhnau To: "plagnioj@jcrosoft.com" , "tomi.valkeinen@ti.com" CC: "niederp@physik.uni-kl.de" , "linux-fbdev@vger.kernel.org" Subject: RE: [PATCH] fbdev: ssd1307fb: Fix activating the charge pump on ssd1306 Thread-Topic: [PATCH] fbdev: ssd1307fb: Fix activating the charge pump on ssd1306 Thread-Index: AQHRXQHYCNet2mj9jkqRHhHsq5bMFJ8YcMoQ Date: Tue, 2 Feb 2016 08:43:04 +0000 Message-ID: References: <1454339039-4976-1-git-send-email-kai.ruhnau@target-sg.com> In-Reply-To: <1454339039-4976-1-git-send-email-kai.ruhnau@target-sg.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: jcrosoft.com; dkim=none (message not signed) header.d=none; jcrosoft.com; dmarc=none action=none header.from=target-sg.com; x-originating-ip: [2003:6f:880f:5600:ccd0:669b:ece0:474f] x-microsoft-exchange-diagnostics: 1; AM2PR02MB0371; 5:EfZuTYjDJdAv4byoiwDBWrYC+Ih0uYr5+gDpy/iGBtQ124LpIvvGcGKCJ42MuJ1QZiCZdcYw3e3kYnKxHSrVcRxdnIEjGAadm3aLMl7wE7xjVIkP9dBaS+5LUBKPzegqfIhQr9JHvAzy1zEAULYTtw==; 24:DAJkKdJqZYKHp9dHhvMXxr+yrSDG7dryp2G9PsA/LhcG1s9um+a14PCeYB8I0dVvXf0OLSr2dZ0LdWsiZlTiYonAozzhEJWLifBQNaeHa+4= x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:AM2PR02MB0371; x-ms-office365-filtering-correlation-id: 2cdddc00-8e0a-4553-1c01-08d32bacde62 x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:; x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046); SRVR:AM2PR02MB0371; BCL:0; PCL:0; RULEID:; SRVR:AM2PR02MB0371; x-forefront-prvs: 084080FC15 x-forefront-antispam-report: SFV:NSPM; SFS:(10019020)(6009001)(13464003)(92566002)(10400500002)(11100500001)(2906002)(87936001)(5001960100002)(4326007)(19580395003)(19580405001)(86362001)(106116001)(5004730100002)(2501003)(33656002)(2900100001)(2950100001)(5001770100001)(76176999)(40100003)(102836003)(50986999)(54356999)(189998001)(77096005)(3470700001)(586003)(3280700002)(6116002)(76576001)(5002640100001)(5008740100001)(1096002)(5003600100002)(122556002)(1220700001)(74316001)(3660700001)(3826002); DIR:OUT; SFP:1102; SCL:1; SRVR:AM2PR02MB0371; H:AM2PR02MB0371.eurprd02.prod.outlook.com; FPR:; SPF:None; MLV:sfv; LANG:en; spamdiagnosticoutput: 1:23 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: target-sg.com X-MS-Exchange-CrossTenant-originalarrivaltime: 02 Feb 2016 08:43:05.0494 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 52a4fe2f-f30a-452d-90b1-03ecc8ab0c0d X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM2PR02MB0371 Sender: linux-fbdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fbdev@vger.kernel.org X-Spam-Status: No, score=-7.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Hi, I just saw that the same thing was already fixed by Julian in November, sorry for doubling this. Best regards Kai -----Original Message----- From: Kai Ruhnau Sent: Montag, 1. Februar 2016 16:04 To: plagnioj@jcrosoft.com; tomi.valkeinen@ti.com Cc: niederp@physik.uni-kl.de; linux-fbdev@vger.kernel.org; Kai Ruhnau Subject: [PATCH] fbdev: ssd1307fb: Fix activating the charge pump on ssd1306 The charge pump is activated by sending 0x14 where the higher bit is always 1 and the lower bit actually toggles it. Signed-off-by: Kai Ruhnau --- drivers/video/fbdev/ssd1307fb.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.4.3 -- Kai Ruhnau Software Manager T:+49 202 769302 19 Target Systemelektronik GmbH & Co. KG Heinz-Fangman-Straße 4 42287 Wuppertal Amtsgericht Wuppertal HRA 23898 Persönlich haftende Gesellschafterin Target Systemelektronik Beteiligungs GmbH Heinz-Fangman-Straße 4, 42287 Wuppertal Amtsgericht Wuppertal HRB 25346 Geschäftsführer: Jürgen Stein -- -- Kai Ruhnau Software Manager T:+49 202 769302 19 Target Systemelektronik GmbH & Co. KG Heinz-Fangman-Straße 4 42287 Wuppertal Amtsgericht Wuppertal HRA 23898 Persönlich haftende Gesellschafterin Target Systemelektronik Beteiligungs GmbH Heinz-Fangman-Straße 4, 42287 Wuppertal Amtsgericht Wuppertal HRB 25346 Geschäftsführer: Jürgen Stein -- -- To unsubscribe from this list: send the line "unsubscribe linux-fbdev" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/video/fbdev/ssd1307fb.c b/drivers/video/fbdev/ssd1307fb.c index fa34808..20d249f 100644 --- a/drivers/video/fbdev/ssd1307fb.c +++ b/drivers/video/fbdev/ssd1307fb.c @@ -285,7 +285,7 @@ static void ssd1307fb_deferred_io(struct fb_info *info, static int ssd1307fb_init(struct ssd1307fb_par *par) { int ret; - u32 precharge, dclk, com_invdir, compins; + u32 precharge, dclk, com_invdir, compins, chargepump; if (par->device_info->need_pwm) { par->pwm = pwm_get(&par->client->dev, NULL); @@ -388,8 +388,8 @@ static int ssd1307fb_init(struct ssd1307fb_par *par) if (ret < 0) return ret; - ret = ssd1307fb_write_cmd(par->client, - (par->device_info->need_chargepump & 0x1 << 2) & 0x14); + chargepump = 0x10 | (par->device_info->need_chargepump & 0x1) << 2; + ret = ssd1307fb_write_cmd(par->client, chargepump); if (ret < 0) return ret;