mtd: rawnand: Pass a nand_chip object to chip->cmd_ctrl()
Let's make the raw NAND API consistent by patching all helpers and hooks to take a nand_chip object instead of an mtd_info one or remove the mtd_info object when both are passed. Let's tackle the chip->cmd_ctrl() hook. Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com>
This commit is contained in:

committed by
Miquel Raynal

parent
c17556f545
commit
0f808c1602
@@ -97,12 +97,11 @@ static inline void davinci_nand_writel(struct davinci_nand_info *info,
|
||||
* Access to hardware control lines: ALE, CLE, secondary chipselect.
|
||||
*/
|
||||
|
||||
static void nand_davinci_hwcontrol(struct mtd_info *mtd, int cmd,
|
||||
static void nand_davinci_hwcontrol(struct nand_chip *nand, int cmd,
|
||||
unsigned int ctrl)
|
||||
{
|
||||
struct davinci_nand_info *info = to_davinci_nand(mtd);
|
||||
struct davinci_nand_info *info = to_davinci_nand(nand_to_mtd(nand));
|
||||
void __iomem *addr = info->current_cs;
|
||||
struct nand_chip *nand = mtd_to_nand(mtd);
|
||||
|
||||
/* Did the control lines change? */
|
||||
if (ctrl & NAND_CTRL_CHANGE) {
|
||||
|
Reference in New Issue
Block a user