Loading drivers/input/misc/mpu3050.c +0 −51 Original line number Diff line number Diff line Loading @@ -484,54 +484,6 @@ static void mpu3050_set_power_mode(struct i2c_client *client, u8 val) } } /** * mpu3050_input_open - called on input event open * @input: input dev of opened device * * The input layer calls this function when input event is opened. The * function will push the device to resume. Then, the device is ready * to provide data. */ static int mpu3050_input_open(struct input_dev *input) { struct mpu3050_sensor *sensor = input_get_drvdata(input); int error; pm_runtime_get_sync(sensor->dev); /* Enable interrupts */ error = i2c_smbus_write_byte_data(sensor->client, MPU3050_INT_CFG, MPU3050_ACTIVE_LOW | MPU3050_OPEN_DRAIN | MPU3050_RAW_RDY_EN); if (error < 0) { pm_runtime_put(sensor->dev); return error; } if (sensor->use_poll) schedule_delayed_work(&sensor->input_work, msecs_to_jiffies(sensor->poll_interval)); return 0; } /** * mpu3050_input_close - called on input event close * @input: input dev of closed device * * The input layer calls this function when input event is closed. The * function will push the device to suspend. */ static void mpu3050_input_close(struct input_dev *input) { struct mpu3050_sensor *sensor = input_get_drvdata(input); if (sensor->use_poll) cancel_delayed_work_sync(&sensor->input_work); pm_runtime_put(sensor->dev); } /** * mpu3050_interrupt_thread - handle an IRQ * @irq: interrupt numner Loading Loading @@ -750,9 +702,6 @@ static int mpu3050_probe(struct i2c_client *client, idev->name = "MPU3050"; idev->id.bustype = BUS_I2C; idev->open = mpu3050_input_open; idev->close = mpu3050_input_close; input_set_capability(idev, EV_ABS, ABS_MISC); input_set_abs_params(idev, ABS_X, MPU3050_MIN_VALUE, MPU3050_MAX_VALUE, 0, 0); Loading Loading
drivers/input/misc/mpu3050.c +0 −51 Original line number Diff line number Diff line Loading @@ -484,54 +484,6 @@ static void mpu3050_set_power_mode(struct i2c_client *client, u8 val) } } /** * mpu3050_input_open - called on input event open * @input: input dev of opened device * * The input layer calls this function when input event is opened. The * function will push the device to resume. Then, the device is ready * to provide data. */ static int mpu3050_input_open(struct input_dev *input) { struct mpu3050_sensor *sensor = input_get_drvdata(input); int error; pm_runtime_get_sync(sensor->dev); /* Enable interrupts */ error = i2c_smbus_write_byte_data(sensor->client, MPU3050_INT_CFG, MPU3050_ACTIVE_LOW | MPU3050_OPEN_DRAIN | MPU3050_RAW_RDY_EN); if (error < 0) { pm_runtime_put(sensor->dev); return error; } if (sensor->use_poll) schedule_delayed_work(&sensor->input_work, msecs_to_jiffies(sensor->poll_interval)); return 0; } /** * mpu3050_input_close - called on input event close * @input: input dev of closed device * * The input layer calls this function when input event is closed. The * function will push the device to suspend. */ static void mpu3050_input_close(struct input_dev *input) { struct mpu3050_sensor *sensor = input_get_drvdata(input); if (sensor->use_poll) cancel_delayed_work_sync(&sensor->input_work); pm_runtime_put(sensor->dev); } /** * mpu3050_interrupt_thread - handle an IRQ * @irq: interrupt numner Loading Loading @@ -750,9 +702,6 @@ static int mpu3050_probe(struct i2c_client *client, idev->name = "MPU3050"; idev->id.bustype = BUS_I2C; idev->open = mpu3050_input_open; idev->close = mpu3050_input_close; input_set_capability(idev, EV_ABS, ABS_MISC); input_set_abs_params(idev, ABS_X, MPU3050_MIN_VALUE, MPU3050_MAX_VALUE, 0, 0); Loading