From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1VgNsv-0000H7-7D for mharc-grub-devel@gnu.org; Tue, 12 Nov 2013 19:00:41 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:46625) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VgNsj-0000G4-F0 for grub-devel@gnu.org; Tue, 12 Nov 2013 19:00:37 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VgNsa-00034b-HO for grub-devel@gnu.org; Tue, 12 Nov 2013 19:00:29 -0500 Received: from mail-ee0-x22e.google.com ([2a00:1450:4013:c00::22e]:34478) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VgNsa-00033a-Ak for grub-devel@gnu.org; Tue, 12 Nov 2013 19:00:20 -0500 Received: by mail-ee0-f46.google.com with SMTP id c4so25100eek.5 for ; Tue, 12 Nov 2013 16:00:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject :content-type; bh=Jo/pcKPgHnKqwgS5XDy9gobKDYPL8MlLpve+/O5A96s=; b=G1PjU7LP2tqVNDCfGWDIqrLB0jY0j48CGUn3GWEN8JtL+FuP2TnOy3QfUyNuLM/+f3 nff3i5elzmgHsqntQelS7uQrZcVqUlCMgH20UPfOVm8wstXgYjCdON7/z2t1Ae4ph/ls a/ybSAMZ5LggnRvcI7k6rnHhTAC0pZlrJTqDKSFJW24UO9pVELgWwlEF4tFNBaGZ+8GK pU2hfAECxzNorN0FAgkdgYI8N94ZoPB0nmPwlluC3lh/JGoQ1MALgRQPiB2K6zBfRbwn Ws70G8EbJ/6cGq0Po5Ls/x20phkEAZCcnU5Hf3OCYnxX8aM4VLWZ1NLKTUgolOG4dMlx y/dw== X-Received: by 10.15.61.66 with SMTP id h42mr5810766eex.62.1384300819269; Tue, 12 Nov 2013 16:00:19 -0800 (PST) Received: from [192.168.1.16] (31-249.1-85.cust.bluewin.ch. [85.1.249.31]) by mx.google.com with ESMTPSA id k7sm73375740eeg.13.2013.11.12.16.00.18 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Tue, 12 Nov 2013 16:00:18 -0800 (PST) Message-ID: <5282C111.70100@gmail.com> Date: Wed, 13 Nov 2013 01:00:17 +0100 From: =?UTF-8?B?VmxhZGltaXIgJ8+GLWNvZGVyL3BoY29kZXInIFNlcmJpbmVua28=?= User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131005 Icedove/17.0.9 MIME-Version: 1.0 To: The development of GRUB 2 Subject: [RFT] Use pair of shifts instead of and in ARM code X-Enigmail-Version: 1.5.1 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="----enig2GOCGJSPXXFNIXGVHVLAU" X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4013:c00::22e 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, 13 Nov 2013 00:00:38 -0000 This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2GOCGJSPXXFNIXGVHVLAU Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable 1ff and 3fff can't be easily loaded on ARM. This patch replaces load+and with pair of shift to keep only wanted bits. diff --git a/grub-core/kern/arm/cache_armv7.S b/grub-core/kern/arm/cache_armv7.S index 0c16b10..454bad3 100644 --- a/grub-core/kern/arm/cache_armv7.S +++ b/grub-core/kern/arm/cache_armv7.S @@ -58,11 +64,17 @@ clean_invalidate_dcache: @ read current cache information mrc p15, 1, r8, c0, c0, 0 @ Read CCSIDR lsr r3, r8, #13 @ Number of sets -1 - ldr r9, =3D0x3fff - and r3, r3, r9 + + @ Keep only 14 bits of r3 + lsl r3, r3, #18 + lsr r3, r3, #18 + lsr r4, r8, #3 @ Number of ways -1 - ldr r9, =3D0x1ff - and r4, r4, r9 + + @ Keep only 9 bits of r4 + lsl r4, r4, #23 + lsr r4, r4, #23 + and r7, r8, #7 @ log2(line size in words) - 2 add r7, r7, #2 @ adjust mov r8, #1 ------enig2GOCGJSPXXFNIXGVHVLAU Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.15 (GNU/Linux) Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iF4EAREKAAYFAlKCwREACgkQmBXlbbo5nOsVkQD/Tv+wsUAwGLgmaF4HUU3Z7gpq xNZIfONXkcX6V4tvleEA/0QGMeT++yjLtkdqQfb37jYwi1giVVEP7cWb/jM7HPIb =lIbw -----END PGP SIGNATURE----- ------enig2GOCGJSPXXFNIXGVHVLAU--