From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nikita Kiryanov Date: Tue, 05 Feb 2013 09:22:35 +0200 Subject: [U-Boot] [PATCH 0/5] Create an API for safely accessing BMP header fields In-Reply-To: <5110AC6D.7050901@compulab.co.il> References: <1359977979-28585-1-git-send-email-nikita@compulab.co.il> <5110AC6D.7050901@compulab.co.il> Message-ID: <5110B33B.50200@compulab.co.il> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 02/05/2013 08:53 AM, Igor Grinberg wrote: > On 02/04/13 13:39, Nikita Kiryanov wrote: >> When configuring U-Boot to display a splash image, the user is free to >> designate whatever address they see fit as the in-memory location of BMP >> file. Unfortunately, this makes it easy to place the BMP header fields in >> unaligned addresses, which will cause a data abort on architectures which >> can't handle unaligned memory accesses. What's worse, addresses which are >> supposed to be issue free (32 bit aligned addresses) actually don't work >> because of the structure of the BMP header file (the header starts with 2 >> chars, followed by __u32 fields. The two chars offset the 32 bit fields away >> from proper alignment). >> >> As a result, it is very easy to brick the board that U-Boot runs on with certain >> architectures. Once a bad address for splash image is selected and the board >> restarted, U-Boot never reaches command line, and yet the only way to prevent >> the data aborts from happening is to clear or change the environment variable >> splashimage. >> >> While it is possible to fix the problem by compiling all relevant files with >> $(PLATFORM_NO_UNALIGNED), it is possible to handle it with finer granularity by >> creating an API for header accesses, and compiling only that with >> $(PLATFORM_NO_UNALIGNED). >> >> This patchset creates such an API, and makes use of it wherever an in-memory BMP >> header is probed for data. >> >> Further information can be found in this discussion: >> http://lists.denx.de/pipermail/u-boot/2013-January/144666.html >> >> Nikita Kiryanov (5): >> Add bmp_layout module for accessing BMP header data >> lcd: use bmp_layout API >> cmd_bmp: use bmp_layout API >> video/cfb_console: use bmp_layout API >> video/bus_vcxk: use bmp_layout API > > In 5 above patches, Nikita has accidentally added my s-o-b, > without me being participating in the patch development or delivery > process. > Nikita, please, don't do so in the future. > > Thanks. > I apologize. It won't happen again. -- Regards, Nikita.