.. | .. |
---|
6 | 6 | */ |
---|
7 | 7 | |
---|
8 | 8 | #include <linux/err.h> |
---|
| 9 | +#include <linux/mod_devicetable.h> |
---|
9 | 10 | #include <linux/module.h> |
---|
10 | 11 | #include <linux/mux/driver.h> |
---|
11 | | -#include <linux/of_platform.h> |
---|
12 | 12 | #include <linux/property.h> |
---|
13 | 13 | #include <linux/spi/spi.h> |
---|
14 | 14 | |
---|
.. | .. |
---|
59 | 59 | s32 idle_state; |
---|
60 | 60 | int ret; |
---|
61 | 61 | |
---|
62 | | - chip_id = (enum adgs1408_chip_id)of_device_get_match_data(dev); |
---|
| 62 | + chip_id = (enum adgs1408_chip_id)device_get_match_data(dev); |
---|
63 | 63 | if (!chip_id) |
---|
64 | 64 | chip_id = spi_get_device_id(spi)->driver_data; |
---|
65 | 65 | |
---|
.. | .. |
---|
93 | 93 | mux->idle_state = idle_state; |
---|
94 | 94 | break; |
---|
95 | 95 | } |
---|
96 | | - /* fall through */ |
---|
| 96 | + fallthrough; |
---|
97 | 97 | default: |
---|
98 | 98 | dev_err(dev, "invalid idle-state %d\n", idle_state); |
---|
99 | 99 | return -EINVAL; |
---|
.. | .. |
---|
119 | 119 | static struct spi_driver adgs1408_driver = { |
---|
120 | 120 | .driver = { |
---|
121 | 121 | .name = "adgs1408", |
---|
122 | | - .of_match_table = of_match_ptr(adgs1408_of_match), |
---|
| 122 | + .of_match_table = adgs1408_of_match, |
---|
123 | 123 | }, |
---|
124 | 124 | .probe = adgs1408_probe, |
---|
125 | 125 | .id_table = adgs1408_spi_id, |
---|