From patchwork Wed Nov 9 19:14:32 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119637 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id F3F21A034C; Wed, 9 Nov 2022 20:14:56 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6AE2440687; Wed, 9 Nov 2022 20:14:54 +0100 (CET) Received: from mail-pg1-f176.google.com (mail-pg1-f176.google.com [209.85.215.176]) by mails.dpdk.org (Postfix) with ESMTP id 22CDA40150 for ; Wed, 9 Nov 2022 20:14:53 +0100 (CET) Received: by mail-pg1-f176.google.com with SMTP id v3so17039810pgh.4 for ; Wed, 09 Nov 2022 11:14:53 -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=yAXi9t9qXnDdLCvHb+CVQXhE0+9sAIZYsFecpV6ZpWc=; b=WLMqRWCxV1WhmkDcU4OOkDw/v6hkgF9+ANWWwQRlcoUpUKGSZmqwO58eVj0BkGEMGg axM1NXND5Q44J+pNcVTgwdWKLxxnmvsNZr9gRi9zH4aPvnvmlO9Vy5Acn6mUxkizvkOz HwU/32D9//dzBh9J6h7XccII8DRBcG0dUDgLONxmQUw1sXg4sKn7h1ZwI92DSp12YwW2 vVjOuijWmj6qGo/g+xw9y6DvX4H7UatfHUzTD3Zjd03B1BO5gobr2gGmYa92iJmz9R02 P0aF3yQgsX1rDUHJORvMFUVZ6h+6I9tlXwPJxKfClW8m6f3a/wR3WsTLpJVpilKEz7DK GRuA== 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=yAXi9t9qXnDdLCvHb+CVQXhE0+9sAIZYsFecpV6ZpWc=; b=dY38Z8Bt8r7Knr/6X28Hw3Rhkf/kI7PAXZYRDbl2rxQEdzzGGkeAMXu6T6s+U6dYX2 tJPK6M97xFkZ50QUeRd7FejhUvavActHEiupMCGKy6E2PMYcl4f6dITUn98BM8KKVpC5 u8UFc6IGwPdPG+Rw3B/p7+vUGZLUtNyu/uKirZk1DbA0Q32HwIfh1Ub69wBI4dbtV649 ccagQabDvSAzak+Q8I//YudrAket8gHt4aFFLS2u9fvEX+CWV7vPVhnNE+yZdeGUjGf+ IPyDm7FEC8Ir7k/7uTHguVZ+b2oOnBq036spuihSlc+BiId+2VJWxUGrh93HVTiZqmtn gJtw== X-Gm-Message-State: ACrzQf36CMp4qCGPNC2p3smSVkbNGdAi23qdp0A334m0fFpKJKMc2pFB Ny9mcv/maJ1K9SWrwNmAI9sImnBL7G7uug== X-Google-Smtp-Source: AMsMyM6tXIBqgYJN1Onk09AKEpN88EuFevoECnrbYgohH4sT96crZcDsw+b7zCDibpwS/Sr4nGrFNA== X-Received: by 2002:a05:6a00:d5f:b0:56e:9868:52b6 with SMTP id n31-20020a056a000d5f00b0056e986852b6mr28806647pfv.4.1668021291941; Wed, 09 Nov 2022 11:14:51 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.14.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:14:51 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Harman Kalra Subject: [PATCH 01/14] eal: fix whitespace Date: Wed, 9 Nov 2022 11:14:32 -0800 Message-Id: <20221109191445.140320-2-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- lib/eal/linux/eal_hugepage_info.c | 6 +++--- lib/eal/linux/eal_interrupts.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/eal/linux/eal_hugepage_info.c b/lib/eal/linux/eal_hugepage_info.c index a1b6cb31ff1a..b6d751a2ee97 100644 --- a/lib/eal/linux/eal_hugepage_info.c +++ b/lib/eal/linux/eal_hugepage_info.c @@ -180,8 +180,8 @@ get_default_hp_size(void) FILE *fd = fopen(proc_meminfo, "r"); if (fd == NULL) rte_panic("Cannot open %s\n", proc_meminfo); - while(fgets(buffer, sizeof(buffer), fd)){ - if (strncmp(buffer, str_hugepagesz, hugepagesz_len) == 0){ + while (fgets(buffer, sizeof(buffer), fd)) { + if (strncmp(buffer, str_hugepagesz, hugepagesz_len) == 0) { size = rte_str_to_size(&buffer[hugepagesz_len]); break; } @@ -231,7 +231,7 @@ get_hugepage_dir(uint64_t hugepage_sz, char *hugedir, int len) if (default_size == 0) default_size = get_default_hp_size(); - while (fgets(buf, sizeof(buf), fd)){ + while (fgets(buf, sizeof(buf), fd)) { const char *pagesz_str; if (rte_strsplit(buf, sizeof(buf), splitstr, _FIELDNAME_MAX, diff --git a/lib/eal/linux/eal_interrupts.c b/lib/eal/linux/eal_interrupts.c index d52ec8eb4cd7..3be1b090be9e 100644 --- a/lib/eal/linux/eal_interrupts.c +++ b/lib/eal/linux/eal_interrupts.c @@ -1073,7 +1073,7 @@ eal_intr_handle_interrupts(int pfd, unsigned totalfds) struct epoll_event events[totalfds]; int nfds = 0; - for(;;) { + for (;;) { nfds = epoll_wait(pfd, events, totalfds, EAL_INTR_EPOLL_WAIT_FOREVER); /* epoll_wait fail */ From patchwork Wed Nov 9 19:14:33 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119638 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 73892A034C; Wed, 9 Nov 2022 20:15:01 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 72DBA410DE; Wed, 9 Nov 2022 20:14:56 +0100 (CET) Received: from mail-pj1-f46.google.com (mail-pj1-f46.google.com [209.85.216.46]) by mails.dpdk.org (Postfix) with ESMTP id BE3D4410DE for ; Wed, 9 Nov 2022 20:14:55 +0100 (CET) Received: by mail-pj1-f46.google.com with SMTP id d13-20020a17090a3b0d00b00213519dfe4aso2841707pjc.2 for ; Wed, 09 Nov 2022 11:14:55 -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=ac5Ru+4OKqvdwqyupYsZlWG2/rQ7YLAQ869MdSC+FrQ=; b=jcu2zjlF+jQTSYg9+KfUZ/f6skMU5WN7LybUPlmFO9fEqBCvia9sStJjj8ds1ffsIx bk5SH1z62/zVIvb/OVE7esi+2Ng0sIESfKCrUXTEMhCoRUKl1EmIlpmVrhHsFJY8ouk1 xj/kJqEdSyVJYqxlRMBJ5twNa5bCFRLIdSMaaroYrcxgGKC3vb2LxEEECPYaw9WQ1h5v ADZxK5vhOXForkTJ0UMmTQJANdvf5NI4z3sttQcDBCkyvPyo+G1j1LC6f7YfZ6gyKuQ7 tge6onQGKqsThQ9tnA/W+ZNDLt1t7sCDtZx4r4jVORyfdxFOW3lqDuGbcG6Td4P1Jzcy 5tBQ== 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=ac5Ru+4OKqvdwqyupYsZlWG2/rQ7YLAQ869MdSC+FrQ=; b=Gp4EUmCgEDldx2rnO9jsiug9wJB1r+9ZaIJqXyPGzuYAMYbQihzvrsm/sKM29pRJx2 /LRLpI9rOBnMtNhxYn9RVI1ZH6MSk2Plz+zDxWNcot+uqcL80Vct/+zzQaMlSSBOp/i6 EjECsGPzVu34wpFX4PAyzwXvzvR4CK2p2tRVswszkPW6fMSkmEJdHRMgbCAUqdwRbxT0 vpO0Du6PKxY22IY6rcNA9yaj9yVE2+Wz5beJDMbfwNWZEJUWQDDmYFugB8e8hybJULR+ fbjthMg+w08RVi0TgsOEgW0jNzx1Plrcht6WJq2dmMToTMufmlllcT9TlhZqp/MIW9dY SQKw== X-Gm-Message-State: ACrzQf3CckRC71S5xvao+SRB+KrKfKGVLfhw4j1/r0lPt1FfdQl4cj5r xtoqNVJfx7rUGhF2nni4xdcwyi/oAcmMnA== X-Google-Smtp-Source: AMsMyM40vNdx2Y7kpmOVGwzmJPFbwDrn5HxSM8RA4q+Y6Wixpq6LmYd2mBOufCzLmYjjLXpHS6xZww== X-Received: by 2002:a17:90b:2d8e:b0:213:d517:f40f with SMTP id sj14-20020a17090b2d8e00b00213d517f40fmr55689976pjb.5.1668021294504; Wed, 09 Nov 2022 11:14:54 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.14.52 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:14:52 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Olivier Matz Subject: [PATCH 02/14] cmdline: fix whitespace Date: Wed, 9 Nov 2022 11:14:33 -0800 Message-Id: <20221109191445.140320-3-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Remove unnecessary spaces in if expressions. Signed-off-by: Stephen Hemminger --- lib/cmdline/cmdline_parse_string.c | 10 +++++----- lib/cmdline/cmdline_rdline.c | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/cmdline/cmdline_parse_string.c b/lib/cmdline/cmdline_parse_string.c index d756638905a2..0b53d0c800cc 100644 --- a/lib/cmdline/cmdline_parse_string.c +++ b/lib/cmdline/cmdline_parse_string.c @@ -77,16 +77,16 @@ cmdline_parse_string(cmdline_parse_token_hdr_t *tk, const char *buf, void *res, continue; } - if ( strncmp(buf, str, token_len) ) { + if (strncmp(buf, str, token_len)) { continue; } - if ( !cmdline_isendoftoken(*(buf+token_len)) ) { + if (!cmdline_isendoftoken(*(buf+token_len))) { continue; } break; - } while ( (str = get_next_token(str)) != NULL ); + } while ( (str = get_next_token(str)) != NULL); if (!str) return -1; @@ -108,7 +108,7 @@ cmdline_parse_string(cmdline_parse_token_hdr_t *tk, const char *buf, void *res, /* unspecified string (unknown single token) */ else { token_len = 0; - while(!cmdline_isendoftoken(buf[token_len]) && + while (!cmdline_isendoftoken(buf[token_len]) && token_len < (STR_TOKEN_SIZE-1)) token_len++; @@ -149,7 +149,7 @@ int cmdline_complete_get_nb_string(cmdline_parse_token_hdr_t *tk) return 0; str = sd->str; - while( (str = get_next_token(str)) != NULL ) { + while ((str = get_next_token(str)) != NULL) { ret++; } return ret; diff --git a/lib/cmdline/cmdline_rdline.c b/lib/cmdline/cmdline_rdline.c index 5cf723a0126a..28fc54cdfebf 100644 --- a/lib/cmdline/cmdline_rdline.c +++ b/lib/cmdline/cmdline_rdline.c @@ -301,7 +301,7 @@ rdline_char_in(struct rdline *rdl, char c) /* delete 1 char from the left */ case CMDLINE_KEY_BKSPACE: case CMDLINE_KEY_BKSPACE2: - if(!cirbuf_del_tail_safe(&rdl->left)) { + if (!cirbuf_del_tail_safe(&rdl->left)) { rdline_puts(rdl, vt100_bs); display_right_buffer(rdl, 1); } @@ -354,7 +354,7 @@ rdline_char_in(struct rdline *rdl, char c) /* paste contents of kill buffer to the left side of caret */ case CMDLINE_KEY_CTRL_Y: i=0; - while(CIRBUF_GET_LEN(&rdl->right) + CIRBUF_GET_LEN(&rdl->left) < + while (CIRBUF_GET_LEN(&rdl->right) + CIRBUF_GET_LEN(&rdl->left) < RDLINE_BUF_SIZE && i < rdl->kill_size) { cirbuf_add_tail(&rdl->left, rdl->kill_buf[i]); @@ -404,7 +404,7 @@ rdline_char_in(struct rdline *rdl, char c) /* add chars */ if (ret == RDLINE_RES_COMPLETE) { i=0; - while(CIRBUF_GET_LEN(&rdl->right) + CIRBUF_GET_LEN(&rdl->left) < + while (CIRBUF_GET_LEN(&rdl->right) + CIRBUF_GET_LEN(&rdl->left) < RDLINE_BUF_SIZE && i < tmp_size) { cirbuf_add_tail(&rdl->left, tmp_buf[i]); From patchwork Wed Nov 9 19:14:34 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119639 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id DC728A034C; Wed, 9 Nov 2022 20:15:06 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 64C574113D; Wed, 9 Nov 2022 20:14:58 +0100 (CET) Received: from mail-pl1-f182.google.com (mail-pl1-f182.google.com [209.85.214.182]) by mails.dpdk.org (Postfix) with ESMTP id 94DC14113D for ; Wed, 9 Nov 2022 20:14:57 +0100 (CET) Received: by mail-pl1-f182.google.com with SMTP id g24so18005236plq.3 for ; Wed, 09 Nov 2022 11:14:57 -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=b1WcfSMTUpWNCO1EbJfT3lp8xDOEHidPF/QX2vmYEtI=; b=QtkzSg1Z7tm5iDZpvkxabc2w+fqq5B7HR8W89M34JobJoFdaj5FhYrM+CVl9/eYfJw wvVeefou4hH9CKSp9/k7cYaQuVutHMn4FtRgTi/q0YUkvwBHfEy6UGc59/YJEO4IQ8vI ACFc0C2O+O7BnXoBrZpugg4Dc8NQftCwDgTZqF/H0fx7C+j+gltGVW8BIi3m6EPbNA+E auRwLBWTnJDyu1/A8DfOS13CDbVVY5928buHSBgB1CkPY4HpED9n5HaV9/rwP52Oy+qj paugbAYRRaoCnN977JFtClbELq8oH1ns/mqmV7oHMWuj0BXkLpN+kwHq6wcwYspYdItg h9sQ== 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=b1WcfSMTUpWNCO1EbJfT3lp8xDOEHidPF/QX2vmYEtI=; b=WxKCWLGYdCGHG4Fdo525ub+m2+SGTLtYY5LG0IYGdbH4GZrVDx/XPgQtZStYI3rk2e +eLug6cguBGCUnqm6BNc/Klv7JBorj/D1ES4YfxxnF83ojDHr2Ry4uNtkBLmZH/x7Sii vLdvOrvi4PknVSTw0sHhEfcCR2XtgU7UeQxAEWBiy7KJ/AR7pBS1buww+5JSm7WiWkBW 1GArTyvouXapw0etGFez+cQiYKV2zq01ABOLZU7/a27QmVPEPtGw/tLBTk9P124aNd6D cQzLqPis0crTuC1BeA/t0f7p3qhH3ATdLEbPdetJs9Sk6CKlyytTvlr7TAcCSwFyykDm Vc6w== X-Gm-Message-State: ACrzQf26BpR11H8fsLge0ho4kKCmbnFwk/TkEq7Bd27eqKHPXUuc+i85 C2kYgWsiLhcBlS9ljV6Fz+fzPlIyO4CUWA== X-Google-Smtp-Source: AMsMyM4yade2vkAWV0p5fAXzLEoydltwSA2iKZxle+PSxw4/OBgGpzGqArneWyWPx6bL5HqJ+E2a0A== X-Received: by 2002:a17:90a:8d15:b0:216:df8f:3de with SMTP id c21-20020a17090a8d1500b00216df8f03demr31292166pjo.80.1668021296450; Wed, 09 Nov 2022 11:14:56 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.14.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:14:55 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Erik Gabriel Carrillo Subject: [PATCH 03/14] timer: fix whitespace Date: Wed, 9 Nov 2022 11:14:34 -0800 Message-Id: <20221109191445.140320-4-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- lib/timer/rte_timer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/timer/rte_timer.c b/lib/timer/rte_timer.c index 85d67573eb9e..9eb73f1fed13 100644 --- a/lib/timer/rte_timer.c +++ b/lib/timer/rte_timer.c @@ -350,7 +350,7 @@ timer_get_prev_entries(uint64_t time_val, unsigned tim_lcore, { unsigned lvl = priv_timer[tim_lcore].curr_skiplist_depth; prev[lvl] = &priv_timer[tim_lcore].pending_head; - while(lvl != 0) { + while (lvl != 0) { lvl--; prev[lvl] = prev[lvl+1]; while (prev[lvl]->sl_next[lvl] && From patchwork Wed Nov 9 19:14:35 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119640 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8F02AA034C; Wed, 9 Nov 2022 20:15:12 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5D0A3410FB; Wed, 9 Nov 2022 20:15:00 +0100 (CET) Received: from mail-pl1-f178.google.com (mail-pl1-f178.google.com [209.85.214.178]) by mails.dpdk.org (Postfix) with ESMTP id B4FC54021E for ; Wed, 9 Nov 2022 20:14:59 +0100 (CET) Received: by mail-pl1-f178.google.com with SMTP id p21so17985691plr.7 for ; Wed, 09 Nov 2022 11:14:59 -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=jJ0X6Dq1D/GY6I6E4pJhph+lV2hSiKEeD8AtC+fUPco=; b=DcTutJDyr1dZ7QMNyQLnFVXxhGcvNXObNc5Sx0Ha7zi+m+fXWF7TyYlfKO97uIbxe0 e0gWfZBSESELX6IZgjRqHtwCeel2ZoRE6Q/8XbdTrOyg6RfDZqcGOU/8gh58TwLK8dQU bJpMi7paidl+Zypd8OuKjQrukP++vqHyga9Np3TjQNfjIKvJx2W32SS7GYRgcpa+gP3d b5jTe+4guTiEFy5gDhZWBAOGdQ88aZMcnvzUgRmJJ4TZhY91r9uDgGOAfRVz83y6IyJr 6ESbbuALsrgk8JEvFOn2C1fW5eFD/EWAkMS/ufQBytAY30KVhbT5QIp8NnttmX4LZ54U WWuw== 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=jJ0X6Dq1D/GY6I6E4pJhph+lV2hSiKEeD8AtC+fUPco=; b=UotB/pIL/YHP+CPGPu7yjsCTEHeVm6W6dYmbCkNv2OZeONQuR5etp3tZ50VDYEA0sh DnFwk7fZNrgoM8W2XJrG5R7cN9xPrz5KiNF97bJpMIkQotR3uIJtactxrjKkDdOBbJ4J l8rAcTp8q03Goy/E55MxL+92DlowCjVlD7L+NEV26paYHMnMkxVXNFtiV4EN9FKN19t5 GcnJIFPZxorDkkeOa5kkkMEtOrkVQwzc8Tf2IMTOQtfNt1xK/QXBjiMhJud2nPhhDAJR ojufMjHEDP9nA8Mq6bNajDPjfZn5yd0SVnsObcEeNfKMG8SfabMUaBVbsgGLky5hLMgK vWiQ== X-Gm-Message-State: ACrzQf0WjnicAe1sKjEegozvsCbDQ334wfNm3TxhW4M7/1xtYrULm7VT nRXz/jadzimcQb4l+jN8IwF2blKEUnKPDQ== X-Google-Smtp-Source: AMsMyM7QZjoHAOP9YCOHzXpRVb+WWvaC9wn2HEXS49OLJuwG5lTHcOuTgekbLA6uVX+lsLxqM3/0zw== X-Received: by 2002:a17:90a:5308:b0:20b:1eae:c94e with SMTP id x8-20020a17090a530800b0020b1eaec94emr46109730pjh.88.1668021298349; Wed, 09 Nov 2022 11:14:58 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.14.56 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:14:57 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Konstantin Ananyev Subject: [PATCH 04/14] ip_frag: fix whitespace Date: Wed, 9 Nov 2022 11:14:35 -0800 Message-Id: <20221109191445.140320-5-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- lib/ip_frag/rte_ipv4_reassembly.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ip_frag/rte_ipv4_reassembly.c b/lib/ip_frag/rte_ipv4_reassembly.c index 4a89a5f5365a..88ee0aa63f62 100644 --- a/lib/ip_frag/rte_ipv4_reassembly.c +++ b/lib/ip_frag/rte_ipv4_reassembly.c @@ -34,7 +34,7 @@ ipv4_frag_reassemble(struct ip_frag_pkt *fp) for (i = n; i != IP_FIRST_FRAG_IDX && ofs != first_len; i--) { /* previous fragment found. */ - if(fp->frags[i].ofs + fp->frags[i].len == ofs) { + if (fp->frags[i].ofs + fp->frags[i].len == ofs) { RTE_ASSERT(curr_idx != i); From patchwork Wed Nov 9 19:14:36 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119641 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 69FCCA034C; Wed, 9 Nov 2022 20:15:20 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 010F142D27; Wed, 9 Nov 2022 20:15:03 +0100 (CET) Received: from mail-pj1-f53.google.com (mail-pj1-f53.google.com [209.85.216.53]) by mails.dpdk.org (Postfix) with ESMTP id 6180A42D27 for ; Wed, 9 Nov 2022 20:15:01 +0100 (CET) Received: by mail-pj1-f53.google.com with SMTP id m14-20020a17090a3f8e00b00212dab39bcdso2807145pjc.0 for ; Wed, 09 Nov 2022 11:15:01 -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=lnR/76JWZ0FP0/lFeyLl7ljxvEGw9UPifWEz/m3GHiw=; b=QJvMFURY508ZTy2kuM9ypK7C0CmwRxEniMSYSx1/RvEfJQ+OjLkeUANpDdcW5wRaY+ +VX6GmNKl070LOhwDMSROMa4IyZP/GxwwcegDyNod8OK98UXIjXvlf5KOfLATyDQh+8y Nvo3YhvpZSA7nn+e42Cr6VSTpcKtll8T0jIOAj2uRFcBhsRbCIhBdsncBcm3VYHdJq6U NZ69S8tEhovwwwTPx4LVyG3fY5EYw/WCkddrX5VxBe6SWtA0deyWrhiwM+ZfYCxsSo8R NfN1Z8nYffR0yjY+Aj6W+xmnxKtLaJQsC+rCW9Cls4C0wck5Zt/0w6JzSDPbEiVo8mok /JYQ== 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=lnR/76JWZ0FP0/lFeyLl7ljxvEGw9UPifWEz/m3GHiw=; b=cjV1XJ+BYT8/7xpF+ZWDjzQS8uZtFqUCJjTEjgZCyf9RQrbxn+z/n/MgW1LSesk4E5 qHh2O2XpKqCzEAzHksX0GTIUJCOkxE/5pJx4A5jfeRLVFzyPIX48jjZF0ZLu4hz3k3Y+ MnssRS5vYghCO0gX5CgagagtqNet53AGmglKvnrDYeP17uyz3U5UP3CrHnsVQx3l1fqS cJ7dt2Eo3EPbnBC/unsoLpBz9pjmROIwfKNL9PHfefBrTPFk3UyRH3XIEHwpoqzXmQFm PEeml5rT5OS6omDhZjO9UvJvoPfbED5XkjmcPkot0wlBWa/FWyVnsRn1WGm6W1zdmHVF JCgg== X-Gm-Message-State: ACrzQf3Vtf2BfSdwUGo4QYeO3sfeQt8Ka7yOx3shDsM+b+1s+76HOVG5 21rHxcW7rLNFh0lYBXId314s9qytBWOdVQ== X-Google-Smtp-Source: AMsMyM61ZRs4nilqJTIukx7s45gnwb93krp3G54OyOD9xqj96g4zR3n3aK8BFVnUZGFtU77JR5qR4A== X-Received: by 2002:a17:90a:c38a:b0:213:119e:ebce with SMTP id h10-20020a17090ac38a00b00213119eebcemr64173731pjt.159.1668021300271; Wed, 09 Nov 2022 11:15:00 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.14.58 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:14:59 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Aman Singh , Yuying Zhang Subject: [PATCH 05/14] testpmd: fix whitspace Date: Wed, 9 Nov 2022 11:14:36 -0800 Message-Id: <20221109191445.140320-6-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- app/test-pmd/cmdline.c | 30 +++++++++++++++--------------- app/test-pmd/parameters.c | 8 ++++---- app/test-pmd/testpmd.c | 2 +- 3 files changed, 20 insertions(+), 20 deletions(-) diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c index 8dc60e938830..ff1fd1b470af 100644 --- a/app/test-pmd/cmdline.c +++ b/app/test-pmd/cmdline.c @@ -2730,11 +2730,11 @@ parse_reta_config(const char *str, while ((p = strchr(p0,'(')) != NULL) { ++p; - if((p0 = strchr(p,')')) == NULL) + if ((p0 = strchr(p,')')) == NULL) return -1; size = p0 - p; - if(size >= sizeof(s)) + if (size >= sizeof(s)) return -1; snprintf(s, sizeof(s), "%.*s", size, p); @@ -3242,15 +3242,15 @@ cmd_config_thresh_parsed(void *parsed_result, if (!strcmp(res->name, "txpt")) tx_pthresh = res->value; - else if(!strcmp(res->name, "txht")) + else if (!strcmp(res->name, "txht")) tx_hthresh = res->value; - else if(!strcmp(res->name, "txwt")) + else if (!strcmp(res->name, "txwt")) tx_wthresh = res->value; - else if(!strcmp(res->name, "rxpt")) + else if (!strcmp(res->name, "rxpt")) rx_pthresh = res->value; - else if(!strcmp(res->name, "rxht")) + else if (!strcmp(res->name, "rxht")) rx_hthresh = res->value; - else if(!strcmp(res->name, "rxwt")) + else if (!strcmp(res->name, "rxwt")) rx_wthresh = res->value; else { fprintf(stderr, "Unknown parameter\n"); @@ -4088,8 +4088,8 @@ cmd_vlan_offload_parsed(void *parsed_result, len = strnlen(str, STR_TOKEN_SIZE); i = 0; /* Get port_id first */ - while(i < len){ - if(str[i] == ',') + while (i < len){ + if (str[i] == ',') break; i++; @@ -4097,7 +4097,7 @@ cmd_vlan_offload_parsed(void *parsed_result, str[i]='\0'; tmp = strtoul(str, NULL, 0); /* If port_id greater that what portid_t can represent, return */ - if(tmp >= RTE_MAX_ETHPORTS) + if (tmp >= RTE_MAX_ETHPORTS) return; port_id = (portid_t)tmp; @@ -4108,17 +4108,17 @@ cmd_vlan_offload_parsed(void *parsed_result, if (!strcmp(res->what, "strip")) rx_vlan_strip_set(port_id, on); - else if(!strcmp(res->what, "stripq")){ + else if (!strcmp(res->what, "stripq")){ uint16_t queue_id = 0; /* No queue_id, return */ - if(i + 1 >= len) { + if (i + 1 >= len) { fprintf(stderr, "must specify (port,queue_id)\n"); return; } tmp = strtoul(str + i + 1, NULL, 0); /* If queue_id greater that what 16-bits can represent, return */ - if(tmp > 0xffff) + if (tmp > 0xffff) return; queue_id = (uint16_t)tmp; @@ -7207,7 +7207,7 @@ static void cmd_mac_addr_parsed(void *parsed_result, ret = rte_eth_dev_mac_addr_remove(res->port_num, &res->address); /* check the return value and print it if is < 0 */ - if(ret < 0) + if (ret < 0) fprintf(stderr, "mac_addr_cmd error: (%s)\n", strerror(-ret)); } @@ -7780,7 +7780,7 @@ static void cmd_vf_mac_addr_parsed(void *parsed_result, res->vf_num); #endif - if(ret < 0) + if (ret < 0) fprintf(stderr, "vf_mac_addr_cmd error: (%s)\n", strerror(-ret)); } diff --git a/app/test-pmd/parameters.c b/app/test-pmd/parameters.c index aed4cdcb8485..b7372e025ffd 100644 --- a/app/test-pmd/parameters.c +++ b/app/test-pmd/parameters.c @@ -306,11 +306,11 @@ parse_portnuma_config(const char *q_arg) /* reset from value set at definition */ while ((p = strchr(p0,'(')) != NULL) { ++p; - if((p0 = strchr(p,')')) == NULL) + if ((p0 = strchr(p,')')) == NULL) return -1; size = p0 - p; - if(size >= sizeof(s)) + if (size >= sizeof(s)) return -1; snprintf(s, sizeof(s), "%.*s", size, p); @@ -366,11 +366,11 @@ parse_ringnuma_config(const char *q_arg) /* reset from value set at definition */ while ((p = strchr(p0,'(')) != NULL) { ++p; - if((p0 = strchr(p,')')) == NULL) + if ((p0 = strchr(p,')')) == NULL) return -1; size = p0 - p; - if(size >= sizeof(s)) + if (size >= sizeof(s)) return -1; snprintf(s, sizeof(s), "%.*s", size, p); diff --git a/app/test-pmd/testpmd.c b/app/test-pmd/testpmd.c index aa7ea29f15ba..04b078a2938b 100644 --- a/app/test-pmd/testpmd.c +++ b/app/test-pmd/testpmd.c @@ -2406,7 +2406,7 @@ start_packet_forwarding(int with_tx_first) test_done = 0; - if(!no_flush_rx) + if (!no_flush_rx) flush_fwd_rx_queues(); rxtx_config_display(); From patchwork Wed Nov 9 19:14:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119642 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 94AD5A034C; Wed, 9 Nov 2022 20:15:26 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 102E242D35; Wed, 9 Nov 2022 20:15:05 +0100 (CET) Received: from mail-pf1-f169.google.com (mail-pf1-f169.google.com [209.85.210.169]) by mails.dpdk.org (Postfix) with ESMTP id D17A642D30 for ; Wed, 9 Nov 2022 20:15:03 +0100 (CET) Received: by mail-pf1-f169.google.com with SMTP id m6so17633512pfb.0 for ; Wed, 09 Nov 2022 11:15:03 -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=YureRJJ8UnWZJR0D8bEypKB06tPvSOWhbhJYoPGui9Q=; b=Ro9MZXCGiDD7baZKmwtvaNNEwLFCMPaeYFI0TDd47zXXI0Ot3klxqc6TlK9GqlPk9P H3GE1A1V1p/fs2NdJ278TWnw5QfKHWWX0q6kVWVbGf8fLdaZuPJ7URYkt9SWxspcrMD6 RwFNsBTzkk2RRn4oWnx6h69XSqFx3ARPvXMqK/dR8mx/LTgL9Fjcw8eeCn2bfl71mLsf v3IoaVig6M3zzvaxTyMsFcNoDzdvJuaR4fss9/DzAjGsb5v+ZOup29FNhUb4GV6foT96 JfUQIESh0ZbkR+VQ7kkNLFCwwC02TkukxoP/B+tetuWA97k5lKL0REZuOjDfNlY+NGMF na+w== 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=YureRJJ8UnWZJR0D8bEypKB06tPvSOWhbhJYoPGui9Q=; b=ZCor/J5i0lGhNEq6HuHFrz+xrz0xYSpXY87c9J6Sbqdc6wHP32wd3cafbMyxq6xbAe JjM/4OYNmfSqqf0a8WZydpUV/oXXEkiZvED+VwcXPN/BlRubzzn5pl1fySisZ78FNAZj 2rh7Mx7hL3FKCRn3asH9raMbliRMX2kzDHAv9dsR+LHGEY4o6XsjD+isaxiBciJabqJc +YLWBM1A8znH+MqqbHcAJmh9IKSDa+rUblGNeyds0/156CYO+WC3YC6LMZom3EQcf2Dl LEUn9coWx6C/j/J8nagzKPbSqXn7q/dNP3h8g8Scv6aRZVI8za6R7EUQLfJtUkNApqQa Z3fQ== X-Gm-Message-State: ACrzQf29iijprGdAOMLpW80JVws1Sfit9uwTnqchL5Y6P5GGUHWsEgwZ 2bvWhecaJZktVjVoq+92M7FPT+DzKQ45xw== X-Google-Smtp-Source: AMsMyM4vmB+BstkunE0CZomEtSaqX7oLKuJcNI7yLwPZ4MIWQf5B0HUUCCmMCSCuaBjA2h4YtyO6Mg== X-Received: by 2002:a05:6a00:15c8:b0:565:bc96:1c5b with SMTP id o8-20020a056a0015c800b00565bc961c5bmr62771705pfu.52.1668021302611; Wed, 09 Nov 2022 11:15:02 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:01 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Olivier Matz , Yipeng Wang , Sameh Gobriel , Bruce Richardson , Vladimir Medvedkin , Anatoly Burakov Subject: [PATCH 06/14] test: fix whitespace Date: Wed, 9 Nov 2022 11:14:37 -0800 Message-Id: <20221109191445.140320-7-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- app/test/test_cmdline_cirbuf.c | 4 ++-- app/test/test_debug.c | 4 ++-- app/test/test_hash.c | 8 ++++---- app/test/test_lpm6_perf.c | 2 +- app/test/test_malloc.c | 14 +++++++------- app/test/test_mbuf.c | 12 ++++++------ app/test/test_spinlock.c | 2 +- 7 files changed, 23 insertions(+), 23 deletions(-) diff --git a/app/test/test_cmdline_cirbuf.c b/app/test/test_cmdline_cirbuf.c index 8ac326cb02e0..6f7aae6df59a 100644 --- a/app/test/test_cmdline_cirbuf.c +++ b/app/test/test_cmdline_cirbuf.c @@ -708,7 +708,7 @@ test_cirbuf_char_fill(void) return -1; } /* delete buffer from tail */ - for(i = 0; i < CMDLINE_TEST_BUFSIZE; i++) + for (i = 0; i < CMDLINE_TEST_BUFSIZE; i++) cirbuf_del_tail_safe(&cb); /* try to delete from an empty buffer */ if (cirbuf_del_tail_safe(&cb) >= 0) { @@ -737,7 +737,7 @@ test_cirbuf_char_fill(void) return -1; } /* delete buffer from head */ - for(i = 0; i < CMDLINE_TEST_BUFSIZE; i++) + for (i = 0; i < CMDLINE_TEST_BUFSIZE; i++) cirbuf_del_head_safe(&cb); /* try to delete from an empty buffer */ if (cirbuf_del_head_safe(&cb) >= 0) { diff --git a/app/test/test_debug.c b/app/test/test_debug.c index 2704f5b92726..c66748019d9f 100644 --- a/app/test/test_debug.c +++ b/app/test/test_debug.c @@ -53,7 +53,7 @@ test_panic(void) return -1; } wait(&status); - if(status == 0){ + if (status == 0){ printf("Child process terminated normally!\n"); return -1; } else @@ -84,7 +84,7 @@ test_exit_val(int exit_val) } wait(&status); printf("Child process status: %d\n", status); - if(!WIFEXITED(status) || WEXITSTATUS(status) != (uint8_t)exit_val){ + if (!WIFEXITED(status) || WEXITSTATUS(status) != (uint8_t)exit_val){ printf("Child process terminated with incorrect status (expected = %d)!\n", exit_val); return -1; diff --git a/app/test/test_hash.c b/app/test/test_hash.c index 3e45afaa67fc..5e0618f0c340 100644 --- a/app/test/test_hash.c +++ b/app/test/test_hash.c @@ -72,7 +72,7 @@ static uint32_t hashtest_key_lens[] = {0, 2, 4, 5, 6, 7, 8, 10, 11, 15, 16, 21, rte_free(g_qsv); \ return -1; \ } \ -} while (0) +} while(0) /* * 5-tuple key type. @@ -724,12 +724,12 @@ static int test_five_keys(void) } /* Lookup */ - for(i = 0; i < 5; i++) + for (i = 0; i < 5; i++) key_array[i] = &keys[i]; ret = rte_hash_lookup_bulk(handle, &key_array[0], 5, (int32_t *)pos); - if(ret == 0) - for(i = 0; i < 5; i++) { + if (ret == 0) + for (i = 0; i < 5; i++) { print_key_info("Lkp", key_array[i], pos[i]); RETURN_IF_ERROR(pos[i] != expected_pos[i], "failed to find key (pos[%u]=%d)", i, pos[i]); diff --git a/app/test/test_lpm6_perf.c b/app/test/test_lpm6_perf.c index aaf2773b6fac..2f9321345e4b 100644 --- a/app/test/test_lpm6_perf.c +++ b/app/test/test_lpm6_perf.c @@ -47,7 +47,7 @@ print_route_distribution(const struct rules_tbl_entry *table, uint32_t n) printf("--------------------------- \n"); /* Count depths. */ - for(i = 1; i <= 128; i++) { + for (i = 1; i <= 128; i++) { unsigned depth_counter = 0; double percent_hits; diff --git a/app/test/test_malloc.c b/app/test/test_malloc.c index de40e506113a..0bb18c8cf7aa 100644 --- a/app/test/test_malloc.c +++ b/app/test/test_malloc.c @@ -86,8 +86,8 @@ test_align_overlap_per_lcore(__rte_unused void *arg) ret = -1; break; } - for(j = 0; j < 1000 ; j++) { - if( *(char *)p1 != 0) { + for (j = 0; j < 1000 ; j++) { + if ( *(char *)p1 != 0) { printf("rte_zmalloc didn't zero the allocated memory\n"); ret = -1; } @@ -157,8 +157,8 @@ test_reordered_free_per_lcore(__rte_unused void *arg) ret = -1; break; } - for(j = 0; j < 1000 ; j++) { - if( *(char *)p1 != 0) { + for (j = 0; j < 1000 ; j++) { + if ( *(char *)p1 != 0) { printf("rte_zmalloc didn't zero the allocated memory\n"); ret = -1; } @@ -331,12 +331,12 @@ test_multi_alloc_statistics(void) /* After freeing both allocations check stats return to original */ rte_malloc_get_socket_stats(socket, &post_stats); - if(second_stats.heap_totalsz_bytes != first_stats.heap_totalsz_bytes) { + if (second_stats.heap_totalsz_bytes != first_stats.heap_totalsz_bytes) { printf("Incorrect heap statistics: Total size \n"); return -1; } /* Check allocated size is equal to two additions plus overhead */ - if(second_stats.heap_allocsz_bytes != + if (second_stats.heap_allocsz_bytes != size + overhead + first_stats.heap_allocsz_bytes) { printf("Incorrect heap statistics: Allocated size \n"); return -1; @@ -495,7 +495,7 @@ test_realloc_socket(int socket) return -1; } /* calc an alignment we don't already have */ - while(RTE_PTR_ALIGN(ptr7, new_align) == ptr7) + while (RTE_PTR_ALIGN(ptr7, new_align) == ptr7) new_align *= 2; char *ptr8 = rte_realloc_socket(ptr7, size7, new_align, socket); if (!ptr8){ diff --git a/app/test/test_mbuf.c b/app/test/test_mbuf.c index 53fe898a384c..d505fd25e022 100644 --- a/app/test/test_mbuf.c +++ b/app/test/test_mbuf.c @@ -120,7 +120,7 @@ static unsigned refcnt_lcore[RTE_MAX_LCORE]; printf("mbuf test FAILED (l.%d): <" str ">\n", \ __LINE__, ##__VA_ARGS__); \ goto fail; \ -} while(0) +} while (0) /* * test data manipulation in mbuf with non-ascii data @@ -154,7 +154,7 @@ test_pktmbuf_with_non_ascii_data(struct rte_mempool *pktmbuf_pool) return 0; fail: - if(m) { + if (m) { rte_pktmbuf_free(m); } return -1; @@ -701,12 +701,12 @@ test_pktmbuf_pool(struct rte_mempool *pktmbuf_pool) } struct rte_mbuf *extra = NULL; extra = rte_pktmbuf_alloc(pktmbuf_pool); - if(extra != NULL) { + if (extra != NULL) { printf("Error pool not empty"); ret = -1; } extra = rte_pktmbuf_clone(m[0], pktmbuf_pool); - if(extra != NULL) { + if (extra != NULL) { printf("Error pool not empty"); ret = -1; } @@ -966,7 +966,7 @@ test_pktmbuf_free_segment(struct rte_mempool *pktmbuf_pool) struct rte_mbuf *mb, *mt; mb = m[i]; - while(mb != NULL) { + while (mb != NULL) { mt = mb; mb = mb->next; rte_pktmbuf_free_seg(mt); @@ -1195,7 +1195,7 @@ verify_mbuf_check_panics(struct rte_mbuf *buf) return -1; } wait(&status); - if(status == 0) + if (status == 0) return -1; return 0; diff --git a/app/test/test_spinlock.c b/app/test/test_spinlock.c index 3f59372300c3..3ee82fa963a5 100644 --- a/app/test/test_spinlock.c +++ b/app/test/test_spinlock.c @@ -237,7 +237,7 @@ test_spinlock(void) /* * Try to acquire a lock that we already own */ - if(!rte_spinlock_recursive_trylock(&slr)) { + if (!rte_spinlock_recursive_trylock(&slr)) { printf("rte_spinlock_recursive_trylock failed on a lock that " "we already own\n"); ret = -1; From patchwork Wed Nov 9 19:14:38 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119643 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 33ECDA034C; Wed, 9 Nov 2022 20:15:32 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2829542D30; Wed, 9 Nov 2022 20:15:07 +0100 (CET) Received: from mail-pl1-f169.google.com (mail-pl1-f169.google.com [209.85.214.169]) by mails.dpdk.org (Postfix) with ESMTP id D83C442D26 for ; Wed, 9 Nov 2022 20:15:05 +0100 (CET) Received: by mail-pl1-f169.google.com with SMTP id j12so17987221plj.5 for ; Wed, 09 Nov 2022 11:15:05 -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=HsB70apY/1oE5usD8NnWNkKMyEbL/zNnBg6TNaVHUxw=; b=Kc+yiwWxVy0JmSaajG8bIi8EluhHssQxdaXKRmRSKRMrbZ+HC50rX6T2SH+YNtdV+3 EAHCKeMQd/YSuMvKMoHpxiCafDQoXVAmgNKNg3QR9w+/yNpgpml60BidohUEd17sjtW6 yz+v0XyXnYYuGD2Pc8m/G94Tbt7GZtiPEzFup2WakdRdQIu+G9XybM673g0ifNRiZHGD pDE3nJoFJsBhmyHI9nJlqq66i1gia4hKGJSzMAwfCtqTRbh+BKYh7ejDREppMehl0yX+ dmWOVTXFnFVr5b8JcS/gZPipDnAcCDqfcVnvBuFgZACpAs/u/0D+yowPAttlck5X1glr I6pQ== 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=HsB70apY/1oE5usD8NnWNkKMyEbL/zNnBg6TNaVHUxw=; b=myFZoy2hzaTZiCVlnQItoV98ZKKCRAfPNdrVewIoOdhDptZbNhZz2/+ySsaktgDqSV yClCl6rfxHKoUHFM55NDyi/BpDwBN+IeUFWzFQlZmnQNLRBdmf7ocdwyvpgPf2Wlrxj1 dP5UMzaOrtBvO5UoxqSNrRK/Ad7yAHTZT0ocA2JAwOPWfuMnp1Aqik1nrzXztG904o/P 3pDBTB3l6w1I+orefrhcqIw9swOV+AZtLzccgEPVK/MZbmqy6D1882BYQ4I1KNo4FHG/ qu3/OLd3SGnaHI3EApwloBE2/Naf5mSdWRKqjEUcP04Vjhg+Au2tB5BeXZurFxA2l97b kwGQ== X-Gm-Message-State: ACrzQf0JDkID/T1qKbeAVpFN8H1P0To3pWMMr8OjB4DHBtyOzGtKIIng YRjXJC8BjpYs96JppGXxSu3Gkh5rtI0kiw== X-Google-Smtp-Source: AMsMyM7Z5gAymEadWGqeR8hdSgzgKhaK0iUSjyYcvxu7znrlgodY0yLV4fLNrK1/qLDUJyoq2u9jYg== X-Received: by 2002:a17:90b:4f8f:b0:20d:be54:f34f with SMTP id qe15-20020a17090b4f8f00b0020dbe54f34fmr81725291pjb.245.1668021304647; Wed, 09 Nov 2022 11:15:04 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:03 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Cristian Dumitrescu Subject: [PATCH 07/14] examples/qos_sched: fix whitespace Date: Wed, 9 Nov 2022 11:14:38 -0800 Message-Id: <20221109191445.140320-8-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger Acked-by: Cristian Dumitrescu --- examples/qos_sched/app_thread.c | 6 +++--- examples/qos_sched/args.c | 2 +- examples/qos_sched/init.c | 2 +- examples/qos_sched/main.c | 4 ++-- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/examples/qos_sched/app_thread.c b/examples/qos_sched/app_thread.c index dbc878b55394..a49356fecf5f 100644 --- a/examples/qos_sched/app_thread.c +++ b/examples/qos_sched/app_thread.c @@ -79,7 +79,7 @@ app_rx_thread(struct thread_conf **confs) if (likely(nb_rx != 0)) { APP_STATS_ADD(conf->stat.nb_rx, nb_rx); - for(i = 0; i < nb_rx; i++) { + for (i = 0; i < nb_rx; i++) { get_pkt_sched(rx_mbufs[i], &subport, &pipe, &traffic_class, &queue, &color); rte_sched_port_pkt_write(conf->sched_port, @@ -91,7 +91,7 @@ app_rx_thread(struct thread_conf **confs) if (unlikely(rte_ring_sp_enqueue_bulk(conf->rx_ring, (void **)rx_mbufs, nb_rx, NULL) == 0)) { - for(i = 0; i < nb_rx; i++) { + for (i = 0; i < nb_rx; i++) { rte_pktmbuf_free(rx_mbufs[i]); APP_STATS_ADD(conf->stat.nb_drop, 1); @@ -137,7 +137,7 @@ app_send_packets(struct thread_conf *qconf, struct rte_mbuf **mbufs, uint32_t nb uint32_t i, len; len = qconf->n_mbufs; - for(i = 0; i < nb_pkt; i++) { + for (i = 0; i < nb_pkt; i++) { qconf->m_table[len] = mbufs[i]; len++; /* enough pkts to be sent */ diff --git a/examples/qos_sched/args.c b/examples/qos_sched/args.c index b2959499ae9a..b752eb221f7c 100644 --- a/examples/qos_sched/args.c +++ b/examples/qos_sched/args.c @@ -451,7 +451,7 @@ app_parse_args(int argc, char **argv) /* sanity check for cores assignment */ nb_lcores = app_cpu_core_count(); - for(i = 0; i < nb_pfc; i++) { + for (i = 0; i < nb_pfc; i++) { if (qos_conf[i].rx_core >= nb_lcores) { RTE_LOG(ERR, APP, "pfc %u: invalid RX lcore index %u\n", i + 1, qos_conf[i].rx_core); diff --git a/examples/qos_sched/init.c b/examples/qos_sched/init.c index 0709aec10c31..41b46b296298 100644 --- a/examples/qos_sched/init.c +++ b/examples/qos_sched/init.c @@ -323,7 +323,7 @@ int app_init(void) rte_exit(EXIT_FAILURE, "Invalid configuration profile\n"); /* Initialize each active flow */ - for(i = 0; i < nb_pfc; i++) { + for (i = 0; i < nb_pfc; i++) { uint32_t socket = rte_lcore_to_socket_id(qos_conf[i].rx_core); struct rte_ring *ring; diff --git a/examples/qos_sched/main.c b/examples/qos_sched/main.c index dc6a17a6464a..7b757df0eb02 100644 --- a/examples/qos_sched/main.c +++ b/examples/qos_sched/main.c @@ -152,7 +152,7 @@ app_stat(void) static struct rte_eth_stats tx_stats[MAX_DATA_STREAMS]; /* print statistics */ - for(i = 0; i < nb_pfc; i++) { + for (i = 0; i < nb_pfc; i++) { struct flow_conf *flow = &qos_conf[i]; rte_eth_stats_get(flow->rx_port, &stats); @@ -212,7 +212,7 @@ main(int argc, char **argv) } else { /* print statistics every second */ - while(1) { + while (1) { sleep(1); app_stat(); } From patchwork Wed Nov 9 19:14:39 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119644 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id C9412A034C; Wed, 9 Nov 2022 20:15:37 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2578542D3B; Wed, 9 Nov 2022 20:15:09 +0100 (CET) Received: from mail-pl1-f180.google.com (mail-pl1-f180.google.com [209.85.214.180]) by mails.dpdk.org (Postfix) with ESMTP id BFFDD42D28 for ; Wed, 9 Nov 2022 20:15:07 +0100 (CET) Received: by mail-pl1-f180.google.com with SMTP id c2so17968376plz.11 for ; Wed, 09 Nov 2022 11:15:07 -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=e6XyBO8PZnvq4w8/QLE7qPDDvughbU7CtcnvRjyy2UU=; b=AbrzZNUwn+sLPfdSQ+FMJrXHbYRpv0gYxfoPzIHdTliRVOqA9e/2FJu3XPXxQ2lj4y KdIIDfcuRcy1weAZvcXbApN8IzpcGLSIyzW3dg+p0dTm+/g6B4zzwKzH4UrMSyCUnOeO OmFj6CAGff7vnJTbkrLYqUY2QzZ+qrShzkZd4xfsPzSR5v2DhOIS2sL6rJ1bzCnJJ2Wl WEh2p76sH+9lsyIAyzOBi820YKyUGORrIvHEDEXIfffPKnmTNJSB+7EtcIfGbr3C7pJ8 UsVqjZE5G867Njwgn1R6kaUaE+1BaLkRgqIoJIWteyA7urNQwhp41oBszLBEWfobM2a4 4BFw== 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=e6XyBO8PZnvq4w8/QLE7qPDDvughbU7CtcnvRjyy2UU=; b=orEn22TP8q4nmFs5bbYrgRVKQsI7NcHJg5EQjIvuwyKAa0Sa0lgoMTrDSRc9nHvFnH UyYO20jZsBGmZA3Rw5sDkXD8IJ/R/5lmY8HR1rCxrZNJqcLmFzmmtgOE51+jSkRTm86V fe3VgEL42t0J9O07p47OMq/e97+FvcMXJu9TUW0fyijva8e2NxMHS9KqpIVxUneAOEIY kJAUoRLH9qTUJb7VV89q8MuenWuhtXbpIs1Afn5R6Px7bzv713D0wyFjYlfKR56xVPG5 K/u88xVKBqT0IjzJE3Uxy7fJnkEUnJZkl2Cq8fotAiGngZHDbcl/6kD6ho/sLs17Q14m tW4A== X-Gm-Message-State: ACrzQf0jVIBgKhV03S7h4/fswsr6jTjEyoobBCswG6NY0KXiJvqJWdOd 6gv7v8P/SUYVkxni4hTf9jtJ6LVBku4J/g== X-Google-Smtp-Source: AMsMyM741dN5JA/S0pL5oW2DGGlt2thtT9lYmadJVbvhE0PpsJHj4M8tPmZXKIwZHhNSYAKgOXG1og== X-Received: by 2002:a17:902:d707:b0:187:2364:1dc1 with SMTP id w7-20020a170902d70700b0018723641dc1mr51794649ply.77.1668021306685; Wed, 09 Nov 2022 11:15:06 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:05 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Maxime Coquelin , Chenbo Xia Subject: [PATCH 08/14] examples/vhost: fix whitespace Date: Wed, 9 Nov 2022 11:14:39 -0800 Message-Id: <20221109191445.140320-9-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords Signed-off-by: Stephen Hemminger --- examples/vhost/main.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/vhost/main.c b/examples/vhost/main.c index 42e53a0f9a4f..cabc8682346c 100644 --- a/examples/vhost/main.c +++ b/examples/vhost/main.c @@ -1491,7 +1491,7 @@ switch_worker(void *arg __rte_unused) } } - while(1) { + while (1) { drain_mbuf_table(tx_q); drain_vhost_table(); /* @@ -1583,7 +1583,7 @@ destroy_device(int vid) return; /*set the remove flag. */ vdev->remove = 1; - while(vdev->ready != DEVICE_SAFE_REMOVE) { + while (vdev->ready != DEVICE_SAFE_REMOVE) { rte_pause(); } @@ -1816,7 +1816,7 @@ print_stats(__rte_unused void *arg) const char clr[] = { 27, '[', '2', 'J', '\0' }; const char top_left[] = { 27, '[', '1', ';', '1', 'H','\0' }; - while(1) { + while (1) { sleep(enable_stats); /* Clear screen and move to top left */ From patchwork Wed Nov 9 19:14:40 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119645 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 379F2A034C; Wed, 9 Nov 2022 20:15:44 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8075742D48; Wed, 9 Nov 2022 20:15:10 +0100 (CET) Received: from mail-pj1-f46.google.com (mail-pj1-f46.google.com [209.85.216.46]) by mails.dpdk.org (Postfix) with ESMTP id 1C10C42D24 for ; Wed, 9 Nov 2022 20:15:09 +0100 (CET) Received: by mail-pj1-f46.google.com with SMTP id d13-20020a17090a3b0d00b00213519dfe4aso2842306pjc.2 for ; Wed, 09 Nov 2022 11:15:09 -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=AWMb4VlbvlNbrESYxHviINq2hlfRwA27ZifZQwv6DLE=; b=7dVtwFxrhjquzowPbJpBo1cOwrKEI+A3KBXZM+l1IffITNl3K8Fwwcq+WHcFBPgZ88 3TTMoO8mqh8mVawodt13TAUYqh78FluANYPqyXZj+gC/YfIrJx6OyWoUGr2rcM6cZZfe Lp5f5eqr/BTeivAhhN8dohSp00hcfx0HOZokjaB5GZucrHWQzX1IWAXV10CmIFgwoq+C ie40jS4NK8yo1I6kCfVamFix9PJawq0V3V8irMpHoyYJEuEGm1YBRm3ndws917B1UrEy uvHTaMY3TAbJOO3LKhGA3wLXfPQGRfzJhT8//L4AwGJyOnL6WuzgaSqmLXD0gNCj3xMG M0nw== 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=AWMb4VlbvlNbrESYxHviINq2hlfRwA27ZifZQwv6DLE=; b=s3jq7z/BLh5Vkfnw+NqB/nCCoMUm8CmKeLYeK4R0QMTv2L+9MkEiQ96P1HXjCO9+rT AS7TNHBumNdfGUkvQn1PIjEBPs97xGkP+zbI0KKXuq04FW1+k4QWxhptOsdlrlssriqe UkL3+WN9ROAZI7gyVghO4XytS1qUyMirKA2ZvzfrBhaBo59KRoKHS9PM9g3sE8jGxCpe xGEEnTb2Qa4C4y7SP3ezABIFEkXpBhDFvHPhyUpOUevsKaTPeqlPMnqDi2UTVwi8LTxh elW0ZQ4Yu70tEhLBBE7thU3iTziAcS9IczY/uxBxJxcZaziVvfqhlEE2ebVqauR2o8j9 7gyA== X-Gm-Message-State: ACrzQf2P4VmGp1m7tlhmMKa60fYP0bpucf+tVczt9o2wBWRBnjjKi/x1 X9a7xyWNkpkMDkJl3paHXNCE2gVR65dDvA== X-Google-Smtp-Source: AMsMyM4IHddrn+YX0GeYLBiqXmZsCD8TGpbWX0M2SQUzyWJIGUglp1rrjAbbxlQg/AiFvWy1Q0ktQw== X-Received: by 2002:a17:902:bb86:b0:17c:4cac:eea4 with SMTP id m6-20020a170902bb8600b0017c4caceea4mr60275003pls.141.1668021308286; Wed, 09 Nov 2022 11:15:08 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:07 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , David Hunt Subject: [PATCH 09/14] l3fwd: fix whitespace Date: Wed, 9 Nov 2022 11:14:40 -0800 Message-Id: <20221109191445.140320-10-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywoords Signed-off-by: Stephen Hemminger --- examples/l3fwd-power/main.c | 6 +++--- examples/l3fwd/main.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/examples/l3fwd-power/main.c b/examples/l3fwd-power/main.c index fd3ade330f82..b2270e1056c8 100644 --- a/examples/l3fwd-power/main.c +++ b/examples/l3fwd-power/main.c @@ -1787,11 +1787,11 @@ parse_config(const char *q_arg) while ((p = strchr(p0,'(')) != NULL) { ++p; - if((p0 = strchr(p,')')) == NULL) + if ((p0 = strchr(p,')')) == NULL) return -1; size = p0 - p; - if(size >= sizeof(s)) + if (size >= sizeof(s)) return -1; snprintf(s, sizeof(s), "%.*s", size, p); @@ -2946,7 +2946,7 @@ main(int argc, char **argv) fflush(stdout); /* init RX queues */ - for(queue = 0; queue < qconf->n_rx_queue; ++queue) { + for (queue = 0; queue < qconf->n_rx_queue; ++queue) { struct rte_eth_rxconf rxq_conf; portid = qconf->rx_queue_list[queue].port_id; diff --git a/examples/l3fwd/main.c b/examples/l3fwd/main.c index 5198ff30dd00..2e1c4939f992 100644 --- a/examples/l3fwd/main.c +++ b/examples/l3fwd/main.c @@ -516,11 +516,11 @@ parse_config(const char *q_arg) while ((p = strchr(p0,'(')) != NULL) { ++p; - if((p0 = strchr(p,')')) == NULL) + if ((p0 = strchr(p,')')) == NULL) return -1; size = p0 - p; - if(size >= sizeof(s)) + if (size >= sizeof(s)) return -1; snprintf(s, sizeof(s), "%.*s", size, p); @@ -1366,7 +1366,7 @@ l3fwd_poll_resource_setup(void) printf("\nInitializing rx queues on lcore %u ... ", lcore_id ); fflush(stdout); /* init RX queues */ - for(queue = 0; queue < qconf->n_rx_queue; ++queue) { + for (queue = 0; queue < qconf->n_rx_queue; ++queue) { struct rte_eth_rxconf rxq_conf; portid = qconf->rx_queue_list[queue].port_id; From patchwork Wed Nov 9 19:14:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119646 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 41198A034C; Wed, 9 Nov 2022 20:15:49 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8D7CA42D4A; Wed, 9 Nov 2022 20:15:12 +0100 (CET) Received: from mail-pg1-f178.google.com (mail-pg1-f178.google.com [209.85.215.178]) by mails.dpdk.org (Postfix) with ESMTP id 588DB42D44 for ; Wed, 9 Nov 2022 20:15:11 +0100 (CET) Received: by mail-pg1-f178.google.com with SMTP id q71so17020851pgq.8 for ; Wed, 09 Nov 2022 11:15:11 -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=GYEQqcVERMmtjH1QTcIBXgv9M6JLSdnwjNpugNsoKuY=; b=01hq8ORISIdQTfhkQn2m8FoS3jwA0LqbI3dvjaFk8Q08ALv3Cr+3OexXcknCC2z6E2 y78R2WL5iePf/8getENljsqfxarvJ2mxGZrujQbMgo1E3A7rHU2bDMd7G78HjC32TfbD fAgzBHs6REYVgJA4LJX2VpbbR7Lte/6e9aMr4lWzQR43d9w0gyXHRsBMPrAhRolB5XrG nrBSY0OIP4BV5oMV78jwqMNVFaLHhPgj9dTNdhBVVa4l+7rPu8Zobv/OTfp2RrPPp3ZB b2XGIVxjXhZ9tUBurZ6omZlKT3xYeDnMqP0xKc7hsm66j6rNmr7BvbUM8+8WrGJgF292 FpGg== 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=GYEQqcVERMmtjH1QTcIBXgv9M6JLSdnwjNpugNsoKuY=; b=XilrEp+csFsevlCfRB4bBItJBPCy/AHWC+99hybT4AFhIkG/Jemp6nf1IGCS5jsizF AmR+wJa14OrRZ28ZLfcGA0cUhWPzrOFdqCpL2JWjIxFg3qNcHUUqfmGY88YuWVpznn5R aM9QmV65JNVwC8uTVIpNa5zVyQOSrCjAenR98gctdW853RnjCefMlxjZu08J4MxgNEXK 5Kvx27dirp/coaIQEDYbv1gBYFoHBokt/fTmZl4WKLor6l4Cuel+ThQ9MH6nJg8N51/3 5cT/d7V5BqzhmJ/rnredKdMRDTiT8o8aObX5Oa0nHZPenNxiKZ10kTk0GseJlYXM+DyC CB7Q== X-Gm-Message-State: ACrzQf3Gf1rQc+VngX3Buv+lsbs2jNtC1hC+v39PZmcRfwPu8TxXKMhb tSUdmiN5NHcbD70ej/PLAvPHTXMzGL8NIg== X-Google-Smtp-Source: AMsMyM4ftdTbGxGNMTc4/YwHfwQV1QQOjClK8tJJur9OqMWvx2Heip3PB/VxSvxp+XEY7ot8i+1cgw== X-Received: by 2002:a05:6a02:10a:b0:461:26b8:1c95 with SMTP id bg10-20020a056a02010a00b0046126b81c95mr50489335pgb.503.1668021310180; Wed, 09 Nov 2022 11:15:10 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:09 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Olivier Matz , Konstantin Ananyev , Anatoly Burakov Subject: [PATCH 10/14] examples: fix whitespace Date: Wed, 9 Nov 2022 11:14:41 -0800 Message-Id: <20221109191445.140320-11-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- examples/cmdline/parse_obj_list.c | 2 +- examples/ip_reassembly/main.c | 2 +- examples/multi_process/symmetric_mp/main.c | 6 +++--- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/examples/cmdline/parse_obj_list.c b/examples/cmdline/parse_obj_list.c index 959bcd14527e..759072d39620 100644 --- a/examples/cmdline/parse_obj_list.c +++ b/examples/cmdline/parse_obj_list.c @@ -42,7 +42,7 @@ parse_obj_list(cmdline_parse_token_hdr_t *tk, const char *buf, void *res, if (res && ressize < sizeof(struct object *)) return -1; - while(!cmdline_isendoftoken(buf[token_len])) + while (!cmdline_isendoftoken(buf[token_len])) token_len++; SLIST_FOREACH(o, tkd->list, next) { diff --git a/examples/ip_reassembly/main.c b/examples/ip_reassembly/main.c index bd0b1d31decf..7e84b4944759 100644 --- a/examples/ip_reassembly/main.c +++ b/examples/ip_reassembly/main.c @@ -300,7 +300,7 @@ send_single_packet(struct rte_mbuf *m, uint16_t port) TX_LCORE_STAT_UPDATE(&qconf->tx_stat, queue, 1); txmb->m_table[txmb->head] = m; - if(++txmb->head == len) + if (++txmb->head == len) txmb->head = 0; return 0; diff --git a/examples/multi_process/symmetric_mp/main.c b/examples/multi_process/symmetric_mp/main.c index 1ff85875dfdf..9c5348bd36ed 100644 --- a/examples/multi_process/symmetric_mp/main.c +++ b/examples/multi_process/symmetric_mp/main.c @@ -156,7 +156,7 @@ smp_parse_args(int argc, char **argv) /* get the port numbers from the port mask */ RTE_ETH_FOREACH_DEV(i) - if(port_mask & (1 << i)) + if (port_mask & (1 << i)) ports[num_ports++] = (uint8_t)i; ret = optind-1; @@ -470,8 +470,8 @@ main(int argc, char **argv) /* Primary instance initialized. 8< */ if (num_ports & 1) rte_exit(EXIT_FAILURE, "Application must use an even number of ports\n"); - for(i = 0; i < num_ports; i++){ - if(proc_type == RTE_PROC_PRIMARY) + for (i = 0; i < num_ports; i++){ + if (proc_type == RTE_PROC_PRIMARY) if (smp_port_init(ports[i], mp, (uint16_t)num_procs) < 0) rte_exit(EXIT_FAILURE, "Error initialising ports\n"); } From patchwork Wed Nov 9 19:14:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119647 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 87D42A034C; Wed, 9 Nov 2022 20:15:54 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 9B4A542D40; Wed, 9 Nov 2022 20:15:14 +0100 (CET) Received: from mail-pl1-f181.google.com (mail-pl1-f181.google.com [209.85.214.181]) by mails.dpdk.org (Postfix) with ESMTP id D3494410D7 for ; Wed, 9 Nov 2022 20:15:12 +0100 (CET) Received: by mail-pl1-f181.google.com with SMTP id v17so18006054plo.1 for ; Wed, 09 Nov 2022 11:15:12 -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=7h9XAuTLAdiw0cbcON/lzoi4fMgOU+VzF4RKwroQFmI=; b=8UxV0xqeXRicwCCybwziql1moAcEUu/g1Obn2xHou538XQ4nWWxQP9ptTEzex7XxST icWBOn3WgfYlSnDLTwIF04vPiGRb3iP+kybv5DshNqX4z6cF1a97vr+shnM/eWnS7kDk 1x43zNrN2gjtdswDwZ5VP2Nuo8uYOlwnup5J/sScuTLHHYxGkja3Y5Qm6wj3MpppSxgt IzB3UTk93CUsmdB11tWlouN94d3aaDT0TsRLPfGvWBL73p8cfA6CV6/mX3gmw76TWRi/ xWawrU0ymKTCTzHOfC94Xpv2MANSRXxaT2h8PuOFOtoKJE1uBgm0578rK1688R3i/XeU jNgQ== 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=7h9XAuTLAdiw0cbcON/lzoi4fMgOU+VzF4RKwroQFmI=; b=gnSu1gJigp2SuaORsgs0SNxXsLNMGmCkREmGm1f85MuBNS+F8Clj5P+HM4jRehRkBR E+hTarcrlF3uli2aeM2vD+mj+YBSM+u4rmTOipblrtXFMpvYL8/i2sBM/OZyTfnN1yHz fsUV6veVgks4K513qqVLkjHtvkEJMeb9EaI55E7nTomUOPArLVX0frCHOaO20g6ATfjI Hf1ylwsjf76mAjk2ydDLHFftc17IQ+LV2dIMj1/eTfqS/HTGqfcUTCOmiEgTRX3/MDY7 BZ8nEAZH3GUpvuNEE6cUjZD390WMikG1uxp0VX7YypcsQB89fQuDwz1Y5r0zq6ZEQk+h jaKQ== X-Gm-Message-State: ACrzQf12TmVjV5IzZll0BgwffkwbwQepl3U57KeeOyoCeWVoXmc/9uHS D1DW7TpZGaPgxnZbZ0+Uvh21G/XDoIZpAw== X-Google-Smtp-Source: AMsMyM5jAMbgnJnqWXi1HbmqBp3eCPmklW5Pk9kvJ4v7HeOtLPDbpd4O1p8q5WB0Wc6tYnkFmeS9ow== X-Received: by 2002:a17:90b:3715:b0:212:bf31:d00 with SMTP id mg21-20020a17090b371500b00212bf310d00mr1188460pjb.33.1668021311734; Wed, 09 Nov 2022 11:15:11 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.10 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:10 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH 11/14] bus/pci: fix whitespace Date: Wed, 9 Nov 2022 11:14:42 -0800 Message-Id: <20221109191445.140320-12-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- drivers/bus/pci/bsd/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/bus/pci/bsd/pci.c b/drivers/bus/pci/bsd/pci.c index 7459d15c7e31..056e2eda2d5f 100644 --- a/drivers/bus/pci/bsd/pci.c +++ b/drivers/bus/pci/bsd/pci.c @@ -368,7 +368,7 @@ rte_pci_scan(void) } dev_count += conf_io.num_matches; - } while(conf_io.status == PCI_GETCONF_MORE_DEVS); + } while (conf_io.status == PCI_GETCONF_MORE_DEVS); close(fd); From patchwork Wed Nov 9 19:14:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119648 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 472A0A034C; Wed, 9 Nov 2022 20:16:00 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id AF72D42D50; Wed, 9 Nov 2022 20:15:17 +0100 (CET) Received: from mail-pj1-f46.google.com (mail-pj1-f46.google.com [209.85.216.46]) by mails.dpdk.org (Postfix) with ESMTP id 2E98B42D51 for ; Wed, 9 Nov 2022 20:15:15 +0100 (CET) Received: by mail-pj1-f46.google.com with SMTP id d59-20020a17090a6f4100b00213202d77e1so2777567pjk.2 for ; Wed, 09 Nov 2022 11:15:15 -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=xGH78huEm2Y1yp8NOt4ytbh0acrjRClJODkI7URptvY=; b=n84f4GFWdnGV74wONGyMytPogdrDHfphgTHEXwjedrennXY5Umc2mC1NFxTvCoMf2g MK4NsgOSNC6AIzTsQX0Z0ptC5pl/EWjkFTyx+wXq2OY5NkjgyyAo/RBzT9nf2Pv9t/ws njZfKPwCYjOE7iwiiI1XmGGi6kie3YX68tDMFFl3rtolQK7LS+ksv8gVfkLjKOLudO6R RiwDynvXdvcNLZ6siFQWIWkDq8Ar7tyZXD8ejfMxycGlu7CTCIDDkAl5OErWAVlotvqJ RF+nrNr/USAccH9+j64rERyba4IwQzyOPI30zXQ6ejxNv2edMIsG+iVN+I5kng3zV/40 FMCw== 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=xGH78huEm2Y1yp8NOt4ytbh0acrjRClJODkI7URptvY=; b=2cP5U8kifFXWca8+HuX+m/Qf0a0Vp5bQIaMI0mh73/DAmowp8auWgB1kfvPy8nYXxm +0scXQa76jZ2Ms/9lxwqFeyvb8k17yxCgo4kF//bmnkk6iaqqr9Hg3fSRcA9mAVrVi/r nbw57Zej0IYbryQFlJWkmE5F6TPnkQ4ir/eV/sZadQ50LxFcbxisbAxUM+Nu0bOqG0Ok +81yQinwqp1e7N/254rK/M6yEdn9P/FtfqdK4lNxgUXFA8aqKdKrlZMqKuf6zUcQDzxC TgEetDGGF9XEbjJ4OM9Bw5HMwZrPPFzan81Gu6i6t/cSRmSd0dJQS/rhVBmZSQQQPleh k2EQ== X-Gm-Message-State: ANoB5pnjNTQfCbXf1NwdTlk/tIZmCyKT8ZyztGKKZgcERCIWwYymaRH+ pWt2jqwmglJlFsO1OqGCtAhEgwFXIBYGbA== X-Google-Smtp-Source: AA0mqf61ypu98ai/fWOfdnnKo3t34NZ7XPP/1IcOUVNKJ7nxIrdsrYWfwci9RR9z3RJYRtT31clf0g== X-Received: by 2002:a17:90a:6448:b0:217:24f3:cefd with SMTP id y8-20020a17090a644800b0021724f3cefdmr29397882pjm.200.1668021314198; Wed, 09 Nov 2022 11:15:14 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:12 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Simei Su , Wenjun Wu Subject: [PATCH 12/14] net/e1000: fix whitespace Date: Wed, 9 Nov 2022 11:14:43 -0800 Message-Id: <20221109191445.140320-13-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- drivers/net/e1000/em_ethdev.c | 4 ++-- drivers/net/e1000/igb_ethdev.c | 8 ++++---- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/net/e1000/em_ethdev.c b/drivers/net/e1000/em_ethdev.c index 8ee9be12ad19..146e74cfc76e 100644 --- a/drivers/net/e1000/em_ethdev.c +++ b/drivers/net/e1000/em_ethdev.c @@ -872,8 +872,8 @@ 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 || - (E1000_READ_REG(hw, E1000_STATUS) & E1000_STATUS_LU)) { + 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; } From patchwork Wed Nov 9 19:14:44 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119649 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7986BA034C; Wed, 9 Nov 2022 20:16:05 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id A796A40143; Wed, 9 Nov 2022 20:15:18 +0100 (CET) Received: from mail-pf1-f169.google.com (mail-pf1-f169.google.com [209.85.210.169]) by mails.dpdk.org (Postfix) with ESMTP id BED6642D52 for ; Wed, 9 Nov 2022 20:15:16 +0100 (CET) Received: by mail-pf1-f169.google.com with SMTP id m6so17634032pfb.0 for ; Wed, 09 Nov 2022 11:15:16 -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=HHt9PbzPy7mkylQAPxjeYOiNiOuzNKGwN6+hVQRO3+Q=; b=8JMBU+H8MF56KyXeQM9IZ1dPDQeJ+upI2TMmQ95+esOiUmHr9iHFzOoOcoSjxPqwEN +2HHvkQ0LQJE/J3f1FXlYYjhCWgX/8EXUhXa5FsdzmD5PJ2ZiDBHZNu2M0O5tIkWncnN EA8sWVIUXSwUKgqzkOYvKPWrAUAgly/xvZHteeE5dSRu22RRaTx56Dgff7O58uCGjGEr NqS1Ft8lF3hgo4SsAuZC283YYxZ+7tZz+RXpemPyy97ibfzcA4JxXkpKCN57S1uZqiKC eszFfvJ5Dbhs4c5+TSw9MPJW09TDIsWfryl68COZDQUTkAWHPX4zV0IpRtCmoF1Uab4s luhg== 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=HHt9PbzPy7mkylQAPxjeYOiNiOuzNKGwN6+hVQRO3+Q=; b=WJFxHWkh7vsG9XbBadCogOWQCM9b9piuKifXrdptEfnZsPlNdI20S37JBCrTpepvUw +/CBitYwv8ZchoPqRjacJ8LeuJXK4V+D8qUDAUBpo30AgVfoPy3frbCw/ENy7XJg/nEB 18IFZBpzCQGoa6uyHLa1J8bTDE8+fu7xSC5alRASe2GLW+9ElM9z4vXw2cPwaAnA9tNs bS9PpXlcv/5np6KIfHfQpcOS/hN3KlXu+ZwLCTMmacNmoG4wF3FUMWQNZsVQChVkSFz2 qAsj1XrozdruKHd3ZQxVNVGwz9vKMu6NRTIi8ntfOGSIfsvU90Istjdyi43Zuup9q8/r n8Fg== X-Gm-Message-State: ACrzQf0S9vL9Y0KPW9ypv327w0XCH492CmSIgWhiVrggnE4lnSAkY9Cu lw6qqhq10ewgcAAqbAlDbwoRlxD1cmkSmg== X-Google-Smtp-Source: AMsMyM72/Sz0CoW8+2bfavfisRjWP0RZerbkGJabRai12VBhmLTLc2zqWlemsBy2njlNIZpTQerP7A== X-Received: by 2002:a63:1c1b:0:b0:46f:7b0f:4fea with SMTP id c27-20020a631c1b000000b0046f7b0f4feamr51741259pgc.423.1668021315936; Wed, 09 Nov 2022 11:15:15 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:15 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Yuying Zhang , Beilei Xing Subject: [PATCH 13/14] net/i40e: fix whitespace Date: Wed, 9 Nov 2022 11:14:44 -0800 Message-Id: <20221109191445.140320-14-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- drivers/net/i40e/i40e_pf.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/net/i40e/i40e_pf.c b/drivers/net/i40e/i40e_pf.c index 15d9ff868f3a..7050e0057d8e 100644 --- a/drivers/net/i40e/i40e_pf.c +++ b/drivers/net/i40e/i40e_pf.c @@ -956,7 +956,7 @@ i40e_pf_host_process_cmd_add_vlan(struct i40e_pf_vf *vf, for (i = 0; i < vlan_filter_list->num_elements; i++) { ret = i40e_vsi_add_vlan(vf->vsi, vid[i]); - if(ret != I40E_SUCCESS) + if (ret != I40E_SUCCESS) goto send_msg; } @@ -996,7 +996,7 @@ i40e_pf_host_process_cmd_del_vlan(struct i40e_pf_vf *vf, vid = vlan_filter_list->vlan_id; for (i = 0; i < vlan_filter_list->num_elements; i++) { ret = i40e_vsi_delete_vlan(vf->vsi, vid[i]); - if(ret != I40E_SUCCESS) + if (ret != I40E_SUCCESS) goto send_msg; } @@ -1577,12 +1577,12 @@ i40e_pf_host_init(struct rte_eth_dev *dev) * return if SRIOV not enabled, VF number not configured or * no queue assigned. */ - if(!hw->func_caps.sr_iov_1_1 || pf->vf_num == 0 || pf->vf_nb_qps == 0) + if (!hw->func_caps.sr_iov_1_1 || pf->vf_num == 0 || pf->vf_nb_qps == 0) return I40E_SUCCESS; /* Allocate memory to store VF structure */ pf->vfs = rte_zmalloc("i40e_pf_vf",sizeof(*pf->vfs) * pf->vf_num, 0); - if(pf->vfs == NULL) + if (pf->vfs == NULL) return -ENOMEM; /* Disable irq0 for VFR event */ From patchwork Wed Nov 9 19:14:45 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 119650 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4F2FCA034C; Wed, 9 Nov 2022 20:16:10 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B23BC42D3E; Wed, 9 Nov 2022 20:15:20 +0100 (CET) Received: from mail-pg1-f176.google.com (mail-pg1-f176.google.com [209.85.215.176]) by mails.dpdk.org (Postfix) with ESMTP id D15E542D54 for ; Wed, 9 Nov 2022 20:15:18 +0100 (CET) Received: by mail-pg1-f176.google.com with SMTP id f63so17048555pgc.2 for ; Wed, 09 Nov 2022 11:15:18 -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=orlqAdyG2cO9p0skE4kv7DuYe3j4iDQmQO7NM85bGpM=; b=FxIk0FJZhp3odYvH8cuFaYnzvfTKMtdCNyPz3VaplLgbEK/PZyejrf/x28jZDudT0z nX+RdLl5GKtcH7leMXNAjMiLnN+GEbWdORz0a7cU9cGrnbPMTe64lZ4YD1NKtvzDwm37 ufDbOZyBYgftndNtbtxEMhfmQ47qV3bxrUXugbqVHoflUgXcFrTJ5MlqepOEREYID8pt COVRNU79qEe250QlP9/afY03oBR/N2wu8nlsfUQNerFjB40O+NHI4WXIAIb5GMH8aRxU GXC95243wdGXq/j6SnItznm1fS2yzC3PLW0DuA7tHGfcwL6mISuJUUzd8MNz5bebANVB +DKQ== 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=orlqAdyG2cO9p0skE4kv7DuYe3j4iDQmQO7NM85bGpM=; b=7RtoCoFV0Rvc0ShREAUBYd7rIu7Elyz9sdajUbIGx2prHzJtOTBDieCXu7Tda711mE DjEovqhuiDy0g6sw6KQKboZNNCtrpSfovDERyjsIZzzOV3gil/4Se3ttzpbja2QoMFTd cNk/4WmSDHCsNIvufzL8sBuY3fXcIigJ2AKwpsczEkAaoBepiDvu1xKxFIxTkvedhiDy jgEWOdmI9GA1GXREnZBiHnbiLoFQLahZ9xYzOrdYmpAdWcbbWnvzFCVjIYzRQn7+NAmh z0y3DPaqAMYaWeMaxz4pdRd6bG1eW+ClssIBeq03RELO6gX0wc1UnVch7I3XZFmn8qzW gUjw== X-Gm-Message-State: ACrzQf398sxBQsP4rYyj05Us2zO9aRfLhetS+P3rfLa9JD+LLjU4TSpb x0I0VNQ+4D8nlwG3PLJmNTpx4XixbvPfLw== X-Google-Smtp-Source: AMsMyM4bRYF7ymA5rWmb3eOmK58hJq9SbwHoXB6v6/2jVRHV8t+4QMSRBW7mW2FMFfJaivurSKpHSg== X-Received: by 2002:a65:6404:0:b0:46f:a711:c481 with SMTP id a4-20020a656404000000b0046fa711c481mr47785241pgv.262.1668021317707; Wed, 09 Nov 2022 11:15:17 -0800 (PST) Received: from hermes.local (204-195-120-218.wavecable.com. [204.195.120.218]) by smtp.gmail.com with ESMTPSA id gn16-20020a17090ac79000b002130c269b6fsm1586698pjb.1.2022.11.09.11.15.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 09 Nov 2022 11:15:16 -0800 (PST) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Rasesh Mody , Shahed Shaikh Subject: [PATCH 14/14] net/bnx2x: fix whitespace Date: Wed, 9 Nov 2022 11:14:45 -0800 Message-Id: <20221109191445.140320-15-stephen@networkplumber.org> X-Mailer: git-send-email 2.35.1 In-Reply-To: <20221109191445.140320-1-stephen@networkplumber.org> References: <20221109191445.140320-1-stephen@networkplumber.org> MIME-Version: 1.0 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 Add space after keywords. Signed-off-by: Stephen Hemminger --- drivers/net/bnx2x/bnx2x.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/bnx2x/bnx2x.h b/drivers/net/bnx2x/bnx2x.h index 89414ac88a93..9cb927e25449 100644 --- a/drivers/net/bnx2x/bnx2x.h +++ b/drivers/net/bnx2x/bnx2x.h @@ -96,7 +96,7 @@ int bnx2x_ilog2(int x) int log = 0; x >>= 1; - while(x) { + while (x) { log++; x >>= 1; }