.. | .. |
---|
528 | 528 | return devm_iio_device_register(&client->dev, indio_dev); |
---|
529 | 529 | } |
---|
530 | 530 | |
---|
| 531 | +static const struct of_device_id max44009_of_match[] = { |
---|
| 532 | + { .compatible = "maxim,max44009" }, |
---|
| 533 | + { } |
---|
| 534 | +}; |
---|
| 535 | +MODULE_DEVICE_TABLE(of, max44009_of_match); |
---|
| 536 | + |
---|
531 | 537 | static const struct i2c_device_id max44009_id[] = { |
---|
532 | 538 | { "max44009", 0 }, |
---|
533 | 539 | { } |
---|
.. | .. |
---|
537 | 543 | static struct i2c_driver max44009_driver = { |
---|
538 | 544 | .driver = { |
---|
539 | 545 | .name = MAX44009_DRV_NAME, |
---|
| 546 | + .of_match_table = max44009_of_match, |
---|
540 | 547 | }, |
---|
541 | 548 | .probe = max44009_probe, |
---|
542 | 549 | .id_table = max44009_id, |
---|
543 | 550 | }; |
---|
544 | 551 | module_i2c_driver(max44009_driver); |
---|
545 | | - |
---|
546 | | -static const struct of_device_id max44009_of_match[] = { |
---|
547 | | - { .compatible = "maxim,max44009" }, |
---|
548 | | - { } |
---|
549 | | -}; |
---|
550 | | -MODULE_DEVICE_TABLE(of, max44009_of_match); |
---|
551 | 552 | |
---|
552 | 553 | MODULE_AUTHOR("Robert Eshleman <bobbyeshleman@gmail.com>"); |
---|
553 | 554 | MODULE_LICENSE("GPL v2"); |
---|