From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9CAEA423F2; Mon, 16 Jan 2023 18:27:51 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 346AF42D1F; Mon, 16 Jan 2023 18:27:39 +0100 (CET) Received: from mail-pj1-f54.google.com (mail-pj1-f54.google.com [209.85.216.54]) by mails.dpdk.org (Postfix) with ESMTP id 2FFEA42D0C for ; Mon, 16 Jan 2023 18:27:37 +0100 (CET) Received: by mail-pj1-f54.google.com with SMTP id q23-20020a17090a065700b002290913a521so12284981pje.5 for ; Mon, 16 Jan 2023 09:27:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20210112.gappssmtp.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=rObn7rAGyLZR1ii6QmC/YOIFEDII5qUdgo8bI36UZNo=; b=idpXNgSG5B1gcN//bwr+4RsSH1+3T2I8tU3Clx87+HZcMuGwxdFgS6TLv3PULY+BC6 UR5pRJnfqGGmNj9y9s+Tow+LsmmuTm4sVhfYcGce5PI1oasIB03YXLiX8G8g5psr3rvq P/JuENBP2P+0NyWVxamKWvRYUpidUB258oyXoDSpRPeRxlqefphyepsQZfI8leM2DBgE FTkcJofMI9CfsBUW1Izqmt4G6MGBXBFDb2A/MCvvPXH2/h5gC9pV7WTvhZLLi31xMV4G v0jBQ4yhiEy6l46OWKjd6mGonohEXC1WTzXkfmFqn0R4tO0kvPP+1XJRLvVZgYPwqHAV ovsQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=rObn7rAGyLZR1ii6QmC/YOIFEDII5qUdgo8bI36UZNo=; b=PpuHSC0ve5E/GQESoHtDny6SOz9bXp7usB9FaFVYNbUeDloqvKqUMCv4dPrpVwXDxH i6+3XEcGfhIouwl0OBLFs69BqOSiFPYHfrG3Ob6QRVa0FSoXAaKQicdEXVS6Gv7UGnVH ItdsPcni03xyR5zJcdMOPP7tn+s5sNGpeSKxu4roOYeMUlvERqttRA+JU2QRAorYnN3G aKIWK1NEBUPC3yCb9Ik3p6wW3bGYi/4qw43n8mPFguugmu8trO67t84ZEc7VwLPfYc5M Ubl0M29VcgUwodbHrYJ+UufZIL3oVy+7viXR1elxKtUdqGHRLsltE+dbAoVdDC1BVne2 0/8A== X-Gm-Message-State: AFqh2kpy1kXJnv5OEwBJeXXjhRBi9qpQ668K/rkn2uDUvhVZjnFon8Rq UQOJKs9vs6zftpQq0rKxXDI2CbEB/8nEQqBmOms= X-Google-Smtp-Source: AMrXdXtkgFerMKFaAM6EqWyoU2DXOrj/YjobuW17pwN1tiQzObSxv8GsBgOkgLP0nfkZvTmpIEad9w== X-Received: by 2002:a17:902:848d:b0:192:fe4b:da3a with SMTP id c13-20020a170902848d00b00192fe4bda3amr559649plo.10.1673890056155; Mon, 16 Jan 2023 09:27:36 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id j3-20020a170902c3c300b001945b984341sm3992635plj.100.2023.01.16.09.27.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Jan 2023 09:27:35 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Simei Su , Wenjun Wu Subject: [PATCH 3/7] net/e1000: fix whitespace Date: Mon, 16 Jan 2023 09:27:27 -0800 Message-Id: <20230116172732.84976-4-stephen@networkplumber.org> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230116172732.84976-1-stephen@networkplumber.org> References: <20230116172732.84976-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org The style standard is to use blank after keywords. I.e "if (" not "if(" Signed-off-by: Stephen Hemminger --- drivers/net/e1000/em_ethdev.c | 2 +- drivers/net/e1000/igb_ethdev.c | 8 ++++---- drivers/net/e1000/igb_pf.c | 2 +- drivers/net/e1000/igb_rxtx.c | 6 +++--- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/drivers/net/e1000/em_ethdev.c b/drivers/net/e1000/em_ethdev.c index 8ee9be12ad19..3cb09538b2df 100644 --- a/drivers/net/e1000/em_ethdev.c +++ b/drivers/net/e1000/em_ethdev.c @@ -872,7 +872,7 @@ eth_em_stats_get(struct rte_eth_dev *dev, struct rte_eth_stats *rte_stats) E1000_DEV_PRIVATE_TO_STATS(dev->data->dev_private); int pause_frames; - if(hw->phy.media_type == e1000_media_type_copper || + if (hw->phy.media_type == e1000_media_type_copper || (E1000_READ_REG(hw, E1000_STATUS) & E1000_STATUS_LU)) { stats->symerrs += E1000_READ_REG(hw,E1000_SYMERRS); stats->sec += E1000_READ_REG(hw, E1000_SEC); diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c index 8858f975f8cc..5c35b8349063 100644 --- a/drivers/net/e1000/igb_ethdev.c +++ b/drivers/net/e1000/igb_ethdev.c @@ -1683,7 +1683,7 @@ igb_read_stats_registers(struct e1000_hw *hw, struct e1000_hw_stats *stats) uint64_t old_rpthc = stats->rpthc; uint64_t old_hgptc = stats->hgptc; - if(hw->phy.media_type == e1000_media_type_copper || + if (hw->phy.media_type == e1000_media_type_copper || (E1000_READ_REG(hw, E1000_STATUS) & E1000_STATUS_LU)) { stats->symerrs += E1000_READ_REG(hw,E1000_SYMERRS); @@ -3500,10 +3500,10 @@ static void igbvf_set_vfta_all(struct rte_eth_dev *dev, bool on) for (i = 0; i < IGB_VFTA_SIZE; i++){ vfta = shadow_vfta->vfta[i]; - if(vfta){ + if (vfta){ mask = 1; for (j = 0; j < 32; j++){ - if(vfta & mask) + if (vfta & mask) igbvf_set_vfta(hw, (uint16_t)((i<<5)+j), on); mask<<=1; @@ -3528,7 +3528,7 @@ igbvf_vlan_filter_set(struct rte_eth_dev *dev, uint16_t vlan_id, int on) /*vind is not used in VF driver, set to 0, check ixgbe_set_vfta_vf*/ ret = igbvf_set_vfta(hw, vlan_id, !!on); - if(ret){ + if (ret){ PMD_INIT_LOG(ERR, "Unable to set VF vlan"); return ret; } diff --git a/drivers/net/e1000/igb_pf.c b/drivers/net/e1000/igb_pf.c index c7588ea57eaa..b1f74eb841d2 100644 --- a/drivers/net/e1000/igb_pf.c +++ b/drivers/net/e1000/igb_pf.c @@ -78,7 +78,7 @@ void igb_pf_host_init(struct rte_eth_dev *eth_dev) if (hw->mac.type == e1000_i350) nb_queue = 1; - else if(hw->mac.type == e1000_82576) + else if (hw->mac.type == e1000_82576) /* per datasheet, it should be 2, but 1 seems correct */ nb_queue = 1; else diff --git a/drivers/net/e1000/igb_rxtx.c b/drivers/net/e1000/igb_rxtx.c index f32dee46df82..2d4a1292053e 100644 --- a/drivers/net/e1000/igb_rxtx.c +++ b/drivers/net/e1000/igb_rxtx.c @@ -196,13 +196,13 @@ struct igb_tx_queue { #ifdef RTE_PMD_USE_PREFETCH #define rte_igb_prefetch(p) rte_prefetch0(p) #else -#define rte_igb_prefetch(p) do {} while(0) +#define rte_igb_prefetch(p) do {} while (0) #endif #ifdef RTE_PMD_PACKET_PREFETCH #define rte_packet_prefetch(p) rte_prefetch1(p) #else -#define rte_packet_prefetch(p) do {} while(0) +#define rte_packet_prefetch(p) do {} while (0) #endif /* @@ -2276,7 +2276,7 @@ igb_dev_mq_rx_configure(struct rte_eth_dev *dev) /* 011b Def_Q ignore, according to VT_CTL.DEF_PL */ mrqc |= 0x3 << E1000_MRQC_DEF_Q_SHIFT; E1000_WRITE_REG(hw, E1000_MRQC, mrqc); - } else if(RTE_ETH_DEV_SRIOV(dev).active == 0) { + } else if (RTE_ETH_DEV_SRIOV(dev).active == 0) { /* * SRIOV inactive scheme */ -- 2.39.0