From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1aW5ZF-0007Qr-Kf for mharc-grub-devel@gnu.org; Wed, 17 Feb 2016 12:07:09 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:35058) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aW5ZA-0007Qe-8n for grub-devel@gnu.org; Wed, 17 Feb 2016 12:07:08 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1aW5Z9-0000AB-5v for grub-devel@gnu.org; Wed, 17 Feb 2016 12:07:04 -0500 Received: from mail-wm0-x22f.google.com ([2a00:1450:400c:c09::22f]:36456) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1aW5Z8-00009w-UT for grub-devel@gnu.org; Wed, 17 Feb 2016 12:07:03 -0500 Received: by mail-wm0-x22f.google.com with SMTP id g62so170976249wme.1 for ; Wed, 17 Feb 2016 09:07:02 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=subject:to:references:from:message-id:date:user-agent:mime-version :in-reply-to:content-type; bh=Y1RlKA4E7Sf+PlY5v3DzNdicot5qkWL/UGPKkGzYB6U=; b=gde1+nEmAaXKjJygZb18X4uIivfi3g+fTiGzYRerqcddBB7h6W2j7ttEcaaqKofEgF LGNt655WsvXM2o9KX71y1ptp2lQXyaPd4j4yG0uvTw++t/d3NxnXKYfma59ceeUV1BAa L1WhnhhI4A+MrEweci5t8IpsdrzdeL9sEENvHj0cT8CPdwe/YUn0hlrRPpFoSeswidue 1VJenn0+EVlrAtVHrKLvgCBkRt/rdVvbSH41ZFYXyCUUziXTgjRUvVc0qiBt90Ll4ScU SKNgUbOZ9LBLjmQ6936MaHVXlXom9e/MN+asZIdMcpcxANxXeeX1zl/MRFCdPoCRi6LA 9qTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:subject:to:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-type; bh=Y1RlKA4E7Sf+PlY5v3DzNdicot5qkWL/UGPKkGzYB6U=; b=X1WyqTJXKwhDSwyJFVZZj/6+lubOGue/6NER5edleheeZzV8H4JgF3eVS0yKWlAIgl HbgjnjuyI/rXJOl1/na0SGWWM7FY1WJaXh4shdpAP/yDqVbJFtL76DgXnWvr8cKDmlXK YiFSrePdxQm3AxEJTYflWEsB8L31w2XjKPQX7tK71QE+5aJWXZBCOioGGFk0mejVL4Sk SX3+oN+I6vuZFKYWPVDXStPO9OJ3bSZhpFQ0+ap/kl3SzR9HRIT1sbgtE3WerOWvqHnW CLUmrNXPuZXA4gjV4WpTwqzp7iSiXVz6zE/wZchKWmesPBj9L119BOG5XWlnxPrk+YkR L08A== X-Gm-Message-State: AG10YOSiBOup9r97dLa6t0P7lK6u0+wDHti8qF5FW0x828fyyjePCWUH0KwyEikFTmkDnQ== X-Received: by 10.28.156.199 with SMTP id f190mr25751404wme.83.1455728822240; Wed, 17 Feb 2016 09:07:02 -0800 (PST) Received: from ?IPv6:2620:0:105f:fd00:a2a8:cdff:fe64:b3b5? ([2620:0:105f:fd00:a2a8:cdff:fe64:b3b5]) by smtp.gmail.com with ESMTPSA id c136sm26279248wmd.3.2016.02.17.09.07.01 for (version=TLSv1/SSLv3 cipher=OTHER); Wed, 17 Feb 2016 09:07:01 -0800 (PST) Subject: Re: Respect EFI block-io buffer alignment To: The development of GNU GRUB References: <20160217154825.GD1159@bivouac.eciton.net> <56C49E90.3070307@gmail.com> <56C4A712.4090909@gmail.com> From: =?UTF-8?Q?Vladimir_'=cf=86-coder/phcoder'_Serbinenko?= Message-ID: <56C4A8AE.8020302@gmail.com> Date: Wed, 17 Feb 2016 18:06:54 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Icedove/38.6.0 MIME-Version: 1.0 In-Reply-To: <56C4A712.4090909@gmail.com> Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="MRmPKuW01I0SwsimOEaWBmqUHj0MVUPxl" X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 2a00:1450:400c:c09::22f X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 17 Feb 2016 17:07:08 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) --MRmPKuW01I0SwsimOEaWBmqUHj0MVUPxl Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable On 17.02.2016 18:00, Andrei Borzenkov wrote: > 17.02.2016 19:23, Vladimir '=CF=86-coder/phcoder' Serbinenko =D0=BF=D0=B8= =D1=88=D0=B5=D1=82: >> On 17.02.2016 16:48, Leif Lindholm wrote: >>> This resolves a complete failure to access devices connected to the >>> SATA port on the ARM ltd. Juno platform (apart from a violation of th= e >>> UEFI block io protocol). >>> >>> The below is a bit of a hack, but I'd like some feedback on preferred= >>> solution before over(or under)engineering something. >>> >>> As far as I can tell, a struct_disk is only ever allocated in >>> kern/disk.c, using grub_zalloc(). So the only reason for the horrid >>> ifdefs is that there is no grub_memalign for EMU. >>> >>> Do I: >>> - Keep the ifdefs? >>> - Implement grub_memalign() for EMU? >> You could insipire by grub_osdep_dl_memalign >>> - Something else? >>> >> The code as-is will not work. Buf is passed from external call to >> grub_disk_read and grub_disk_read tries to read in-place whenever >> possible. There are 2 cases in current codebase when we need a special= >=20 > It can be changed to read into cache and copy in buf instead of read > into buf and copy in cache. >=20 This is often not very good idea as you lose buffering as you split transactions. This was a reason GRUB2 was slower than GRUB Legacy on some systems until it was rewritten to current code. >=20 >=20 >=20 > _______________________________________________ > Grub-devel mailing list > Grub-devel@gnu.org > https://lists.gnu.org/mailman/listinfo/grub-devel >=20 --MRmPKuW01I0SwsimOEaWBmqUHj0MVUPxl Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v2 iF4EAREKAAYFAlbEqK4ACgkQmBXlbbo5nOs87AD/fB1NEhyDk0Q58DDltTwcB2bD sSMVNTSxS1P1432wEyQBAJzBQtVoYpKyj5/0PZ3t6o/WgVOSZvBL0QwAGj/uyQ4s =ubcB -----END PGP SIGNATURE----- --MRmPKuW01I0SwsimOEaWBmqUHj0MVUPxl--