Return ENODEV when model is not matched

This commit is contained in:
Jeremy Soller 2018-09-04 10:14:37 -06:00
parent c523cdb570
commit ade5ee8b80
1 changed files with 4 additions and 1 deletions

View File

@ -264,7 +264,10 @@ static struct dmi_system_id s76_dmi_table[] __initdata = {
MODULE_DEVICE_TABLE(dmi, s76_dmi_table);
static int __init s76_init(void) {
dmi_check_system(s76_dmi_table);
if (!dmi_check_system(s76_dmi_table) > 0) {
S76_INFO("Model does not utilize this driver");
return -ENODEV;
}
if (!wmi_has_guid(S76_EVENT_GUID)) {
S76_INFO("No known WMI event notification GUID found\n");