if (of_find_property(node, "wifi-bt-power-toggle", NULL)) {
data->power_toggle = true;
- LOG("%s: get property wifi-bt-power-toggle.\n");
+ LOG("%s: get property wifi-bt-power-toggle.\n", __func__);
} else {
data->power_toggle = false;
}
ret = rfkill_rk_setup_gpio(pdev, &pdata->wake_gpio, pdata->name, "wake");
if (ret) goto fail_gpio;
- ret = rfkill_rk_setup_wake_irq(rfkill);
+ ret = rfkill_rk_setup_gpio(pdev, &pdata->rts_gpio, rfkill->pdata->name, "rts");
if (ret) goto fail_gpio;
- ret = rfkill_rk_setup_gpio(pdev, &pdata->rts_gpio, rfkill->pdata->name, "rts");
+ wake_lock_init(&(rfkill->bt_irq_wl), WAKE_LOCK_SUSPEND, "rfkill_rk_irq_wl");
+
+ ret = rfkill_rk_setup_wake_irq(rfkill);
if (ret) goto fail_gpio;
DBG("setup rfkill\n");
if (ret < 0)
goto fail_rfkill;
- wake_lock_init(&(rfkill->bt_irq_wl), WAKE_LOCK_SUSPEND, "rfkill_rk_irq_wl");
INIT_DELAYED_WORK(&rfkill->bt_sleep_delay_work, rfkill_rk_delay_sleep_bt);
//rfkill_rk_set_power(rfkill, BT_BLOCKED);