static int pega_rfkill_set(void *data, bool blocked) { struct asus_rfkill *rfk = data; int ret = asus_pega_lucid_set(rfk->asus, rfk->control_id, !blocked); return ret; }
static void asus_als_switch(struct asus_laptop *asus, int value) { int ret; if (asus->is_pega_lucid) { ret = asus_pega_lucid_set(asus, PEGA_ALS, value); if (!ret) ret = asus_pega_lucid_set(asus, PEGA_ALS_POWER, value); } else { ret = write_acpi_int(asus->handle, METHOD_ALS_CONTROL, value); } if (ret) pr_warning("Error setting light sensor switch\n"); asus->light_switch = value; }
static int pega_rfkill_set(void *data, bool blocked) { struct asus_pega_rfkill *pega_rfk = data; int ret = asus_pega_lucid_set(pega_rfk->asus, pega_rfk->control_id, !blocked); pr_warn("Setting rfkill %d, to %d; returned %d\n", pega_rfk->control_id, !blocked, ret); return ret; }