Messages in this thread | | | Date | Fri, 03 May 2024 18:59:52 -0600 | From | Lyndon Sanche <> | Subject | Re: [PATCH v5] platform/x86: dell-laptop: Implement platform_profile |
| |
On Fri, May 3 2024 at 11:19:07 PM +02:00:00, Armin Wolf <W_Armin@gmx.de> wrote: > Am 01.05.24 um 23:58 schrieb Lyndon Sanche: >> +static int thermal_init(void) >> +{ >> + int ret; >> + int supported_modes; >> + >> + /* If thermal modes not supported, exit without error */ >> + ret = thermal_get_supported_modes(&supported_modes); >> + if (ret < 0) >> + return ret; > > Hi, > > some older models might not support the USTT commands, which would > prevent dell-laptop > from loading on such machines. > Since dell-smbios-base already knows which commands are supported > (stored in da_supported_commands), > maybe you can add a function for checking if a certain class of > commands is supported and > skip thermal_init() if the USTT commands are not supported. > > Thanks, > Armin Wolf
This is a good idea, I will have a look at dell-smbios-base to see exactly how I can check for support. If support is not available, thermal_init will skip or return 0 (depending on where I put the check).
Thanks,
Lyndon
| |