Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3249990pxk; Mon, 5 Oct 2020 05:16:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxvLbw8GMPxM/+rfV7kJwwzdYgjaKzzirwnNr0cq3pddZih2yjRsE/NGPovc9q4ewUb8e2n X-Received: by 2002:a17:907:2076:: with SMTP id qp22mr15151274ejb.358.1601900190909; Mon, 05 Oct 2020 05:16:30 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601900190; cv=none; d=google.com; s=arc-20160816; b=Wk2SXOOZWmPbx+NvTZX/dJM5em1g+X1e/B3xPS7xA8ewNcjBsKCafEIgkuTZEiJPQ2 6UqP2KmcUbVhEX6clemrxeVolUxx/1TAQRXQK4XysJIpR3179FsrRxfDCMAnj7dNSvJ9 ug8KSUqIgz0LPtYtrVZStnNVDrdFmPsmb1BwbLwXj3bFNTc6gv+NSGxe0x1CMXPkZF1b +qqxLhpyoCxH0vwoTParRdm/7wMkt73z/2ZdLMLfd/AlNI+o2120pIexjK2VQsGTwzIs bYQxpvlOQhop9ohAlphzE0ZP2xfaD/P2N19EBxDU6xjnesuMwhcT7Ejh3JgVXeIryk5b 0qsQ== 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=WIpei+B+VHOg39SkSPrnwtHwn/6hCUq/JOAs6UCcngk=; b=MaA45yBo8WZHTOfsmxVQkS9NBt5wvv2YlM2mY6aBcwumMB4f8HM3gxI4VP8prPSjzh b0QwSIy5/UWGVuk217ELmcMfzhVvCOGsli0xsQPvH/65k/8rQjTM1CuOWCRzA8iccNDZ r1GxvTflr1e7U6TRuaMSAcOJL+r+Zz4aus4hJuGMfjkzA0VkbAnvgw3XvEkBexLkiYVB d0dhDhYkNLQPoa1pW4jxUBuczajyTGYL2yVwPqcWqbIKVrQo1hCMEMW6f1hHuaOZy6hO XDWybFUIG4SxXdV8A47pTXu0EFaLJu1UnxWMrJo0w7sCnUcHBCxwfTSvT1cO1mZ5JMWn hpwQ== 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 u22si1939435ejg.300.2020.10.05.05.16.07; Mon, 05 Oct 2020 05:16:30 -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 S1726776AbgJEMOQ (ORCPT + 99 others); Mon, 5 Oct 2020 08:14:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46382 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726197AbgJEMMb (ORCPT ); Mon, 5 Oct 2020 08:12:31 -0400 Received: from smtp2-2.goneo.de (smtp2.goneo.de [IPv6:2001:1640:5::8:33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 29B61C0613B0 for ; Mon, 5 Oct 2020 05:12:28 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by smtp2.goneo.de (Postfix) with ESMTP id 11B5723FD2C; Mon, 5 Oct 2020 14:12:27 +0200 (CEST) X-Virus-Scanned: by goneo X-Spam-Flag: NO X-Spam-Score: -2.989 X-Spam-Level: X-Spam-Status: No, score=-2.989 tagged_above=-999 tests=[ALL_TRUSTED=-1, AWL=-0.089, 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 lButTQ8Cprdw; Mon, 5 Oct 2020 14:12:26 +0200 (CEST) Received: from lem-wkst-02.lemonage.de. (hq.lemonage.de [87.138.178.34]) by smtp2.goneo.de (Postfix) with ESMTPA id 0795123F789; Mon, 5 Oct 2020 14:12:25 +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 13/32] auxdisplay: Make use of enum for backlight on / off Date: Mon, 5 Oct 2020 14:11:41 +0200 Message-Id: <20201005121200.3427363-14-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 To turn the backlight on or off use our new enum CHARLCD_ON / CHARLCD_OFF. Reviewed-by: Willy Tarreau Signed-off-by: Lars Poeschel --- drivers/auxdisplay/charlcd.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/auxdisplay/charlcd.c b/drivers/auxdisplay/charlcd.c index 154419513186..9631f70e8128 100644 --- a/drivers/auxdisplay/charlcd.c +++ b/drivers/auxdisplay/charlcd.c @@ -115,7 +115,7 @@ static void charlcd_bl_off(struct work_struct *work) if (priv->bl_tempo) { priv->bl_tempo = false; if (!(priv->flags & LCD_FLAG_L)) - priv->lcd.ops->backlight(&priv->lcd, 0); + priv->lcd.ops->backlight(&priv->lcd, CHARLCD_OFF); } mutex_unlock(&priv->bl_tempo_lock); } @@ -132,7 +132,7 @@ void charlcd_poke(struct charlcd *lcd) mutex_lock(&priv->bl_tempo_lock); if (!priv->bl_tempo && !(priv->flags & LCD_FLAG_L)) - lcd->ops->backlight(lcd, 1); + lcd->ops->backlight(lcd, CHARLCD_ON); priv->bl_tempo = true; schedule_delayed_work(&priv->bl_work, LCD_BL_TEMPO_PERIOD * HZ); mutex_unlock(&priv->bl_tempo_lock); @@ -829,7 +829,7 @@ int charlcd_unregister(struct charlcd *lcd) the_charlcd = NULL; if (lcd->ops->backlight) { cancel_delayed_work_sync(&priv->bl_work); - priv->lcd.ops->backlight(&priv->lcd, 0); + priv->lcd.ops->backlight(&priv->lcd, CHARLCD_OFF); } return 0; -- 2.28.0