ARM64: dts: rk3399: fixup android next backlight gpio
[firefly-linux-kernel-4.4.55.git] / drivers / extcon / extcon.c
index 21a123cadf78278947e551aaaa1772a60728969a..a101db469857c053507c86570e22c4c2f6bc5fd9 100644 (file)
@@ -635,7 +635,7 @@ static int create_extcon_class(void)
                        return PTR_ERR(extcon_class);
                extcon_class->dev_groups = extcon_groups;
 
-#if defined(CONFIG_ANDROID)
+#if defined(CONFIG_ANDROID) && !defined(CONFIG_SWITCH)
                switch_class = class_compat_register("switch");
                if (WARN(!switch_class, "cannot allocate"))
                        return -ENOMEM;