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

Commit 43ff39f2 authored by Thomas Sujith's avatar Thomas Sujith Committed by Len Brown
Browse files

ACPI video: check for error from thermal_cooling_device_register



Need to check whether thermal_cooling_device_register
returned ERROR or not.

Signed-off-by: default avatarThomas Sujith <sujith.thomas@intel.com>
Signed-off-by: default avatarLen Brown <len.brown@intel.com>
parent d76628c6
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -731,6 +731,9 @@ static void acpi_video_device_find_cap(struct acpi_video_device *device)

		device->cdev = thermal_cooling_device_register("LCD",
					device->dev, &video_cooling_ops);
		if (IS_ERR(device->cdev))
			return;

		if (device->cdev) {
			printk(KERN_INFO PREFIX
				"%s is registered as cooling_device%d\n",