From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefan Roese Date: Tue, 27 Oct 2015 12:20:14 +0100 Subject: [U-Boot] [PATCH] cfi_flash: use specific width types for cword In-Reply-To: <1445615451-4471-1-git-send-email-ryan.harkin@linaro.org> References: <1445615451-4471-1-git-send-email-ryan.harkin@linaro.org> Message-ID: <562F5DEE.4000607@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 23.10.2015 17:50, Ryan Harkin wrote: > This patch changes the cword union to use specific length types that are > architecture indepented. > > This patch also renames the members of the cword union to represent > their usage, i.e.: > > c -> w8 > s -> w16 > l -> w32 > ll -> w64 > > Where "w" stands for "width" in bits. > > I discovered this problem when enabling CFI flash on vexpress64. > cword.l was an unsigned long int, but it was intended to be 32 bits wide. > Unfortunately, it's 64-bits wide on a 64-bit system, meaning that a > 64-bit system fails when attempting to use 32-bit wide CFI flash parts. > > Similar problems also existed with the other cword sizes. > > Signed-off-by: Ryan Harkin Applied to u-boot-cfi-flash/master. Thanks, Stefan