Hi, Ralf This patch is too big for review, If the basic idea is okay for you, I will split it and resend it. Thanks, Wu Zhangjin On Sun, Dec 26, 2010 at 1:40 AM, Wu Zhangjin <wuzhangjin@xxxxxxxxx> wrote: > current_cpu_prid(), cpu_prid_comp(), cpu_prid_imp() and cpu_prid_rev() > are added to simplify/beautify the processord_id related code. > > And if current_cpu_prid() is pre-encoded for the specific processor in > cpu-feature-overrides.h, the code generation will be optimized. > > cpu_prid_encode() and cpu_prid_encode_copt() are added to encode the > current_cpu_prid(), the former one can be used by most of the processors > whose 'Company Options' part of the prid register is 0 or is not used by > any of the existing codes. Or current_cpu_prid() can be simply assigned > as the value of read_c0_prid(), which can be printed by the > show_cpuinfo() defined in arch/mips/kernel/proc.c. > > The size of compressed kernel image(vmlinuz) can be reduced about 0.1M > if current_cpu_prid() is pre-defined as a fixed value in > cpu-feature-overrides.h.