lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Tue, 25 Apr 2023 16:59:40 +0200
From:   Hans de Goede <hdegoede@...hat.com>
To:     Jorge Lopez <jorgealtxwork@...il.com>
Cc:     Armin Wolf <W_Armin@....de>, platform-driver-x86@...r.kernel.org,
        linux-kernel@...r.kernel.org, thomas@...ch.de
Subject: Re: [PATCH v10 03/14] HP BIOSCFG driver - bioscfg

Hi,

On 4/25/23 16:32, Jorge Lopez wrote:
> On Tue, Apr 25, 2023 at 5:34 AM Hans de Goede <hdegoede@...hat.com> wrote:
>>
>> Hi All,
>>
>> On 4/19/23 20:04, Armin Wolf wrote:
>>> Am 19.04.23 um 17:13 schrieb Jorge Lopez:
>>
>> <snip>
>>
>>>> +static int __init bioscfg_init(void)
>>>> +{
>>>> +    int ret = 0;
>>>> +    int bios_capable = wmi_has_guid(HP_WMI_BIOS_GUID);
>>>> +
>>>> +    if (!bios_capable) {
>>>> +        pr_err("Unable to run on non-HP system\n");
>>>> +        return -ENODEV;
>>>> +    }
>>>> +
>>>
>>> Currently, this driver will no get automatically loaded on supported hardware,
>>> something which would be quite beneficial for users to have.
>>> Since the HP_WMI_BIOS_GUID is already handled by the hp-wmi driver, maybe this
>>> driver (which also already implements a function similar to hp_wmi_perform_query())
>>> could register a platform device which is then used by this driver? This together
>>> with MODULE_DEVICE_TABLE() would allow for automatically loading the module on supported hardware.
>>
>> Both drivers can already co-exist since the old hp-wmi driver uses the old
>> wmi kernel functions and is not a "wmi_driver" so there is no need for
>> a platform_device for this driver to bind to since the wmi_device is
>> still free for it to bind to.
>>
>> This does indeed need a MODULE_DEVICE_TABLE() statement for
>> the bios_attr_pass_interface_id_table[] id-table. Note only for that
>> table, because the HP_WMI_BIOS_GUID is present on models which do
>> not support this and we don't want the module to auto-load there.
>>
> 
> I am considering adding a check for the  HP_WMI_SET_BIOS_SETTING_GUID
> and HP_WMI_BIOS_GUID during the initialization process.
> The driver will report a message If HP_WMI_SET_BIOS_SETTING_GUID is
> found or not.
> If HP_WMI_SET_BIOS_SETTING_GUID does not exist, the driver cannot
> change the BIOS settings.

Right, adding a check for  HP_WMI_BIOS_GUID to bioscfg_init()
sounds like a good idea.

That + add a a MODULE_DEVICE_TABLE() statement to
the bios_attr_pass_interface_id_table[] id-table.

Regards,

Hans


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