uncompress and ll debug uart consolidation
I started looking at the 10 duplicate implementations of PL01x uart code in various mach/uncompress.h. My first thought was just consolidate those into 1 uncompress-pl01x.h header similar to debug-pl01x.S.
However, the LL debug macros are basically doing the same thing and are already used by compressed/head.S, so why not make the uncompress code use them? The debug macros are already included when DEBUG is defined for compressed/head.S. It's quite trivial to use putc from head.S in misc.c instead of the C version. To take it a step further, why not just use kernel/debug.S for the decompresser and replace much of the code in compressed/head.S. This would get rid of 2 implementations of DCC, SA1100 and S3C2410 code.
Am I missing something?
Rob
Quoted 13 lines · Rob Herring
I started looking at the 10 duplicate implementations of PL01x uart code in various
mach/uncompress.h. My first thought was just consolidate those into 1uncompress-pl01x.hheader similar todebug-pl01x.S.However, the LL debug macros are basically doing the same thing and are already used by
compressed/head.S, so why not make the uncompress code use them? The debug macros are already included when DEBUG is defined forcompressed/head.S. It's quite trivial to use putc fromhead.Sinmisc.cinstead of the C version. To take it a step further, why not just usekernel/debug.Sfor the decompresser and replace much of the code incompressed/head.S. This would get rid of 2 implementations of DCC, SA1100 and S3C2410 code.
Quoted 1 line
Am I missing something?
I've been looking forward to do exactly that. Didn't get around to it yet, so if you feel like doing that work then please go ahead and I'll be glad to review it.
Nicolas