在 2023/4/15 上午2:32, Mark Brown 写道:
On Wed, Apr 12, 2023 at 12:51:52PM +0800, Yinbo Zhu wrote:
+static int __maybe_unused loongson_spi_suspend(struct device *dev)
+{
+ struct loongson_spi *loongson_spi;
+ struct spi_master *master;
+
+ master = dev_get_drvdata(dev);
+ loongson_spi = spi_master_get_devdata(master);
+
+ loongson_spi->spcr = loongson_spi_read_reg(loongson_spi, LOONGSON_SPI_SPCR_REG);
This is missing a call to spi_controller_suspend(), and similarly resume
is missing a call to spi_controller_resume(). Otherwise this looks
good.
okay, I will add it.
Thanks.