lkml.org 
[lkml]   [2016]   [Feb]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v3 3/5] dell-wmi: enable receiving WMI events on Dell Vostro V131
> >  static void __exit dell_wmi_exit(void)
> > {
> > + struct calling_interface_buffer *buffer;
> > +
> > + if (wmi_requires_smbios_request) {
> > + buffer = dell_smbios_get_buffer();
> > + buffer->input[0] = 0x10000;
> > + buffer->input[1] = 0x51534554;
> > + dell_smbios_send_request(17, 3);
> > + dell_smbios_release_buffer();
> > + }
> > +
> > wmi_remove_notify_handler(DELL_EVENT_GUID);
> > dell_wmi_input_destroy();
> > }
>
> Hi! I would propose moving this get_buffer, send, release code into own
> function with boolean argument on/off. This de-duplicate same code plus
> decrease level of indentation in _init function. And maybe adding ascii
> string comment representation for that 0x5153... number can be useful.

Ah, yes, sure. I will do that in v4.

--
Best regards,
Michał Kępień

\
 
 \ /
  Last update: 2016-02-16 23:21    [W:0.222 / U:0.264 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site