[U-Boot] [PATCH] part_dos: fix crash with big sector size

Sergei Shtylyov
2011-07-26T18:57:33Z

Hello.

I wrote:

> Apple iPod nanos have sector sizes of 2 or 4 KiB, which crashes U-Boot when it
> tries to read the MBR into 512-byte buffer situated on stack. Instead use the
> variable length arrays to be safe with any large sector size.

> Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>

> ---
> The same change is probably needed for disk/part_amiga.c but I'm not really
> sure if Amiga supports USB... :-)

Damn, the FAT code is also hardwired for 512-byte sectors. I wonder which
century we are in? :-)

WBR, Sergei