From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pa0-f45.google.com (mail-pa0-f45.google.com [209.85.220.45]) by dpdk.org (Postfix) with ESMTP id C8E36C12C for ; Thu, 7 Jan 2016 19:46:53 +0100 (CET) Received: by mail-pa0-f45.google.com with SMTP id cy9so265054278pac.0 for ; Thu, 07 Jan 2016 10:46:53 -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=AYveKG381+KRNFWcSBqUk4rOTktWb764z/wTMuAvT80=; b=azZVtLgTOunQ4r/eOBaKhB1MC1MbLLu1CjRGDDajIhV6WRcZJ0uHJBTWlv0c3ymGLr rFA5VGGer33B/hrtUVaA1WUEVYTXfW49jrFaAg/rcH66zLb5KCTCpQxbKm557ZBNC+GX lcAAw6542ecaOzDZf/w1l//zZVw9n0uC0UHCwDEUeiUVu/n83i0db2tcUsj66nj5dxxp g+j67YlGLk+tBxGDJ94ToWDk4NS69HesFvbeE4zGyE2gt8F5Ds1GAb55Tvn21y3q8q47 O03CU9vQESBprT0lv26r8CqHXiiO+mijfmdUp6yZtDh1n6RVY0kJf4FDRyHoR0DZF/N8 9Epw== 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=AYveKG381+KRNFWcSBqUk4rOTktWb764z/wTMuAvT80=; b=GokI8DER/bn6s8nJqw3c0SAD/tyX9VhbC8vvqLhTIlAMUK0FPdENVpxZZYmKkZjTaU A44oxNrrqE2WXm2kcz6AWyX4FarubEq3Z7U+5R/YB4Y/gsUa+AtAACcdOlFz65B14dsf zmZYRTtkt/U81odT2a4rVlpTGjI6vlJ/1FUdRrIxpe4hR5QLODKtattxZWcHcRUrQbaq jvcWF7ZJJImIbvjDMnRq2hQAOH6gQL2vwQva76Emqc5RanqPphKj2hTgG/jJJ37e+41H MAZlpnY2F93y/ixzgexRMEOS6z6yj0FKsplNtuvir3hL0M2a7rGwpZ8+tctjyaXkN+/e 18gg== X-Gm-Message-State: ALoCoQlxeF1AhWOBgKLPJhHaz8X0Yc1CPeOOSHQya5nu/xVk4wOMW7iAE7/i7lmblnZ13Vn6y902eyLi1YYog/33Qu+8htW4RBxoh2SVDqlWpBH9cWMKEww= MIME-Version: 1.0 X-Received: by 10.66.240.97 with SMTP id vz1mr153063008pac.29.1452192413165; Thu, 07 Jan 2016 10:46:53 -0800 (PST) Received: by 10.66.196.81 with HTTP; Thu, 7 Jan 2016 10:46:53 -0800 (PST) In-Reply-To: <20160107101925.293062ad@xeon-e3> References: <1452184390-5994-1-git-send-email-sshukla@mvista.com> <1452184390-5994-7-git-send-email-sshukla@mvista.com> <20160107101925.293062ad@xeon-e3> Date: Fri, 8 Jan 2016 00:16:53 +0530 Message-ID: From: Santosh Shukla To: Stephen Hemminger Content-Type: text/plain; charset=UTF-8 X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Cc: dev@dpdk.org Subject: Re: [dpdk-dev] [PATCH v3 06/12] eal: pci: vfio: add rd/wr func for pci bar space 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, 07 Jan 2016 18:46:54 -0000 On Thu, Jan 7, 2016 at 11:49 PM, Stephen Hemminger < stephen@networkplumber.org> wrote: > On Thu, 7 Jan 2016 22:03:03 +0530 > Santosh Shukla wrote: > > > > > +int rte_eal_pci_read_bar(const struct rte_pci_device *device > __rte_unused, > > + void *buf __rte_unused, > > + size_t len __rte_unused, > > + off_t offset __rte_unused, > > + int bar_idx __rte_unused) > > +{ > > +#ifdef VFIO_PRESENT > > + const struct rte_intr_handle *intr_handle = &device->intr_handle; > > + return pci_vfio_read_bar(intr_handle, buf, len, offset, bar_idx); > > +#else > > + return 0; /* UIO's not applicable */ > > +#endif > > +} > > It seems wrong to declare all the parameters as unused but then use them. > Maybe there is a way to have a macro for USED(x) in the #else case > Yes, I followed such practice in v2 series but missed on v3, Sorry for that and we'll take care in v4.