[U-Boot-Users] Request: s3c24xx getting its own start.S file ?

Hi!
I'm spending the better part of this day to finally put quite a number of the s3c24xx related patches from my various trees into the s3c24xx custodian tree.
Merging the code in start.S is particularly cumbersome, since this file has already exceeded any reasonable number of #ifdef/endif clauses[1] and even while looking long and hard at it, I simply cannot make reasonably sure that I don't break non-s3c codepaths.
This will get significantly worse when I start to add code for s3c2440, s3c2442, s3c2443 and maybe even 2412, 24a0, 2460 and/or others. They all have their subtle differences in low-level initialization, and they all support various booting modes (NOR, NAND, OneNAND, ...).
I know code duplication is really bad. But then, having unreadable code that even experienced developers have a hard time understanding is also not the best choice.
What are your thoughts on this?
[1] = http://git.denx.de/?p=u-boot/u-boot-s3c24xx.git;a=blob;f=cpu/arm920t/start.S...
participants (1)
-
Harald Welte