Revert "Revert "input: touch: sharp: turn off TOUCH_CLK by default.""
David Pu [Mon, 23 Nov 2015 06:29:28 +0000 (22:29 -0800)]
This reverts commit aea857137f1733436bde5f4b0a9a6b0552e16adc.

Bug 1706267

Change-Id: I1628c717030cdc05fdc235f4aaf22591c1966108
Signed-off-by: David Pu <dpu@nvidia.com>
Reviewed-on: http://git-master/r/836392
(cherry picked from commit e7e977f3bdc9c0d06e73fda8d07447221ddffc36)
Reviewed-on: http://git-master/r/840228
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>

drivers/input/touchscreen/lr388k7_ts.c

index 3d593af..625c5ad 100644 (file)
@@ -2259,8 +2259,9 @@ static struct lr388k7_platform_data *lr388k7_parse_dt(struct device *dev,
        struct lr388k7_platform_data *pdata;
        struct device_node *np = dev->of_node;
        int ret, val, irq_gpio;
+#if defined(ACTIVE_ENABLE)
        const char *str;
-
+#endif
        pdata = devm_kzalloc(dev, sizeof(*pdata), GFP_KERNEL);
        if (!pdata)
                return ERR_PTR(-ENOMEM);
@@ -2312,6 +2313,7 @@ static struct lr388k7_platform_data *lr388k7_parse_dt(struct device *dev,
                goto exit_release_all_gpio;
        pdata->ts_touch_num_max = val;
 
+#if defined(ACTIVE_ENABLE)
        ret = of_property_read_string(np, "name-of-clock", &str);
        if (ret < 0)
                goto exit_release_all_gpio;
@@ -2322,7 +2324,6 @@ static struct lr388k7_platform_data *lr388k7_parse_dt(struct device *dev,
                goto exit_release_all_gpio;
        pdata->name_of_clock_con = (char *)str;
 
-#if defined(ACTIVE_ENABLE)
        pdata->gpio_clk_sel = of_get_named_gpio_flags(np,
                                                      "clock-sel-gpio",
                                                      0,