none
Toggle BIOS option through driver/application RRS feed

  • Question

  • Hi,

    I have a BIOS in which there is an options for enabling and disabling features on a platform. We also have a couple of applications which use this platform feature. What we would like to do is enable this feature in the BIOS only if the application is installed or is about to run. 

    Is there a way to communicate with the BIOS and toggle this option from the program or in a driver?

    I realize i have to restart if i change the bios option.

    The reason for wanting this feature is because the platform sequesters memory from the OS and we do not want to do this unless the application is installed/and or is about to run.

    I have looked at WMI and an example using GetFirmwareEnvironmentVariable(). Are there other ways to achieve this ?


    Friday, October 25, 2013 7:23 PM

Answers

  • You need to work with the BIOS vendor to define a way to programmatically change BIOS settings.  Even if your chosen method of communication is through UEFI environment variables (which is a reasonable choice) you'll still need to work that out directly with the BIOS vendor.

    In the past, this has been done a few different ways, from simple manipulation of the CMOS data at predetermined addresses to the ACPI to WMI mapper (which exposes BIOS data through WMI.)  UEFI variable are probably the most straightforward mechanism if both your BIOS and your OS support UEFI.

    Monday, October 28, 2013 5:05 PM

All replies

  • if the feature takes memory from the OS, how can toggling the feature work at runtime when it is initially off? the OS will be using the memory that will be sequestered, thinking that it owns the memory and then the BIOS magically takes it away? I don't think that will work

    d -- This posting is provided "AS IS" with no warranties, and confers no rights.

    Friday, October 25, 2013 9:02 PM
  • Thanks for the Reply Doron. The idea is that the feature will be initially off. We can detect that the feature is off by reading some registers in a kernel driver. Once we detect that the feature is off, we would like to set a environment variable in NVRAM of the bios(possibly) and restart the system. We can then have the BIOS read the NVRAM env variable and turn the feature on after restart based on weather the variable is set or not in NVRAM. 

    Does that make it clearer ?

    Thanks

    Monday, October 28, 2013 3:26 PM
  • You need to work with the BIOS vendor to define a way to programmatically change BIOS settings.  Even if your chosen method of communication is through UEFI environment variables (which is a reasonable choice) you'll still need to work that out directly with the BIOS vendor.

    In the past, this has been done a few different ways, from simple manipulation of the CMOS data at predetermined addresses to the ACPI to WMI mapper (which exposes BIOS data through WMI.)  UEFI variable are probably the most straightforward mechanism if both your BIOS and your OS support UEFI.

    Monday, October 28, 2013 5:05 PM