Advertisement
cheako

Add acpi support to input driver mpu3050.

Sep 24th, 2015
364
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Index: linux-4.1.3/drivers/input/misc/mpu3050.c
  2. ===================================================================
  3. --- linux-4.1.3.orig/drivers/input/misc/mpu3050.c
  4. +++ linux-4.1.3/drivers/input/misc/mpu3050.c
  5. @@ -463,12 +463,22 @@ static const struct of_device_id mpu3050
  6.  };
  7.  MODULE_DEVICE_TABLE(of, mpu3050_of_match);
  8.  
  9. +#ifdef CONFIG_ACPI
  10. +static const struct acpi_device_id mpu3050_acpi_match[] = {
  11. +   { "MPU3050", 0 },
  12. +   { "INVN6500", 1 }, /* T300CHI */
  13. +   { },
  14. +};
  15. +MODULE_DEVICE_TABLE(acpi, mpu3050_acpi_match);
  16. +#endif
  17. +
  18.  static struct i2c_driver mpu3050_i2c_driver = {
  19.     .driver = {
  20.         .name   = "mpu3050",
  21.         .owner  = THIS_MODULE,
  22.         .pm = &mpu3050_pm,
  23.         .of_match_table = mpu3050_of_match,
  24. +       .acpi_match_table = ACPI_PTR(mpu3050_acpi_match),
  25.     },
  26.     .probe      = mpu3050_probe,
  27.     .remove     = mpu3050_remove,
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement