Re: [PATCH] mtd: core: Fix erase area alignment for non power of 2 erasesize

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jan 09, 2019 at 12:28:14PM +0100, Ladislav Michl wrote:
> Devices as AT45DB161 DataFlash uses non power of two page size (528)
> while present alignment algorithm relies on erasesize being power
> of 2.
> Fix that by introducing helper functions rounding to any multiply.
> Note that logic is sligthly changed to be consistent as ending
> address is moved forward to include also last byte meant to be
> erased while previous implementation moved it backward.
> 
> Signed-off-by: Ladislav Michl <ladis@xxxxxxxxxxxxxx>
> ---
>  drivers/mtd/core.c     | 28 ++++++++++++++++++++++------
>  include/linux/kernel.h |  5 +++++
>  2 files changed, 27 insertions(+), 6 deletions(-)

Applied, thanks

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



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux