On Mon, Apr 22, 2013 at 10:53:50AM +0200, Oleksij Rempel wrote: > From: Oleksij Rempel <bug-track@xxxxxxxxxxxxxxxxx> > > diff --git a/drivers/nor/cfi_flash.h b/drivers/nor/cfi_flash.h > index 8f818ba..6c7cac4 100644 > --- a/drivers/nor/cfi_flash.h > +++ b/drivers/nor/cfi_flash.h > @@ -295,7 +295,11 @@ static inline u64 flash_read64(void *addr) > */ > static inline uchar *flash_make_addr (struct flash_info *info, flash_sect_t sect, uint offset) > { > +#ifdef CONFIG_DRIVER_CFI_BANK_SHIFT_1 > + return ((uchar *) (info->start[sect] + (offset * info->portwidth << 1))); > +#else > return ((uchar *) (info->start[sect] + (offset * info->portwidth))); > +#endif > } Please make this a runtime option configurable via platform data. Making this a compile time option is not so nice. Or could this be automatically detected? Sascha -- Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox