From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jason Cooper Date: Tue, 8 May 2012 11:43:49 -0400 Subject: [U-Boot] [PATCH] ext2load: increase read speed In-Reply-To: <4F98A23C.1090401@boundarydevices.com> References: <1332945431-12441-1-git-send-email-u-boot@lakedaemon.net> <4F98A23C.1090401@boundarydevices.com> Message-ID: <20120508154349.GC15711@titan.lakedaemon.net> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Wed, Apr 25, 2012 at 06:17:48PM -0700, Eric Nelson wrote: > On 03/28/2012 07:37 AM, Jason Cooper wrote: > >This patch dramatically drops the amount of time u-boot needs to read a > >file from an ext2 partition. On a typical 2 to 5 MB file (kernels and > >initrds) it goes from tens of seconds to a couple seconds. > > > >All we are doing here is grouping contiguous blocks into one read. > > > >Boot tested on Globalscale Technologies Dreamplug (Kirkwood ARM SoC) > >with three different files. sha1sums were calculated in Linux > >userspace, and then confirmed after ext2load. > > > >Signed-off-by: Jason Cooper > > Tested-by: Eric Nelson Thanks for testing! I've copied your results into the commit and will be doing a pull request shortly. thx, Jason. > > Tested on i.MX6 Sabre Lite board loading a file of ~900k: > > Without patch: > > MX6QSABRELITE U-Boot > time ext2load sata 0:1 12000000 > /usr/lib/libperl.so.5.12.4 && crc32 12000000 $filesize > Loading file "/usr/lib/libperl.so.5.12.4" from sata device 0:1 (hda1) > 958032 bytes read > > time: 0.414 seconds, 414 ticks > CRC32 for 12000000 ... 120e9e4f ==> 550deec9 > > With patch: > MX6QSABRELITE U-Boot > time ext2load sata 0:1 12000000 > /usr/lib/libperl.so.5.12.4 && crc32 12000000 $filesize > Loading file "/usr/lib/libperl.so.5.12.4" from sata device 0:1 (hda1) > 958032 bytes read > > time: 0.205 seconds, 205 ticks > CRC32 for 12000000 ... 120e9e4f ==> 550deec9