Received: from list by lists.gnu.org with archive (Exim 4.71) id 1f2NHK-0007Ty-2x for mharc-grub-devel@gnu.org; Sat, 31 Mar 2018 16:39:10 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49437) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1f2NHH-0007TT-CA for grub-devel@gnu.org; Sat, 31 Mar 2018 16:39:08 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1f2NHG-0001Ex-8K for grub-devel@gnu.org; Sat, 31 Mar 2018 16:39:07 -0400 Received: from mail.gw90.de ([2a01:4f8:140:71f5::3]:36896) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1f2NHG-00017e-11 for grub-devel@gnu.org; Sat, 31 Mar 2018 16:39:06 -0400 Received: from [2a02:8109:b5bf:f806:2d1f:41f7:fba1:a29f] (helo=mattotaupa) by mail.gw90.de with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1f2NH8-0005Di-JD for grub-devel@gnu.org; Sat, 31 Mar 2018 20:38:58 +0000 Message-ID: <4bd57307cd937b4b6146b7202935b6d2e6b313fe.camel@users.sourceforge.net> Subject: Re: [PATCH] Fix packed-not-aligned error on GCC 8 From: Paul Menzel To: grub-devel@gnu.org Date: Sat, 31 Mar 2018 22:38:31 +0200 In-Reply-To: <20180328045935.x4qqdjho5tk472mh@mazu> References: <1521617508.7171.729.camel@users.sourceforge.net> <20180321094447.5tvd3b2rhhaujuza@mazu> <20180322140905.GF7226@router-fw-old.local.net-space.pl> <20180326085234.c5fzrs7vrpy335dv@mazu> <20180326142820.GA13283@router-fw-old.local.net-space.pl> <20180328045935.x4qqdjho5tk472mh@mazu> Content-Type: multipart/signed; micalg="pgp-sha1"; protocol="application/pgp-signature"; boundary="=-Uma0Ljo2UpBDUMw13AyZ" X-Mailer: Evolution 3.28.0-3 Mime-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a01:4f8:140:71f5::3 X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 31 Mar 2018 20:39:08 -0000 --=-Uma0Ljo2UpBDUMw13AyZ Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Dear Michael, dear Daniel, Thank you for the fix. Am Mittwoch, den 28.03.2018, 12:59 +0800 schrieb Michael Chang: > On Mon, Mar 26, 2018 at 04:28:20PM +0200, Daniel Kiper wrote: > > On Mon, Mar 26, 2018 at 04:52:34PM +0800, Michael Chang wrote: > > > When building with GCC 8, there are several errors regarding packed-n= ot-aligned. > > >=20 > > > ./include/grub/gpt_partition.h:79:1: error: alignment 1 of ???struct = grub_gpt_partentry??? is less than 8 [-Werror=3Dpacked-not-aligned] > > >=20 > > > This patch tries to fix the build error by cleaning up the ambiguity = of placing > >=20 > > s/tries to fix/fixes/? >=20 > Yes. I think the patch is adequate to say so. =20 I also think, *fixes* sounds better. Maybe Daniel can amend that. > > > aligned structure in a packed one. In "struct grub_btrfs_time" and "s= truct > > > grub_gpt_part_type", the aligned attribute seems to be superfluous, a= nd also > > > has to be packed, to ensure the structure is bit-to-bit mapped to the= format > > > laid on disk. I think we could blame to copy and paste error here for= the > > > mistake. In "struct efi_variable", we have to use grub_efi_packed_gui= d_t, as > > > the name suggests. :) > > >=20 > > > Signed-off-by: Michael Chang > > > Tested-by: Michael Chang > >=20 > > Otherwise, Reviewed-by: Daniel Kiper > >=20 > > If there are no objections I will apply this in a week or so. >=20 > Thank you very much. :) Tested-by: Paul Menzel Thanks, Paul --=-Uma0Ljo2UpBDUMw13AyZ Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part Content-Transfer-Encoding: 7bit -----BEGIN PGP SIGNATURE----- iF0EABECAB0WIQQ8+w9d414FAVARIpk9fVorbA4dWAUCWr/xzgAKCRA9fVorbA4d WNjKAJ0TyhySdfJPSi5mofLwQ0slgc/z8ACdEKwpOZ1pIUmDGOOZrstpiNceoKI= =7o3c -----END PGP SIGNATURE----- --=-Uma0Ljo2UpBDUMw13AyZ--