]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commit
i2c: i801: Ensure that SMBHSTSTS_INUSE_STS is cleared when leaving i801_access
authorHeiner Kallweit <hkallweit1@gmail.com>
Sun, 6 Jun 2021 13:55:55 +0000 (15:55 +0200)
committerStefan Bader <stefan.bader@canonical.com>
Fri, 13 Aug 2021 07:29:24 +0000 (09:29 +0200)
commitd001a0336e9ebb7a9e9b4a828f60e1e6087f8b7e
treee3116fbcfcde7bc7642c17867b8830e45b4c9006
parent616e52587e84f9b57e3c461cf2e62b126fb68d0c
i2c: i801: Ensure that SMBHSTSTS_INUSE_STS is cleared when leaving i801_access

BugLink: https://bugs.launchpad.net/bugs/1936863
[ Upstream commit 065b6211a87746e196b56759a70c7851418dd741 ]

As explained in [0] currently we may leave SMBHSTSTS_INUSE_STS set,
thus potentially breaking ACPI/BIOS usage of the SMBUS device.

Seems patch [0] needs a little bit more of review effort, therefore
I'd suggest to apply a part of it as quick win. Just clearing
SMBHSTSTS_INUSE_STS when leaving i801_access() should fix the
referenced issue and leaves more time for discussing a more
sophisticated locking handling.

[0] https://www.spinics.net/lists/linux-i2c/msg51558.html

Fixes: 01590f361e94 ("i2c: i801: Instantiate SPD EEPROMs automatically")
Suggested-by: Hector Martin <marcan@marcan.st>
Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Reviewed-by: Hector Martin <marcan@marcan.st>
Reviewed-by: Jean Delvare <jdelvare@suse.de>
Tested-by: Jean Delvare <jdelvare@suse.de>
Signed-off-by: Wolfram Sang <wsa@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Signed-off-by: Kamal Mostafa <kamal@canonical.com>
Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
drivers/i2c/busses/i2c-i801.c