From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from na01-by2-obe.outbound.protection.outlook.com (mail-by2on0058.outbound.protection.outlook.com [207.46.100.58]) by dpdk.org (Postfix) with ESMTP id 687462C14 for ; Fri, 22 Apr 2016 16:51:56 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-caviumnetworks-com; h=From:To:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=gPB9y5QfkQTlwR9uI5bngjWNrhRaYIesXGGzozX+zpY=; b=TixpnkwhKVsCFHLswenUEoUsKRwms+iujQmgbLHjhNKfA4cVPte/ojyeJbvbAEs3jSlSwQsnCv1rpVNqj8LzHVW8wmFpIpj+2pvFjXkWZ5hGSmV+uXBCGBCI4nginSyDv7fmMELVZcmEsUB/F6M97HlOZb16Z5j/w4mn+T3UpGE= Authentication-Results: dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; dmarc=none action=none header.from=caviumnetworks.com; Received: from hp-mjc.semihalf.local (213.17.239.108) by DM2PR0701MB1033.namprd07.prod.outlook.com (10.160.25.141) with Microsoft SMTP Server (TLS) id 15.1.466.19; Fri, 22 Apr 2016 14:51:53 +0000 From: To: CC: , , Maciej Czekaj Date: Fri, 22 Apr 2016 16:51:19 +0200 Message-ID: <1461336680-7581-3-git-send-email-maciej.czekaj@caviumnetworks.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1461319098-22632-1-git-send-email-maciej.czekaj@caviumnetworks.com> References: <1461319098-22632-1-git-send-email-maciej.czekaj@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [213.17.239.108] X-ClientProxiedBy: HE1PR02CA0059.eurprd02.prod.outlook.com (10.163.170.27) To DM2PR0701MB1033.namprd07.prod.outlook.com (10.160.25.141) X-MS-Office365-Filtering-Correlation-Id: 58cabd6c-2d09-49f6-ce5d-08d36abda596 X-Microsoft-Exchange-Diagnostics: 1; DM2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WA+194MGpoB1hQj0A== X-Microsoft-Exchange-Diagnostics: 1; DM2PR0701MB1033; 20:4tUmomgY39KbF6x8q3YJQdkO6GOtjdvD+LwpHO+jRI6guz7eqicJq2B++Eh3s98kuBFldKiA4Rl0DPRXRa8HmNDdjNj/8q8jMRZPpf0JG3jr4MLhyMTITb+mv+VvdJmVL5Vt1A6yrkC8K1gQFzP0aTkqG8fVLatPud9NgeMULurEpkOj9PyDIIyDUy6AdFwLNJY1UWG/9tuzZSUCN44+1aDcnSOlQD9KBBG/WXWw2cL8T2Y7aS4J8MHyjGPzr4BWjGyBfRn/L1cCGws0sJnaqe5yx+RL3UeRJvv7IFKcp1hW/MINqK8ezfJwZq5xSgAJeJoIywFIrGjqrJc4g+dOpMEgxTfhpoqbvaJM2wC8+o27jRTzI46ly1tAvX10X6UwpF/Db/Yyrl1cg38C57sp1qNlO3cPCCfEOK3lZetKgghR9Njttcw9GLF1cbRpS8Jwg91oBtub/x/sx7hrhnOqGP8aw/QLu1N+eNRewpnBnILsKwD8F0hgGl+NCGqUXFLEtWUdgvxESJj7zMJbzdU0Ei3aGF8FvpPZKCQhdEfnF00p32KEZdiwH1UNR6gfinvcL9azkH2cXccUNUIlzDUWIhjIu25ONXVO+WLonMi1eGI= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(9101521026)(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046); SRVR:DM2PR0701MB1033; BCL:0; PCL:0; RULEID:; SRVR:DM2PR0701MB1033; X-Microsoft-Exchange-Diagnostics: 1; DM2PR0701MB1033; 4:A8KZtcD8T5Up9CZSM3hvWeBo2AG86Z0JiTaRNuJOfsxbFzFpw7ihwfK1E3nDsjnTXy+meWLwnkcNW61wbxLW2NDfIaG+absR+Rhz+mmxaNTRgTBVe1YLoMU/8p9Jtanj3/U39xkObzE1/lWnSSEb+oQLGNZJtyWMS+3HUDH6joERvixueAAYxCloDWtgBnoTRMN7JBdwlYAwa5uzugQKDDefQOL1Yo4g6W9bJm860qMGpZmh95K/D2j4zA+Nk1JxtI3XqnoP76tfhShADOoBpwXdFecdMUszz0uH4mDj/pJ25idbHKcGoNOCA5R2XnRfwbecAUzMj4tMoh+sFXx5UfSAMlaGquP47dIgHaElXwbiPzoPjQeboRVRJdupO5vtW/Njqq515MvXq8CM2KWYog== X-Forefront-PRVS: 0920602B08 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(42186005)(6116002)(3846002)(5004730100002)(4326007)(86152002)(48376002)(19580395003)(19580405001)(586003)(50226001)(2876002)(36756003)(1096002)(5008740100001)(86362001)(2950100001)(50986999)(229853001)(50466002)(189998001)(2351001)(5003940100001)(76176999)(107886002)(92566002)(81166005)(77096005)(2906002)(47776003)(110136002)(4001430100002)(66066001)(33646002); DIR:OUT; SFP:1101; SCL:1; SRVR:DM2PR0701MB1033; H:hp-mjc.semihalf.local; FPR:; SPF:None; MLV:sfv; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DM2PR0701MB1033; 23:OJuuO67+JCUy15gDdImepx8P8XX95g5VAUA1jpB?= =?us-ascii?Q?P/YnJYigkFsKMbvE/Cll/u31G/JEgiQUux+CkWrREdbFoFdjorErYF68X2D/?= =?us-ascii?Q?ol55wJvt3S5XvSbWATcM1F6bXNDmmbC6waTfV8qMrK0bKoSpUxcD4w9aZsly?= =?us-ascii?Q?DEuv8q/yU4fe3LlHZSXzTJDrJRCJuyjk51/StCPMZh9GEvxa3XuYJe7wUG2i?= =?us-ascii?Q?1R/PLQDNuRuyO39YKywtT1wFyCnf09YBTq4BBrVsAl4GP10VOsKYoGrYe0LB?= =?us-ascii?Q?eO8cQp2wMZ+IjAIY/x8RA8lb2x4jZgNgql2BTgu27EQA8J4ZX6VHcFAEN7mc?= =?us-ascii?Q?R0o3/a/+JlL3z9egPw15Z964AeMDcjGpX0TfDM1d6tvu63WeELPFKLGT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Fpq9j5EF8DCCneKfFNXWifAs6xZOS0=; 7:prZVpM3bd+uFuE9sfu0DGwG8FhdAGjYK358jZtMPF7+9nbq2IR/miNvuwSjKmQTAiOBC8RWB2FrNuCcvQ26gOFTamVMONdPyAmfV8KwBf4Z9aSvyX/tk7UCanyR8POrbwyoztWyUml8ecbp8M6lO7m/V+rYfjFAx3jx8VoKNeXSVQquhGYu91TTQ7uJwgc/6MJfcG/dM4mStoLBlO/VoX5o3x8pmQb7pYaGPK8lJmK4= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 22 Apr 2016 14:51:53.4952 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM2PR0701MB1033 Subject: [dpdk-dev] [PATCH v2 2/3] app/testpmd: extend port config with scatter parameter X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Apr 2016 14:51:57 -0000 From: Maciej Czekaj "port config all scatter on|off" allows for controlling rxmode.enable_scatter in command line. Signed-off-by: Maciej Czekaj --- app/test-pmd/cmdline.c | 17 +++++++++++++---- doc/guides/testpmd_app_ug/testpmd_funcs.rst | 11 +++++++++++ 2 files changed, 24 insertions(+), 4 deletions(-) diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c index c5b9479..929d19a 100644 --- a/app/test-pmd/cmdline.c +++ b/app/test-pmd/cmdline.c @@ -559,10 +559,10 @@ static void cmd_help_long_parsed(void *parsed_result, "port config all max-pkt-len (value)\n" " Set the max packet length.\n\n" - "port config all (crc-strip|rx-cksum|hw-vlan|hw-vlan-filter|" + "port config all (crc-strip|scatter|rx-cksum|hw-vlan|hw-vlan-filter|" "hw-vlan-strip|hw-vlan-extend|drop-en)" " (on|off)\n" - " Set crc-strip/rx-checksum/hardware-vlan/drop_en" + " Set crc-strip/scatter/rx-checksum/hardware-vlan/drop_en" " for ports.\n\n" "port config all rss (all|ip|tcp|udp|sctp|ether|none)\n" @@ -1410,6 +1410,15 @@ cmd_config_rx_mode_flag_parsed(void *parsed_result, printf("Unknown parameter\n"); return; } + } else if (!strcmp(res->name, "scatter")) { + if (!strcmp(res->value, "on")) + rx_mode.enable_scatter = 1; + else if (!strcmp(res->value, "off")) + rx_mode.enable_scatter = 0; + else { + printf("Unknown parameter\n"); + return; + } } else if (!strcmp(res->name, "rx-cksum")) { if (!strcmp(res->value, "on")) rx_mode.hw_ip_checksum = 1; @@ -1487,7 +1496,7 @@ cmdline_parse_token_string_t cmd_config_rx_mode_flag_all = TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, all, "all"); cmdline_parse_token_string_t cmd_config_rx_mode_flag_name = TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, name, - "crc-strip#rx-cksum#hw-vlan#" + "crc-strip#scatter#rx-cksum#hw-vlan#" "hw-vlan-filter#hw-vlan-strip#hw-vlan-extend"); cmdline_parse_token_string_t cmd_config_rx_mode_flag_value = TOKEN_STRING_INITIALIZER(struct cmd_config_rx_mode_flag, value, @@ -1496,7 +1505,7 @@ cmdline_parse_token_string_t cmd_config_rx_mode_flag_value = cmdline_parse_inst_t cmd_config_rx_mode_flag = { .f = cmd_config_rx_mode_flag_parsed, .data = NULL, - .help_str = "port config all crc-strip|rx-cksum|hw-vlan|" + .help_str = "port config all crc-strip|scatter|rx-cksum|hw-vlan|" "hw-vlan-filter|hw-vlan-strip|hw-vlan-extend on|off", .tokens = { (void *)&cmd_config_rx_mode_flag_port, diff --git a/doc/guides/testpmd_app_ug/testpmd_funcs.rst b/doc/guides/testpmd_app_ug/testpmd_funcs.rst index aed5e47..f2755cb 100644 --- a/doc/guides/testpmd_app_ug/testpmd_funcs.rst +++ b/doc/guides/testpmd_app_ug/testpmd_funcs.rst @@ -1187,6 +1187,17 @@ CRC stripping is off by default. The ``on`` option is equivalent to the ``--crc-strip`` command-line option. +port config - scatter +~~~~~~~~~~~~~~~~~~~~~~~ + +Set RX scatter mode on or off for all ports:: + + testpmd> port config all scatter (on|off) + +RX scatter mode is off by default. + +The ``on`` option is equivalent to the ``--enable-scatter`` command-line option. + port config - RX Checksum ~~~~~~~~~~~~~~~~~~~~~~~~~ -- 1.9.1