From: Mario Limonciello <superm1@kernel.org>
To: Basavaraj Natikar <basavaraj.natikar@amd.com>,
Jiri Kosina <jikos@kernel.org>,
Benjamin Tissoires <bentiss@kernel.org>
Cc: linux-kernel@vger.kernel.org (open list),
linux-input@vger.kernel.org (open list:AMD SENSOR FUSION HUB
DRIVER), Mario Limonciello <mario.limonciello@amd.com>,
Pratap Nirujogi <pratap.nirujogi@amd.com>,
Anson Tsao <anson.tsao@amd.com>
Subject: [PATCH 3/3] HID: amd_sfh: Don't show wrong status for amd_sfh_hpd_info()
Date: Fri, 28 Feb 2025 10:31:53 -0600 [thread overview]
Message-ID: <20250228163153.2554935-4-superm1@kernel.org> (raw)
In-Reply-To: <20250228163153.2554935-1-superm1@kernel.org>
From: Mario Limonciello <mario.limonciello@amd.com>
When HPD is present but has been disabled, avoid reporting HPD status
to PMF.
Cc: Pratap Nirujogi <pratap.nirujogi@amd.com>
Tested-by: Anson Tsao <anson.tsao@amd.com>
Signed-off-by: Mario Limonciello <mario.limonciello@amd.com>
---
drivers/hid/amd-sfh-hid/sfh1_1/amd_sfh_interface.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/hid/amd-sfh-hid/sfh1_1/amd_sfh_interface.c b/drivers/hid/amd-sfh-hid/sfh1_1/amd_sfh_interface.c
index ffb98b4c36cbd..837d59e7a6610 100644
--- a/drivers/hid/amd-sfh-hid/sfh1_1/amd_sfh_interface.c
+++ b/drivers/hid/amd-sfh-hid/sfh1_1/amd_sfh_interface.c
@@ -129,7 +129,7 @@ static int amd_sfh_hpd_info(u8 *user_present)
if (!user_present)
return -EINVAL;
- if (!emp2 || !emp2->dev_en.is_hpd_present)
+ if (!emp2 || !emp2->dev_en.is_hpd_present || !emp2->dev_en.is_hpd_enabled)
return -ENODEV;
hpdstatus.val = readl(emp2->mmio + amd_get_c2p_val(emp2, 4));
--
2.43.0
next prev parent reply other threads:[~2025-02-28 16:32 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-02-28 16:31 [PATCH 0/3] Adjust behavior for HPD sensor Mario Limonciello
2025-02-28 16:31 ` [PATCH 1/3] HID: amd_sfh: Allow configuring whether HPD is enabled or disabled Mario Limonciello
2025-02-28 16:31 ` [PATCH 2/3] HID: amd_sfh: Default to HPD disabled Mario Limonciello
2025-02-28 16:31 ` Mario Limonciello [this message]
2025-03-04 20:50 ` [PATCH 0/3] Adjust behavior for HPD sensor Jiri Kosina
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20250228163153.2554935-4-superm1@kernel.org \
--to=superm1@kernel.org \
--cc=anson.tsao@amd.com \
--cc=basavaraj.natikar@amd.com \
--cc=bentiss@kernel.org \
--cc=jikos@kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mario.limonciello@amd.com \
--cc=pratap.nirujogi@amd.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.