mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-22 02:20:40 +00:00
HID: amd_sfh: Don't show client init failed as error when discovery fails
[ Upstream commite51d8d3ea3
] When sensor discovery fails, this means that the system doesn't have any sensors connected and a user should only be notified at most one time. A message is already displayed at WARN level of "failed to discover, sensors not enabled". It's pointless to show that the client init failed at ERR level for the same condition. Check the return code and don't display this message in those conditions. Fixes:b5d7f43e97
("HID: amd_sfh: Add support for sensor discovery") Reported-by: David Chang <David.Chang@amd.com> Signed-off-by: Mario Limonciello <mario.limonciello@amd.com> Acked-by: Basavaraj Natikar <Basavaraj.Natikar@amd.com> Signed-off-by: Jiri Kosina <jkosina@suse.cz> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
parent
c36369f7db
commit
36c27d813e
1 changed files with 2 additions and 1 deletions
|
@ -323,7 +323,8 @@ static int amd_mp2_pci_probe(struct pci_dev *pdev, const struct pci_device_id *i
|
|||
rc = amd_sfh_hid_client_init(privdata);
|
||||
if (rc) {
|
||||
amd_sfh_clear_intr(privdata);
|
||||
dev_err(&pdev->dev, "amd_sfh_hid_client_init failed\n");
|
||||
if (rc != -EOPNOTSUPP)
|
||||
dev_err(&pdev->dev, "amd_sfh_hid_client_init failed\n");
|
||||
return rc;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue