[RFC/PATCH v2] [POWERPC] bootwrapper: build multiple cuImages

Grant Likely grant.likely at secretlab.ca
Sat Feb 2 06:57:35 EST 2008


On 2/1/08, Stephen Neuendorffer <stephen.neuendorffer at xilinx.com> wrote:
> What if it was something like:
>
> image-$(CONFIG_MPC832x_MDS)             += cuImage.mpc832x_mds
> image-$(CONFIG_MPC832x_RDB)             += cuImage.mpc832x_rdb
> image-$(CONFIG_MPC834x_ITX)             += cuImage.mpc8349emitx \
>                                            cuImage.mpc8349emitxgp
> platform-$(CONFIG_MPC83xx)              += cuboot-83xx.o
>
> $(obj)/cuImage.%: vmlinux $(dtstree)/%.dts $(wrapperbits) $(platform-y)
>         $(call if_changed,wrap,$(platform-y),(dtstree)/$*.dts)
>
> Which would eliminate making all the unnecessary bits of platform code
> and enabling the smart bits to be factored out of the wrapper?  It would
> also make the dependency between the board and the platform code
> specific.It would also prevent building more than one platform at a
> time, but I don't think that's really possibly anyway?

It *is* possible, which is the goal of this patch.

:-D

There are only a few bits of non-multiplatform stuff left for 6xx
compatible platforms and those won't take too long to clear out.

The biggest part of the problem is the overloading of the cuImage.%
target.  If the wrapper was encoded in the target then the problem
would go away.  For example:

image-$(CONFIG_LITE5200)             += cuImage-52xx.lite5200b
image-$(CONFIG_MPC832x_MDS)             += cuImage-83xx.mpc832x_mds
image-$(CONFIG_MPC832x_RDB)             += cuImage-83xx.mpc832x_rdb
image-$(CONFIG_MPC834x_ITX)             += cuImage-83xx.mpc8349emitx \
                                           cuImage-83xx.mpc8349emitxgp

And then have targets for each of the cuImage-<platform>.%, like so:

$(obj)/cuImage-52xx-%: vmlinux $(dtstree)/%.dts $(wrapperbits)
        $(call if_changed,wrap,cuboot-52xx,(dtstree)/$*.dts)
$(obj)/cuImage-83xx-%: vmlinux $(dtstree)/%.dts $(wrapperbits)
        $(call if_changed,wrap,cuboot-83xx,(dtstree)/$*.dts)

Cheers,
g.

-- 
Grant Likely, B.Sc., P.Eng.
Secret Lab Technologies Ltd.



More information about the Linuxppc-dev mailing list