Re: [PATCH 10/11] Add MPC8360EMDS board support
From: Olof Johansson <hidden>
Date: 2006-09-27 16:22:42
On Wed, 27 Sep 2006 10:42:17 -0400 Dan Malek [off-list ref] wrote:
Since BCSRs are board specific, does anyone remember the day when a simple #define, ioremap, and a few lines of code in the board setup file was all that was needed? :-)
Yes, also called "board port hell". One of the major points with the device tree is that the needed information for the system is in there, not compiled into the kernel. So you can boot the same kernel binary on several boards, as long as the drivers are built in and the correct device tree is used. Has everyone missed/forgotten that objective completely?
What wrong with still doing that? It seems everyone is obsessed with device tree syntax and forget that a few lines of code may still be a reasonable solution.
The device tree describes the system, not how to program it. I think that's where the confusion might be. I.e. create a generic "board-controller" device node, and put a suitable "compatible" property in there, so the right board controller driver can be chosen based on it. Having the address of the controller in there helps too, especially if there are two boards out there with the same controller but at different memory location. -Olof