Re: [PATCH v4 2/4] i2c: designware: Convert PCI driver to use shutdown hook

From: William A. Kennington III

Date: Mon May 11 2026 - 15:55:20 EST



On 5/8/26 01:15, Andy Shevchenko wrote:
On Thu, May 07, 2026 at 08:05:16PM +0000, William A. Kennington III wrote:
Convert the PCI driver to use the new i2c_dw_shutdown() hook, allowing
the controller to gracefully NACK master requests during system shutdown.
...
Done

+static void i2c_dw_pci_shutdown(struct pci_dev *pdev)
+{
+ struct dw_i2c_dev *i_dev;
+
+ i_dev = pci_get_drvdata(pdev);
+ if (!i_dev)
+ return;
+
+ pm_runtime_disable(&pdev->dev);
+ if (!pm_runtime_status_suspended(&pdev->dev))
There is a difference between pm_runtime_status_suspended() and
pm_runtime_suspended(). Are you sure you use the proper call here?
(Please, double check.)

pm_runtime_suspend() would always return false after pm_runtime_disable()


+ i2c_dw_shutdown(i_dev);
+}