From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from out4-smtp.messagingengine.com (out4-smtp.messagingengine.com [66.111.4.28]) by dpdk.org (Postfix) with ESMTP id 0F0D81E34; Sun, 7 May 2017 14:14:52 +0200 (CEST) Received: from compute1.internal (compute1.nyi.internal [10.202.2.41]) by mailout.nyi.internal (Postfix) with ESMTP id 8266A208BD; Sun, 7 May 2017 08:14:52 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute1.internal (MEProxy); Sun, 07 May 2017 08:14:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=monjalon.net; h= cc:content-transfer-encoding:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc:x-sasl-enc; s=mesmtp; bh=KNWxcD3QPqVlOYV k8mMjGPgxK6CrKTO6TUxo1HX6Dw8=; b=TseTVzAV8g8U6P20Q1UC39hUoeVO5HY VDxEQR8uE0VWiruMyAeBC5gVRL6l8m4DklyDzHe6HT9cs3b8gnp4tpuvEFR7scrR k5HQHAkEPT4Gf93n2zoMiqkEBCPoIgJ0/mQoHiobG6Cj59azLHhSpsj6DeeRGBOG V5pJmx8Vd958= DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc:x-sasl-enc; s= fm1; bh=KNWxcD3QPqVlOYVk8mMjGPgxK6CrKTO6TUxo1HX6Dw8=; b=IYHn2x8i yAfmXr5AZ2Gd2hn9Bl/A2w63/vrg1QYvc/CZhy3BN8lIu2Nqo0z/vpimHBa332yp pMaHhknBBf7TSjRWdI4IMEVdsiG8hTp7TCVlC6nAsgJy20S80RrJ43niIO0ZlEKJ Widd839KDpdGU2yVkXHEbHOBu0t22ESz259Gus4+PXQ3ilAfWSedhBtEUDJYnpFk BROcrZJAwUKtnxFBu/LwGfh4voHKwu2RX1VodfQ2IgAAVOjzf1sdu+pNNRnga06Q MbvGVnynlOrOnxkcvu1RT9b5to0/5Yeeaf+yoQ68S24Eo9aMT7o2jjTwN8iwXDrI kE2V3OzgX07jmQ== X-ME-Sender: X-Sasl-enc: liMmVDNa43TKw0tRD7MtJ8vWFgGTuDLssSLs1iur58WR 1494159292 Received: from xps.localnet (184.203.134.77.rev.sfr.net [77.134.203.184]) by mail.messagingengine.com (Postfix) with ESMTPA id 42E362418B; Sun, 7 May 2017 08:14:52 -0400 (EDT) From: Thomas Monjalon To: Shahaf Shuler Cc: dev@dpdk.org, jingjing.wu@intel.com, stable@dpdk.org Date: Sun, 07 May 2017 14:14:49 +0200 Message-ID: <213478826.uc3EAffF5t@xps> In-Reply-To: <20170503134429.22723-1-shahafs@mellanox.com> References: <20170503134429.22723-1-shahafs@mellanox.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH v2] app/testpmd: support non contiguous socket ids X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 May 2017 12:14:53 -0000 03/05/2017 15:44, Shahaf Shuler: > + printf("Invalid socket id, options are: "); > + for (i = 0; i < num_sockets; i++) { > + printf("%u%s", socket_ids[i], > + (i == num_sockets - 1) ? "\n" : ","); [...] > + printf("Invalid socket id, options are: "); > + for (i = 0; i < num_sockets; i++) { > + printf("%u%s", socket_ids[i], > + (i == num_sockets - 1) ? "\n" : ","); [...] > + printf("socket id options are: "); > + for (i = 0; i < num_sockets; i++) { > + printf("%u%s", socket_ids[i], > + (i == num_sockets - 1) ? > + "\n" : ","); It is three times the same copy pasted code. Please make a function.