[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200310204142.540fc7c4@collabora.com>
Date: Tue, 10 Mar 2020 20:41:42 +0100
From: Boris Brezillon <boris.brezillon@...labora.com>
To: Mason Yang <masonccyang@...c.com.tw>
Cc: miquel.raynal@...tlin.com, richard@....at, vigneshr@...com,
frieder.schrempf@...tron.de, tglx@...utronix.de, stefan@...er.ch,
juliensu@...c.com.tw, allison@...utok.net,
linux-kernel@...r.kernel.org, bbrezillon@...nel.org,
rfontana@...hat.com, linux-mtd@...ts.infradead.org,
yuehaibing@...wei.com, s.hauer@...gutronix.de
Subject: Re: [PATCH v3 3/4] mtd: rawnand: Add support manufacturer specific
suspend/resume operation
On Tue, 10 Mar 2020 20:39:30 +0100
Boris Brezillon <boris.brezillon@...labora.com> wrote:
> On Tue, 3 Mar 2020 15:21:23 +0800
> Mason Yang <masonccyang@...c.com.tw> wrote:
>
> > Patch nand_suspend() & nand_resume() for manufacturer specific
> > suspend/resume operation.
> >
> > Signed-off-by: Mason Yang <masonccyang@...c.com.tw>
> > Reported-by: kbuild test robot <lkp@...el.com>
> > Reviewed-by: Miquel Raynal <miquel.raynal@...tlin.com>
> > ---
> > drivers/mtd/nand/raw/nand_base.c | 11 ++++++++---
> > include/linux/mtd/rawnand.h | 4 ++++
> > 2 files changed, 12 insertions(+), 3 deletions(-)
> >
> > diff --git a/drivers/mtd/nand/raw/nand_base.c b/drivers/mtd/nand/raw/nand_base.c
> > index 769be81..b44e460 100644
> > --- a/drivers/mtd/nand/raw/nand_base.c
> > +++ b/drivers/mtd/nand/raw/nand_base.c
> > @@ -4327,7 +4327,9 @@ static int nand_suspend(struct mtd_info *mtd)
> > struct nand_chip *chip = mtd_to_nand(mtd);
> >
> > mutex_lock(&chip->lock);
> > - chip->suspended = 1;
> > + if (chip->_suspend)
> > + if (!chip->_suspend(chip))
> > + chip->suspended = 1;
Shouldn't you propagate the error to the caller if chip->_suspend()
fails?
Powered by blists - more mailing lists