From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <nhorman@tuxdriver.com>
Received: from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58])
 by dpdk.org (Postfix) with ESMTP id 079B668BE
 for <dev@dpdk.org>; Thu, 11 Dec 2014 15:18:04 +0100 (CET)
Received: from hmsreliant.think-freely.org
 ([2001:470:8:a08:7aac:c0ff:fec2:933b] helo=localhost)
 by smtp.tuxdriver.com with esmtpsa (TLSv1:AES128-SHA:128) (Exim 4.63)
 (envelope-from <nhorman@tuxdriver.com>)
 id 1Xz4Yj-0005hJ-Cl; Thu, 11 Dec 2014 09:17:54 -0500
Date: Thu, 11 Dec 2014 09:17:27 -0500
From: Neil Horman <nhorman@tuxdriver.com>
To: Thomas Monjalon <thomas.monjalon@6wind.com>
Message-ID: <20141211141727.GC28213@hmsreliant.think-freely.org>
References: <1415381289-43291-1-git-send-email-jyu@vmware.com>
 <D0ADD64A.2E3F8%jyu@vmware.com>
 <20141211002838.GA24240@localhost.localdomain>
 <30845403.kPBAiWVWY3@xps13>
MIME-Version: 1.0
Content-Type: text/plain; charset=iso-8859-1
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <30845403.kPBAiWVWY3@xps13>
User-Agent: Mutt/1.5.23 (2014-03-12)
X-Spam-Score: -2.9 (--)
X-Spam-Status: No
Cc: dev@dpdk.org
Subject: Re: [dpdk-dev] lib: include rte_memory.h for __rte_cache_aligned
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: patches and discussions about DPDK <dev.dpdk.org>
List-Unsubscribe: <http://dpdk.org/ml/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://dpdk.org/ml/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <http://dpdk.org/ml/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
X-List-Received-Date: Thu, 11 Dec 2014 14:18:04 -0000

On Thu, Dec 11, 2014 at 01:36:54AM +0100, Thomas Monjalon wrote:
> Hi Neil,
> 
> 2014-12-10 19:28, Neil Horman:
> > On Wed, Dec 10, 2014 at 07:09:03PM +0000, Jia Yu wrote:
> > > Hi Neil,
> > > 
> > > Moving __rte_cache_aligned right after struct keyword will help. On the
> > > other hand, enforcing this rule for existing (100+) and future definitions
> > > will be difficult. It¹s clearer and a good practice to include header file
> > > explicitly.
> > > 
> > You need to include the header file regardless of what you do.  The advantage to
> > placing the macro right after the struct keyword is that failure to include the
> > header will result in a compiler error, rather than silent behavioral changes
> > and run time breakage.
> > 
> > You don't have to enforce putting the attribute after the struct keyword, I'd
> > say just move them now to protect the current code.  Subsequent patch authors
> > will see the existing style and follow suit.  Or they won't, and we'll point out
> > the issue during review.
> 
> It should be a different patch for next release cycle.
> Let's apply this fix only for 1.8.0.
> 
Why?  Theres no harm in doing so now.
Neil