Thread (9 messages) 9 messages, 4 authors, 2012-07-05

How to handle parameter variation across different boards but same platform

flat view

From: Vaibhav Hiremath <hidden>
Date: 2012-07-05 05:42:32
Also in: alsa-devel


On 7/4/2012 7:57 PM, Mark Brown wrote:
On Wed, Jul 04, 2012 at 02:17:48PM +0000, Hebbar, Gururaja wrote:
quoted
On Wed, Jul 04, 2012 at 19:31:18, Mark Brown wrote:
quoted
quoted
If these are totally different boards they should have different machine
IDs set so machine_is_() should identify.  If that isn't there then you
need to do something custom to your products to identify the boards
further.
quoted
They are different boards with same SoC (AM33xx). So they both are true for
machine_is_am33xx().
What if the device only supports Linux boot from DT, where we set
machine_desc.nr = ~0 ??

Does machine ID still gets set? May be I am missing something...

As part of my debugging, on AM335xEVM platform machine_is_am33xx()
returns false, since the value of machine_desc.nr is set to ~0.

Thanks,
Vaibhav
That's not how this stuff is supposed to work - machine is the board,
you should have cpu_is_() for identifying the SoC.
quoted
We have a means to detect the type of board but in arch/arm/mach-omap2/ 
board file. However, I believe it is not recommended to call boards api
inside drivers.
Only for generic drivers, board specific drivers are obviously board
specific.  The point is that you shouldn't make something that could run
on many boards depend on an API specific to a particular board.



_______________________________________________
Davinci-linux-open-source mailing list
Davinci-linux-open-source at linux.davincidsp.com
http://linux.davincidsp.com/mailman/listinfo/davinci-linux-open-source
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help