Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp220399pxj; Wed, 16 Jun 2021 00:28:16 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyrMAJ4MvoGEML4x+yWoVghiTU8UdlNfO+LD1XjOx2GmOkCBovYPbcb6tcEIReu5u7nv256 X-Received: by 2002:a05:6e02:20c8:: with SMTP id 8mr2568452ilq.67.1623828496385; Wed, 16 Jun 2021 00:28:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1623828496; cv=none; d=google.com; s=arc-20160816; b=po/jihRAlbI/SSVCGHaUZdIo9LGaJ5i8QsXsDBww9nmrX+nvU0qVoI89eaH4nexGrp xIAv0q6U/3Z0Q6Yp9vbVdkDsSHGSJ58LDV+Wpiwa68YWKS1zeqJ9dSENTl9p6JiyvKUS +7H5IOzbiwhPb2JK0beIJXJ/QIYdTra8U66pqG0K8m535VUcPaAGQ1wa5agCz1vd8NGL yQRfi5aLe8L5HsfN8UOOIX9lrngXbNV93HdyGJZqKDIaZTIAdC2SiXNxqtO9arpq4HcU CwNcN+ITaFa9Bq1VAC5Tt42rvKwQ0DcfIlPlK80j/dLpgbqsIJSXV0O+jFX+IyTPfKCo Jqrw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:references:in-reply-to:message-id :date:subject:cc:to:from; bh=FAC8hv5wbFFZKZqd1JiftoIWYu7yIzk/ZBgrCW+l5dY=; b=FbaFJgRkGX9iorEXyIJNcPAvHXpVySkPhJDO2FN4hjeUOh4s6gzNQPtYqZhaNJk0dU LrbsjYRfRR+8TqIsurynnDCVo/mXFX5V5YgIWsh+97TtoYjsX9blZTo9/TwmiKJr8Znm gy7BBDJy2R3h1E6LmjcfeGw0PY4CYGzAAQ/OdTMceNb2n99vrwycP533c2nwBFYc0bKq Rwt/d1BNc9nDjhJjfmL3THN8xfJn8D0s9wCJ/7x0tDz/4fdmxi1QMH1bUeUc0hfleRly /PvAfHTFM4PgieEhPys69mMkJO7gWhetNLh/Dxn70HBePTQIueFywGRtfGS9I38Efuop GVOQ== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f15si1724873ila.89.2021.06.16.00.28.04; Wed, 16 Jun 2021 00:28:16 -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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232047AbhFPH3Q (ORCPT + 99 others); Wed, 16 Jun 2021 03:29:16 -0400 Received: from szxga03-in.huawei.com ([45.249.212.189]:7329 "EHLO szxga03-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231468AbhFPH3B (ORCPT ); Wed, 16 Jun 2021 03:29:01 -0400 Received: from dggemv711-chm.china.huawei.com (unknown [172.30.72.54]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4G4c8v3B0xz6yD1; Wed, 16 Jun 2021 15:22:55 +0800 (CST) Received: from dggemi759-chm.china.huawei.com (10.1.198.145) by dggemv711-chm.china.huawei.com (10.1.198.66) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256) id 15.1.2176.2; Wed, 16 Jun 2021 15:26:54 +0800 Received: from localhost.localdomain (10.67.165.24) by dggemi759-chm.china.huawei.com (10.1.198.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.2176.2; Wed, 16 Jun 2021 15:26:54 +0800 From: Guangbin Huang To: , , , , CC: , , , Subject: [PATCH net-next 09/15] net: cosa: add necessary () to macro argument Date: Wed, 16 Jun 2021 15:23:35 +0800 Message-ID: <1623828221-48349-10-git-send-email-huangguangbin2@huawei.com> X-Mailer: git-send-email 2.8.1 In-Reply-To: <1623828221-48349-1-git-send-email-huangguangbin2@huawei.com> References: <1623828221-48349-1-git-send-email-huangguangbin2@huawei.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [10.67.165.24] X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To dggemi759-chm.china.huawei.com (10.1.198.145) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Peng Li Macro argument 'cosa' may be better as '(cosa)' to avoid precedence issues. Signed-off-by: Peng Li Signed-off-by: Guangbin Huang --- drivers/net/wan/cosa.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/net/wan/cosa.c b/drivers/net/wan/cosa.c index 6125ca4..a6629dc 100644 --- a/drivers/net/wan/cosa.c +++ b/drivers/net/wan/cosa.c @@ -238,14 +238,14 @@ MODULE_LICENSE("GPL"); #define cosa_inw inw #endif -#define is_8bit(cosa) (!(cosa->datareg & 0x08)) - -#define cosa_getstatus(cosa) (cosa_inb(cosa->statusreg)) -#define cosa_putstatus(cosa, stat) (cosa_outb(stat, cosa->statusreg)) -#define cosa_getdata16(cosa) (cosa_inw(cosa->datareg)) -#define cosa_getdata8(cosa) (cosa_inb(cosa->datareg)) -#define cosa_putdata16(cosa, dt) (cosa_outw(dt, cosa->datareg)) -#define cosa_putdata8(cosa, dt) (cosa_outb(dt, cosa->datareg)) +#define is_8bit(cosa) (!((cosa)->datareg & 0x08)) + +#define cosa_getstatus(cosa) (cosa_inb((cosa)->statusreg)) +#define cosa_putstatus(cosa, stat) (cosa_outb(stat, (cosa)->statusreg)) +#define cosa_getdata16(cosa) (cosa_inw((cosa)->datareg)) +#define cosa_getdata8(cosa) (cosa_inb((cosa)->datareg)) +#define cosa_putdata16(cosa, dt) (cosa_outw(dt, (cosa)->datareg)) +#define cosa_putdata8(cosa, dt) (cosa_outb(dt, (cosa)->datareg)) /* Initialization stuff */ static int cosa_probe(int ioaddr, int irq, int dma); -- 2.8.1