struct work_struct work;
struct led_classdev kbd_bl_led;
unsigned long flags;
- uint8_t brightness;
+ u8 brightness;
};
static void yogabook_work(struct work_struct *work)
int r;
data = devm_kzalloc(dev, sizeof(*data), GFP_KERNEL);
- if (data == NULL)
+ if (!data)
return -ENOMEM;
data->kbd_adev = acpi_dev_get_first_match_dev("GDIX1001", NULL, -1);
if (!data->kbd_adev)
- return dev_err_probe(dev, -ENODEV, "Cannot find the touchpad device in ACPI tables\n");
+ return dev_err_probe(dev, -ENODEV,
+ "Cannot find the touchpad device in ACPI tables\n");
data->dig_adev = acpi_dev_get_first_match_dev("WCOM0019", NULL, -1);
if (!data->dig_adev) {
- r = dev_err_probe(dev, -ENODEV, "Cannot find the digitizer device in ACPI tables\n");
+ r = dev_err_probe(dev, -ENODEV,
+ "Cannot find the digitizer device in ACPI tables\n");
goto error_put_devs;
}
int r;
data = devm_kzalloc(dev, sizeof(*data), GFP_KERNEL);
- if (data == NULL)
+ if (!data)
return -ENOMEM;
data->kbd_dev = bus_find_device_by_name(&i2c_bus_type, NULL, "i2c-goodix_ts");