[PATCH 06/10] ARM: Samsung: Modify s3c64xx_spi{0|1|2}_set_platdata function

Heiko Stübner heiko at sntech.de
Wed May 9 19:10:14 EST 2012


Am Mittwoch, 9. Mai 2012, 10:56:17 schrieb Mark Brown:
> On Wed, May 09, 2012 at 03:34:50AM +0530, Thomas Abraham wrote:
> > +	s3c64xx_spi0_set_platdata("s3c6410-spi", NULL, 0, 1);
> 
> Shouldn't we just set the name in the struct platform_device rather than
> requiring the machine to pass it through by hand?

Similar to the adc and rtc driver, all Samsung platforms reuse a common 
platform-device definition for the s3c64xx-spi and simply will set the correct 
name when the machine type is determined during boot.

I.e. I will also have to change my out-of-tree machine stuff to set the 
s3c2443-spi name using this method.

The alternative is creating a mulitude of platform devices for each possible 
machine type using this driver.


Heiko


More information about the devicetree-discuss mailing list