[PATCH v2 4/6] ARM: Samsung: Modify s3c64xx_spi{0|1|2}_set_platdata function

Mark Brown broonie at opensource.wolfsonmicro.com
Fri Jun 1 08:39:03 EDT 2012

On Fri, Jun 01, 2012 at 10:47:44AM +0800, Thomas Abraham wrote:

> 1. There is one instance of 'struct platform_device' for each of the
> spi controller instances (0/1/2) named "s3c64xx-spi" (in
> arch/arm/plat-samsung/devs.c).

Right, which looks rather like it is specific to s3c64xx at least given
the naming...  there aren't any current in tree users, though I do have
one out of tree user on s3c6410.  If this is supposed to be used on the
later SoCs too then I guess it ought to be renamed anyway since what's
there looks wrong.

> 5. If point 4 is not correct, the other option is to create a separate
> instances of 'struct platform_device' for each of the s3c, s5p and
> Exynos4/5 SoC's. Is this the correct way, and if yes, could you please
> help me understand the issues in setting the name of the platform
> device at runtime.

That would seem less painful to me.  The big problem I've found is with
things like matching clocks up where if you look at the device that's
being registered it has one name but at runtime it has another name, it
makes everything much harder to follow.  There was one of the devices
where the .id also ended up getting changed which created even more
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20120601/f821ab6d/attachment-0001.sig>

More information about the linux-arm-kernel mailing list