From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from emea01-am1-obe.outbound.protection.outlook.com (mail-am1on0066.outbound.protection.outlook.com [157.56.112.66]) by dpdk.org (Postfix) with ESMTP id EAC935A8C for ; Thu, 9 Jul 2015 10:25:56 +0200 (CEST) Received: from AM2PR02CA0013.eurprd02.prod.outlook.com (10.160.28.151) by VI1PR02MB0815.eurprd02.prod.outlook.com (10.162.14.152) with Microsoft SMTP Server (TLS) id 15.1.207.19; Thu, 9 Jul 2015 08:25:55 +0000 Received: from DB3FFO11FD055.protection.gbl (2a01:111:f400:7e04::188) by AM2PR02CA0013.outlook.office365.com (2a01:111:e400:8400::23) with Microsoft SMTP Server (TLS) id 15.1.213.14 via Frontend Transport; Thu, 9 Jul 2015 08:25:54 +0000 Authentication-Results: spf=fail (sender IP is 124.207.145.166) smtp.mailfrom=ezchip.com; ezchip.com; dkim=none (message not signed) header.d=none; Received-SPF: Fail (protection.outlook.com: domain of ezchip.com does not designate 124.207.145.166 as permitted sender) receiver=protection.outlook.com; client-ip=124.207.145.166; helo=bjgfarm-1.internal.tilera.com; Received: from bjgfarm-1.internal.tilera.com (124.207.145.166) by DB3FFO11FD055.mail.protection.outlook.com (10.47.217.127) with Microsoft SMTP Server (TLS) id 15.1.213.8 via Frontend Transport; Thu, 9 Jul 2015 08:25:53 +0000 Received: (from zlu@localhost) by bjgfarm-1.internal.tilera.com (8.14.4/8.14.4/Submit) id t698PnoG003917; Thu, 9 Jul 2015 16:25:49 +0800 From: Zhigang Lu To: Date: Thu, 9 Jul 2015 16:25:11 +0800 Message-ID: <1436430321-3864-3-git-send-email-zlu@ezchip.com> X-Mailer: git-send-email 2.1.2 In-Reply-To: <1436430321-3864-1-git-send-email-zlu@ezchip.com> References: <1436430321-3864-1-git-send-email-zlu@ezchip.com> X-EOPAttributedMessage: 0 X-Microsoft-Exchange-Diagnostics: 1; DB3FFO11FD055; 1:/+BGyirlFW4GTndOAYLirWxn97qMYR3u6gA+bJ49biKKZxrS4LZx7PuorXx3xHhiQeyWrXEOLhGDD2sDx0H9Dtt0M+f1LL/57E4gSlBC5msMkMg9vDLaIChTMd1w/y9gvNRG5HHxn+z0w9+ulvzlzAnTUxC6rC7rB1lbbgUkda9rW2DxI98BdHKeAo6SeqsjU8d/2Gm8QDJsMrg7z7oD/itmGCRetjwRCRBtH7przOr73turmJDD13U9+dlcNEwJkH20OdUXhqPQR3pHikBOXO/DOTlxmUwimXIh1m2BRXjrxHp8KVDMe4RTaMaSXpo7JZSNb55NUZUZ39n3ZXdotXSxkoWXsOsIzGfqaF0HxZpYNuoBGU775W7LnoKo5RiCUxczhUQJyQn0FtdXecgiqQco/AulEUq4/Iy5xXtbn/wiP4Bc30SHYIeWCiWYcG9M X-Forefront-Antispam-Report: CIP:124.207.145.166; CTRY:CN; IPV:NLI; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(2980300002)(339900001)(189002)(199003)(6806004)(76176999)(110136002)(2950100001)(5001960100002)(86362001)(106466001)(189998001)(19580395003)(87936001)(107886002)(50226001)(92566002)(47776003)(42186005)(33646002)(50986999)(104016003)(77156002)(46102003)(62966003)(450100001)(85426001)(36756003)(229853001)(2351001)(105606002)(19580405001)(50466002)(48376002)(5003940100001)(4001430100001); DIR:OUT; SFP:1101; SCL:1; SRVR:VI1PR02MB0815; H:bjgfarm-1.internal.tilera.com; FPR:; SPF:Fail; MLV:sfv; MX:1; A:1; LANG:en; MIME-Version: 1.0 Content-Type: text/plain X-Microsoft-Exchange-Diagnostics: 1; VI1PR02MB0815; 2:xV3n8G09j+k/JKl5S9y+xnYAFPyXn/jVbTUac2vwmqmjhO1CoedC2aksIen3562N; 3:bkKnORZ8cKFF0ZHuoSSk8HrsKunz7bArM98L1b2MliF2aOIOulzYoK5z9qJyA7b9obzuldRqhfHdQxS4Do49cdA4/uSgt9wxHcPi/Q8iBWX/gWA7DMr5hSsYdNIZxpkDa2P7DMl5ujeDJF2w1UgLYTFUXoZ71JxRh+SLV3/SSN6M4KoMdMqrwscp1Hmg8GVlLkRlhEYVpQ1X19rv55BQq4NDY9JHmXt+QCvxOYt0V0Kbw7eMOrgYtz2HUk9vLG1b; 25:2Mp91Gt/Od2Q6wUN9hXrAULunpVFrEOCJpSY+DxQ31dEar1Q4+QFUtwgJp1W71uRkbw9NxdwNCtBJUFxbfaypBtBMGQ0/DtPgbsmHuf8JvRUclZ55ApTwzebjh7jCkxRpjuQSFoCgl5F/Eh7MwtXpx2hB3aac4dDDGZVRzKIahs0uqtLhugZJWiLU8RStwCzI4cxltv5R8UI3P4YUCyX6oWGQxut2nYP4FEs8/WmqtoYs9SVc6hO/8OhN3quMqQDNIYVRnl06bCAbU8Vvpv32w==; 20:mKNGjPWgLwCUEnDP6gNaIOqTrTSLOEhYtu1q1kgJv1rnsiL6H2w5jnH8oStjdzVsa51Tk0r1JICqBpDrepj8Fw6qxeDYgvM7QxmPrjJw7B9N2r9AQ4wfVqh/XJJwFXPcWQknR/6s1/4h4/97dnN8p86ACCwPY+spjG7VmgKgx3g= X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:VI1PR02MB0815; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(601004)(5005006)(3002001); SRVR:VI1PR02MB0815; BCL:0; PCL:0; RULEID:; SRVR:VI1PR02MB0815; X-Microsoft-Exchange-Diagnostics: 1; VI1PR02MB0815; 4:QonwR8xSbOjJ1NlBGVbQKx744OVEEd454klEV0F7A7zD9QMdj3/LkFZjavqDzAzwH1/G0W9kLRIR54BPj/YKB7X057FDSJ5s+A1JD2aHjdYY67iKz0+tPJmng5nBLoSqNYCDEH6vSF61aouWSmJouR/ktIGbhh22v4J/nP9GwU2ndPDXW4B0sjjy+5iPP9rVzlQ6grNB4Q4r8UhMLbkeWECqlgZaO0Bhrc3q6HU8FfDeYnvbW9/ox8ViwuWgD+H6tYbbbAdHfyOrMRSAB5fOGplqC+5uMTZrwJaauq/1sPM= X-Forefront-PRVS: 0632519F33 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; VI1PR02MB0815; 23:u4FgU4qPDa2LT8jqDDqC5M6KndfFOWDmIeSF8KhW7?= =?us-ascii?Q?4U5vqp4WAjSvPp8Gt4PXTjN3QpEg7Ub3yBiZY7SgqaZzxk4ulHKdLVX9i4H+?= =?us-ascii?Q?aDEDI76FBdFf9ruhYWDwKdW9W4ws0N0h8ptZQHjwYzRno0eXreZEMXPKn8br?= =?us-ascii?Q?6tKa9cWk9uRP2e1/MD1HGYYIEnPMegH69xMdY9mrjnL9KrS/fw6XkleDuxfB?= =?us-ascii?Q?rhhyyO5ag3J6BX0i0YVZn9qGVP2VmPHxMlP1q9bM9JZx5/yzdavMnPkO8X10?= =?us-ascii?Q?MmoPWMTcxSc2Z8FBAFExcPRJI08tS1f67S9cT8/7xpdkRuxrFHvqKYIG3L96?= =?us-ascii?Q?Fg18zgPi0eNoNUsvNI1jejG6EpwLEZU94Lf/BFmpV8kvddk0fG0yoAVJYR4Z?= =?us-ascii?Q?xx2exDb8J7Rpf90V7z4TtJ/d4o+QAHnXmb2yFevjQW5XjCtBdvY+oqm8yGYV?= =?us-ascii?Q?iw+NfvT9gZrMn529U26dBhSoGL5Mwld4L0L3ROCwEA+TLZQwfbzzcHhpP73y?= =?us-ascii?Q?txUQrA7mk+fnkpWdA6TIONvj3liB3+9by8OTgGo13M3L/tE1wf3e/ao2r4Oz?= =?us-ascii?Q?kEp5lMrMastp0pqptQj1tzrlztotU1eJb1mkWZowrPGod2q5Jwla+2p9RqLw?= =?us-ascii?Q?Ot6+B6hPYWZGvkDSOyRRxG5ysM1fxbMytegAYBjAu9JY6Gfrjbb80jk1kREZ?= =?us-ascii?Q?EXaHk4KFUubLZi11EpM9A0Ubys52k4jZKGSwCfHZMCgs117wgO76z8hTvJpL?= =?us-ascii?Q?4fpmOg0rGc4cphwwHKWgQ59Rdaw48QjNuYVLI1bgAn4ikpDxAApknbKcSYZb?= =?us-ascii?Q?Qjgh92A4Yzf/BelkXsox/yARow7cvL1qDOvsgPZYWx69XxIhvNuwhs2ZLC4d?= =?us-ascii?Q?ZUNEWyaHS88BF+940Kvf0qLLT+EUIXS8WBpvG4FRW1QuwYq0wrtFYneQQGfo?= =?us-ascii?Q?EJknU3LkPOu4Ouohtg10bd1CWiPELJ9b/FmRnypTNUdYNg2oq2RGhx4VF9wt?= =?us-ascii?Q?ck=3D?= X-Microsoft-Exchange-Diagnostics: 1; VI1PR02MB0815; 5:3gKkHkzvK5CyW5FjpjfOaUosIb9xxTe2vuFU4xm1aouwli7rMa063uYUlJcg1IAQg0eAcZnsGSbWxXF8ZEdOKLp1Kfelb6rU0XKatIUxLSOOX2J/+x2/pB0kNZbt8k/J9A/7LP1SlYLxUJSNJQ2yow==; 24:dIJDxBeL0gaJjztRNM4yzFyc5QF1R6KLFehKBFe7vmQVU9Oqz6OzEsJfN0srcXNb2m68iLsQ7q2StckUiaWZYnql52M732UN74RKo4zjBDg=; 20:NbuT9JoQh6PhtIOToKcz2OHTw1h1okXwe9uwfyMiYqImfVZcyuPdRUKuCnZKbKdwDsaL3eKnKf87nZFJK+jmUw== SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: ezchip.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 09 Jul 2015 08:25:53.4657 (UTC) X-MS-Exchange-CrossTenant-Id: 0fc16e0a-3cd3-4092-8b2f-0a42cff122c3 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=0fc16e0a-3cd3-4092-8b2f-0a42cff122c3; Ip=[124.207.145.166]; Helo=[bjgfarm-1.internal.tilera.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: VI1PR02MB0815 Cc: Cyril Chemparathy Subject: [dpdk-dev] [PATCH v5 02/11] hash: check SSE flags only on x86 builds 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: Thu, 09 Jul 2015 08:25:57 -0000 From: Cyril Chemparathy This is necessary because the required CPU flags may not be defined on other architectures. Signed-off-by: Cyril Chemparathy Signed-off-by: Zhigang Lu Acked-by: Bruce Richardson --- lib/librte_hash/rte_hash_crc.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/librte_hash/rte_hash_crc.h b/lib/librte_hash/rte_hash_crc.h index abdbd9a..1f6f5bf 100644 --- a/lib/librte_hash/rte_hash_crc.h +++ b/lib/librte_hash/rte_hash_crc.h @@ -425,12 +425,14 @@ static inline void rte_hash_crc_set_alg(uint8_t alg) { switch (alg) { +#if defined(RTE_ARCH_I686) || defined(RTE_ARCH_X86_64) case CRC32_SSE42_x64: if (! rte_cpu_get_flag_enabled(RTE_CPUFLAG_EM64T)) alg = CRC32_SSE42; case CRC32_SSE42: if (! rte_cpu_get_flag_enabled(RTE_CPUFLAG_SSE4_2)) alg = CRC32_SW; +#endif case CRC32_SW: crc32_alg = alg; default: -- 2.1.2