Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3206029pxk; Mon, 21 Sep 2020 07:52:00 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzPOLEqIjmxi6h26twqK94ll1javJxfVElWprzAmOf73j2Nn9s5ZmcnSW5ws1plJ8l1sQ/7 X-Received: by 2002:a17:906:fb04:: with SMTP id lz4mr7791924ejb.535.1600699920488; Mon, 21 Sep 2020 07:52:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600699920; cv=none; d=google.com; s=arc-20160816; b=HcU78np0i3xf9jjQa3xNxP09oQn6ygc+c8LGtKAdQANp2yTXBRSZ6TKcdzqmKqkWnR ebiwLRftfA4CW02dp42qRHSu2X8c5uwTyMDH0pOZwrx1Os6fbu3YWSzjptt53aDSllif 9DxSnIt/A0luhpe+nQq6uvbcgx4EE6UWhWeJGJBUqDOUe5T3DHsDa7A2Bk4Rl8Sg3eCq n3clKXscYBWpi2Xg6g0x1P0YDp1ts6UYDXX7mXgQudB/oeLB2zVqOtrwHvkb2UewjyPs l9a6DxL6+UrXLPqJMoYsN5cYBvVy+mDFHAoMl2Kb9QYDOBqLbHM5Mk8Dro9ImdJwVu8B rP4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=jIcAnT6TjvkzuSrAZ+fg5Q+KmomOtWyX9N5TS1ykQe4=; b=TtVbWu5M7SaT9Bl+stATzUGNKtBymNMbu9QCDIuJ4tHTJV5TCWtyjVmtxARm7WDU16 6Y/jaECumus+J1yy1/RUzRLklrvtygUE9sI1TQTgIrMjMU8sQV4WMNTLmadetuk2HLdf 6pcqFotzIHhzckZpDCHtoYfse+PKYIYMCSrGjvBcF//7PrjwxlPR8j19s9V5Fv5S3WNj a1cAbLKEuIhyYPp6iaimLkCEgoI+YCjPpd/X/VVQ69ta+AvAMldDE18G0V4uwhY2RtSI upwlT5s64EA1C71lj10Wid7qpIOzC2iy+6Ne3WFCgsahO1pgEYFKtpnvTDPFMT33wa4+ Z+7w== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a6si1641032edn.512.2020.09.21.07.51.37; Mon, 21 Sep 2020 07:52:00 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728078AbgIUOst (ORCPT + 99 others); Mon, 21 Sep 2020 10:48:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44396 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728065AbgIUOsN (ORCPT ); Mon, 21 Sep 2020 10:48:13 -0400 Received: from smtp1.goneo.de (smtp1.goneo.de [IPv6:2001:1640:5::8:30]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id BDC70C0613D4 for ; Mon, 21 Sep 2020 07:48:12 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by smtp1.goneo.de (Postfix) with ESMTP id A745E23F05E; Mon, 21 Sep 2020 16:48:11 +0200 (CEST) X-Virus-Scanned: by goneo X-Spam-Flag: NO X-Spam-Score: -2.998 X-Spam-Level: X-Spam-Status: No, score=-2.998 tagged_above=-999 tests=[ALL_TRUSTED=-1, AWL=-0.098, BAYES_00=-1.9] autolearn=ham Received: from smtp1.goneo.de ([127.0.0.1]) by localhost (smtp1.goneo.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id dFOI0AKCNpVz; Mon, 21 Sep 2020 16:48:07 +0200 (CEST) Received: from lem-wkst-02.lemonage.de. (hq.lemonage.de [87.138.178.34]) by smtp1.goneo.de (Postfix) with ESMTPA id D457123F16B; Mon, 21 Sep 2020 16:48:06 +0200 (CEST) From: poeschel@lemonage.de To: Miguel Ojeda Sandonis , linux-kernel@vger.kernel.org (open list) Cc: Lars Poeschel Subject: [PATCH v2 23/32] auxdisplay: Remove unnecessary hd44780 from charlcd Date: Mon, 21 Sep 2020 16:46:35 +0200 Message-Id: <20200921144645.2061313-24-poeschel@lemonage.de> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200921144645.2061313-1-poeschel@lemonage.de> References: <20191016082430.5955-1-poeschel@lemonage.de> <20200921144645.2061313-1-poeschel@lemonage.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Lars Poeschel The last two commits made another chunk of hd44780 code unnecessary which we remove here. Signed-off-by: Lars Poeschel --- drivers/auxdisplay/charlcd.c | 17 +---------------- 1 file changed, 1 insertion(+), 16 deletions(-) diff --git a/drivers/auxdisplay/charlcd.c b/drivers/auxdisplay/charlcd.c index d672e4c371e1..29737c3e18f6 100644 --- a/drivers/auxdisplay/charlcd.c +++ b/drivers/auxdisplay/charlcd.c @@ -25,16 +25,8 @@ /* Keep the backlight on this many seconds for each flash */ #define LCD_BL_TEMPO_PERIOD 4 -/* LCD commands */ -#define LCD_CMD_FUNCTION_SET 0x20 /* Set function */ -#define LCD_CMD_DATA_LEN_8BITS 0x10 /* Set data length to 8 bits */ -#define LCD_CMD_TWO_LINES 0x08 /* Set to two display lines */ -#define LCD_CMD_FONT_5X10_DOTS 0x04 /* Set char font to 5x10 dots */ - #define LCD_CMD_SET_CGRAM_ADDR 0x40 /* Set char generator RAM address */ -#define LCD_CMD_SET_DDRAM_ADDR 0x80 /* Set display data RAM address */ - #define LCD_ESCAPE_LEN 24 /* Max chars for LCD escape command */ #define LCD_ESCAPE_CHAR 27 /* Use char 27 for escape command */ @@ -426,14 +418,7 @@ static inline int handle_lcd_special_code(struct charlcd *lcd) if (oldflags == priv->flags) return processed; - if ((oldflags ^ priv->flags) & (LCD_FLAG_F | LCD_FLAG_N)) - hdc->write_cmd(hdc, - LCD_CMD_FUNCTION_SET | - ((hdc->ifwidth == 8) ? LCD_CMD_DATA_LEN_8BITS : 0) | - ((priv->flags & LCD_FLAG_F) ? LCD_CMD_FONT_5X10_DOTS : 0) | - ((priv->flags & LCD_FLAG_N) ? LCD_CMD_TWO_LINES : 0)); - /* check whether L flag was changed */ - else if ((oldflags ^ priv->flags) & LCD_FLAG_L) + if ((oldflags ^ priv->flags) & LCD_FLAG_L) charlcd_backlight(lcd, !!(priv->flags & LCD_FLAG_L)); return processed; -- 2.28.0