From patchwork Thu May 4 20:05:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mathieu Desnoyers X-Patchwork-Id: 90241 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:b0ea:0:b0:3b6:4342:cba0 with SMTP id b10csp609149vqo; Thu, 4 May 2023 14:09:10 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ5t1U4Z4nDttmSiD5HSm770gG7myWIX4Jrxv8OAtZWu7+0bqI6IJcaxyl9PbWr4FKhM3LI1 X-Received: by 2002:a17:902:7d85:b0:1a8:bc5:4912 with SMTP id a5-20020a1709027d8500b001a80bc54912mr4593098plm.52.1683234550314; Thu, 04 May 2023 14:09:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1683234550; cv=none; d=google.com; s=arc-20160816; b=YHag5JENFXWtcjfsHzQGzh7eql1k+yBkCk1IDCTuoeuC8mpXG7JjtjVcrnESMV9PZf 1whq3eGAgLzx9PKDNtPX6qaIFF654HpWs80TAvkApuB2NPXsM56+/hUOsf8T1BenbhjX xq6RUgyIq2f11peERmSc+p9TIb54AmpITfcd1grQbJzIPSiWOxw2SLBEaw0+sYe5aCNJ hBE31CQdMvmvClpz7JGPtdxvmFmVH07AsEiMW+ED+BMMWduTsPG7QUXw/T6MVrjEgfHG Nejosl9Z61Axdjs1BRP0wEvte7SQyHqF12MYxEGUewus4/K7EJ6ZtfDnRqQnuzC0Fh4U zhZg== 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 :dkim-signature; bh=8E9tCuc8caFbaCRIHqxlR5dNn5NMNoGkMgzVPGqCktk=; b=1D1Mx+0QImL2JnLJsl7OrUIGQtsFAe+AqdPXK2a9OHM5e3QP6JlUdwz5bNCwegkeMO Ac0V3TjalhezizSz5XwacvB0csKmyX8DxfMqq0s2P2u+sUTplFxlK5MBqymbCVQHSkm0 d3TnxNsGJNuWw0xVdjw4dWOWxDpsreg7Wa1LZml+Y+T0eo0uW3J1cz3vjFCCfCjpnFnz QgLX/ic4ydBW+QKtvHgDbfR1C+7SrFIO1zvDz4QiC6W4AEwOSAaLo+WeJxttbVPVjab0 P36NsvM/Tb1rbqVzfChKnuL2nojMwau+hbW8o5z0kNSrNqJhTyxDqpQGm9C38MLl90p5 LI8A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@efficios.com header.s=smtpout1 header.b="O8/ofAq1"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=efficios.com Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id rm12-20020a17090b3ecc00b0024681cc291csi5136822pjb.88.2023.05.04.14.08.55; Thu, 04 May 2023 14:09:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@efficios.com header.s=smtpout1 header.b="O8/ofAq1"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=efficios.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230376AbjEDVCL (ORCPT + 99 others); Thu, 4 May 2023 17:02:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58268 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230370AbjEDVBj (ORCPT ); Thu, 4 May 2023 17:01:39 -0400 Received: from smtpout.efficios.com (unknown [IPv6:2607:5300:203:b2ee::31e5]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0AA6A14E61 for ; Thu, 4 May 2023 14:01:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=efficios.com; s=smtpout1; t=1683230734; bh=4SJMp1te2JkZx1CFuIwS27tlAnRiNSVpgrNwcTggKBQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=O8/ofAq1zgKtNVBwizAqBo6VPHz1KvIuRHyyIfW/cPGoa7HBxwdD9IsDlm6MCfCtU 1Xq0ctKQjJZsSymzJWterSninx0fyNR8uNTt9RPL7HoqCGPi5ltJh72eT959mbzWgI enh/p1OD/wGmFU6zjf73ft0NWHva2NXDvyOaeyvmKW2J6w4fgUDmRMByTkDG/Yu87m HaISwZxSXkZzBXIqxuRTqQqcNofwWRm66ELNBvhTuDtu7UBZm2kD53A49JLxV+JThy cMYcG2P2Kx2EaxdL5zwM9Cz/N67dTecAMHrvHfzTAdLhGGJ7PidlDOgDOh5QOSn43U +E94H2JQg/gBw== Received: from localhost.localdomain (192-222-143-198.qc.cable.ebox.net [192.222.143.198]) by smtpout.efficios.com (Postfix) with ESMTPSA id 4QC4Yp1R7Yz11jH; Thu, 4 May 2023 16:05:34 -0400 (EDT) From: Mathieu Desnoyers To: Andrew Morton Cc: linux-kernel@vger.kernel.org, Mathieu Desnoyers , Jiang Liu Subject: [RFC PATCH 10/13] resource_ext.h: Remove useless parentheses around macro parameters Date: Thu, 4 May 2023 16:05:24 -0400 Message-Id: <20230504200527.1935944-11-mathieu.desnoyers@efficios.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230504200527.1935944-1-mathieu.desnoyers@efficios.com> References: <20230504200527.1935944-1-mathieu.desnoyers@efficios.com> MIME-Version: 1.0 X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RDNS_NONE,SPF_HELO_NONE, SPF_PASS,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1764999352027187105?= X-GMAIL-MSGID: =?utf-8?q?1764999352027187105?= Parentheses around macro parameters which are surrounded by commas is a scenario where those added parentheses are useless, because the comma is the operator with the lowest precedence. Remove those useless parentheses to make list iteration code consistent across kernel headers. Signed-off-by: Mathieu Desnoyers Cc: Andrew Morton Cc: Jiang Liu --- include/linux/resource_ext.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/linux/resource_ext.h b/include/linux/resource_ext.h index ff0339df56af..f4a3c0040886 100644 --- a/include/linux/resource_ext.h +++ b/include/linux/resource_ext.h @@ -60,11 +60,11 @@ resource_list_destroy_entry(struct resource_entry *entry) resource_list_free_entry(entry); } -#define resource_list_for_each_entry(entry, list) \ - list_for_each_entry((entry), (list), node) +#define resource_list_for_each_entry(entry, list) \ + list_for_each_entry(entry, list, node) #define resource_list_for_each_entry_safe(entry, tmp, list) \ - list_for_each_entry_safe((entry), (tmp), (list), node) + list_for_each_entry_safe(entry, tmp, list, node) static inline struct resource_entry * resource_list_first_type(struct list_head *list, unsigned long type)