From mboxrd@z Thu Jan 1 00:00:00 1970 From: Christoph Hellwig Subject: Re: [PATCH, RFC] byteorder: sanity check toolchain vs kernel endianess Date: Mon, 13 May 2019 14:04:35 +0200 Message-ID: <20190513120435.GB22993@lst.de> References: <20190412143538.11780-1-hch@lst.de> <87woiutwq4.fsf@concordia.ellerman.id.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Dmitry Vyukov Cc: Michael Ellerman , Arnd Bergmann , Nick Kossifidis , Christoph Hellwig , Linus Torvalds , Andrew Morton , linux-arch , Linux Kernel Mailing List , linuxppc-dev , Andrew Donnellan List-Id: linux-arch.vger.kernel.org On Mon, May 13, 2019 at 01:50:19PM +0200, Dmitry Vyukov wrote: > > We did have some bugs in the past (~1-2 y/ago) but AFAIK they are all > > fixed now. These days I build most of my kernels with a bi-endian 64-bit > > toolchain, and switching endian without running `make clean` also works. > > For the record, yes, it turn out to be a problem in our code (a latent > bug). We actually used host (x86) gcc to build as-if ppc code that can > run on the host, so it defined neither LE no BE macros. It just > happened to work in the past :) So Nick was right and these checks actually are useful.. From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from verein.lst.de ([213.95.11.211]:38873 "EHLO newverein.lst.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728268AbfEMME4 (ORCPT ); Mon, 13 May 2019 08:04:56 -0400 Date: Mon, 13 May 2019 14:04:35 +0200 From: Christoph Hellwig Subject: Re: [PATCH, RFC] byteorder: sanity check toolchain vs kernel endianess Message-ID: <20190513120435.GB22993@lst.de> References: <20190412143538.11780-1-hch@lst.de> <87woiutwq4.fsf@concordia.ellerman.id.au> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-arch-owner@vger.kernel.org List-ID: To: Dmitry Vyukov Cc: Michael Ellerman , Arnd Bergmann , Nick Kossifidis , Christoph Hellwig , Linus Torvalds , Andrew Morton , linux-arch , Linux Kernel Mailing List , linuxppc-dev , Andrew Donnellan Message-ID: <20190513120435.hTqX9_USAH1N0R_1n72tDODLMemCPRyoMgLQlGXXPmA@z> On Mon, May 13, 2019 at 01:50:19PM +0200, Dmitry Vyukov wrote: > > We did have some bugs in the past (~1-2 y/ago) but AFAIK they are all > > fixed now. These days I build most of my kernels with a bi-endian 64-bit > > toolchain, and switching endian without running `make clean` also works. > > For the record, yes, it turn out to be a problem in our code (a latent > bug). We actually used host (x86) gcc to build as-if ppc code that can > run on the host, so it defined neither LE no BE macros. It just > happened to work in the past :) So Nick was right and these checks actually are useful..