Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8d039bc7 authored by Carlos Corbacho's avatar Carlos Corbacho Committed by Len Brown
Browse files

acer-wmi: Make device detection error messages more descriptive



The current device detection error messages are all copy & pasted - make
them more descriptive so it's easier to see where in the code a problem
occurs.

Signed-off-by: default avatarCarlos Corbacho <carlos@strangeworlds.co.uk>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent a527f2d7
Loading
Loading
Loading
Loading
+7 −5
Original line number Original line Diff line number Diff line
@@ -1052,11 +1052,12 @@ static int __init acer_wmi_init(void)


	if (wmi_has_guid(WMID_GUID2) && interface) {
	if (wmi_has_guid(WMID_GUID2) && interface) {
		if (ACPI_FAILURE(WMID_set_capabilities())) {
		if (ACPI_FAILURE(WMID_set_capabilities())) {
			printk(ACER_ERR "Unable to detect available devices\n");
			printk(ACER_ERR "Unable to detect available WMID "
					"devices\n");
			return -ENODEV;
			return -ENODEV;
		}
		}
	} else if (!wmi_has_guid(WMID_GUID2) && interface) {
	} else if (!wmi_has_guid(WMID_GUID2) && interface) {
		printk(ACER_ERR "Unable to detect available devices\n");
		printk(ACER_ERR "No WMID device detection method found\n");
		return -ENODEV;
		return -ENODEV;
	}
	}


@@ -1064,7 +1065,8 @@ static int __init acer_wmi_init(void)
		interface = &AMW0_interface;
		interface = &AMW0_interface;


		if (ACPI_FAILURE(AMW0_set_capabilities())) {
		if (ACPI_FAILURE(AMW0_set_capabilities())) {
			printk(ACER_ERR "Unable to detect available devices\n");
			printk(ACER_ERR "Unable to detect available AMW0 "
					"devices\n");
			return -ENODEV;
			return -ENODEV;
		}
		}
	}
	}
@@ -1075,8 +1077,8 @@ static int __init acer_wmi_init(void)
	find_quirks();
	find_quirks();


	if (!interface) {
	if (!interface) {
		printk(ACER_ERR "No or unsupported WMI interface, unable to ");
		printk(ACER_ERR "No or unsupported WMI interface, unable to "
		printk(KERN_CONT "load.\n");
				"load\n");
		return -ENODEV;
		return -ENODEV;
	}
	}