Re: [RFC PATCH v2 00/14] Remove unneccessary included headers

2018-06-04 Thread Michael Ellerman
Christophe Leroy  writes:

> The purpose of this serie is to limit the number of includes to
> only the necessary ones in order to reduce the number of files
> recompiled everytime a header file is modified.
>
> This is the start of the work, please provide feedback if any so
> that I don't go in the wrong direction.
>
> Handled inclusion changes more carrefully after Michael feedback.
>
> Started splitting some headers in order to reduce their coverage.
>
> Christophe Leroy (14):
>   powerpc: remove kdump.h from page.h
>   powerpc: remove unneeded inclusions of cpu_has_feature.h
>   powerpc/405: move PPC405_ERR77 in asm-405.h
>   powerpc: move ASM_CONST and stringify_in_c() into asm-const.h
>   powerpc: clean the inclusion of stringify.h
>   powerpc: clean inclusions of asm/feature-fixups.h
>   powerpc: remove superflous inclusions of asm/fixmap.h
>   powerpc: declare set_breakpoint() static
>   powerpc/book3s: Remove PPC_PIN_SIZE
>   powerpc: fix includes in asm/processor.h
>   powerpc/nohash: fix hash related comments in pgtable.h
>   powerpc/44x: remove page.h from mmu-44x.h
>   powerpc: split reg.h in two parts
>   powerpc: Split synch.h in two parts

Still some problems :)

  http://kisskb.ellerman.id.au/kisskb/head/14047/

cheers


arch/powerpc/include/asm/reg.h:1286:31: error: expected ':' or ')' before 
'ASM_FTR_IFCLR':
  allmodconfig+64K_PAGES powerpc
  allmodconfig+64K_PAGES powerpc-5.3
  allmodconfig+ppc64le ppc64le
  powernv_defconfig+NO_NUMA ppc64le
  powernv_defconfig+NO_PERF ppc64le
  powernv_defconfig+NO_RADIX ppc64le
  powernv_defconfig+STRICT_RWX ppc64le
  powernv_defconfig+THIN ppc64le
  powerpc-allmodconfig powerpc
  powerpc-allmodconfig powerpc-5.3
  powerpc-allyesconfig powerpc
  powerpc-allyesconfig powerpc-5.3
  ppc64_defconfig powerpc
  ppc64_defconfig powerpc-5.3
  ppc64_defconfig+NO_ALTIVEC powerpc
  ppc64_defconfig+NO_ALTIVEC powerpc-5.3
  ppc64_defconfig+NO_HUGETLB powerpc
  ppc64_defconfig+NO_HUGETLB powerpc-5.3
  ppc64_defconfig+NO_KVM powerpc
  ppc64_defconfig+NO_KVM powerpc-5.3
  ppc64_defconfig+NO_RADIX powerpc
  ppc64_defconfig+NO_TM powerpc
  ppc64_defconfig+NO_TM powerpc-5.3
  ppc64_defconfig+UP powerpc
  ppc64_defconfig+UP powerpc-5.3
  ppc64e_defconfig powerpc
  ppc64e_defconfig powerpc-5.3
  ppc64e_defconfig+KEXEC powerpc
  ppc64e_defconfig+KEXEC powerpc-5.3
  ppc64e_defconfig+UP powerpc
  ppc64e_defconfig+UP powerpc-5.3
  ppc64le_defconfig ppc64le
  ppc64le_defconfig+NO_KPROBES ppc64le
  ppc64le_defconfig+NO_KVM ppc64le
  ppc6xx_defconfig powerpc
  ppc6xx_defconfig powerpc-5.3
  pseries_defconfig powerpc
  pseries_defconfig powerpc-5.3
  pseries_defconfig+FA_DUMP powerpc
  pseries_defconfig+FA_DUMP powerpc-5.3
  pseries_defconfig+NO_MEMORY_HOTPLUG powerpc
  pseries_defconfig+NO_MEMORY_HOTPLUG powerpc-5.3
  pseries_defconfig+NO_MEMORY_HOTREMOVE powerpc
  pseries_defconfig+NO_SPLPAR powerpc
  pseries_defconfig+NO_SPLPAR powerpc-5.3
  pseries_le_defconfig ppc64le
  pseries_le_defconfig+NO_NUMA ppc64le
  pseries_le_defconfig+NO_SPLPAR ppc64le
  skiroot_defconfig ppc64le


[RFC PATCH v2 00/14] Remove unneccessary included headers

2018-06-01 Thread Christophe Leroy
The purpose of this serie is to limit the number of includes to
only the necessary ones in order to reduce the number of files
recompiled everytime a header file is modified.

This is the start of the work, please provide feedback if any so
that I don't go in the wrong direction.

Handled inclusion changes more carrefully after Michael feedback.

Started splitting some headers in order to reduce their coverage.

