fake_ecc_layout is only used in the mxs nand driver, so make it static. Also it's not necessary to zero the structure. Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> --- drivers/mtd/nand/nand_mxs.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/mtd/nand/nand_mxs.c b/drivers/mtd/nand/nand_mxs.c index fb3e2b7958..4317c30805 100644 --- a/drivers/mtd/nand/nand_mxs.c +++ b/drivers/mtd/nand/nand_mxs.c @@ -236,7 +236,7 @@ struct mxs_nand_info { int bb_mark_bit_offset; }; -struct nand_ecclayout fake_ecc_layout; +static struct nand_ecclayout fake_ecc_layout; static inline int mxs_nand_is_imx6(struct mxs_nand_info *info) { @@ -2188,8 +2188,6 @@ static int mxs_nand_probe(struct device_d *dev) if (err) goto err2; - memset(&fake_ecc_layout, 0, sizeof(fake_ecc_layout)); - /* structures must be linked */ chip = &nand_info->nand_chip; mtd = &nand_info->mtd; -- 2.20.1 _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox