Commit 2caf87a4 authored by Kim Phillips's avatar Kim Phillips Committed by David Woodhouse

mtd: fsl_ifc_nand: fix sparse warnings

drivers/mtd/nand/fsl_ifc_nand.c:196:34: warning: cast removes address space of expression [sparse]
drivers/mtd/nand/fsl_ifc_nand.c:196:34: warning: incorrect type in initializer (different address spaces) [sparse]
drivers/mtd/nand/fsl_ifc_nand.c:196:34:    expected unsigned int [noderef] [usertype] <asn:2>*mainarea [sparse]
drivers/mtd/nand/fsl_ifc_nand.c:196:34:    got unsigned int [usertype] *<noident> [sparse]
...
Signed-off-by: default avatarKim Phillips <kim.phillips@freescale.com>
Signed-off-by: default avatarArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
Signed-off-by: default avatarDavid Woodhouse <David.Woodhouse@intel.com>
parent bb0a13a1
...@@ -193,7 +193,7 @@ static int is_blank(struct mtd_info *mtd, unsigned int bufnum) ...@@ -193,7 +193,7 @@ static int is_blank(struct mtd_info *mtd, unsigned int bufnum)
struct nand_chip *chip = mtd->priv; struct nand_chip *chip = mtd->priv;
struct fsl_ifc_mtd *priv = chip->priv; struct fsl_ifc_mtd *priv = chip->priv;
u8 __iomem *addr = priv->vbase + bufnum * (mtd->writesize * 2); u8 __iomem *addr = priv->vbase + bufnum * (mtd->writesize * 2);
u32 __iomem *mainarea = (u32 *)addr; u32 __iomem *mainarea = (u32 __iomem *)addr;
u8 __iomem *oob = addr + mtd->writesize; u8 __iomem *oob = addr + mtd->writesize;
int i; int i;
...@@ -591,8 +591,8 @@ static uint8_t fsl_ifc_read_byte16(struct mtd_info *mtd) ...@@ -591,8 +591,8 @@ static uint8_t fsl_ifc_read_byte16(struct mtd_info *mtd)
* next byte. * next byte.
*/ */
if (ifc_nand_ctrl->index < ifc_nand_ctrl->read_bytes) { if (ifc_nand_ctrl->index < ifc_nand_ctrl->read_bytes) {
data = in_be16((uint16_t *)&ifc_nand_ctrl-> data = in_be16((uint16_t __iomem *)&ifc_nand_ctrl->
addr[ifc_nand_ctrl->index]); addr[ifc_nand_ctrl->index]);
ifc_nand_ctrl->index += 2; ifc_nand_ctrl->index += 2;
return (uint8_t) data; return (uint8_t) data;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment