Received: by 2002:a05:6a10:9e8c:0:0:0:0 with SMTP id y12csp234066pxx; Wed, 28 Oct 2020 03:37:56 -0700 (PDT) X-Google-Smtp-Source: ABdhPJxOyU6Tm8/ygahHaRuqEWrlqMxCbql4J5j7PsEx3Y+fbv/2e7vH4xwmF1WJItzJfx/01yYy X-Received: by 2002:a05:6402:651:: with SMTP id u17mr6801979edx.206.1603881476660; Wed, 28 Oct 2020 03:37:56 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603881476; cv=none; d=google.com; s=arc-20160816; b=Uu7bAAb1avi8yuiFZa5x3FlP0FQWxz/duwGP/srR7XOn/wcIL0fgI3nqiUCNdupkde mif1gHILi+lMHeuGNpH+x96QolpQqBspRB+13V9XtaAKLJJAEzTVzwsG9s0THQfO3nZc poTdYeezspo2sUFlvIekAb++BS5MsYjWm09oz4YZ/t5vfUa5Oeqa2zrlAT8DmuXcO9ew vn8kAniXk+HO24QAJueG/t+pxZ2bpAesdI1222uMUkoVm6S4SY9tpzDqyBzyZpMK8qVe +8sj9ovp0sYvUIwgquVACu7GsPxQN/h0suqdNCtvAuHUp1euE6GhlrGsfXsvfPT7991V qUrw== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=UAJTit6wHd9m1o7aV28KQLbjqd/bSKkPW8ASNTsFRHY=; b=pcYso8PDf9qnhBwDREti0EAB76zhzBHEtOeo1DBsiT11APJX6+/IOlvpRygZ1u9LVI XWr0q9vV6FSda/LtV4Lu4DlHb+9scYiCySt+PmlkPL6BKMv9HG5QfKuElgPSoLeT5mCo lqp1QIO40KA/L9kWn5K0xLRAq4pL1MFpxOimlgq2dtKtQ6EL7/ob5PirG/9/FqO+0pty anDJ4CgjgE6kR5ocdTefB6KPiuiwL1z8FHpUzKXWC5Xq4OgmVQ/J7E2tazIVlpTXioWG Np6daZsHHUggdBcpdXeuqwIhbcX0xYNniapZvXWt269umP2CIATnhPss4RacAzNJCS3Q 1XCg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=uRN8JRLt; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id d4si2698178edr.173.2020.10.28.03.37.34; Wed, 28 Oct 2020 03:37:56 -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; dkim=pass header.i=@kernel.org header.s=default header.b=uRN8JRLt; 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1762769AbgJ0Oo0 (ORCPT + 99 others); Tue, 27 Oct 2020 10:44:26 -0400 Received: from mail.kernel.org ([198.145.29.99]:42712 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1761124AbgJ0Om4 (ORCPT ); Tue, 27 Oct 2020 10:42:56 -0400 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9033420773; Tue, 27 Oct 2020 14:42:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1603809776; bh=Aj3H/mllP3Z1Ndwy+73zR5D3CeWuFmetb4clh9ff4xM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uRN8JRLtx5K9p5mdNJYDS2lsijJFr4NsDjefwlGDgw90HpGa47uw2KudUPY+s9lUH 4qJ1/dBEhNB0bAc/+cKa/NwP3JNYMXaasfvw6BgkOq303vBk6OkYCnTT04HkOcAt4t kRc0JNryjPXCU90uxDSX95iUXZaOIUWHan59tPKY= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, YueHaibing , Dmitry Torokhov , Sasha Levin Subject: [PATCH 5.4 285/408] Input: stmfts - fix a & vs && typo Date: Tue, 27 Oct 2020 14:53:43 +0100 Message-Id: <20201027135508.267699830@linuxfoundation.org> X-Mailer: git-send-email 2.29.1 In-Reply-To: <20201027135455.027547757@linuxfoundation.org> References: <20201027135455.027547757@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: YueHaibing [ Upstream commit d04afe14b23651e7a8bc89727a759e982a8458e4 ] In stmfts_sysfs_hover_enable_write(), we should check value and sdata->hover_enabled is all true. Fixes: 78bcac7b2ae1 ("Input: add support for the STMicroelectronics FingerTip touchscreen") Signed-off-by: YueHaibing Link: https://lore.kernel.org/r/20200916141941.16684-1-yuehaibing@huawei.com Signed-off-by: Dmitry Torokhov Signed-off-by: Sasha Levin --- drivers/input/touchscreen/stmfts.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/input/touchscreen/stmfts.c b/drivers/input/touchscreen/stmfts.c index b6f95f20f9244..cd8805d71d977 100644 --- a/drivers/input/touchscreen/stmfts.c +++ b/drivers/input/touchscreen/stmfts.c @@ -479,7 +479,7 @@ static ssize_t stmfts_sysfs_hover_enable_write(struct device *dev, mutex_lock(&sdata->mutex); - if (value & sdata->hover_enabled) + if (value && sdata->hover_enabled) goto out; if (sdata->running) -- 2.25.1