alienware-wmi rework RFC

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi!

I'm planning on migrating the alienware-wmi driver to the new WMI
interface, as it's currently using the deprecated one. My plan is to:

rename alienware-wmi.c -> alienware-wmi-base.c
create alienware-wmi.h
create alienware-wmi-legacy
create alienware-wmi-wmax

The last two files would not be independent modules, just includes for
the base module. The base module would be in charge of initializing the
platform driver plus the correct wmi_driver backend, but the wmi probes 
would register the platform device. This would be very similar to what
other dell drivers already do. Aditionally I want to migrate everything
to the state container design pattern.

I would do this in such a way that the legacy and new code would be
completely independent of each other (i.e. different state containters,
dmi checks, etc).

Pros:
 - Modern interfaces and design patterns
 - This is compatible with Mario's upcoming platform profile changes as
   the WMAX device would hold a reference to the platform device
 - Would not break compatibility as legacy code is independent
 - Easier to understand and develop in the future

Cons:
 - Initialy alienware-wmi-base.c would be almost completely legacy code,
   as new features don't require a platform device (yet), so
   alienware-wmi-base would basically just register the wmax wmi driver
   on newer machines
 - With this design users would not be able to completely exclude legacy
   code with CONFIG parameters

After this I want to add HWMON and sparse keymap capabilities to the
wmax interface.

I'm sure there are things I'm not seeing so feedback is greatly
appreciated!

Regards,
Kurt




[Index of Archives]     [Linux Kernel Development]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux