# Re: \[PATCH v2 06/19\] powerpc/cputable: Split cpu\_specs\[\] out of cputable.h

- From: Nicholas Piggin \<npiggin@gmail.com\>
- Date: 2022-09-20 08:57:01 
- List: linuxppc-dev
- Page: https://ratatoskr.run/linuxppc-dev/2022/09/1938826
- Thread: https://ratatoskr.run/linuxppc-dev/2022/09/1937935/t.md

```text
On Tue Sep 20, 2022 at 3:01 AM AEST, Christophe Leroy wrote:
> cpu_specs[] is full of #ifdefs depending on the different
> types of CPU.
>
> CPUs are mutually exclusive, it is therefore possible to split
> cpu_specs[] into smaller more readable pieces.
>
> Create cpu_specs_XXX.h that will each be dedicated on one
> of the following mutually exclusive families:
> - 40x
> - 44x
> - 47x
> - 8xx
> - e500
> - book3s/32
> - book3s/64
>
> In book3s/32, the block for 603 has been moved in front in order
> to not have two 604 blocks.


>
> Signed-off-by: Christophe Leroy <redacted>
> ---
>  arch/powerpc/kernel/cpu_specs.h           |   27 +
>  arch/powerpc/kernel/cpu_specs_40x.h       |  280 +++
>  arch/powerpc/kernel/cpu_specs_44x.h       |  304 ++++
>  arch/powerpc/kernel/cpu_specs_47x.h       |   78 +
>  arch/powerpc/kernel/cpu_specs_8xx.h       |   21 +
>  arch/powerpc/kernel/cpu_specs_book3s_32.h |  607 +++++++
>  arch/powerpc/kernel/cpu_specs_book3s_64.h |  488 ++++++
>  arch/powerpc/kernel/cpu_specs_e500.h      |  135 ++
>  arch/powerpc/kernel/cputable.c            | 1877 +--------------------

This series is a nice cleanup. No comments yet but kernel/ is getting
pretty crowded. Should we make some subdirectories for subarch things
like mm has?

Can do that after your series. Probably requires another merge window
to do it.

Thanks,
Nick
```
