diff options
author | Rafał Miłecki <zajec5@gmail.com> | 2015-02-12 20:13:20 +0000 |
---|---|---|
committer | Rafał Miłecki <zajec5@gmail.com> | 2015-02-12 20:13:20 +0000 |
commit | 615909819d20c9144c545b240561897cdbf40ebb (patch) | |
tree | a303b7a7dd6ab5ff1db255f284acf701c93cc344 /target | |
parent | 02aa882e606f029b4bdfb37ca53069242090e5ea (diff) | |
download | mtk-20170518-615909819d20c9144c545b240561897cdbf40ebb.zip mtk-20170518-615909819d20c9144c545b240561897cdbf40ebb.tar.gz mtk-20170518-615909819d20c9144c545b240561897cdbf40ebb.tar.bz2 |
kernel: mtdsplit_uimage: fix passed info about buf size
We obviously can't use sizeof(*buf) which is always 1.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
SVN-Revision: 44424
Diffstat (limited to 'target')
-rw-r--r-- | target/linux/generic/files/drivers/mtd/mtdsplit/mtdsplit_uimage.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/target/linux/generic/files/drivers/mtd/mtdsplit/mtdsplit_uimage.c b/target/linux/generic/files/drivers/mtd/mtdsplit/mtdsplit_uimage.c index 2bb5e9a..2602f98 100644 --- a/target/linux/generic/files/drivers/mtd/mtdsplit/mtdsplit_uimage.c +++ b/target/linux/generic/files/drivers/mtd/mtdsplit/mtdsplit_uimage.c @@ -113,11 +113,11 @@ static int __mtdsplit_parse_uimage(struct mtd_info *master, uimage_size = 0; - ret = read_uimage_header(master, offset, buf, sizeof(*buf)); + ret = read_uimage_header(master, offset, buf, MAX_HEADER_LEN); if (ret) continue; - ret = find_header(buf, sizeof(*buf)); + ret = find_header(buf, MAX_HEADER_LEN); if (ret < 0) { pr_debug("no valid uImage found in \"%s\" at offset %llx\n", master->name, (unsigned long long) offset); |