diff options
author | Miquel Raynal <miquel.raynal@bootlin.com> | 2023-02-23 10:27:32 +0100 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2023-02-23 10:27:32 +0100 |
commit | 27121864ab366992583d894961ecdc6e2ffe0ca1 (patch) | |
tree | 87ef1dcf82ce2d0d29b686d5ae81003ab3eb3b4a /drivers/mtd/parsers | |
parent | 84549c816dc317f012798e706e58669b3b013604 (diff) | |
parent | f047382519ca41702ebaee5a862e87390f687137 (diff) | |
download | linux-27121864ab366992583d894961ecdc6e2ffe0ca1.tar.gz linux-27121864ab366992583d894961ecdc6e2ffe0ca1.tar.bz2 linux-27121864ab366992583d894961ecdc6e2ffe0ca1.zip |
Merge tag 'spi-nor/for-6.3' into mtd/next
SPI NOR changes:
* small fixes on core and spansion driver.
Diffstat (limited to 'drivers/mtd/parsers')
-rw-r--r-- | drivers/mtd/parsers/scpart.c | 2 | ||||
-rw-r--r-- | drivers/mtd/parsers/tplink_safeloader.c | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/drivers/mtd/parsers/scpart.c b/drivers/mtd/parsers/scpart.c index 02601bb33de4..6e5e11c37078 100644 --- a/drivers/mtd/parsers/scpart.c +++ b/drivers/mtd/parsers/scpart.c @@ -50,7 +50,7 @@ static int scpart_scan_partmap(struct mtd_info *master, loff_t partmap_offs, int cnt = 0; int res = 0; int res2; - loff_t offs; + uint32_t offs; size_t retlen; struct sc_part_desc *pdesc = NULL; struct sc_part_desc *tmpdesc; diff --git a/drivers/mtd/parsers/tplink_safeloader.c b/drivers/mtd/parsers/tplink_safeloader.c index f601e7bd8627..1c689dafca2a 100644 --- a/drivers/mtd/parsers/tplink_safeloader.c +++ b/drivers/mtd/parsers/tplink_safeloader.c @@ -91,7 +91,7 @@ static int mtd_parser_tplink_safeloader_parse(struct mtd_info *mtd, buf = mtd_parser_tplink_safeloader_read_table(mtd); if (!buf) { err = -ENOENT; - goto err_out; + goto err_free_parts; } for (idx = 0, offset = TPLINK_SAFELOADER_DATA_OFFSET; @@ -118,6 +118,8 @@ static int mtd_parser_tplink_safeloader_parse(struct mtd_info *mtd, err_free: for (idx -= 1; idx >= 0; idx--) kfree(parts[idx].name); +err_free_parts: + kfree(parts); err_out: return err; }; |