From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id AACFA559A for ; Wed, 1 Mar 2017 15:50:29 +0100 (CET) Received: from fmsmga006.fm.intel.com ([10.253.24.20]) by orsmga105.jf.intel.com with ESMTP; 01 Mar 2017 06:50:24 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.35,226,1484035200"; d="scan'208";a="71554804" Received: from dhunt5-mobl.ger.corp.intel.com (HELO [10.237.221.69]) ([10.237.221.69]) by fmsmga006.fm.intel.com with ESMTP; 01 Mar 2017 06:50:23 -0800 To: dev@dpdk.org References: <1487647073-129064-2-git-send-email-david.hunt@intel.com> <1488354455-142764-1-git-send-email-david.hunt@intel.com> <1488354455-142764-10-git-send-email-david.hunt@intel.com> Cc: bruce.richardson@intel.com From: "Hunt, David" Message-ID: Date: Wed, 1 Mar 2017 14:50:22 +0000 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.7.1 MIME-Version: 1.0 In-Reply-To: <1488354455-142764-10-git-send-email-david.hunt@intel.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v8 09/18] lib: add symbol versioning to distributor 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: Wed, 01 Mar 2017 14:50:31 -0000 ERROR:SPACING: space prohibited before that ',' (ctx:WxW) #84: FILE: lib/librte_distributor/rte_distributor.c:172: +BIND_DEFAULT_SYMBOL(rte_distributor_get_pkt, , 17.05); ^ FYI, checkpatch does not like this regardless of whether there's a space there or not. It complains either way. :) Regards, Dave. On 1/3/2017 7:47 AM, David Hunt wrote: > Also bumped up the ABI version number in the Makefile > > Signed-off-by: David Hunt > --- > lib/librte_distributor/Makefile | 2 +- > lib/librte_distributor/rte_distributor.c | 8 ++++++++ > lib/librte_distributor/rte_distributor_v20.c | 10 ++++++++++ > lib/librte_distributor/rte_distributor_version.map | 14 ++++++++++++++ > 4 files changed, 33 insertions(+), 1 deletion(-) > > diff --git a/lib/librte_distributor/Makefile b/lib/librte_distributor/Makefile > index 2b28eff..2f05cf3 100644 > --- a/lib/librte_distributor/Makefile > +++ b/lib/librte_distributor/Makefile > @@ -39,7 +39,7 @@ CFLAGS += $(WERROR_FLAGS) -I$(SRCDIR) > > EXPORT_MAP := rte_distributor_version.map > > -LIBABIVER := 1 > +LIBABIVER := 2 > > # all source are stored in SRCS-y > SRCS-$(CONFIG_RTE_LIBRTE_DISTRIBUTOR) := rte_distributor_v20.c > diff --git a/lib/librte_distributor/rte_distributor.c b/lib/librte_distributor/rte_distributor.c > index 6e1debf..2c5511d 100644 > --- a/lib/librte_distributor/rte_distributor.c > +++ b/lib/librte_distributor/rte_distributor.c > @@ -36,6 +36,7 @@ > #include > #include > #include > +#include > #include > #include > #include > @@ -168,6 +169,7 @@ rte_distributor_get_pkt(struct rte_distributor *d, > } > return count; > } > +BIND_DEFAULT_SYMBOL(rte_distributor_get_pkt, , 17.05); > > int > rte_distributor_return_pkt(struct rte_distributor *d, > @@ -197,6 +199,7 @@ rte_distributor_return_pkt(struct rte_distributor *d, > > return 0; > } > +BIND_DEFAULT_SYMBOL(rte_distributor_return_pkt, , 17.05); > > /**** APIs called on distributor core ***/ > > @@ -476,6 +479,7 @@ rte_distributor_process(struct rte_distributor *d, > > return num_mbufs; > } > +BIND_DEFAULT_SYMBOL(rte_distributor_process, , 17.05); > > /* return to the caller, packets returned from workers */ > int > @@ -504,6 +508,7 @@ rte_distributor_returned_pkts(struct rte_distributor *d, > > return retval; > } > +BIND_DEFAULT_SYMBOL(rte_distributor_returned_pkts, , 17.05); > > /* > * Return the number of packets in-flight in a distributor, i.e. packets > @@ -549,6 +554,7 @@ rte_distributor_flush(struct rte_distributor *d) > > return flushed; > } > +BIND_DEFAULT_SYMBOL(rte_distributor_flush, , 17.05); > > /* clears the internal returns array in the distributor */ > void > @@ -565,6 +571,7 @@ rte_distributor_clear_returns(struct rte_distributor *d) > for (wkr = 0; wkr < d->num_workers; wkr++) > d->bufs[wkr].retptr64[0] = 0; > } > +BIND_DEFAULT_SYMBOL(rte_distributor_clear_returns, , 17.05); > > /* creates a distributor instance */ > struct rte_distributor * > @@ -638,3 +645,4 @@ rte_distributor_create(const char *name, > > return d; > } > +BIND_DEFAULT_SYMBOL(rte_distributor_create, , 17.05); > diff --git a/lib/librte_distributor/rte_distributor_v20.c b/lib/librte_distributor/rte_distributor_v20.c > index 1f406c5..bb6c5d7 100644 > --- a/lib/librte_distributor/rte_distributor_v20.c > +++ b/lib/librte_distributor/rte_distributor_v20.c > @@ -38,6 +38,7 @@ > #include > #include > #include > +#include > #include > #include > #include "rte_distributor_v20.h" > @@ -63,6 +64,7 @@ rte_distributor_request_pkt_v20(struct rte_distributor_v20 *d, > rte_pause(); > buf->bufptr64 = req; > } > +VERSION_SYMBOL(rte_distributor_request_pkt, _v20, 2.0); > > struct rte_mbuf * > rte_distributor_poll_pkt_v20(struct rte_distributor_v20 *d, > @@ -76,6 +78,7 @@ rte_distributor_poll_pkt_v20(struct rte_distributor_v20 *d, > int64_t ret = buf->bufptr64 >> RTE_DISTRIB_FLAG_BITS; > return (struct rte_mbuf *)((uintptr_t)ret); > } > +VERSION_SYMBOL(rte_distributor_poll_pkt, _v20, 2.0); > > struct rte_mbuf * > rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d, > @@ -87,6 +90,7 @@ rte_distributor_get_pkt_v20(struct rte_distributor_v20 *d, > rte_pause(); > return ret; > } > +VERSION_SYMBOL(rte_distributor_get_pkt, _v20, 2.0); > > int > rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d, > @@ -98,6 +102,7 @@ rte_distributor_return_pkt_v20(struct rte_distributor_v20 *d, > buf->bufptr64 = req; > return 0; > } > +VERSION_SYMBOL(rte_distributor_return_pkt, _v20, 2.0); > > /**** APIs called on distributor core ***/ > > @@ -314,6 +319,7 @@ rte_distributor_process_v20(struct rte_distributor_v20 *d, > d->returns.count = ret_count; > return num_mbufs; > } > +VERSION_SYMBOL(rte_distributor_process, _v20, 2.0); > > /* return to the caller, packets returned from workers */ > int > @@ -334,6 +340,7 @@ rte_distributor_returned_pkts_v20(struct rte_distributor_v20 *d, > > return retval; > } > +VERSION_SYMBOL(rte_distributor_returned_pkts, _v20, 2.0); > > /* return the number of packets in-flight in a distributor, i.e. packets > * being workered on or queued up in a backlog. */ > @@ -362,6 +369,7 @@ rte_distributor_flush_v20(struct rte_distributor_v20 *d) > > return flushed; > } > +VERSION_SYMBOL(rte_distributor_flush, _v20, 2.0); > > /* clears the internal returns array in the distributor */ > void > @@ -372,6 +380,7 @@ rte_distributor_clear_returns_v20(struct rte_distributor_v20 *d) > memset(d->returns.mbufs, 0, sizeof(d->returns.mbufs)); > #endif > } > +VERSION_SYMBOL(rte_distributor_clear_returns, _v20, 2.0); > > /* creates a distributor instance */ > struct rte_distributor_v20 * > @@ -415,3 +424,4 @@ rte_distributor_create_v20(const char *name, > > return d; > } > +VERSION_SYMBOL(rte_distributor_create, _v20, 2.0); > diff --git a/lib/librte_distributor/rte_distributor_version.map b/lib/librte_distributor/rte_distributor_version.map > index 73fdc43..3a285b3 100644 > --- a/lib/librte_distributor/rte_distributor_version.map > +++ b/lib/librte_distributor/rte_distributor_version.map > @@ -13,3 +13,17 @@ DPDK_2.0 { > > local: *; > }; > + > +DPDK_17.05 { > + global: > + > + rte_distributor_clear_returns; > + rte_distributor_create; > + rte_distributor_flush; > + rte_distributor_get_pkt; > + rte_distributor_poll_pkt; > + rte_distributor_process; > + rte_distributor_request_pkt; > + rte_distributor_return_pkt; > + rte_distributor_returned_pkts; > +} DPDK_2.0;