Date: Thu, 14 Jan 2016 09:53:23 -0700 From: Warner Losh <imp@bsdimp.com> To: NGie Cooper <yaneurabeya@gmail.com> Cc: Steven Hartland <smh@freebsd.org>, src-committers <src-committers@freebsd.org>, "svn-src-all@freebsd.org" <svn-src-all@freebsd.org>, "svn-src-head@freebsd.org" <svn-src-head@freebsd.org> Subject: Re: svn commit: r293903 - in head/sys/boot: arm/uboot efi/fdt efi/libefi Message-ID: <CANCZdfqVL4tSB%2BmVP8AYwsZuBF0Y=i%2B8_wPC_aOriPZAV99wXg@mail.gmail.com> In-Reply-To: <9A7534C4-0A2C-4DAC-981A-09868F1723DA@gmail.com> References: <201601140922.u0E9M1rV025146@repo.freebsd.org> <F3E05332-F6B1-4685-812A-FD2BBB870075@gmail.com> <9A7534C4-0A2C-4DAC-981A-09868F1723DA@gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, Jan 14, 2016 at 2:47 AM, NGie Cooper <yaneurabeya@gmail.com> wrote: > > > On Jan 14, 2016, at 01:27, NGie Cooper <yaneurabeya@gmail.com> wrote: > > > > > >> On Jan 14, 2016, at 01:22, Steven Hartland <smh@FreeBSD.org> wrote: > >> > >> Author: smh > >> Date: Thu Jan 14 09:22:01 2016 > >> New Revision: 293903 > >> URL: https://svnweb.freebsd.org/changeset/base/293903 > >> > >> Log: > >> Fix GCC warnings causing build failure after r293724 > >> > >> Disable some compiler warnings for GCC (non-standard compiler) fixing > >> build failures introduced by r293724, which enabled WARNS in the EFI > boot > >> code, when compiling with none standard compiler (GCC). > > > > Disabling warnings is wrong. Here=E2=80=99s how arm could be fixed: > > > > $ svn diff sys/boot/ > > Index: sys/boot/common/bootstrap.h > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > --- sys/boot/common/bootstrap.h (revision 293877) > > +++ sys/boot/common/bootstrap.h (working copy) > > @@ -32,6 +32,7 @@ > > #include <sys/types.h> > > #include <sys/queue.h> > > #include <sys/linker_set.h> > > +#include <time.h> > > > > /* > > * Generic device specifier; architecture-dependant > > @@ -332,12 +333,8 @@ > > extern struct arch_switch archsw; > > > > /* This must be provided by the MD code, but should it be in the archsw= ? > */ > > -void delay(int delay); > > - > > void dev_cleanup(void); > > > > -time_t time(time_t *tloc); > > - > > #ifndef CTASSERT /* Allow lint to override */ > > #define CTASSERT(x) _CTASSERT(x, __LINE__) > > #define _CTASSERT(x, y) __CTASSERT(x, y) > > Index: sys/boot/efi/include/efiapi.h > > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > > --- sys/boot/efi/include/efiapi.h (revision 293877) > > +++ sys/boot/efi/include/efiapi.h (working copy) > > @@ -532,6 +532,7 @@ > > typedef > > EFI_STATUS > > (EFIAPI *EFI_RESERVED_SERVICE) ( > > + VOID > > ); > > > > typedef > > > > amd64 is a bit trickier: > > > > /scratch/tmp/ngie/svn/sys/boot/efi/libefi/../include/efigop.h:75: > warning: 'ms_abi' attribute directive ignored > > > > I didn=E2=80=99t dig into why this is happening [yet], other than there= maybe > being MS extensions involved? > > > > Thanks, > > -NGie > > This might fix amd64: > > Index: /scratch/tmp/ngie/svn/sys/boot/efi/libefi/../include/amd64/efibind= .h > =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > --- /scratch/tmp/ngie/svn/sys/boot/efi/libefi/../include/amd64/efibind.h > (revision 293877) > +++ /scratch/tmp/ngie/svn/sys/boot/efi/libefi/../include/amd64/efibind.h > (working copy) > @@ -160,8 +160,10 @@ > // > > #ifdef __amd64__ > +#if defined(__clang__) && (__clang_major__ >=3D 3 && __clang_minor__ >= =3D 5) > #define EFIAPI __attribute__((ms_abi)) > #endif > +#endif > > #ifndef EFIAPI // Forces EFI calling conventions > reguardless of compiler options > #ifdef _MSC_EXTENSIONS > Sure this fix is right? If you aren't marking the ABI correctly, how could this possibly work? Warner
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfqVL4tSB%2BmVP8AYwsZuBF0Y=i%2B8_wPC_aOriPZAV99wXg>