Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3249441pxk; Mon, 5 Oct 2020 05:15:40 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx4hRx0bxMgN24RiAXn2mLeTxaKOM+AZ+S+5Ljun+59tQ0eLUUeCtKf+ZSCeNR4AaeY0op4 X-Received: by 2002:a17:906:4e06:: with SMTP id z6mr1848962eju.370.1601900140701; Mon, 05 Oct 2020 05:15:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601900140; cv=none; d=google.com; s=arc-20160816; b=XRXfn3/qDB2gQM7Y73dvIjbsoJVoUYm6zBIYU9iVZ6qSrAXsZN9tQSJt7hcc9+e60S V19bwuqtBnXBCxnAi5T3vGU6+Zb91mRX2ybVg7JfEbvTuxUCau/mULewBMSYU70Pjua+ PmNqVmcBuTgi3GCpA8V41DhozLZsZfEgMZxpnAdQpYvZxGz1JPnUz3fy7sgZrZ5ffQkq VQ7oSNWdO6/27IvKqnLcLxFYoGtW/uBerH27euc8PvvPy9YmCAitY3NNomnQNNBGhFf/ MADAJvy+lGUFlrN+lzXhQpqFR7+utZCpUm2oJS+Ya1YDwQWKwX4IXOoLX7PeqZJpH3pC NTqw== 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=JvhDmhIWT4HhIVtgrW0DkhZs3wn1nLJl9nsweeQEKZc=; b=MBh30K+jJ8GzCMKh9boYiyf3tScBHGv0pPgxbbgtmcm5/aZd3dwvW21wZP8qJTWMId c/sImxoKJ6N255cteAyOvG5wmt6IE6wh0omswKGdtJd5i2rG/7O6/MLR2cV4rh1yULXL dmTijMTZ/wfbjxRV6SGg9lb+hIo3fOqC94NdJeF/gx14hn9af6CFH02z+A8zuv/1UkA7 BwOrTVmCais8R72TgVBpzlU3o2NOGIvzuJGD4+Vwud8PUtmcK9hvdgnOJZli80Guad+2 pjJtcZi2UVHNDrWp98j8eImSbV88Q/QLJ7gRSUwA8DW8ZyB+4Huc0a7Kn0pYNwWLlx52 0ezw== 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 df7si7823360edb.75.2020.10.05.05.15.17; Mon, 05 Oct 2020 05:15:40 -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 S1726680AbgJEMNe (ORCPT + 99 others); Mon, 5 Oct 2020 08:13:34 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46416 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726391AbgJEMMg (ORCPT ); Mon, 5 Oct 2020 08:12:36 -0400 Received: from smtp2-2.goneo.de (smtp2.goneo.de [IPv6:2001:1640:5::8:33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 1DA17C0613AA for ; Mon, 5 Oct 2020 05:12:36 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.goneo.de (Postfix) with ESMTP id 051B0241CC2; Mon, 5 Oct 2020 14:12:35 +0200 (CEST) X-Virus-Scanned: by goneo X-Spam-Flag: NO X-Spam-Score: -2.984 X-Spam-Level: X-Spam-Status: No, score=-2.984 tagged_above=-999 tests=[ALL_TRUSTED=-1, AWL=-0.084, BAYES_00=-1.9] autolearn=ham Received: from smtp2.goneo.de ([127.0.0.1]) by localhost (smtp2.goneo.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Lf5VYH0ATDXN; Mon, 5 Oct 2020 14:12:33 +0200 (CEST) Received: from lem-wkst-02.lemonage.de. (hq.lemonage.de [87.138.178.34]) by smtp2.goneo.de (Postfix) with ESMTPA id A301123FF11; Mon, 5 Oct 2020 14:12:33 +0200 (CEST) From: poeschel@lemonage.de To: Miguel Ojeda Sandonis , linux-kernel@vger.kernel.org (open list) Cc: Lars Poeschel , Willy Tarreau Subject: [PATCH v3 23/32] auxdisplay: Remove unnecessary hd44780 from charlcd Date: Mon, 5 Oct 2020 14:11:51 +0200 Message-Id: <20201005121200.3427363-24-poeschel@lemonage.de> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201005121200.3427363-1-poeschel@lemonage.de> References: <20201005121200.3427363-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. Reviewed-by: Willy Tarreau 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