Commit 6e7f2538 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'devicetree-fixes-for-4.14' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux

Pull DeviceTree fixes from Rob Herring:

 - fix build for !OF providing empty of_find_device_by_node

 - fix Abracon vendor prefix

 - sync dtx_diff include paths (again)

 - a stm32h7 clock binding doc fix

* tag 'devicetree-fixes-for-4.14' of git://git.kernel.org/pub/scm/linux/kernel/git/robh/linux:
  dt-bindings: clk: stm32h7: fix clock-cell size
  scripts/dtc: dtx_diff - 2nd update of include dts paths to match build
  dt-bindings: fix vendor prefix for Abracon
  of: provide inline helper for of_find_device_by_node
parents a141fd55 127b8e26
......@@ -32,7 +32,7 @@ Example:
compatible = "st,stm32h743-rcc", "st,stm32-rcc";
reg = <0x58024400 0x400>;
#reset-cells = <1>;
#clock-cells = <2>;
#clock-cells = <1>;
clocks = <&clk_hse>, <&clk_lse>, <&clk_i2s_ckin>;
st,syscfg = <&pwrcfg>;
......
......@@ -3,8 +3,8 @@ Device tree binding vendor prefix registry. Keep list in alphabetical order.
This isn't an exhaustive list, but you should add new prefixes to it before
using them to avoid name-space collisions.
abcn Abracon Corporation
abilis Abilis Systems
abracon Abracon Corporation
actions Actions Semiconductor Co., Ltd.
active-semi Active-Semi International Inc
ad Avionic Design GmbH
......
......@@ -57,7 +57,14 @@ extern const struct of_device_id of_default_bus_match_table[];
extern struct platform_device *of_device_alloc(struct device_node *np,
const char *bus_id,
struct device *parent);
#ifdef CONFIG_OF
extern struct platform_device *of_find_device_by_node(struct device_node *np);
#else
static inline struct platform_device *of_find_device_by_node(struct device_node *np)
{
return NULL;
}
#endif
/* Platform devices and busses creation */
extern struct platform_device *of_platform_device_create(struct device_node *np,
......
......@@ -86,6 +86,7 @@ eod
compile_to_dts() {
dtx="$1"
dtc_include="$2"
if [ -d "${dtx}" ] ; then
......@@ -113,7 +114,7 @@ compile_to_dts() {
# ----- input is DTS (source)
if ( cpp ${cpp_flags} -x assembler-with-cpp ${dtx} \
| ${DTC} -I dts ) ; then
| ${DTC} ${dtc_include} -I dts ) ; then
return
fi
......@@ -320,18 +321,13 @@ fi
cpp_flags="\
-nostdinc \
-I${srctree}/arch/${ARCH}/boot/dts \
-I${srctree}/scripts/dtc/include-prefixes \
-I${srctree}/drivers/of/testcase-data \
-undef -D__DTS__"
dtc_flags="\
-i ${srctree}/arch/${ARCH}/boot/dts/ \
-i ${srctree}/kernel/dts \
${dtx_path_1_dtc_include} \
${dtx_path_2_dtc_include}"
DTC="${DTC} ${dtc_flags} -O dts -qq -f ${dtc_sort} -o -"
DTC="\
${DTC} \
-i ${srctree}/scripts/dtc/include-prefixes \
-O dts -qq -f ${dtc_sort} -o -"
# ----- do the diff or decompile
......@@ -339,11 +335,11 @@ DTC="${DTC} ${dtc_flags} -O dts -qq -f ${dtc_sort} -o -"
if (( ${cmd_diff} )) ; then
diff ${diff_flags} --label "${dtx_file_1}" --label "${dtx_file_2}" \
<(compile_to_dts "${dtx_file_1}") \
<(compile_to_dts "${dtx_file_2}")
<(compile_to_dts "${dtx_file_1}" "${dtx_path_1_dtc_include}") \
<(compile_to_dts "${dtx_file_2}" "${dtx_path_2_dtc_include}")
else
compile_to_dts "${dtx_file_1}"
compile_to_dts "${dtx_file_1}" "${dtx_path_1_dtc_include}"
fi
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment