[PATCH v1 0/5] Added support for spi-nor device pm in m25p80

Kamal Dasu kdasu.kdev at gmail.com
Fri Feb 3 15:31:11 PST 2017


The changes below implements power management support in m25p80.
m25p80 pm resume() calls newly a implemented spi_nor_pm_rescan()
function that sets up the spi-nor flash to its probed state. 
This is needed on platfroms that turn off power to the spi-nor
part on suspend, in such cases some parts might need to: 
1. remove flash protection (if applicable)
2. set the address width and/or
3. set the read mode to quad mode depending on the probed configuration

The changes use existing spi-nor framework by refactoring code a bit so
that it can be reused in scan and rescan functions. Changes also ensures
that for platforms that do not need pm support shall not be affected. 

Kamal Dasu (5):
  mtd: spi-nor: Added way to rescan spi-nor device
  mtd: m25p80: Added pm ops support
  spi: Added way to check for pm support for flash devices
  mtd: m25p80: Check if the spi flash device has pm support
  spi: bcm-qspi: Implement the master flash_pm_supported() call

 drivers/mtd/devices/m25p80.c  | 21 ++++++++++
 drivers/mtd/spi-nor/spi-nor.c | 93 +++++++++++++++++++++++++++++++++++++------
 drivers/spi/spi-bcm-qspi.c    |  6 +++
 include/linux/mtd/spi-nor.h   | 17 ++++++++
 include/linux/spi/spi.h       |  8 ++++
 5 files changed, 133 insertions(+), 12 deletions(-)

-- 
1.9.1




More information about the linux-mtd mailing list