From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f195.google.com (mail-pf0-f195.google.com [209.85.192.195]) by dpdk.org (Postfix) with ESMTP id 125913195; Mon, 27 Nov 2017 03:00:57 +0100 (CET) Received: by mail-pf0-f195.google.com with SMTP id 17so16674914pfn.12; Sun, 26 Nov 2017 18:00:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=j75ieAIQogopUkFlC/XflOEm5PkiVPWR+UfgIL4j7I8=; b=NzTHBD0H/qzT9/fdVpPht2wbiAtimMixTdi0Iha/R3pWKJ2D/hb7noVicbe5LnKJcO UFeADZZpnK5FmoywzY+nBeteWBigXaRgnwo8gLTE0wbPDuITi6P8XY6yzJoetSD0fwHt RzAYTL//jpdoXa4Y157VzYMQWn5CpbLCCT7IF9bq+JAuc7tqTlGqMadZ+8Q7QHhARNow 3Cvd+h1D185qBWsV9SJbC9m9be+OPgB+cPS4D/Lg2ox6wSi6e4IiYqMM+iO2MnVwUBjU l86FOz66IcALisQn+Qd54iq8Xv2+hrXRcZc9xpj/HV1MDuGDpyjJUch6apRxoG2jYGYj phtA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=j75ieAIQogopUkFlC/XflOEm5PkiVPWR+UfgIL4j7I8=; b=boYJzPydSluCz47qo6smi+C6Cms/3Ltx4jf5NO5+aePWsfcLgqevEBKE6caetjCByL BKropLkoumfByh/Rd2ufYewE5TjsA73TdeaaV3dQFz3T3F1aGnZrVqIWYant+m6FXmZH 9EP7mKaPx7M0/3U7HPw+Kl+fDpF+5+GjJdduc07AOxzyifXuDk1srNyxXm0qgB1Bgmty ddcX0lfiuUKdxCrEqGxucvOxiXwsMNiPFTQPWln9wnXY0uarF7A3eTkXLagpWISd8gCx t/exB24///zTVd7/NFvmWR4dcMbIG6thzjAM8Us8+7cYhVuxo94leJs5lv60trATxTkI VGxA== X-Gm-Message-State: AJaThX637dX6UiV86K+NYVO+ImXeV43JW2k2cfuh8urWbpLk0HAkQdin JZY+QXdowcyPS1uei/6GvAA= X-Google-Smtp-Source: AGs4zMZLWTesr9yXHlf3/TR3ANzPs1AjH4f4hgVCIZhRpYI/0qKt5fxg7qiH1oSiz2HLVwKkIfsayg== X-Received: by 10.99.5.200 with SMTP id 191mr35603604pgf.450.1511748056365; Sun, 26 Nov 2017 18:00:56 -0800 (PST) Received: from localhost.localdomain ([38.106.11.25]) by smtp.gmail.com with ESMTPSA id a87sm48926743pfg.159.2017.11.26.18.00.50 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Sun, 26 Nov 2017 18:00:55 -0800 (PST) From: Jia He To: jerin.jacob@caviumnetworks.com, dev@dpdk.org, bruce.richardson@intel.com, konstantin.ananyev@intel.com Cc: olivier.matz@6wind.com, jianbo.liu@arm.com, hemant.agrawal@nxp.com, Jia He , stable@dpdk.org, Jia He Date: Sun, 26 Nov 2017 18:00:22 -0800 Message-Id: <1511748024-7245-2-git-send-email-hejianet@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1511748024-7245-1-git-send-email-hejianet@gmail.com> References: <1510291392-33251-1-git-send-email-hejianet@gmail.com> <1511748024-7245-1-git-send-email-hejianet@gmail.com> Subject: [dpdk-dev] [PATCH V6 1/3] eal/arm64: remove the braces {} for dmb() and dsb() X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 27 Nov 2017 02:00:57 -0000 for the code as follows: if (condition) rte_smp_rmb(); else rte_smp_wmb(); Without this patch, compiler will report this error: error: 'else' without a previous 'if' Fixes: 84733fd0d75e ("eal/arm: fix memory barrier definition") Cc: stable@dpdk.org Signed-off-by: Jia He --- lib/librte_eal/common/include/arch/arm/rte_atomic_64.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/librte_eal/common/include/arch/arm/rte_atomic_64.h b/lib/librte_eal/common/include/arch/arm/rte_atomic_64.h index 0b70d62..71da29c 100644 --- a/lib/librte_eal/common/include/arch/arm/rte_atomic_64.h +++ b/lib/librte_eal/common/include/arch/arm/rte_atomic_64.h @@ -43,8 +43,8 @@ extern "C" { #include "generic/rte_atomic.h" -#define dsb(opt) { asm volatile("dsb " #opt : : : "memory"); } -#define dmb(opt) { asm volatile("dmb " #opt : : : "memory"); } +#define dsb(opt) asm volatile("dsb " #opt : : : "memory") +#define dmb(opt) asm volatile("dmb " #opt : : : "memory") #define rte_mb() dsb(sy) -- 2.7.4