thermal: return an error on failure to register thermal class
[pandora-kernel.git] / drivers / thermal / thermal_sys.c
index 6472e7e..1a19a2f 100644 (file)
@@ -1875,6 +1875,7 @@ static int __init thermal_init(void)
                idr_destroy(&thermal_cdev_idr);
                mutex_destroy(&thermal_idr_lock);
                mutex_destroy(&thermal_list_lock);
+               return result;
        }
        result = genetlink_init();
        return result;