i2c: designware: Introduce semaphore reservation timer to AMDPSP driver
authorJan Dabros <jsd@semihalf.com>
Fri, 12 Aug 2022 07:15:26 +0000 (09:15 +0200)
committerWolfram Sang <wsa@kernel.org>
Sat, 20 Aug 2022 06:29:04 +0000 (08:29 +0200)
commit786f01d205cebb0b114423ec0b66c4d19074faa1
treebe3ca5d9165029b86421429de2f7370632aaafeb
parented5c2f5fd10dda07263f79f338a512c0f49f76f5
i2c: designware: Introduce semaphore reservation timer to AMDPSP driver

In order to optimize performance, limit amount of back and forth
transactions between x86 and PSP. This is done by introduction of
semaphore reservation period - that is window in which x86 isn't
releasing the bus immediately after each I2C transaction.

In order to protect PSP from being starved while waiting for
arbitration, after a programmed time bus is automatically released by a
deferred function.

Signed-off-by: Jan Dabros <jsd@semihalf.com>
Acked-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
[wsa: removed an unneeded empty line]
Signed-off-by: Wolfram Sang <wsa@kernel.org>
drivers/i2c/busses/i2c-designware-amdpsp.c