[9/9] spi/pxa2xx: pass of_node to spi device and set a parent device
diff mbox

Message ID 1290597207-29838-10-git-send-email-bigeasy@linutronix.de
State Superseded, archived
Headers show

Commit Message

Sebastian Andrzej Siewior Nov. 24, 2010, 11:13 a.m. UTC
None

Patch
diff mbox

diff --git a/drivers/spi/pxa2xx_spi.c b/drivers/spi/pxa2xx_spi.c
index 5c8c6e3..6d3cb79 100644
--- a/drivers/spi/pxa2xx_spi.c
+++ b/drivers/spi/pxa2xx_spi.c
@@ -1556,6 +1556,10 @@  static int __init pxa2xx_spi_probe(struct platform_device *pdev)
 	drv_data->pdev = pdev;
 	drv_data->ssp = ssp;
 
+	master->dev.parent = &pdev->dev;
+#ifdef CONFIG_OF
+	master->dev.of_node = pdev->dev.of_node;
+#endif
 	/* the spi->mode bits understood by this driver: */
 	master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH;