19d041268SAndrew Victor# 29d041268SAndrew Victor# Makefile for the linux kernel. 39d041268SAndrew Victor# 49d041268SAndrew Victor 59d041268SAndrew Victor# CPU-specific support 6b53cdd03SAlexandre Belloniobj-$(CONFIG_SOC_AT91RM9200) += at91rm9200.o 7cac01723SNicolas Ferreobj-$(CONFIG_SOC_AT91SAM9) += at91sam9.o 8cac01723SNicolas Ferreobj-$(CONFIG_SOC_SAMA5) += sama5.o 92d4c44e9SSzemző Andrásobj-$(CONFIG_SOC_SAMV7) += samv7.o 108f4b4794SLudovic Desroches 11b7b272a8SAndrew Victor# Power Management 12b2f06274SAlexandre Belloniobj-$(CONFIG_ATMEL_PM) += pm.o pm_suspend.o 139d041268SAndrew Victor 14176a1b3dSAlexandre Belloniifeq ($(CONFIG_CPU_V7),y) 15176a1b3dSAlexandre BelloniAFLAGS_pm_suspend.o := -march=armv7-a 16176a1b3dSAlexandre Belloniendif 179d041268SAndrew Victorifeq ($(CONFIG_PM_DEBUG),y) 189d041268SAndrew VictorCFLAGS_pm.o += -DDEBUG 199d041268SAndrew Victorendif 2065cc1a59SAlexandre Belloni 2165cc1a59SAlexandre Belloni# Default sed regexp - multiline due to syntax constraints 2265cc1a59SAlexandre Bellonidefine sed-y 2365cc1a59SAlexandre Belloni "/^->/{s:->#\(.*\):/* \1 */:; \ 2465cc1a59SAlexandre Belloni s:^->\([^ ]*\) [\$$#]*\([-0-9]*\) \(.*\):#define \1 \2 /* \3 */:; \ 2565cc1a59SAlexandre Belloni s:^->\([^ ]*\) [\$$#]*\([^ ]*\) \(.*\):#define \1 \2 /* \3 */:; \ 2665cc1a59SAlexandre Belloni s:->::; p;}" 2765cc1a59SAlexandre Belloniendef 2865cc1a59SAlexandre Belloni 2965cc1a59SAlexandre Belloni# Use filechk to avoid rebuilds when a header changes, but the resulting file 3065cc1a59SAlexandre Belloni# does not 3165cc1a59SAlexandre Bellonidefine filechk_offsets 3265cc1a59SAlexandre Belloni (set -e; \ 3365cc1a59SAlexandre Belloni echo "#ifndef $2"; \ 3465cc1a59SAlexandre Belloni echo "#define $2"; \ 3565cc1a59SAlexandre Belloni echo "/*"; \ 3665cc1a59SAlexandre Belloni echo " * DO NOT MODIFY."; \ 3765cc1a59SAlexandre Belloni echo " *"; \ 3865cc1a59SAlexandre Belloni echo " * This file was generated by Kbuild"; \ 3965cc1a59SAlexandre Belloni echo " */"; \ 4065cc1a59SAlexandre Belloni echo ""; \ 4165cc1a59SAlexandre Belloni sed -ne $(sed-y); \ 4265cc1a59SAlexandre Belloni echo ""; \ 4365cc1a59SAlexandre Belloni echo "#endif" ) 4465cc1a59SAlexandre Belloniendef 4565cc1a59SAlexandre Belloni 4665cc1a59SAlexandre Belloniarch/arm/mach-at91/pm_data-offsets.s: arch/arm/mach-at91/pm_data-offsets.c 4765cc1a59SAlexandre Belloni $(call if_changed_dep,cc_s_c) 4865cc1a59SAlexandre Belloni 4965cc1a59SAlexandre Belloniinclude/generated/at91_pm_data-offsets.h: arch/arm/mach-at91/pm_data-offsets.s FORCE 5065cc1a59SAlexandre Belloni $(call filechk,offsets,__PM_DATA_OFFSETS_H__) 5165cc1a59SAlexandre Belloni 5265cc1a59SAlexandre Belloniarch/arm/mach-at91/pm_suspend.o: include/generated/at91_pm_data-offsets.h 53