# ==========================================================================
# Installing dtb files
#
# Installs all dtb files listed in $(dtb-y) either in the
# INSTALL_DTBS_PATH directory or the default location:
#
#   $INSTALL_PATH/dtbs/$KERNELRELEASE
#
# Traverse through subdirectories listed in $(dts-dirs).
# ==========================================================================

src := $(obj)

PHONY := __dtbs_install
__dtbs_install:

export dtbinst-root ?= $(obj)

include include/config/auto.conf
include scripts/Kbuild.include
include $(src)/Makefile

PHONY += __dtbs_install_prep
__dtbs_install_prep:
ifeq ("$(dtbinst-root)", "$(obj)")
	$(Q)mkdir -p $(INSTALL_DTBS_PATH)
endif

dtbinst-files	:= $(dtb-y)
dtbinst-dirs	:= $(dts-dirs)

# Helper targets for Installing DTBs into the boot directory
quiet_cmd_dtb_install =	INSTALL $<
      cmd_dtb_install =	mkdir -p $(2); cp $< $(2)

install-dir = $(patsubst $(dtbinst-root)%,$(INSTALL_DTBS_PATH)%,$(obj))

$(dtbinst-files) $(dtbinst-dirs): | __dtbs_install_prep

$(dtbinst-files): %.dtb: $(obj)/%.dtb
	$(call cmd,dtb_install,$(install-dir))

$(dtbinst-dirs):
	$(Q)$(MAKE) $(dtbinst)=$(obj)/$@

PHONY += $(dtbinst-files) $(dtbinst-dirs)
__dtbs_install: $(dtbinst-files) $(dtbinst-dirs)

.PHONY: $(PHONY)
>Tobias Klauser</td></tr></table>
<table class='tabs'><tr><td>
<a href='/cgit.cgi/linux/net-next.git/'>summary</a><a href='/cgit.cgi/linux/net-next.git/refs/'>refs</a><a class='active' href='/cgit.cgi/linux/net-next.git/log/include/soc/bcm2835'>log</a><a href='/cgit.cgi/linux/net-next.git/tree/include/soc/bcm2835'>tree</a><a href='/cgit.cgi/linux/net-next.git/commit/include/soc/bcm2835'>commit</a><a href='/cgit.cgi/linux/net-next.git/diff/include/soc/bcm2835'>diff</a></td><td class='form'><form class='right' method='get' action='/cgit.cgi/linux/net-next.git/log/include/soc/bcm2835'>
<select name='qt'>
<option value='grep'>log msg</option>
<option value='author'>author</option>
<option value='committer'>committer</option>
<option value='range'>range</option>
</select>
<input class='txt' type='search' size='10' name='q' value=''/>
<input type='submit' value='search'/>
</form>
</td></tr></table>
<div class='path'>path: <a href='/cgit.cgi/linux/net-next.git/log/'>root</a>/<a href='/cgit.cgi/linux/net-next.git/log/include'>include</a>/<a href='/cgit.cgi/linux/net-next.git/log/include/soc'>soc</a>/<a href='/cgit.cgi/linux/net-next.git/log/include/soc/bcm2835'>bcm2835</a></div><div class='content'><table class='list nowrap'><tr class='nohover'><th class='left'>Age</th><th class='left'>Commit message (<a href='/cgit.cgi/linux/net-next.git/log/include/soc/bcm2835?showmsg=1'>Expand</a>)</th><th class='left'>Author</th><th class='left'>Files</th><th class='left'>Lines</th></tr>