Linux Input/HID development
 help / color / mirror / Atom feed
* [PATCH hid-next] HID: amd_sfh: Set the AMD SFH driver to depend on x86
@ 2024-02-28 11:39 Basavaraj Natikar
  2024-02-28 12:11 ` Jiri Kosina
  0 siblings, 1 reply; 2+ messages in thread
From: Basavaraj Natikar @ 2024-02-28 11:39 UTC (permalink / raw)
  To: jikos, benjamin.tissoires, linux-input
  Cc: Basavaraj Natikar, Stephen Rothwell

Considering that amd_sfh exists only on AMD platforms, set the AMD SFH
driver to depend on x86 to avoid build warnings or errors on other
architectures, as shown below.

drivers/hid/amd-sfh-hid/amd_sfh_pcie.c: In function 'amd_mp2_pci_probe':
drivers/hid/amd-sfh-hid/amd_sfh_pcie.c:413:21: error: 'boot_cpu_data'
undeclared (first use in this function); did you mean 'boot_cpu_hwid'?
  413 |                 if (boot_cpu_data.x86 >= 0x1A)
      |                     ^~~~~~~~~~~~~
      |                     boot_cpu_hwid

Fixes: 6296562f30b1 ("HID: amd_sfh: Extend MP2 register access to SFH")
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Closes: https://lore.kernel.org/all/20240228145648.41c493ec@canb.auug.org.au/
Signed-off-by: Basavaraj Natikar <Basavaraj.Natikar@amd.com>
---
 drivers/hid/amd-sfh-hid/Kconfig | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/hid/amd-sfh-hid/Kconfig b/drivers/hid/amd-sfh-hid/Kconfig
index af752dd3a340..329de5e12c1a 100644
--- a/drivers/hid/amd-sfh-hid/Kconfig
+++ b/drivers/hid/amd-sfh-hid/Kconfig
@@ -6,6 +6,7 @@ menu "AMD SFH HID Support"
 config AMD_SFH_HID
 	tristate "AMD Sensor Fusion Hub"
 	depends on HID
+	depends on X86
 	help
 	  If you say yes to this option, support will be included for the
 	  AMD Sensor Fusion Hub.
-- 
2.25.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH hid-next] HID: amd_sfh: Set the AMD SFH driver to depend on x86
  2024-02-28 11:39 [PATCH hid-next] HID: amd_sfh: Set the AMD SFH driver to depend on x86 Basavaraj Natikar
@ 2024-02-28 12:11 ` Jiri Kosina
  0 siblings, 0 replies; 2+ messages in thread
From: Jiri Kosina @ 2024-02-28 12:11 UTC (permalink / raw)
  To: Basavaraj Natikar; +Cc: benjamin.tissoires, linux-input, Stephen Rothwell

On Wed, 28 Feb 2024, Basavaraj Natikar wrote:

> Considering that amd_sfh exists only on AMD platforms, set the AMD SFH
> driver to depend on x86 to avoid build warnings or errors on other
> architectures, as shown below.
> 
> drivers/hid/amd-sfh-hid/amd_sfh_pcie.c: In function 'amd_mp2_pci_probe':
> drivers/hid/amd-sfh-hid/amd_sfh_pcie.c:413:21: error: 'boot_cpu_data'
> undeclared (first use in this function); did you mean 'boot_cpu_hwid'?
>   413 |                 if (boot_cpu_data.x86 >= 0x1A)
>       |                     ^~~~~~~~~~~~~
>       |                     boot_cpu_hwid
> 
> Fixes: 6296562f30b1 ("HID: amd_sfh: Extend MP2 register access to SFH")
> Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
> Closes: https://lore.kernel.org/all/20240228145648.41c493ec@canb.auug.org.au/
> Signed-off-by: Basavaraj Natikar <Basavaraj.Natikar@amd.com>

Applied, thanks.

-- 
Jiri Kosina
SUSE Labs


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-02-28 12:11 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-28 11:39 [PATCH hid-next] HID: amd_sfh: Set the AMD SFH driver to depend on x86 Basavaraj Natikar
2024-02-28 12:11 ` Jiri Kosina

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox