diff options
author | Boris Brezillon <boris.brezillon@bootlin.com> | 2018-08-04 22:59:22 +0200 |
---|---|---|
committer | Miquel Raynal <miquel.raynal@bootlin.com> | 2018-10-03 11:12:25 +0200 |
commit | 871a4073f438c61cc4cf7471476d9a8a29ccf620 (patch) | |
tree | c0aeba6998ec60d53b49f4a0149f2c0423949a02 /drivers/mtd | |
parent | 480bdd8b7ab6971f15258a73638cc3880ed7256d (diff) | |
download | linux-871a4073f438c61cc4cf7471476d9a8a29ccf620.tar.bz2 |
mtd: rawnand: Make maxchips an unsigned int
There's no good reason to make maxchips a signed integer, since only
positive values are valid. Make it an unsigned int.
Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>
Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
Diffstat (limited to 'drivers/mtd')
-rw-r--r-- | drivers/mtd/nand/raw/nand_base.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/mtd/nand/raw/nand_base.c b/drivers/mtd/nand/raw/nand_base.c index ef4d90ed896d..a7e85127c131 100644 --- a/drivers/mtd/nand/raw/nand_base.c +++ b/drivers/mtd/nand/raw/nand_base.c @@ -5915,11 +5915,12 @@ static int nand_dt_init(struct nand_chip *chip) * prevented dynamic allocations during this phase which was unconvenient and * as been banned for the benefit of the ->init_ecc()/cleanup_ecc() hooks. */ -static int nand_scan_ident(struct nand_chip *chip, int maxchips, +static int nand_scan_ident(struct nand_chip *chip, unsigned int maxchips, struct nand_flash_dev *table) { struct mtd_info *mtd = nand_to_mtd(chip); - int i, nand_maf_id, nand_dev_id; + int nand_maf_id, nand_dev_id; + unsigned int i; int ret; /* Enforce the right timings for reset/detection */ @@ -6730,7 +6731,7 @@ static void nand_detach(struct nand_chip *chip) * The flash ID is read and the mtd/chip structures are filled with the * appropriate values. */ -int nand_scan_with_ids(struct nand_chip *chip, int maxchips, +int nand_scan_with_ids(struct nand_chip *chip, unsigned int maxchips, struct nand_flash_dev *ids) { int ret; |