Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp3282031pxk; Mon, 5 Oct 2020 06:05:43 -0700 (PDT) X-Google-Smtp-Source: ABdhPJy3Dq73s49rOojB19sRNIu9wJTOaDMgp1dlrwMQsuWsqBHFpyYG4E+b3bwhgvYiSpE6g2eA X-Received: by 2002:a19:fc1c:: with SMTP id a28mr1188832lfi.517.1601903143698; Mon, 05 Oct 2020 06:05:43 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1601903143; cv=none; d=google.com; s=arc-20160816; b=xiwtlEDI6m4xhaXha5xMmDGEncuOtEjY9xKbLYRq441swxwqaNzGqTMSqZ5cAfyRg3 8Q0MyQdqt77hizHs2qdKj0eOJCyscksdABH4P8nYy+ume+UIA1pd/dPWN2CVDrq7oUKQ MQpUA0i0/SIIiGGcNuNqpdTuZG0VEVu7QydAKETcSeAt/PJ1x3SHFjcfqFXxEhusFVxQ NYa4VMxGig81u6FdtHusFzqWidF0sPOzmknAap5BrkQZxQ4xWRNW5WMyoadKPafnQBPt +tDpUTHJhoxaY0I/7EVWSXl/fe/4slytCRV2gcryEAqNJvVKx7X7I38zDX502Zo0JKU2 MJPQ== 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 :message-id:date:subject:cc:to:from; bh=WIpei+B+VHOg39SkSPrnwtHwn/6hCUq/JOAs6UCcngk=; b=GCe8HbThQmIhnfaI29OoaldHCY92wEpVU/kcggJq5yZbDwd4E/sqIyIn45QV6MTJjS qfvBgGxcHbGwRqquAEYL5bZNjUNR8z9cHBwqksYRqOefqt9uL+Mhfhmub286kagEkCJX nKIMJCzLkpMEH4lSbAKqk9305ZkRZdCcUsCHulGlFHHMSe3Zku1EueZsHMkHy/veFI0A Ho6oQatr16pr7WF6HYxfzH5muQU3GCXE61ViPJj+96gt0fAR8xkVq+D8Rnr/6D7qkBfR aNBDdd1KLaij/AUil8WLoNQxNdeUBR67bhSJq/ebIDEl/PqofqRr+AoGT47i4w9rJ1zx +diw== 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 ci27si6219415ejc.22.2020.10.05.06.05.19; Mon, 05 Oct 2020 06:05:43 -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 S1726259AbgJENBi (ORCPT + 99 others); Mon, 5 Oct 2020 09:01:38 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54016 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725891AbgJENBh (ORCPT ); Mon, 5 Oct 2020 09:01:37 -0400 Received: from smtp3.goneo.de (smtp3.goneo.de [IPv6:2001:1640:5::8:37]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id F1F6DC0613B8 for ; Mon, 5 Oct 2020 06:01:36 -0700 (PDT) Received: from localhost (localhost [127.0.0.1]) by smtp3.goneo.de (Postfix) with ESMTP id B85BD24001D; Mon, 5 Oct 2020 15:01:34 +0200 (CEST) X-Virus-Scanned: by goneo X-Spam-Flag: NO X-Spam-Score: -2.957 X-Spam-Level: X-Spam-Status: No, score=-2.957 tagged_above=-999 tests=[ALL_TRUSTED=-1, AWL=-0.057, BAYES_00=-1.9] autolearn=ham Received: from smtp3.goneo.de ([127.0.0.1]) by localhost (smtp3.goneo.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id r2hQaYapMTiT; Mon, 5 Oct 2020 15:01:33 +0200 (CEST) Received: from lem-wkst-02.lemonage.de. (hq.lemonage.de [87.138.178.34]) by smtp3.goneo.de (Postfix) with ESMTPA id D76E123EEDD; Mon, 5 Oct 2020 15:01:32 +0200 (CEST) From: poeschel@lemonage.de To: Miguel Ojeda Sandonis , linux-kernel@vger.kernel.org (open list) Cc: Lars Poeschel , Willy Tarreau Subject: [PATCH v4 13/32] auxdisplay: Make use of enum for backlight on / off Date: Mon, 5 Oct 2020 15:01:09 +0200 Message-Id: <20201005130128.3430804-1-poeschel@lemonage.de> X-Mailer: git-send-email 2.28.0 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