From 6b44adc22e6f4cc4fe8e1bb6c69b6bf8ec8da533 Mon Sep 17 00:00:00 2001 From: Tom Rini Date: Thu, 5 Dec 2013 14:48:39 -0500 Subject: yaffs2: Use lldiv for 64bit division Signed-off-by: Tom Rini --- fs/yaffs2/yaffs_uboot_glue.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'fs/yaffs2/yaffs_uboot_glue.c') diff --git a/fs/yaffs2/yaffs_uboot_glue.c b/fs/yaffs2/yaffs_uboot_glue.c index e113e4039e..50000a135b 100644 --- a/fs/yaffs2/yaffs_uboot_glue.c +++ b/fs/yaffs2/yaffs_uboot_glue.c @@ -20,6 +20,7 @@ */ #include +#include #include #include "nand.h" @@ -184,7 +185,7 @@ void cmd_yaffs_devconfig(char *_mp, int flash_dev, } if (end_block == 0) - end_block = mtd->size / mtd->erasesize - 1; + end_block = lldiv(mtd->size, mtd->erasesize - 1); if (end_block < start_block) { printf("Bad start/end\n"); -- cgit