diff options
Diffstat (limited to 'drivers/spi/spi_mpc8xxx.c')
-rw-r--r-- | drivers/spi/spi_mpc8xxx.c | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/drivers/spi/spi_mpc8xxx.c b/drivers/spi/spi_mpc8xxx.c index e324627d97a2..75b7f8c0babc 100644 --- a/drivers/spi/spi_mpc8xxx.c +++ b/drivers/spi/spi_mpc8xxx.c | |||
@@ -797,7 +797,7 @@ static void mpc8xxx_spi_free_dummy_rx(void) | |||
797 | static unsigned long mpc8xxx_spi_cpm_get_pram(struct mpc8xxx_spi *mspi) | 797 | static unsigned long mpc8xxx_spi_cpm_get_pram(struct mpc8xxx_spi *mspi) |
798 | { | 798 | { |
799 | struct device *dev = mspi->dev; | 799 | struct device *dev = mspi->dev; |
800 | struct device_node *np = dev_archdata_get_node(&dev->archdata); | 800 | struct device_node *np = dev->of_node; |
801 | const u32 *iprop; | 801 | const u32 *iprop; |
802 | int size; | 802 | int size; |
803 | unsigned long spi_base_ofs; | 803 | unsigned long spi_base_ofs; |
@@ -851,7 +851,7 @@ static unsigned long mpc8xxx_spi_cpm_get_pram(struct mpc8xxx_spi *mspi) | |||
851 | static int mpc8xxx_spi_cpm_init(struct mpc8xxx_spi *mspi) | 851 | static int mpc8xxx_spi_cpm_init(struct mpc8xxx_spi *mspi) |
852 | { | 852 | { |
853 | struct device *dev = mspi->dev; | 853 | struct device *dev = mspi->dev; |
854 | struct device_node *np = dev_archdata_get_node(&dev->archdata); | 854 | struct device_node *np = dev->of_node; |
855 | const u32 *iprop; | 855 | const u32 *iprop; |
856 | int size; | 856 | int size; |
857 | unsigned long pram_ofs; | 857 | unsigned long pram_ofs; |
@@ -1123,7 +1123,7 @@ static void mpc8xxx_spi_cs_control(struct spi_device *spi, bool on) | |||
1123 | 1123 | ||
1124 | static int of_mpc8xxx_spi_get_chipselects(struct device *dev) | 1124 | static int of_mpc8xxx_spi_get_chipselects(struct device *dev) |
1125 | { | 1125 | { |
1126 | struct device_node *np = dev_archdata_get_node(&dev->archdata); | 1126 | struct device_node *np = dev->of_node; |
1127 | struct fsl_spi_platform_data *pdata = dev->platform_data; | 1127 | struct fsl_spi_platform_data *pdata = dev->platform_data; |
1128 | struct mpc8xxx_spi_probe_info *pinfo = to_of_pinfo(pdata); | 1128 | struct mpc8xxx_spi_probe_info *pinfo = to_of_pinfo(pdata); |
1129 | unsigned int ngpios; | 1129 | unsigned int ngpios; |
@@ -1224,7 +1224,7 @@ static int __devinit of_mpc8xxx_spi_probe(struct of_device *ofdev, | |||
1224 | const struct of_device_id *ofid) | 1224 | const struct of_device_id *ofid) |
1225 | { | 1225 | { |
1226 | struct device *dev = &ofdev->dev; | 1226 | struct device *dev = &ofdev->dev; |
1227 | struct device_node *np = ofdev->node; | 1227 | struct device_node *np = ofdev->dev.of_node; |
1228 | struct mpc8xxx_spi_probe_info *pinfo; | 1228 | struct mpc8xxx_spi_probe_info *pinfo; |
1229 | struct fsl_spi_platform_data *pdata; | 1229 | struct fsl_spi_platform_data *pdata; |
1230 | struct spi_master *master; | 1230 | struct spi_master *master; |
@@ -1312,8 +1312,11 @@ static const struct of_device_id of_mpc8xxx_spi_match[] = { | |||
1312 | MODULE_DEVICE_TABLE(of, of_mpc8xxx_spi_match); | 1312 | MODULE_DEVICE_TABLE(of, of_mpc8xxx_spi_match); |
1313 | 1313 | ||
1314 | static struct of_platform_driver of_mpc8xxx_spi_driver = { | 1314 | static struct of_platform_driver of_mpc8xxx_spi_driver = { |
1315 | .name = "mpc8xxx_spi", | 1315 | .driver = { |
1316 | .match_table = of_mpc8xxx_spi_match, | 1316 | .name = "mpc8xxx_spi", |
1317 | .owner = THIS_MODULE, | ||
1318 | .of_match_table = of_mpc8xxx_spi_match, | ||
1319 | }, | ||
1317 | .probe = of_mpc8xxx_spi_probe, | 1320 | .probe = of_mpc8xxx_spi_probe, |
1318 | .remove = __devexit_p(of_mpc8xxx_spi_remove), | 1321 | .remove = __devexit_p(of_mpc8xxx_spi_remove), |
1319 | }; | 1322 | }; |