[PATCH 0/2][RESEND] oem: add oem-specific tests for verifying BIOS interfaces

Colin Ian King colin.king at canonical.com
Mon Dec 10 14:35:44 UTC 2012


On 10/12/12 08:40, Alex Hung wrote:
> Each OEM (i.e. hp, dell, acer, asus and so on) has different set of BIOS
> interfaces for implementing OEM features, such as wireless device controls and
> special power management, that are not defined in ACPI specification.
>
> It may worth noting that the kernel module is not integrated into fwts, i.e. it
> will not be compiled with fwts. The intended behaviors is not to make a dkms
> package to replace the origin kernel module, but is to do the following
> (using hp-wmi as an example):
>
> 1. rmmod original hp-wmi.ko
> 2. insmod new hp-wmi.ko
> 3. run the tests
> 4. rmmod new hp-wmi.ko
> 5. insmod original hp-wmi.ko
>
> Does the above make sense? Any comments are appreciated.

I'm in favour of fwts doing this automatically if requested. We can 
check for WMI GUIDs:

95F24279-4D7B-4334-9387-ACCDC67EF61C
5FB7F034-2C63-45e9-BE91-3D44E2C707E4

..and then kick off the test if they match.  The test would then unload 
the original hp-wmi driver, load the test version, do the test, and then 
unload the test version and load the original version.

So we should probably add a new a fwts helper function in 
src/lib/src/fwts_wmi.c where one passes in an array of GUIDs to check 
for and it returns true of the firmware matches. See the attached 
example code (not tested!).  You call this with the GUIDs you expect to 
see, and if they are present then you can run do the module handling and 
run the test.

Colin



>
> Alex Hung (2):
>    oem: wireless: add tests for toggling the states of wireless device,
>         including WIFI, Bluetooth and WWAN (3G), via a kernel interface
>      that     will be created for different OEM systems (i.e. ASUS,
>      Dell, HP, and     so on).
>    oem: the kernel module creates an ioctl sys nodes for testing hp's
>       WMI interface. This interface currently supports WMI command 0x1b,
>          including get and set functions.
>
>   oem/Makefile                |    6 +
>   oem/hp-wmi.c                |  533 +++++++++++++++++++++++++++++++++++++++++++
>   src/Makefile.am             |    3 +-
>   src/oem/wireless/wireless.c |  189 +++++++++++++++
>   4 files changed, 730 insertions(+), 1 deletion(-)
>   create mode 100644 oem/Makefile
>   create mode 100644 oem/hp-wmi.c
>   create mode 100644 src/oem/wireless/wireless.c
>

-------------- next part --------------
A non-text attachment was scrubbed...
Name: fwts_guids.c
Type: text/x-csrc
Size: 2227 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/fwts-devel/attachments/20121210/e880e37d/attachment.c>


More information about the fwts-devel mailing list