Christophe Leroy (14):
  powerpc: remove kdump.h from page.h
  powerpc: remove unneeded inclusions of cpu_has_feature.h
  powerpc/405: move PPC405_ERR77 in asm-405.h
  powerpc: move ASM_CONST and stringify_in_c() into asm-const.h
  powerpc: clean the inclusion of stringify.h
  powerpc: clean inclusions of asm/feature-fixups.h
  powerpc: remove superflous inclusions of asm/fixmap.h
  powerpc: declare set_breakpoint() static
  powerpc/book3s: Remove PPC_PIN_SIZE
  powerpc: fix includes in asm/processor.h
  powerpc/nohash: fix hash related comments in pgtable.h
  powerpc/44x: remove page.h from mmu-44x.h
  powerpc: split reg.h in two parts
  powerpc: Split synch.h in two parts

 arch/powerpc/crypto/md5-asm.S |  1 +
 arch/powerpc/crypto/sha1-powerpc-asm.S|  1 +
 arch/powerpc/include/asm/asm-405.h| 19 +++
 arch/powerpc/include/asm/asm-compat.h | 26 +-
 arch/powerpc/include/asm/asm-const.h  | 14 +
 arch/powerpc/include/asm/atomic.h |  2 +
 arch/powerpc/include/asm/barrier.h|  3 ++
 arch/powerpc/include/asm/bitops.h |  2 +
 arch/powerpc/include/asm/book3s/32/pgtable.h  |  7 ---
 arch/powerpc/include/asm/book3s/64/hash.h |  2 +
 arch/powerpc/include/asm/book3s/64/mmu-hash.h |  2 +-
 arch/powerpc/include/asm/book3s/64/radix.h|  2 +
 arch/powerpc/include/asm/cacheflush.h |  1 -
 arch/powerpc/include/asm/cmpxchg.h|  3 +-
 arch/powerpc/include/asm/code-patching.h  |  1 +
 arch/powerpc/include/asm/cputable.h   |  3 +-
 arch/powerpc/include/asm/cputime.h|  1 -
 arch/powerpc/include/asm/dbell.h  |  2 +-
 arch/powerpc/include/asm/dcr-native.h |  1 +
 arch/powerpc/include/asm/debug.h  |  1 -
 arch/powerpc/include/asm/dt_cpu_ftrs.h|  2 -
 arch/powerpc/include/asm/exception-64s.h  |  2 +
 arch/powerpc/include/asm/feature-fixups.h |  2 +
 arch/powerpc/include/asm/firmware.h   |  3 +-
 arch/powerpc/include/asm/fixmap.h |  2 -
 arch/powerpc/include/asm/futex.h  |  2 +-
 arch/powerpc/include/asm/hw_breakpoint.h  |  1 +
 arch/powerpc/include/asm/iommu.h  |  1 +
 arch/powerpc/include/asm/jump_label.h |  2 +-
 arch/powerpc/include/asm/kvm_booke_hv_asm.h   |  2 +
 arch/powerpc/include/asm/mmu-44x.h| 11 ++--
 arch/powerpc/include/asm/mmu.h|  3 +-
 arch/powerpc/include/asm/nohash/32/pgtable.h  |  7 +--
 arch/powerpc/include/asm/nohash/64/pgtable.h  | 19 ++-
 arch/powerpc/include/asm/page.h   |  3 +-
 arch/powerpc/include/asm/page_64.h|  2 +
 arch/powerpc/include/asm/ppc-opcode.h |  3 +-
 arch/powerpc/include/asm/ppc_asm.h|  1 +
 arch/powerpc/include/asm/processor.h  |  5 +-
 arch/powerpc/include/asm/ptrace.h |  1 +
 arch/powerpc/include/asm/reg-ftr.h| 63 +++
 arch/powerpc/include/asm/reg.h| 36 +
 arch/powerpc/include/asm/reg_a2.h |  2 +
 arch/powerpc/include/asm/reg_fsl_emb.h|  2 +
 arch/powerpc/include/asm/spinlock.h   |  3 +-
 arch/powerpc/include/asm/{synch.h => synch-ftr.h} | 24 ++---
 arch/powerpc/include/asm/synch.h  | 30 ---
 arch/powerpc/include/asm/thread_info.h|  3 +-
 arch/powerpc/include/asm/uaccess.h|  1 -
 arch/powerpc/kernel/cpu_setup_6xx.S   |  1 +
 arch/powerpc/kernel/crash.c   |  1 -
 arch/powerpc/kernel/entry_32.S|  2 +
 arch/powerpc/kernel/entry_64.S|  3 ++
 arch/powerpc/kernel/exceptions-64e.S  |  1 +
 arch/powerpc/kernel/exceptions-64s.S  |  2 +
 arch/powerpc/kernel/fpu.S |  2 +
 arch/powerpc/kernel/head_32.S |  1 +
 arch/powerpc/kernel/head_40x.S|  1 +
 arch/powerpc/kernel/head_64.S |  2 +
 arch/powerpc/kernel/head_8xx.S|  1 -
 arch/powerpc/kernel/head_fsl_booke.S  |  1 +
 arch/powerpc/kernel/idle_6xx.S|  1 +
 arch/powerpc/kernel/idle_book3s.S |  3 ++
 arch/powerpc/kernel/idle_e500.S   |  1 +
 arch/powerpc/kernel/idle_power4.S |  1 +