xref: /openbmc/linux/arch/sh/mm/Makefile (revision 5a846aba)
11b3edd97SPaul Mundt#
21b3edd97SPaul Mundt# Makefile for the Linux SuperH-specific parts of the memory manager.
31b3edd97SPaul Mundt#
41b3edd97SPaul Mundt
5a99eae54SPaul Mundtobj-y			:= alignment.o cache.o init.o consistent.o mmap.o
61b3edd97SPaul Mundt
7*5a846abaSRich Felkercacheops-$(CONFIG_CPU_J2)		:= cache-j2.o
8*5a846abaSRich Felkercacheops-$(CONFIG_CPU_SUBTYPE_SH7619)	:= cache-sh2.o
91b3edd97SPaul Mundtcacheops-$(CONFIG_CPU_SH2A)		:= cache-sh2a.o
101b3edd97SPaul Mundtcacheops-$(CONFIG_CPU_SH3)		:= cache-sh3.o
111b3edd97SPaul Mundtcacheops-$(CONFIG_CPU_SH4)		:= cache-sh4.o flush-sh4.o
121b3edd97SPaul Mundtcacheops-$(CONFIG_CPU_SH5)		:= cache-sh5.o flush-sh4.o
131b3edd97SPaul Mundtcacheops-$(CONFIG_SH7705_CACHE_32KB)	+= cache-sh7705.o
143cf6fa1eSPaul Mundtcacheops-$(CONFIG_CPU_SHX3)		+= cache-shx3.o
151b3edd97SPaul Mundt
161b3edd97SPaul Mundtobj-y			+= $(cacheops-y)
171b3edd97SPaul Mundt
181b3edd97SPaul Mundtmmu-y			:= nommu.o extable_32.o
1928080329SPaul Mundtmmu-$(CONFIG_MMU)	:= extable_$(BITS).o fault.o gup.o ioremap.o kmap.o \
2028080329SPaul Mundt			   pgtable.o tlbex_$(BITS).o tlbflush_$(BITS).o
211b3edd97SPaul Mundt
221b3edd97SPaul Mundtobj-y			+= $(mmu-y)
231b3edd97SPaul Mundt
246ae66502SMatt Flemingdebugfs-y			:= asids-debugfs.o
256ae66502SMatt Flemingifndef CONFIG_CACHE_OFF
266ae66502SMatt Flemingdebugfs-$(CONFIG_CPU_SH4)	+= cache-debugfs.o
271b3edd97SPaul Mundtendif
281b3edd97SPaul Mundt
291b3edd97SPaul Mundtifdef CONFIG_MMU
306ae66502SMatt Flemingdebugfs-$(CONFIG_CPU_SH4)	+= tlb-debugfs.o
311b3edd97SPaul Mundttlb-$(CONFIG_CPU_SH3)		:= tlb-sh3.o
32bb29c677SPaul Mundttlb-$(CONFIG_CPU_SH4)		:= tlb-sh4.o tlb-urb.o
331b3edd97SPaul Mundttlb-$(CONFIG_CPU_SH5)		:= tlb-sh5.o
34bb29c677SPaul Mundttlb-$(CONFIG_CPU_HAS_PTEAEX)	:= tlb-pteaex.o tlb-urb.o
351b3edd97SPaul Mundtobj-y				+= $(tlb-y)
361b3edd97SPaul Mundtendif
371b3edd97SPaul Mundt
386ae66502SMatt Flemingobj-$(CONFIG_DEBUG_FS)		+= $(debugfs-y)
391b3edd97SPaul Mundtobj-$(CONFIG_HUGETLB_PAGE)	+= hugetlbpage.o
40a0ab3668SPaul Mundtobj-$(CONFIG_PMB)		+= pmb.o
411b3edd97SPaul Mundtobj-$(CONFIG_NUMA)		+= numa.o
424d35b93aSMatt Flemingobj-$(CONFIG_IOREMAP_FIXED)	+= ioremap_fixed.o
439edef286SPaul Mundtobj-$(CONFIG_UNCACHED_MAPPING)	+= uncached.o
44c993487eSPaul Mundtobj-$(CONFIG_HAVE_SRAM_POOL)	+= sram.o
451b3edd97SPaul Mundt
46d4f7e513SChris SmithGCOV_PROFILE_pmb.o := n
47d4f7e513SChris Smith
482ec08e14SPaul Mundt# Special flags for tlbex_64.o.  This puts restrictions on the number of
491b3edd97SPaul Mundt# caller-save registers that the compiler can target when building this file.
501b3edd97SPaul Mundt# This is required because the code is called from a context in entry.S where
511b3edd97SPaul Mundt# very few registers have been saved in the exception handler (for speed
521b3edd97SPaul Mundt# reasons).
531b3edd97SPaul Mundt# The caller save registers that have been saved and which can be used are
541b3edd97SPaul Mundt# r2,r3,r4,r5 : argument passing
551b3edd97SPaul Mundt# r15, r18 : SP and LINK
561b3edd97SPaul Mundt# tr0-4 : allow all caller-save TR's.  The compiler seems to be able to make
571b3edd97SPaul Mundt#         use of them, so it's probably beneficial to performance to save them
581b3edd97SPaul Mundt#         and have them available for it.
591b3edd97SPaul Mundt#
601b3edd97SPaul Mundt# The resources not listed below are callee save, i.e. the compiler is free to
611b3edd97SPaul Mundt# use any of them and will spill them to the stack itself.
621b3edd97SPaul Mundt
632ec08e14SPaul MundtCFLAGS_tlbex_64.o += -ffixed-r7 \
641b3edd97SPaul Mundt	-ffixed-r8 -ffixed-r9 -ffixed-r10 -ffixed-r11 -ffixed-r12 \
651b3edd97SPaul Mundt	-ffixed-r13 -ffixed-r14 -ffixed-r16 -ffixed-r17 -ffixed-r19 \
661b3edd97SPaul Mundt	-ffixed-r20 -ffixed-r21 -ffixed-r22 -ffixed-r23 \
671b3edd97SPaul Mundt	-ffixed-r24 -ffixed-r25 -ffixed-r26 -ffixed-r27 \
681b3edd97SPaul Mundt	-ffixed-r36 -ffixed-r37 -ffixed-r38 -ffixed-r39 -ffixed-r40 \
691b3edd97SPaul Mundt	-ffixed-r41 -ffixed-r42 -ffixed-r43  \
701b3edd97SPaul Mundt	-ffixed-r60 -ffixed-r61 -ffixed-r62 \
711b3edd97SPaul Mundt	-fomit-frame-pointer
721b3edd97SPaul Mundt
73a234ca0fSmatt mooneyccflags-y := -Werror
74