lkml.org 
[lkml]   [2019]   [Jun]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [EXT] Re: [PATCH] mtd: spi-nor: Add prep/unprep for spi_nor_resume
Date


> -----Original Message-----
> From: Tudor.Ambarus@microchip.com <Tudor.Ambarus@microchip.com>
> Sent: Thursday, June 6, 2019 12:46 AM
> To: Han Xu <han.xu@nxp.com>; cyrille.pitchen@wedev4u.fr;
> marek.vasut@gmail.com
> Cc: boris.brezillon@free-electrons.com; f.fainelli@gmail.com;
> kdasu.kdev@gmail.com; richard@nod.at; linux-kernel@vger.kernel.org;
> linux-mtd@lists.infradead.org; dl-linux-imx <linux-imx@nxp.com>;
> computersforpeace@gmail.com
> Subject: [EXT] Re: [PATCH] mtd: spi-nor: Add prep/unprep for
> spi_nor_resume
>
> Caution: EXT Email
>
> Hi, Han,
>
> On 04/25/2019 12:08 AM, Han Xu wrote:
> > External E-Mail
> >
> >
> > In the new implemented spi_nor_resume function, the spi_nor_init()
> > should be braced by prep/unprep functions._
> >
>
> Would you please explain why this is needed? Have you tried a
> suspend/resume cycle while a write was in progress and it failed?

Same as all other functions that hooked up with mtd ops, such as
_read/_write/_lock/_unlock, the _resume function also need to call the
lower level controller's prep/unprep functions to properly handle runtime
pm and mutex.

I didn't try suspend/resume during writing, but found accessing registers
without enabling clock when system resumed.

>
> Thanks,
> ta
\
 
 \ /
  Last update: 2019-06-07 00:34    [W:0.577 / U:0.060 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site