From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f173.google.com (mail-pf0-f173.google.com [209.85.192.173]) by dpdk.org (Postfix) with ESMTP id 241BE5961 for ; Sat, 9 Jan 2016 14:18:09 +0100 (CET) Received: by mail-pf0-f173.google.com with SMTP id q63so23166538pfb.1 for ; Sat, 09 Jan 2016 05:18:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mvista-com.20150623.gappssmtp.com; s=20150623; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=EwMfx42H42Gt7LxiVUNpyVBMVgpR+gkKmAfjWwprHJo=; b=VKwGSFosI/CGVs+eE7aesmbB7ZAaqNOAvFVFRl9oDMoPR6FFYa5hs+oLMqHQxPe1pG 969DyE36tBfsUOVaGLIDpiphvdWS3oqBTP9Rw/phFSf2Ojf0j6e66cf7+w7d+tj7g7EW lQqaOW9Ae+SmPVo8myPKcoYAvQONk4bLWZAN1NW2rYB/9bS4GjTcluKhKxFPSimpGzrq I1NL3OEgXimkVyXK9wsjq+VJ8H5J68FBqwA8q1K+KtnevSArXQCeIA6/95tbfGlFiGjz 2T0in12WoWxKD97Ow5X0xZOek0685DlmKqQ1gcHJhV56C7/QZXczSamY3UWVSkhlsy6Y 8dOQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type; bh=EwMfx42H42Gt7LxiVUNpyVBMVgpR+gkKmAfjWwprHJo=; b=M34vllEE85zpY+ycsbrjaaxjLlU6njHfhbLs0s5HEPv3dyqs9UvR2COkVW6MAzsmlX /FjWGemaNYux/BZFT9rZs9AYOV6oP1fpeypiJTbLhWacEcZxUOgl8qgDx7LcXmjYVmfK SEKqe7ase8S1DOkSPLtjfHRxR2fmj4hswNsdH2y7tE2SsjzAdtjyQUjYznOgU8jpa0Bd PFGLPCSi2AZYGlqF176OZzs/4rLHi5X7ThibcfSKvFbRlCa0Ua6w6ESp+BHBSGXbcT/R mDWGXLQwMwV1BFgsn4Z2+O81+d9tBF2oSs6FrvFZK+nRjWYET7yq70UZPigxsuf1CjZo XNKA== X-Gm-Message-State: ALoCoQlQHtDljbNN2FVLsmRRXTnxKlnY4Cb/wnW9jx/StDTpe13HMGseKcPqt6tUaFn1CAhbJ5x/Af2jmzAnuFe2NlkxYk/NVkoSNboPb/oJYCOHxWy8axE= MIME-Version: 1.0 X-Received: by 10.98.12.6 with SMTP id u6mr10402475pfi.155.1452345488465; Sat, 09 Jan 2016 05:18:08 -0800 (PST) Received: by 10.66.196.81 with HTTP; Sat, 9 Jan 2016 05:18:08 -0800 (PST) In-Reply-To: <20160107101407.54b18175@xeon-e3> References: <1452184390-5994-1-git-send-email-sshukla@mvista.com> <1452184390-5994-4-git-send-email-sshukla@mvista.com> <20160107101407.54b18175@xeon-e3> Date: Sat, 9 Jan 2016 18:48:08 +0530 Message-ID: From: Santosh Shukla To: Stephen Hemminger Content-Type: text/plain; charset=UTF-8 Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH v3 03/12] linuxapp: eal: arm: Always return 0 for rte_eal_iopl_init() 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: Sat, 09 Jan 2016 13:18:09 -0000 On Thu, Jan 7, 2016 at 11:44 PM, Stephen Hemminger wrote: > On Thu, 7 Jan 2016 22:03:00 +0530 > Santosh Shukla wrote: > >> #else >> +#if defined(RTE_ARCH_ARM) || defined(RTE_ARCH_ARM64) >> + return 0; /* iopl syscall not supported for ARM/ARM64 */ >> +#endif >> return -1; >> #endif > > Minor net why not: > > #elif defined(RTE_ARCH_ARM) || defined(RTE_ARCH_ARM64) > return -1 > #else > > That way you won't generate two return statements and potentially > trigger warnings from static checkers. returning -1 would fail for arm/arm64. I guess you meant return 0, right? if so then would need one more return for non-x86/non-arm case. Also I am working on another patchset suggested by Jerin [1] on iopl() in v2 series, That new patchset intended to get rid-off ifdef X_86 clutter for sys/io.h and more iop() definition to arch/platform file. I don't want to include those changes in v3 series as because it seems like two different topic. [1] http://dpdk.org/dev/patchwork/patch/9533/