On Sat, Apr 29, 2023 at 9:16 PM Hans de Goede <hdegoede@xxxxxxxxxx> wrote: > > Change the yogabook_wmi_ prefix of remaining generic (non WMI specific) > symbols to yogabook_ . > > This is a preparation patch for making lenovo-yogabook-wmi also work > on the Android version of the Yoga Book 1 which does not have a WMI > interface to deal with toggling the keyboard half between > touch-keyboard and wacom-digitizer mode. ... > - struct yogabook_wmi *data = > - container_of(cdev, struct yogabook_wmi, kbd_bl_led); > + struct yogabook_data *data = > + container_of(cdev, struct yogabook_data, kbd_bl_led); ... > - struct yogabook_wmi *data = > - container_of(cdev, struct yogabook_wmi, kbd_bl_led); > + struct yogabook_data *data = > + container_of(cdev, struct yogabook_data, kbd_bl_led); Perhaps a helper as many other drivers do? #define ... container_of() or even static inline. Also consider constification of the data passed here and there (if it makes sense). -- With Best Regards, Andy Shevchenko