lkml.org 
[lkml]   [2022]   [Dec]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] HID: amd_sfh: Add support for tablet-mode-switch sensor
On Thu, 15 Dec 2022, Adrian Freund wrote:

> > In file included from drivers/hid/amd-sfh-hid/sfh1_1/amd_sfh_desc.c:15:
> >>> drivers/hid/amd-sfh-hid/sfh1_1/../hid_descriptor/amd_sfh_hid_report_desc.h:649:17:
> >>> warning: 'tms_report_descriptor' defined but not used
> >>> [-Wunused-const-variable=]
> > 649 | static const u8 tms_report_descriptor[] = {
> > | ^~~~~~~~~~~~~~~~~~~~~
> hid_descriptor/amd_sfh_hid_report_desc.h is included from both
> hid_descriptor/amd_sfh_hid_desc.c and sfh1_1/amd_sfh_desc.c, the first of
> which has 4 usages of tms_report_descriptor. The later is for sensor fusion
> hub 1.1. I don't have access to a devices using sfh1.1, so I can't add support
> for the tablet mode switch there, causing the variable to be unused for that
> import.

I'd say either move the rdesc directly to
hid_descriptor/amd_sfh_hid_desc.c, or alternatively mark it with
__attribute__((used)).

--
Jiri Kosina
SUSE Labs

\
 
 \ /
  Last update: 2022-12-15 11:28    [W:0.050 / U:0.776 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site