Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp299723ybb; Wed, 15 Apr 2020 01:31:18 -0700 (PDT) X-Google-Smtp-Source: APiQypJWfmXnFBOzdwoPjUbVrhmxD9tQQCJkxIh2keaKcW1RfIj50h9WO+Ow6DvGMrRwWOXr/NIQ X-Received: by 2002:aa7:d887:: with SMTP id u7mr1138110edq.174.1586939478133; Wed, 15 Apr 2020 01:31:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1586939478; cv=none; d=google.com; s=arc-20160816; b=zS9ElTTLIyo4Gu3vuN1Jj4KM8fBDmNKxe0LmAWXggz0XBUw/tPZdEl27/pqjLvVORK qcgbO2ZasjB1bb+oxlUAH1Yc9Ovp9ppWkS3EJkm+EN4SAXY3J/RefcqwKWmNDhdQyrz6 pp0kuOUJWYVsDoaGS0azwIvXgaZNZpW13BZNTISLiIp/+Rmgftd+LqKZ0bzGl3iHzfZq e+ysNq0giXbjc0lLXpQk+4tnsKMGlHLa38rlBxPFXN7tr0sSyhZNOG7VHwJ/oT2TgG+F B1QRg+r9uoa9Qgg/WXuvaaKWfqY52AmbaLJCCGzuDaF3PXhG6h20Y1zJeBCMawzwgT7x 5IUA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:message-id:date:subject:cc :to:from; bh=r8FB4XMMeybyR1iFXbOlOODFf3VD80u3otfNPjpyruA=; b=SO5rKe34HGyD2PRLQDYLEd0oANO8j3JMHAW6VLsMEBXG9sSqLxMJO5uIMqbiJVMuS4 0bcksXCOAHVyg8uAEe4ECo4yWGTiZvPd4j8+WnFX4pvCOIdlT2/iEfaTZ8ZVX5UTw/b0 Ma3eMkJvqBcBQ0FLxr+IyMPgdz26azq4tE22qxkOmzlAE2wBF7NyeHu2IFZvrhUyS7HH uAjWVx2tYxED8y6HpfA6kj5eu8vWvVxE/AX0K8YDhyzJ9eLiad41GmCzhSKevcrxbxFY oxZp6BRaOv8yHaPB/oDf3PQ4OQ+04jGMDtCty0+1UAnxFDttd1ZATs27U7216Dad/jwH 0RkA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for 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 d26si1071606ejc.216.2020.04.15.01.30.30; Wed, 15 Apr 2020 01:31:18 -0700 (PDT) Received-SPF: pass (google.com: best guess record for 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: best guess record for 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 S2404826AbgDNDfz (ORCPT + 99 others); Mon, 13 Apr 2020 23:35:55 -0400 Received: from szxga07-in.huawei.com ([45.249.212.35]:55506 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2404802AbgDNDfy (ORCPT ); Mon, 13 Apr 2020 23:35:54 -0400 Received: from DGGEMS406-HUB.china.huawei.com (unknown [172.30.72.58]) by Forcepoint Email with ESMTP id 9944925E1A5E1D16CDB4; Tue, 14 Apr 2020 11:35:50 +0800 (CST) Received: from linux-lmwb.huawei.com (10.175.103.112) by DGGEMS406-HUB.china.huawei.com (10.3.19.206) with Microsoft SMTP Server id 14.3.487.0; Tue, 14 Apr 2020 11:35:39 +0800 From: Zou Wei To: , , CC: Zou Wei Subject: [PATCH -next] mm/usercopy: fix warning Comparison to bool Date: Tue, 14 Apr 2020 11:42:04 +0800 Message-ID: <1586835724-45738-1-git-send-email-zou_wei@huawei.com> X-Mailer: git-send-email 2.6.2 MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.175.103.112] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org fix below warnings reported by coccicheck mm/usercopy.c:304:5-18: WARNING: Comparison to bool Reported-by: Hulk Robot Signed-off-by: Zou Wei --- mm/usercopy.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/usercopy.c b/mm/usercopy.c index 660717a..04346cf 100644 --- a/mm/usercopy.c +++ b/mm/usercopy.c @@ -301,7 +301,7 @@ __setup("hardened_usercopy=", parse_hardened_usercopy); static int __init set_hardened_usercopy(void) { - if (enable_checks == false) + if (!enable_checks) static_branch_enable(&bypass_usercopy_checks); return 1; } -- 2.6.2