From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f47.google.com (mail-wm0-f47.google.com [74.125.82.47]) by dpdk.org (Postfix) with ESMTP id 5930B8D38 for ; Sat, 21 Nov 2015 11:45:36 +0100 (CET) Received: by wmvv187 with SMTP id v187so102960221wmv.1 for ; Sat, 21 Nov 2015 02:45:36 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:organization:user-agent :in-reply-to:references:mime-version:content-transfer-encoding :content-type; bh=6+gzfyZugbX8dNZKjzyzEPXSA8xuA77B/sKV+ALdFvQ=; b=Ojt4CIvfJYysSWhy+XMCnJwMMkYxsoNAG8ee/bXw5CXtwhV1IPYi1JzeW/vcr71S3/ tTpTuxsK5wLjhbxzOuda89FPaAfBxS/7R5LnjPL52fEmKWxB8uxe+0CfEK/LzcpKGvKe KuhBKrwjiDkl6/QzxbrLfwqApGJ8FUbUlkB0yxLtJm5UdHibSWQJ0jSWDIZtlEee9E00 AfK+pYWMd+eRW/nU84RyGSsmHfO/aC8qMWsntympt1Tfzsz4mCMGiw5diJDbZQHGpRhX AwCwby55k8XCMdl+qOwClM0Eh/XdRmti0+G0nMvc0FuuigsZeR3ciDvQoqQGJ7hkohsi Wy4w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:organization :user-agent:in-reply-to:references:mime-version :content-transfer-encoding:content-type; bh=6+gzfyZugbX8dNZKjzyzEPXSA8xuA77B/sKV+ALdFvQ=; b=KmpPcKx57NkBP5s8koYL1SV/Svp2RYoLvsP08wAnYHVl8c66/0Kb9hbcprnV7VK3KE 47+MKD5piW7LTBxgRWbnSxq7N9377q4ZwgfZxcYzDL/9e9Z56qpIJREMFYza5DGLA1Xr zY/MB3ewprUyPUY54+qDjZx9sBEP3BqBJXmejxqbF9PRdvQycIBBJWbr4ikA4ovSLVoj +sujhcB0zFRownvBX2xXDpHzJ5OX2wBFWzA5zwBBsjlIoJ4ZkTYVsBVV/HHuore/gzNE n2g0ixoKd6/4mja+Zy2TNRp1Z6du2dWeaP+8dhRf20KnyzQr0jR5j47kMhFD3jpYgLKH PF2g== X-Gm-Message-State: ALoCoQmdNLAwKfeeQGIFo4drvLRFz0o1NT4CQZ3DfApdCKLU/F9BoE7VPoWAdLFz/xqee0XZXM5T X-Received: by 10.28.184.134 with SMTP id i128mr8091073wmf.12.1448102736202; Sat, 21 Nov 2015 02:45:36 -0800 (PST) Received: from xps13.localnet (136-92-190-109.dsl.ovh.fr. [109.190.92.136]) by smtp.gmail.com with ESMTPSA id v196sm3552557wmv.10.2015.11.21.02.45.35 (version=TLSv1/SSLv3 cipher=OTHER); Sat, 21 Nov 2015 02:45:35 -0800 (PST) From: Thomas Monjalon To: Matthew Hall Date: Sat, 21 Nov 2015 11:44:20 +0100 Message-ID: <2295250.tyqBLnBnCL@xps13> Organization: 6WIND User-Agent: KMail/4.14.10 (Linux/4.1.6-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <20151121084935.GA24056@mhcomputing.net> References: <20151121084935.GA24056@mhcomputing.net> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Cc: dev@dpdk.org Subject: Re: [dpdk-dev] difficulty w/ RTE_NEXT_ABI 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, 21 Nov 2015 10:45:36 -0000 2015-11-21 03:49, Matthew Hall: > I was trying to rebase my DPDK onto v2.1.0 and I came across some very > confusing code in examples/l3fwd/main.c . > > So... this code used the RTE_NEXT_ABI macros on a change which does not appear > to affect the API... on a function that is marked always_inline ??? > > Maybe I missed something but this seems pointless. An always_inline function > is going to have to be recompiled in any case. > > Now I have no clue what would makes sense for my version of the function > either... because RTE_NEXT_ABI is a binary on/off but trying to track a > multi-variate quantity of ABI updates. > > For now I guess I have to write it like this inside the RTE_NEXT_ABI: > > rfc1812_process(struct ipv4_hdr *ipv4_hdr, uint32_t *dp, uint32_t ptype) > > This seems unpleasant and kind of painful. What did I miss here? > > Matthew. > > static inline __attribute__((always_inline)) void > <<<<<<< 8e29af8a2843b6342dbc72db43ac82c9d29695bf > #ifdef RTE_NEXT_ABI > rfc1812_process(struct ipv4_hdr *ipv4_hdr, uint16_t *dp, uint32_t ptype) > #else > rfc1812_process(struct ipv4_hdr *ipv4_hdr, uint16_t *dp, uint32_t flags) > #endif The new mbuf provides packet type instead of flags. So the processing in this function is changed and the variable name is different to reflect this.