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 3D200A00C4 for ; Tue, 8 Nov 2022 00:18:01 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2DEBE400D7; Tue, 8 Nov 2022 00:18:01 +0100 (CET) Received: from dpdk.org (dpdk.org [92.243.24.197]) by mails.dpdk.org (Postfix) with ESMTP id 275924003C for ; Tue, 8 Nov 2022 00:17:59 +0100 (CET) Received: by dpdk.org (Postfix, from userid 65534) id 064A3121ED8; Tue, 8 Nov 2022 00:17:58 +0100 (CET) Subject: |WARNING| pw119532 [RFC] mempool: add API to return pointer to free space on per-core cache In-Reply-To: <20221107231536.1135652-1-kamalakshitha.aligeri@arm.com> References: <20221107231536.1135652-1-kamalakshitha.aligeri@arm.com> To: test-report@dpdk.org From: checkpatch@dpdk.org Cc: Kamalakshitha Aligeri Message-Id: <20221107231759.064A3121ED8@dpdk.org> Date: Tue, 8 Nov 2022 00:17:58 +0100 (CET) X-BeenThere: test-report@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: automatic DPDK test reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: test-report-bounces@dpdk.org Test-Label: checkpatch Test-Status: WARNING http://dpdk.org/patch/119532 _coding style issues_ WARNING:UNSPECIFIED_INT: Prefer 'unsigned int' to bare use of 'unsigned' #83: FILE: app/test/test_mempool.c:199: + unsigned i, j; ERROR:SPACING: space required after that ',' (ctx:VxV) #127: FILE: app/test/test_mempool.c:243: + cache_objs = rte_mempool_get_cache(mp,1); ^ WARNING:BRACES: braces {} are not necessary for any arm of this statement #128: FILE: app/test/test_mempool.c:244: + if (cache_objs != NULL) { [...] + else { [...] ERROR:POINTER_LOCATION: "(foo*)" should be "(foo *)" #129: FILE: app/test/test_mempool.c:245: + rte_memcpy(cache_objs, &obj, sizeof(void*)); ERROR:ELSE_AFTER_BRACE: else should follow close brace '}' #131: FILE: app/test/test_mempool.c:247: + } + else { ERROR:SPACING: space required after that ',' (ctx:VxV) #147: FILE: app/test/test_mempool.c:263: + cache_objs = rte_mempool_get_cache(mp,1); ^ WARNING:BRACES: braces {} are not necessary for any arm of this statement #148: FILE: app/test/test_mempool.c:264: + if (cache_objs != NULL) { [...] + else { [...] ERROR:ELSE_AFTER_BRACE: else should follow close brace '}' #151: FILE: app/test/test_mempool.c:267: + } + else { ERROR:SPACING: space required after that ',' (ctx:VxV) #154: FILE: app/test/test_mempool.c:270: + cache_objs = rte_mempool_get_cache(mp,1); ^ WARNING:BRACES: braces {} are not necessary for any arm of this statement #155: FILE: app/test/test_mempool.c:271: + if (cache_objs != NULL) { [...] + else { [...] ERROR:ELSE_AFTER_BRACE: else should follow close brace '}' #158: FILE: app/test/test_mempool.c:274: + } + else { WARNING:SPACING: space prohibited between function name and open parenthesis '(' #180: FILE: app/test/test_mempool.c:296: + cache_objs = rte_mempool_get_cache (mp, MEMPOOL_SIZE); ERROR:ELSE_AFTER_BRACE: else should follow close brace '}' #199: FILE: app/test/test_mempool.c:315: + } + else { ERROR:CODE_INDENT: code indent should use tabs where possible #238: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:102: + struct rte_mempool *mp = txep[0].mbuf->pool;$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #238: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:102: + struct rte_mempool *mp = txep[0].mbuf->pool;$ ERROR:CODE_INDENT: code indent should use tabs where possible #244: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:105: +^I void **cache_objs;$ ERROR:SPACING: space required after that ',' (ctx:VxV) #245: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:106: + cache_objs = rte_mempool_get_cache(mp,n); ^ ERROR:SPACING: spaces required around that '!=' (ctx:VxV) #247: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:108: + if (cache_objs!=NULL) { ^ ERROR:CODE_INDENT: code indent should use tabs where possible #248: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:109: +^I^I for (i = 0; i < n; i++) {$ WARNING:SUSPECT_CODE_INDENT: suspect code indent for conditional statements (24, 33) #248: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:109: + for (i = 0; i < n; i++) { [...] + rte_memcpy(&cache_objs[i],&txep->mbuf,sizeof(txep->mbuf)); ERROR:CODE_INDENT: code indent should use tabs where possible #249: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:110: +^I^I^I /* no need to reset txep[i].mbuf in vector path */$ ERROR:CODE_INDENT: code indent should use tabs where possible #250: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:111: +^I^I^I rte_memcpy(&cache_objs[i],&txep->mbuf,sizeof(txep->mbuf));$ ERROR:SPACING: space required after that ',' (ctx:VxO) #250: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:111: + rte_memcpy(&cache_objs[i],&txep->mbuf,sizeof(txep->mbuf)); ^ ERROR:SPACING: space required before that '&' (ctx:OxV) #250: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:111: + rte_memcpy(&cache_objs[i],&txep->mbuf,sizeof(txep->mbuf)); ^ ERROR:SPACING: space required after that ',' (ctx:VxV) #250: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:111: + rte_memcpy(&cache_objs[i],&txep->mbuf,sizeof(txep->mbuf)); ^ ERROR:CODE_INDENT: code indent should use tabs where possible #251: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:112: + txep++;$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #251: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:112: + txep++;$ ERROR:CODE_INDENT: code indent should use tabs where possible #252: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:113: +^I^I }$ ERROR:CODE_INDENT: code indent should use tabs where possible #253: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:114: +^I^I goto done;$ WARNING:SUSPECT_CODE_INDENT: suspect code indent for conditional statements (16, 23) #255: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:116: + else { + for (i = 0; i < n; i++) { ERROR:ELSE_AFTER_BRACE: else should follow close brace '}' #255: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:116: + } + else { CHECK:BRACES: Unbalanced braces around else statement #255: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:116: + else { WARNING:TABSTOP: Statements should start on a tabstop #256: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:117: + for (i = 0; i < n; i++) { WARNING:SUSPECT_CODE_INDENT: suspect code indent for conditional statements (23, 32) #256: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:117: + for (i = 0; i < n; i++) { + free[i] = txep->mbuf; ERROR:CODE_INDENT: code indent should use tabs where possible #257: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:118: +^I^I free[i] = txep->mbuf;$ WARNING:TABSTOP: Statements should start on a tabstop #259: FILE: drivers/net/i40e/i40e_rxtx_vec_common.h:120: + } ERROR:CODE_INDENT: code indent should use tabs where possible #286: FILE: lib/mempool/rte_mempool.h:1374: + void **cache_objs;$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #286: FILE: lib/mempool/rte_mempool.h:1374: + void **cache_objs;$ ERROR:CODE_INDENT: code indent should use tabs where possible #288: FILE: lib/mempool/rte_mempool.h:1376: + /* increment stat now, adding in mempool always success */$ ERROR:CODE_INDENT: code indent should use tabs where possible #289: FILE: lib/mempool/rte_mempool.h:1377: + RTE_MEMPOOL_STAT_ADD(mp, put_bulk, 1);$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #289: FILE: lib/mempool/rte_mempool.h:1377: + RTE_MEMPOOL_STAT_ADD(mp, put_bulk, 1);$ ERROR:CODE_INDENT: code indent should use tabs where possible #290: FILE: lib/mempool/rte_mempool.h:1378: + RTE_MEMPOOL_STAT_ADD(mp, put_objs, n);$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #290: FILE: lib/mempool/rte_mempool.h:1378: + RTE_MEMPOOL_STAT_ADD(mp, put_objs, n);$ ERROR:CODE_INDENT: code indent should use tabs where possible #292: FILE: lib/mempool/rte_mempool.h:1380: + struct rte_mempool_cache *cache = rte_mempool_default_cache(mp,$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #292: FILE: lib/mempool/rte_mempool.h:1380: + struct rte_mempool_cache *cache = rte_mempool_default_cache(mp,$ ERROR:CODE_INDENT: code indent should use tabs where possible #293: FILE: lib/mempool/rte_mempool.h:1381: + rte_lcore_id());$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #293: FILE: lib/mempool/rte_mempool.h:1381: + rte_lcore_id());$ ERROR:CODE_INDENT: code indent should use tabs where possible #295: FILE: lib/mempool/rte_mempool.h:1383: + /* No cache provided or the request itself is too big for the cache */$ ERROR:CODE_INDENT: code indent should use tabs where possible #296: FILE: lib/mempool/rte_mempool.h:1384: + if (unlikely(cache == NULL || n > cache->flushthresh))$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #296: FILE: lib/mempool/rte_mempool.h:1384: + if (unlikely(cache == NULL || n > cache->flushthresh))$ ERROR:CODE_INDENT: code indent should use tabs where possible #297: FILE: lib/mempool/rte_mempool.h:1385: + return NULL;$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #297: FILE: lib/mempool/rte_mempool.h:1385: + return NULL;$ ERROR:CODE_INDENT: code indent should use tabs where possible #299: FILE: lib/mempool/rte_mempool.h:1387: + if (cache->len + n <= cache->flushthresh) {$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #299: FILE: lib/mempool/rte_mempool.h:1387: + if (cache->len + n <= cache->flushthresh) {$ ERROR:CODE_INDENT: code indent should use tabs where possible #300: FILE: lib/mempool/rte_mempool.h:1388: +^I cache_objs = &cache->objs[cache->len];$ ERROR:CODE_INDENT: code indent should use tabs where possible #307: FILE: lib/mempool/rte_mempool.h:1395: + return cache_objs;$ WARNING:LEADING_SPACE: please, no spaces at the start of a line #307: FILE: lib/mempool/rte_mempool.h:1395: + return cache_objs;$ total: 35 errors, 21 warnings, 230 lines checked