diff options
author | Leilk Liu <leilk.liu@mediatek.com> | 2015-12-30 21:59:00 -0500 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2015-12-31 17:09:59 -0500 |
commit | 4eaf6f730355ce3725dd8c98e62696ec4c507e9b (patch) | |
tree | be4717146574cc549bd7ccf08017ca173ffdaa8d | |
parent | 5c5e09f623d5984532a74b90d3d24e1caa99bc9f (diff) |
spi: mediatek: merge all identical compat to mtk_common_compat
This patch merge all identical compat into on mtk_common_compat
and used for all compatible soc.
Signed-off-by: Leilk Liu <leilk.liu@mediatek.com>
Reviewed-by: Matthias Brugger <matthias.bgg@gmail.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
-rw-r--r-- | drivers/spi/spi-mt65xx.c | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/drivers/spi/spi-mt65xx.c b/drivers/spi/spi-mt65xx.c index 00a36dacfe2f..917c564edd4a 100644 --- a/drivers/spi/spi-mt65xx.c +++ b/drivers/spi/spi-mt65xx.c | |||
@@ -95,8 +95,7 @@ struct mtk_spi { | |||
95 | const struct mtk_spi_compatible *dev_comp; | 95 | const struct mtk_spi_compatible *dev_comp; |
96 | }; | 96 | }; |
97 | 97 | ||
98 | static const struct mtk_spi_compatible mt6589_compat; | 98 | static const struct mtk_spi_compatible mtk_common_compat; |
99 | static const struct mtk_spi_compatible mt8135_compat; | ||
100 | static const struct mtk_spi_compatible mt8173_compat = { | 99 | static const struct mtk_spi_compatible mt8173_compat = { |
101 | .need_pad_sel = true, | 100 | .need_pad_sel = true, |
102 | .must_tx = true, | 101 | .must_tx = true, |
@@ -112,9 +111,15 @@ static const struct mtk_chip_config mtk_default_chip_info = { | |||
112 | }; | 111 | }; |
113 | 112 | ||
114 | static const struct of_device_id mtk_spi_of_match[] = { | 113 | static const struct of_device_id mtk_spi_of_match[] = { |
115 | { .compatible = "mediatek,mt6589-spi", .data = (void *)&mt6589_compat }, | 114 | { .compatible = "mediatek,mt6589-spi", |
116 | { .compatible = "mediatek,mt8135-spi", .data = (void *)&mt8135_compat }, | 115 | .data = (void *)&mtk_common_compat, |
117 | { .compatible = "mediatek,mt8173-spi", .data = (void *)&mt8173_compat }, | 116 | }, |
117 | { .compatible = "mediatek,mt8135-spi", | ||
118 | .data = (void *)&mtk_common_compat, | ||
119 | }, | ||
120 | { .compatible = "mediatek,mt8173-spi", | ||
121 | .data = (void *)&mt8173_compat, | ||
122 | }, | ||
118 | {} | 123 | {} |
119 | }; | 124 | }; |
120 | MODULE_DEVICE_TABLE(of, mtk_spi_of_match); | 125 | MODULE_DEVICE_TABLE(of, mtk_spi_of_match); |