]> www.infradead.org Git - users/jedix/linux-maple.git/commit
i2c: designware: Consolidate PM ops
authorAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Tue, 27 Aug 2024 15:00:37 +0000 (18:00 +0300)
committerAndi Shyti <andi.shyti@kernel.org>
Mon, 9 Sep 2024 22:36:44 +0000 (00:36 +0200)
commit534696e4c0bb7dee8f2ceacb1127ad6549f23f53
tree204c5fd669b81bc76bf6d8bf95fd9fd6f36338e0
parent01e00b5db8608400665a9cc20d9a56b2eeec3186
i2c: designware: Consolidate PM ops

We have the same (*) PM ops in the PCI and platform drivers.
Instead, consolidate that PM ops under exported variable and
deduplicate them.

*)
With the subtle ACPI and P-Unit behaviour differences in PCI case.
But this is not a problem as for ACPI we need to take care of the
P-Unit semaphore anyway and calling PM ops for PCI makes sense as
it might provide specific operation regions in ACPI (however there
are no known devices on market that are using it with PCI enabled I2C).
Note, the clocks are not in use in the PCI case.

Reviewed-by: Andi Shyti <andi.shyti@kernel.org>
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Tested-by: Sanket Goswami <Sanket.Goswami@amd.com>
Acked-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
Signed-off-by: Andi Shyti <andi.shyti@kernel.org>
drivers/i2c/busses/i2c-designware-common.c
drivers/i2c/busses/i2c-designware-core.h
drivers/i2c/busses/i2c-designware-pcidrv.c
drivers/i2c/busses/i2c-designware-platdrv.c