From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pg0-f65.google.com (mail-pg0-f65.google.com [74.125.83.65]) by dpdk.org (Postfix) with ESMTP id 8C8111B65E for ; Fri, 10 Nov 2017 06:23:36 +0100 (CET) Received: by mail-pg0-f65.google.com with SMTP id p9so6615005pgc.8 for ; Thu, 09 Nov 2017 21:23:36 -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=Kk3PMTEWsNgaksaHsHizpi0R+X/GSP7iXpZRuUPWjXk=; b=C9As2pyqm3QVcfoqGfkJhWIx1yyd59cRW8QGsvluUQ0n8Kva8KuY21Me88BdWo+f0o pP/b35nJYtcDJXM8wjyMA1xuY4fLPmcUHxSIykruE1BXzSxQ8RGBBk0GZK4R2/LWfg+A FGCTbQxUnoTHfLW1LfHg7+OA57NnlKKle3spSbgE2Z1kPNBGHcH3pBQrWlITcqMqCtjg 5yp1TGFF5h7tjVEHoSSsTCUakf0qnqOzMrT6iy5UbgHndXj1VDnZMauCKlwSikeipaRs PiloHKfPg6Tuxs/jFl6rUNdF3fUzb/KMvf2i08z4fdglZvMmWrWq/dpvDxwWTguzc0Fp NChw== 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=Kk3PMTEWsNgaksaHsHizpi0R+X/GSP7iXpZRuUPWjXk=; b=qxjjRjDyhJZ4Qp/fhq9ol6nMBc3yAvnStmHcBunmfdsDGmxXJHFW49QDWauRS8zHko QHczEHUVvWmoKmP3K3zkWxDrHVDoAFIQPVGn9YzZ5jVTbZVHa3FHZdr0spVlCU9Qjhr8 fjKKRWCSMAiLe350rAcWnDB4D3zKcQ5pvI05Zrb0UAutaYY1B43dRc8/h4KX95kUFmmR zvk5BHNbkLHda/bD8cOj2OzJC5ZLhcEV6A7L5KBXeo9YCk6fVhG1mK97mJ+3wT7zmsWw 7kLKvjdkb3uCCRsTFiU0zm+D9PBksrFKO6HhWkqSLLxgjjqdK3yLnpEXgjjdEb2lx9Kd WrBQ== X-Gm-Message-State: AJaThX6Lfe275CHsNcwHoMHkUH1NFOS1BLzRTKzzDOEp96zr0MjWqEs7 SCZe3HBd1B6CbyuyB/H1r2JRqg== X-Google-Smtp-Source: ABhQp+Q0u9UaXtytRQj7u6R6RetjW+GS4aFfa0pmrJpuhzKFyz+w+qkrxixeM3mQyaK4tvGDF1iASA== X-Received: by 10.98.233.21 with SMTP id j21mr3006566pfh.97.1510291415857; Thu, 09 Nov 2017 21:23:35 -0800 (PST) Received: from nfv-demo01.hxtcorp.net ([38.106.11.25]) by smtp.gmail.com with ESMTPSA id y27sm16121568pfi.107.2017.11.09.21.23.29 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 09 Nov 2017 21:23:35 -0800 (PST) From: Jia He To: jerin.jacob@caviumnetworks.com, dev@dpdk.org, olivier.matz@6wind.com Cc: konstantin.ananyev@intel.com, bruce.richardson@intel.com, jianbo.liu@arm.com, hemant.agrawal@nxp.com, Jia He , Jia He Date: Fri, 10 Nov 2017 05:23:10 +0000 Message-Id: <1510291392-33251-2-git-send-email-hejianet@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1510291392-33251-1-git-send-email-hejianet@gmail.com> References: <1510278669-8489-1-git-send-email-hejianet@gmail.com> <1510291392-33251-1-git-send-email-hejianet@gmail.com> Subject: [dpdk-dev] [PATCH v5 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: Fri, 10 Nov 2017 05:23:37 -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/arm64: fix memory barrier definition") 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