Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
f2dcd0f8
Commit
f2dcd0f8
authored
Dec 04, 2012
by
Grant Likely
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'robherring/for-next' into devicetree/next
parents
465aac6d
300db34a
Changes
22
Hide whitespace changes
Inline
Side-by-side
Showing
22 changed files
with
88 additions
and
87 deletions
+88
-87
Documentation/kbuild/makefiles.txt
Documentation/kbuild/makefiles.txt
+8
-7
arch/arm/Makefile
arch/arm/Makefile
+2
-2
arch/arm/boot/Makefile
arch/arm/boot/Makefile
+0
-12
arch/arm/boot/dts/Makefile
arch/arm/boot/dts/Makefile
+8
-0
arch/arm64/Makefile
arch/arm64/Makefile
+11
-6
arch/arm64/boot/Makefile
arch/arm64/boot/Makefile
+0
-5
arch/arm64/boot/dts/.gitignore
arch/arm64/boot/dts/.gitignore
+1
-0
arch/arm64/boot/dts/Makefile
arch/arm64/boot/dts/Makefile
+5
-0
arch/c6x/Makefile
arch/c6x/Makefile
+1
-1
arch/c6x/boot/Makefile
arch/c6x/boot/Makefile
+0
-20
arch/c6x/boot/dts/Makefile
arch/c6x/boot/dts/Makefile
+20
-0
arch/c6x/boot/dts/linked_dtb.S
arch/c6x/boot/dts/linked_dtb.S
+2
-0
arch/microblaze/Makefile
arch/microblaze/Makefile
+1
-1
arch/microblaze/boot/Makefile
arch/microblaze/boot/Makefile
+1
-18
arch/microblaze/boot/dts/Makefile
arch/microblaze/boot/dts/Makefile
+22
-0
arch/microblaze/boot/dts/linked_dtb.S
arch/microblaze/boot/dts/linked_dtb.S
+2
-0
arch/mips/cavium-octeon/Makefile
arch/mips/cavium-octeon/Makefile
+0
-3
arch/mips/lantiq/dts/Makefile
arch/mips/lantiq/dts/Makefile
+0
-3
arch/mips/netlogic/dts/Makefile
arch/mips/netlogic/dts/Makefile
+0
-3
arch/openrisc/Makefile
arch/openrisc/Makefile
+1
-1
arch/openrisc/boot/dts/Makefile
arch/openrisc/boot/dts/Makefile
+0
-5
scripts/Makefile.lib
scripts/Makefile.lib
+3
-0
No files found.
Documentation/kbuild/makefiles.txt
View file @
f2dcd0f8
...
...
@@ -1175,15 +1175,16 @@ When kbuild executes, the following steps are followed (roughly):
in an init section in the image. Platform code *must* copy the
blob to non-init memory prior to calling unflatten_device_tree().
Example:
#arch/x86/platform/ce4100/Makefile
clean-files := *dtb.S
To use this command, simply add *.dtb into obj-y or targets, or make
some other target depend on %.dtb
DTC_FLAGS := -p 1024
obj-y += foo.dtb.o
A central rule exists to create $(obj)/%.dtb from $(src)/%.dts;
architecture Makefiles do no need to explicitly write out that rule.
$(obj)/%.dtb: $(src)/%.dts
$(call cmd,dtc)
Example:
targets += $(dtb-y)
clean-files += *.dtb
DTC_FLAGS ?= -p 1024
--- 6.8 Custom kbuild commands
...
...
arch/arm/Makefile
View file @
f2dcd0f8
...
...
@@ -292,10 +292,10 @@ zinstall uinstall install: vmlinux
$(Q)$(MAKE)
$(build)
=
$(boot)
MACHINE
=
$(MACHINE)
$@
%.dtb
:
scripts
$(Q)$(MAKE)
$(build)
=
$(boot)
MACHINE
=
$(MACHINE)
$(boot)
/
$@
$(Q)$(MAKE)
$(build)
=
$(boot)
/dts
MACHINE
=
$(MACHINE)
$(boot)
/dts
/
$@
dtbs
:
scripts
$(Q)$(MAKE)
$(build)
=
$(boot)
MACHINE
=
$(MACHINE)
$(boot)
/
$@
$(Q)$(MAKE)
$(build)
=
$(boot)
/dts
MACHINE
=
$(MACHINE)
dtbs
# We use MRPROPER_FILES and CLEAN_FILES now
archclean
:
...
...
arch/arm/boot/Makefile
View file @
f2dcd0f8
...
...
@@ -15,8 +15,6 @@ ifneq ($(MACHINE),)
include
$(srctree)/$(MACHINE)/Makefile.boot
endif
include
$(srctree)/arch/arm/boot/dts/Makefile
# Note: the following conditions must always be true:
# ZRELADDR == virt_to_phys(PAGE_OFFSET + TEXT_OFFSET)
# PARAMS_PHYS must be within 4MB of ZRELADDR
...
...
@@ -59,16 +57,6 @@ $(obj)/zImage: $(obj)/compressed/vmlinux FORCE
endif
targets
+=
$
(
dtb-y
)
# Rule to build device tree blobs
$(obj)/%.dtb
:
$(src)/dts/%.dts FORCE
$(
call
if_changed_dep,dtc
)
$(obj)/dtbs
:
$(addprefix $(obj)/
,
$(dtb-y))
clean-files
:=
*
.dtb
ifneq
($(LOADADDR),)
UIMAGE_LOADADDR
=
$(LOADADDR)
else
...
...
arch/arm/boot/dts/Makefile
View file @
f2dcd0f8
...
...
@@ -104,4 +104,12 @@ dtb-$(CONFIG_ARCH_VT8500) += vt8500-bv07.dtb \
wm8505-ref.dtb
\
wm8650-mid.dtb
targets
+=
dtbs
endif
# *.dtb used to be generated in the directory above. Clean out the
# old build results so people don't accidentally use them.
dtbs
:
$(addprefix $(obj)/
,
$(dtb-y))
$(Q)
rm
-f
$(obj)
/../
*
.dtb
clean-files
:=
*
.dtb
arch/arm64/Makefile
View file @
f2dcd0f8
...
...
@@ -41,20 +41,24 @@ libs-y := arch/arm64/lib/ $(libs-y)
libs-y
+=
$(LIBGCC)
# Default target when executing plain make
KBUILD_IMAGE
:=
Image.gz
KBUILD_IMAGE
:=
Image.gz
KBUILD_DTBS
:=
dtbs
all
:
$(KBUILD_IMAGE)
all
:
$(KBUILD_IMAGE)
$(KBUILD_DTBS)
boot
:=
arch
/arm64/boot
Image Image.gz
:
vmlinux
$(Q)$(MAKE)
$(build)
=
$(boot)
MACHINE
=
$(MACHINE)
$(boot)
/
$@
$(Q)$(MAKE)
$(build)
=
$(boot)
$(boot)
/
$@
zinstall install
:
vmlinux
$(Q)$(MAKE)
$(build)
=
$(boot)
MACHINE
=
$(MACHINE)
$@
$(Q)$(MAKE)
$(build)
=
$(boot)
$@
%.dtb
:
$(Q)$(MAKE)
$(build)
=
$(boot)
MACHINE
=
$(MACHINE)
$(boot)
/
$@
%.dtb
:
scripts
$(Q)$(MAKE)
$(build)
=
$(boot)
/dts
$(boot)
/dts/
$@
dtbs
:
scripts
$(Q)$(MAKE)
$(build)
=
$(boot)
/dts
$(boot)
/dts/
$@
# We use MRPROPER_FILES and CLEAN_FILES now
archclean
:
...
...
@@ -63,6 +67,7 @@ archclean:
define
archhelp
echo
'* Image.gz - Compressed kernel image (arch/$(ARCH)/boot/Image.gz)'
echo
' Image - Uncompressed kernel image (arch/$(ARCH)/boot/Image)'
echo
'* dtbs - Build device tree blobs for enabled boards'
echo
' install - Install uncompressed kernel'
echo
' zinstall - Install compressed kernel'
echo
' Install using (your) ~/bin/installkernel or'
...
...
arch/arm64/boot/Makefile
View file @
f2dcd0f8
...
...
@@ -22,9 +22,6 @@ $(obj)/Image: vmlinux FORCE
$(obj)/Image.gz
:
$(obj)/Image FORCE
$(
call
if_changed,gzip
)
$(obj)/%.dtb
:
$(src)/dts/%.dts
$(
call
cmd,dtc
)
install
:
$(obj)/Image
$(CONFIG_SHELL)
$(srctree)
/
$(src)
/install.sh
$(KERNELRELEASE)
\
$(obj)
/Image System.map
"
$(INSTALL_PATH)
"
...
...
@@ -32,5 +29,3 @@ install: $(obj)/Image
zinstall
:
$(obj)/Image.gz
$(CONFIG_SHELL)
$(srctree)
/
$(src)
/install.sh
$(KERNELRELEASE)
\
$(obj)
/Image.gz System.map
"
$(INSTALL_PATH)
"
clean-files
+=
*
.dtb
arch/arm64/boot/dts/.gitignore
0 → 100644
View file @
f2dcd0f8
*.dtb
arch/arm64/boot/dts/Makefile
0 → 100644
View file @
f2dcd0f8
targets
+=
dtbs
dtbs
:
$(addprefix $(obj)/
,
$(dtb-y))
clean-files
:=
*
.dtb
arch/c6x/Makefile
View file @
f2dcd0f8
...
...
@@ -41,7 +41,7 @@ DTB:=$(subst dtbImage.,,$(filter dtbImage.%, $(MAKECMDGOALS)))
export
DTB
ifneq
($(DTB),)
core-y
+=
$(boot)
/
core-y
+=
$(boot)
/
dts/
endif
# With make 3.82 we cannot mix normal and wildcard targets
...
...
arch/c6x/boot/Makefile
View file @
f2dcd0f8
...
...
@@ -6,25 +6,5 @@ OBJCOPYFLAGS_vmlinux.bin := -O binary
$(obj)/vmlinux.bin
:
vmlinux FORCE
$(
call
if_changed,objcopy
)
DTC_FLAGS
?=
-p
1024
ifneq
($(DTB),)
obj-y
+=
linked_dtb.o
endif
$(obj)/%.dtb
:
$(src)/dts/%.dts FORCE
$(
call
if_changed_dep,dtc
)
quiet_cmd_cp
=
CP
$<
$@$2
cmd_cp
=
cat
$<
>
$@$2
||
(
rm
-f
$@
&&
echo false
)
# Generate builtin.dtb from $(DTB).dtb
$(obj)/builtin.dtb
:
$(obj)/$(DTB).dtb
$(
call
if_changed,cp
)
$(obj)/linked_dtb.o
:
$(obj)/builtin.dtb
$(obj)/dtbImage.%
:
vmlinux
$(
call
if_changed,objcopy
)
clean-files
:=
$(obj)
/
*
.dtb
arch/c6x/boot/dts/Makefile
0 → 100644
View file @
f2dcd0f8
#
# Makefile for device trees
#
DTC_FLAGS
?=
-p
1024
ifneq
($(DTB),)
obj-y
+=
linked_dtb.o
endif
quiet_cmd_cp
=
CP
$<
$@$2
cmd_cp
=
cat
$<
>
$@$2
||
(
rm
-f
$@
&&
echo false
)
# Generate builtin.dtb from $(DTB).dtb
$(obj)/builtin.dtb
:
$(obj)/$(DTB).dtb
$(
call
if_changed,cp
)
$(obj)/linked_dtb.o
:
$(obj)/builtin.dtb
clean-files
:=
*
.dtb
arch/c6x/boot/linked_dtb.S
→
arch/c6x/boot/
dts/
linked_dtb.S
View file @
f2dcd0f8
.
section
__fdt_blob
,"
a
"
.
incbin
"
arch
/
c6x
/
boot
/
builtin.dtb
"
.
incbin
"
arch
/
c6x
/
boot
/
dts
/
builtin.dtb
"
arch/microblaze/Makefile
View file @
f2dcd0f8
...
...
@@ -57,7 +57,7 @@ boot := arch/microblaze/boot
DTB
:=
$(
subst
simpleImage.,,
$(
filter
simpleImage.%,
$(MAKECMDGOALS)
))
ifneq
($(DTB),)
core-y
+=
$(boot)
/
core-y
+=
$(boot)
/
dts/
endif
# defines filename extension depending memory management type
...
...
arch/microblaze/boot/Makefile
View file @
f2dcd0f8
...
...
@@ -2,21 +2,10 @@
# arch/microblaze/boot/Makefile
#
obj-y
+=
linked_dtb.o
targets
:=
linux.bin linux.bin.gz simpleImage.%
OBJCOPYFLAGS
:=
-R
.note
-R
.comment
-R
.note.gnu.build-id
-O
binary
# Ensure system.dtb exists
$(obj)/linked_dtb.o
:
$(obj)/system.dtb
# Generate system.dtb from $(DTB).dtb
ifneq
($(DTB),system)
$(obj)/system.dtb
:
$(obj)/$(DTB).dtb
$(
call
if_changed,cp
)
endif
$(obj)/linux.bin
:
vmlinux FORCE
$(
call
if_changed,objcopy
)
$(
call
if_changed,uimage
)
...
...
@@ -45,10 +34,4 @@ $(obj)/simpleImage.%: vmlinux FORCE
@
echo
'Kernel: $@ is ready'
' (#'
`
cat
.version
`
')'
# Rule to build device tree blobs
DTC_FLAGS
:=
-p
1024
$(obj)/%.dtb
:
$(src)/dts/%.dts FORCE
$(
call
if_changed_dep,dtc
)
clean-files
+=
*
.dtb simpleImage.
*
.unstrip linux.bin.ub
clean-files
+=
simpleImage.
*
.unstrip linux.bin.ub
arch/microblaze/boot/dts/Makefile
0 → 100644
View file @
f2dcd0f8
#
# arch/microblaze/boot/Makefile
#
obj-y
+=
linked_dtb.o
# Ensure system.dtb exists
$(obj)/linked_dtb.o
:
$(obj)/system.dtb
# Generate system.dtb from $(DTB).dtb
ifneq
($(DTB),system)
$(obj)/system.dtb
:
$(obj)/$(DTB).dtb
$(
call
if_changed,cp
)
endif
quiet_cmd_cp
=
CP
$<
$@$2
cmd_cp
=
cat
$<
>
$@$2
||
(
rm
-f
$@
&&
echo false
)
# Rule to build device tree blobs
DTC_FLAGS
:=
-p
1024
clean-files
+=
*
.dtb
arch/microblaze/boot/linked_dtb.S
→
arch/microblaze/boot/
dts/
linked_dtb.S
View file @
f2dcd0f8
.
section
__fdt_blob
,"
a
"
.
incbin
"
arch
/
microblaze
/
boot
/
system.dtb
"
.
incbin
"
arch
/
microblaze
/
boot
/
dts
/
system.dtb
"
arch/mips/cavium-octeon/Makefile
View file @
f2dcd0f8
...
...
@@ -24,9 +24,6 @@ DTB_FILES = $(patsubst %.dts, %.dtb, $(DTS_FILES))
obj-y
+=
$(
patsubst
%.dts, %.dtb.o,
$(DTS_FILES)
)
$(obj)/%.dtb
:
$(src)/%.dts FORCE
$(
call
if_changed_dep,dtc
)
# Let's keep the .dtb files around in case we want to look at them.
.SECONDARY
:
$(addprefix $(obj)/
,
$(DTB_FILES))
...
...
arch/mips/lantiq/dts/Makefile
View file @
f2dcd0f8
obj-$(CONFIG_DT_EASY50712)
:=
easy50712.dtb.o
$(obj)/%.dtb
:
$(obj)/%.dts
$(
call
if_changed,dtc
)
arch/mips/netlogic/dts/Makefile
View file @
f2dcd0f8
obj-$(CONFIG_DT_XLP_EVP)
:=
xlp_evp.dtb.o
$(obj)/%.dtb
:
$(obj)/%.dts
$(
call
if_changed,dtc
)
arch/openrisc/Makefile
View file @
f2dcd0f8
...
...
@@ -50,6 +50,6 @@ BUILTIN_DTB := y
else
BUILTIN_DTB
:=
n
endif
core-$(BUILTIN_DTB)
+=
arch
/openrisc/boot/
core-$(BUILTIN_DTB)
+=
arch
/openrisc/boot/
dts/
all
:
vmlinux
arch/openrisc/boot/Makefile
→
arch/openrisc/boot/
dts/
Makefile
View file @
f2dcd0f8
ifneq
'$(CONFIG_OPENRISC_BUILTIN_DTB)' '""'
BUILTIN_DTB
:=
$(
patsubst
"%"
,%,
$(CONFIG_OPENRISC_BUILTIN_DTB)
)
.dtb.o
else
...
...
@@ -10,6 +8,3 @@ obj-y += $(BUILTIN_DTB)
clean-files
:=
*
.dtb.S
#DTC_FLAGS ?= -p 1024
$(obj)/%.dtb
:
$(src)/dts/%.dts FORCE
$(
call
if_changed_dep,dtc
)
scripts/Makefile.lib
View file @
f2dcd0f8
...
...
@@ -266,6 +266,9 @@ $(obj)/%.dtb.S: $(obj)/%.dtb
quiet_cmd_dtc
=
DTC
$@
cmd_dtc
=
$(objtree)
/scripts/dtc/dtc
-O
dtb
-o
$@
-b
0
$(DTC_FLAGS)
-d
$(depfile)
$<
$(obj)/%.dtb
:
$(src)/%.dts FORCE
$(
call
if_changed_dep,dtc
)
# Bzip2
# ---------------------------------------------------------------------------
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment