[PATCH] ARM: qcom_defconfig: Enable MAILBOX

2018-09-06 Thread frowand . list
From: Frank Rowand Problem: ab460a2e72da ("rpmsg: qcom_smd: Access APCS through mailbox framework" added a "depends on MAILBOX") to RPMSG_QCOM_SMD, thus RPMSG_QCOM_SMD becomes unset since MAILBOX was not enabled in qcom_defconfig and is not otherwise selected for the dragonboard. When the

[PATCH 4/6] ARM: dts: qcom-msm8974: use named constant for interrupt flag LEVEL HIGH

2018-09-06 Thread frowand . list
From: Frank Rowand Cosmetic change of integer value "4" in the third field of the "interrupts" property to the correct named constant. Signed-off-by: Frank Rowand --- arch/arm/boot/dts/qcom-msm8974.dtsi | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git

[PATCH 6/6] ARM: dts: qcom-msm8974: change invalid flag IRQ NONE to valid value

2018-09-06 Thread frowand . list
From: Frank Rowand Change the third field of the "interrupts" property from IRQ_TYPE_NONE to the correct value. I do not have hardware documentation for these devices, so I followed a mail list suggestion to copy the flag values from the same type of node in

[PATCH 2/6] ARM: dts: qcom-msm8974: use named constant for interrupt type GIC_SPI

2018-09-06 Thread frowand . list
From: Frank Rowand Cosmetic change of integer value "0" in the first field of the "interrupts" property to the correct named constant. Signed-off-by: Frank Rowand --- arch/arm/boot/dts/qcom-msm8974.dtsi | 56 +++-- 1 file changed, 29 insertions(+), 27

[PATCH 1/6] ARM: dts: qcom-msm8974: use named constant for interrupt type GIC_PPI

2018-09-06 Thread frowand . list
From: Frank Rowand Cosmetic change of integer value "1" in the first field of the "interrupts" property to the correct named constant. Signed-off-by: Frank Rowand --- arch/arm/boot/dts/qcom-msm8974.dtsi | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git

[PATCH 0/6] ARM: dts: qcom-msm8974: change invalid flag IRQ NONE to valid value

2018-09-06 Thread frowand . list
From: Frank Rowand A boot time warning of devicetree interrupts types set to the invalid value of none was added by 83a86fbb5b56 ("irqchip/gic: Loudly complain about the use of IRQ_TYPE_NONE"). This patch series fixes the devicetree source to replace IRQ_TYPE_NONE with the appropriate value.

[PATCH 5/6] ARM: dts: qcom-msm8974: use named constant for interrupt flag NONE

2018-09-06 Thread frowand . list
From: Frank Rowand Cosmetic change of integer value "0" in the third field of the "interrupts" property to the correct named constant. Signed-off-by: Frank Rowand --- arch/arm/boot/dts/qcom-msm8974.dtsi | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git

[PATCH 3/6] ARM: dts: qcom-msm8974: use named constant for interrupt flag EDGE RISING

2018-09-06 Thread frowand . list
From: Frank Rowand Cosmetic change of integer value "1" in the third field of the "interrupts" property to the correct named constant. Signed-off-by: Frank Rowand --- arch/arm/boot/dts/qcom-msm8974.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git

[PATCH] of: overlay: update phandle cache on overlay apply and remove

2018-07-12 Thread frowand . list
From: Frank Rowand A comment in the review of the patch adding the phandle cache said that the cache would have to be updated when modules are applied and removed. This patch implements the cache updates. Fixes: 0b3ce78e90fc ("of: cache phandle nodes to reduce cost of

[PATCH v4 0/2] of: cache phandle nodes to reduce cost of of_find_node_by_phandle()

2018-02-28 Thread frowand . list
From: Frank Rowand Create a cache of the nodes that contain a phandle property. Use this cache to find the node for a given phandle value instead of scanning the devicetree to find the node. If the phandle value is not found in the cache, of_find_node_by_phandle() will

[PATCH v4 2/2] of: add early boot allocation of of_find_node_by_phandle() cache

2018-02-28 Thread frowand . list
From: Frank Rowand The initial implementation of the of_find_node_by_phandle() cache allocates the cache using kcalloc(). Add an early boot allocation of the cache so it will be usable during early boot. Switch over to the kcalloc() based cache once normal memory

[PATCH v4 1/2] of: cache phandle nodes to reduce cost of of_find_node_by_phandle()

2018-02-28 Thread frowand . list
From: Frank Rowand Create a cache of the nodes that contain a phandle property. Use this cache to find the node for a given phandle value instead of scanning the devicetree to find the node. If the phandle value is not found in the cache, of_find_node_by_phandle() will

[PATCH 1/2] of: unittest: remove unneeded local return value variables

2018-03-08 Thread frowand . list
From: Frank Rowand A common pattern in many unittest functions is to save the return value of a function in a local variable, then test the value of the local variable, without using that return value for any further purpose. Remove the local return value variable for

[PATCH 2/2] of: unittest: local return value variable related cleanups

2018-03-08 Thread frowand . list
From: Frank Rowand Several more style issues became apparent while creating "of: unittest: remove unneeded local return value variables". Correct those issues. Signed-off-by: Frank Rowand --- drivers/of/unittest.c | 22 ++ 1

[PATCH v7 2/5] of: change overlay apply input data from unflattened to FDT

2018-03-03 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v7 3/5] of: Documentation: of_overlay_apply() replaced by of_overlay_fdt_apply()

2018-03-03 Thread frowand . list
From: Frank Rowand Signed-off-by: Frank Rowand --- Documentation/devicetree/overlay-notes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/overlay-notes.txt

[PATCH v7 5/5] of: improve reporting invalid overlay target path

2018-03-03 Thread frowand . list
From: Frank Rowand Errors while developing the patch to create of_overlay_fdt_apply() exposed inadequate error messages to debug problems when overlay devicetree fragment nodes contain an invalid target path. Improve the messages in find_target_node() to remedy this.

[PATCH v7 0/5] of: change overlay apply input data from unflattened

2018-03-03 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v7 4/5] of: convert unittest overlay devicetree source to sugar syntax

2018-03-03 Thread frowand . list
From: Frank Rowand The unittest-data overlays have been pulled into proper overlay devicetree source files without changing their format. The next step is to convert them to use sugar syntax instead of hand coding overlay fragments structure. A few of the overlays can

[PATCH v7 1/5] x86: devicetree: fix config option around x86_flattree_get_config()

2018-03-03 Thread frowand . list
From: Frank Rowand x86_flattree_get_config() is incorrectly protected by ifdef CONFIG_OF_FLATTREE. It uses of_get_flat_dt_size(), which only exists if CONFIG_OF_EARLY_FLATTREE. This issue has not been exposed previously because OF_FLATTREE did not occur unless it was

[PATCH v5 3/3] of: add early boot allocation of of_find_node_by_phandle() cache

2018-03-04 Thread frowand . list
From: Frank Rowand The initial implementation of the of_find_node_by_phandle() cache allocates the cache using kcalloc(). Add an early boot allocation of the cache so it will be usable during early boot. Switch over to the kcalloc() based cache once normal memory

[PATCH v5 1/3] of: cache phandle nodes to reduce cost of of_find_node_by_phandle()

2018-03-04 Thread frowand . list
From: Frank Rowand Create a cache of the nodes that contain a phandle property. Use this cache to find the node for a given phandle value instead of scanning the devicetree to find the node. If the phandle value is not found in the cache, of_find_node_by_phandle() will

[PATCH v5 0/3] of: cache phandle nodes to reduce cost of of_find_node_by_phandle()

2018-03-04 Thread frowand . list
From: Frank Rowand Create a cache of the nodes that contain a phandle property. Use this cache to find the node for a given phandle value instead of scanning the devicetree to find the node. If the phandle value is not found in the cache, of_find_node_by_phandle() will

[PATCH v5 2/3] memblock: add memblock_free() alloc when CONFIG_HAVE_MEMBLOCK is not set

2018-03-04 Thread frowand . list
From: Frank Rowand When CONFIG_HAVE_MEMBLOCK is not set, an error version of memblock_alloc() exists. Add the matching memblock_free(). Signed-off-by: Frank Rowand --- Andrew or Michal, can you please ack this patch to be accepted by Rob? With

[PATCH v4 4/4] of: improve reporting invalid overlay target path

2018-03-01 Thread frowand . list
From: Frank Rowand Errors while developing the patch to create of_overlay_fdt_apply() exposed inadequate error messages to debug problems when overlay devicetree fragment nodes contain an invalid target path. Improve the messages in find_target_node() to remedy this.

[PATCH v4 0/4] of: change overlay apply input data from unflattened

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v4 2/4] of: Documentation: of_overlay_apply() replaced by of_overlay_fdt_apply()

2018-03-01 Thread frowand . list
From: Frank Rowand Signed-off-by: Frank Rowand --- Documentation/devicetree/overlay-notes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/overlay-notes.txt

[PATCH v5 4/4] of: improve reporting invalid overlay target path

2018-03-01 Thread frowand . list
From: Frank Rowand Errors while developing the patch to create of_overlay_fdt_apply() exposed inadequate error messages to debug problems when overlay devicetree fragment nodes contain an invalid target path. Improve the messages in find_target_node() to remedy this.

[PATCH v5 0/4] of: change overlay apply input data from unflattened

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v5 1/4] of: change overlay apply input data from unflattened to FDT

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v5 3/4] of: convert unittest overlay devicetree source to sugar syntax

2018-03-01 Thread frowand . list
From: Frank Rowand The unittest-data overlays have been pulled into proper overlay devicetree source files without changing their format. The next step is to convert them to use sugar syntax instead of hand coding overlay fragments structure. A few of the overlays can

[PATCH v5 2/4] of: Documentation: of_overlay_apply() replaced by of_overlay_fdt_apply()

2018-03-01 Thread frowand . list
From: Frank Rowand Signed-off-by: Frank Rowand --- Documentation/devicetree/overlay-notes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/overlay-notes.txt

[PATCH v6 0/4] of: change overlay apply input data from unflattened

2018-03-02 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v6 3/4] of: convert unittest overlay devicetree source to sugar syntax

2018-03-02 Thread frowand . list
From: Frank Rowand The unittest-data overlays have been pulled into proper overlay devicetree source files without changing their format. The next step is to convert them to use sugar syntax instead of hand coding overlay fragments structure. A few of the overlays can

[PATCH v6 4/4] of: improve reporting invalid overlay target path

2018-03-02 Thread frowand . list
From: Frank Rowand Errors while developing the patch to create of_overlay_fdt_apply() exposed inadequate error messages to debug problems when overlay devicetree fragment nodes contain an invalid target path. Improve the messages in find_target_node() to remedy this.

[PATCH v6 1/4] of: change overlay apply input data from unflattened to FDT

2018-03-02 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v6 2/4] of: Documentation: of_overlay_apply() replaced by of_overlay_fdt_apply()

2018-03-02 Thread frowand . list
From: Frank Rowand Signed-off-by: Frank Rowand --- Documentation/devicetree/overlay-notes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/overlay-notes.txt

[PATCH] x86: devicetree: fix config option around x86_flattree_get_config()

2018-03-02 Thread frowand . list
From: Frank Rowand x86_flattree_get_config() is incorrectly protected by ifdef CONFIG_OF_FLATTREE. It uses of_get_flat_dt_size(), which only exists if CONFIG_OF_EARLY_FLATTREE. This issue has not been exposed previously because OF_FLATTREE did not occur unless it was

[PATCH v4 1/4] of: change overlay apply input data from unflattened to FDT

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to

[PATCH v4 3/4] of: convert unittest overlay devicetree source to sugar syntax

2018-03-01 Thread frowand . list
From: Frank Rowand The unittest-data overlays have been pulled into proper overlay devicetree source files without changing their format. The next step is to convert them to use sugar syntax instead of hand coding overlay fragments structure. A few of the overlays can

[PATCH] of: overlay: update documentation to match current implementation

2018-10-14 Thread frowand . list
From: Frank Rowand The overlay information in Documentation/devicetree/ is out of date. Signed-off-by: Frank Rowand --- .../devicetree/dynamic-resolution-notes.txt| 24 -- Documentation/devicetree/overlay-notes.txt | 93 ++ 2 files changed, 42

[PATCH] of: overlay: user space synchronization

2018-10-14 Thread frowand . list
From: Frank Rowand When an overlay is applied or removed, the live devicetree visible in /proc/device-tree/, aka /sys/firmware/devicetree/base/, reflects the changes. There is no method for user space to determine whether the live devicetree was modified by overlay actions. Provide a sysfs

[PATCH] of: Documentation: remove unmaintained todo file

2018-10-14 Thread frowand . list
From: Frank Rowand The todo.txt file was created by a previous maintainer and has never been updated by the current OPEN FIRMWARE AND FLATTENED DEVICE TREE maintainers. Remove the out of date file. Signed-off-by: Frank Rowand --- Documentation/devicetree/todo.txt | 10 -- 1 file

[PATCH v2] of: overlay: user space synchronization

2018-10-15 Thread frowand . list
From: Frank Rowand When an overlay is applied or removed, the live devicetree visible in /proc/device-tree/, aka /sys/firmware/devicetree/base/, reflects the changes. There is no method for user space to determine whether the live devicetree was modified by overlay actions. Provide a sysfs

[PATCH v3] of: overlay: user space synchronization

2018-10-16 Thread frowand . list
From: Frank Rowand When an overlay is applied or removed, the live devicetree visible in /proc/device-tree/, aka /sys/firmware/devicetree/base/, reflects the changes. There is no method for user space to determine whether the live devicetree was modified by overlay actions. Provide a sysfs

[PATCH v4 15/18] of: overlay: set node fields from properties when add new overlay node

2018-10-15 Thread frowand . list
From: Frank Rowand Overlay nodes added by add_changeset_node() do not have the node fields name, phandle, and type set. The node passed to __of_attach_node() when the add node changeset entry is processed does not contain any properties. The node's properties are located in add property

[PATCH v4 09/18] of: overlay: validate overlay properties #address-cells and #size-cells

2018-10-15 Thread frowand . list
From: Frank Rowand If overlay properties #address-cells or #size-cells are already in the live devicetree for any given node, then the values in the overlay must match the values in the live tree. If the properties are already in the live tree then there is no need to create a changeset entry

[PATCH v4] of: overlay: user space synchronization

2018-11-02 Thread frowand . list
From: Frank Rowand When an overlay is applied or removed, the live devicetree visible in /proc/device-tree/, aka /sys/firmware/devicetree/base/, reflects the changes. There is no method for user space to determine whether the live devicetree was modified by overlay actions. Provide a sysfs

[PATCH] of: add dtc annotations functionality to dtx_diff

2018-11-26 Thread frowand . list
From: Frank Rowand Add -T and --annotations command line arguments to dtx_diff. These arguments will be passed through to dtc. dtc will then add source location annotations to its output. Signed-off-by: Frank Rowand --- This feature depends upon commit 5667e7ef9a9a ("annotations: add the

[PATCH v4 0/2] of: cache phandle nodes to reduce cost of of_find_node_by_phandle()

2018-02-28 Thread frowand . list
From: Frank Rowand Create a cache of the nodes that contain a phandle property. Use this cache to find the node for a given phandle value instead of scanning the devicetree to find the node. If the phandle value is not found in the cache, of_find_node_by_phandle() will fall back to the tree

[PATCH v4 2/2] of: add early boot allocation of of_find_node_by_phandle() cache

2018-02-28 Thread frowand . list
From: Frank Rowand The initial implementation of the of_find_node_by_phandle() cache allocates the cache using kcalloc(). Add an early boot allocation of the cache so it will be usable during early boot. Switch over to the kcalloc() based cache once normal memory allocation becomes available.

[PATCH v4 1/2] of: cache phandle nodes to reduce cost of of_find_node_by_phandle()

2018-02-28 Thread frowand . list
From: Frank Rowand Create a cache of the nodes that contain a phandle property. Use this cache to find the node for a given phandle value instead of scanning the devicetree to find the node. If the phandle value is not found in the cache, of_find_node_by_phandle() will fall back to the tree

[PATCH v4 0/4] of: change overlay apply input data from unflattened

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to devicetree code, which is thus

[PATCH v4 2/4] of: Documentation: of_overlay_apply() replaced by of_overlay_fdt_apply()

2018-03-01 Thread frowand . list
From: Frank Rowand Signed-off-by: Frank Rowand --- Documentation/devicetree/overlay-notes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/overlay-notes.txt b/Documentation/devicetree/overlay-notes.txt index c4aa0adf13ec..5175a24d387e 100644

[PATCH v4 4/4] of: improve reporting invalid overlay target path

2018-03-01 Thread frowand . list
From: Frank Rowand Errors while developing the patch to create of_overlay_fdt_apply() exposed inadequate error messages to debug problems when overlay devicetree fragment nodes contain an invalid target path. Improve the messages in find_target_node() to remedy this. Signed-off-by: Frank

[PATCH v4 1/4] of: change overlay apply input data from unflattened to FDT

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to devicetree code, which is thus

[PATCH v4 3/4] of: convert unittest overlay devicetree source to sugar syntax

2018-03-01 Thread frowand . list
From: Frank Rowand The unittest-data overlays have been pulled into proper overlay devicetree source files without changing their format. The next step is to convert them to use sugar syntax instead of hand coding overlay fragments structure. A few of the overlays can not be converted because

[PATCH v5 4/4] of: improve reporting invalid overlay target path

2018-03-01 Thread frowand . list
From: Frank Rowand Errors while developing the patch to create of_overlay_fdt_apply() exposed inadequate error messages to debug problems when overlay devicetree fragment nodes contain an invalid target path. Improve the messages in find_target_node() to remedy this. Signed-off-by: Frank

[PATCH v5 0/4] of: change overlay apply input data from unflattened

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to devicetree code, which is thus

[PATCH v5 1/4] of: change overlay apply input data from unflattened to FDT

2018-03-01 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to devicetree code, which is thus

[PATCH v5 3/4] of: convert unittest overlay devicetree source to sugar syntax

2018-03-01 Thread frowand . list
From: Frank Rowand The unittest-data overlays have been pulled into proper overlay devicetree source files without changing their format. The next step is to convert them to use sugar syntax instead of hand coding overlay fragments structure. A few of the overlays can not be converted because

[PATCH v5 2/4] of: Documentation: of_overlay_apply() replaced by of_overlay_fdt_apply()

2018-03-01 Thread frowand . list
From: Frank Rowand Signed-off-by: Frank Rowand --- Documentation/devicetree/overlay-notes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/overlay-notes.txt b/Documentation/devicetree/overlay-notes.txt index c4aa0adf13ec..5175a24d387e 100644

[PATCH] of: add early boot allocation of of_find_node_by_phandle() cache

2018-02-14 Thread frowand . list
From: Frank Rowand The initial implementation of the of_find_node_by_phandle() cache allocates the cache using kcalloc(). Add an early boot allocation of the cache so it will be usable during early boot. Switch over to the kcalloc() based cache once normal memory allocation becomes available.

[PATCH v3] of: cache phandle nodes to reduce cost of of_find_node_by_phandle()

2018-02-14 Thread frowand . list
From: Frank Rowand Create a cache of the nodes that contain a phandle property. Use this cache to find the node for a given phandle value instead of scanning the devicetree to find the node. If the phandle value is not found in the cache, of_find_node_by_phandle() will fall back to the tree

[PATCH v3 3/4] of: convert unittest overlay devicetree source to sugar syntax

2018-02-14 Thread frowand . list
From: Frank Rowand The unittest-data overlays have been pulled into proper overlay devicetree source files without changing their format. The next step is to convert them to use sugar syntax instead of hand coding overlay fragments structure. A few of the overlays can not be converted because

[PATCH v3 0/4] of: change overlay apply input data from unflattened

2018-02-14 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to devicetree code, which is thus

[PATCH v3 2/4] of: Documentation: of_overlay_apply() replaced by of_overlay_fdt_apply()

2018-02-14 Thread frowand . list
From: Frank Rowand Signed-off-by: Frank Rowand --- Documentation/devicetree/overlay-notes.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/overlay-notes.txt b/Documentation/devicetree/overlay-notes.txt index c4aa0adf13ec..5175a24d387e 100644

[PATCH v3 1/4] of: change overlay apply input data from unflattened to FDT

2018-02-14 Thread frowand . list
From: Frank Rowand Move duplicating and unflattening of an overlay flattened devicetree (FDT) into the overlay application code. To accomplish this, of_overlay_apply() is replaced by of_overlay_fdt_apply(). The copy of the FDT (aka "duplicate FDT") now belongs to devicetree code, which is thus

[PATCH v3 4/4] of: improve reporting invalid overlay target path

2018-02-14 Thread frowand . list
From: Frank Rowand Errors while developing the patch to create of_overlay_fdt_apply() exposed inadequate error messages to debug problems when overlay devicetree fragment nodes contain an invalid target path. Improve the messages in find_target_node() to remedy this. Signed-off-by: Frank

[PATCH 2/2] of: unittest: local return value variable related cleanups

2018-03-08 Thread frowand . list
From: Frank Rowand Several more style issues became apparent while creating "of: unittest: remove unneeded local return value variables". Correct those issues. Signed-off-by: Frank Rowand --- drivers/of/unittest.c | 22 ++ 1 file changed, 6 insertions(+), 16 deletions(-)

[PATCH 1/2] of: unittest: remove unneeded local return value variables

2018-03-08 Thread frowand . list
From: Frank Rowand A common pattern in many unittest functions is to save the return value of a function in a local variable, then test the value of the local variable, without using that return value for any further purpose. Remove the local return value variable for these cases. A second

[PATCH] MAINTAINERS: add keyword for devicetree overlay notifiers

2018-04-27 Thread frowand . list
From: Frank Rowand From: Frank Rowand Devicetree overlay notifiers have a chance to potentially get pointers into the overlay unflattened devicetree and overlay FDT. The only protection against these pointers being accessed after the underlying data has been released by kfree() is by source

[PATCH v2] MAINTAINERS: add keyword for devicetree overlay notifiers

2018-04-27 Thread frowand . list
From: Frank Rowand Devicetree overlay notifiers have a chance to potentially get pointers into the overlay unflattened devicetree and overlay FDT. The only protection against these pointers being accessed after the underlying data has been released by kfree() is by source code review of patches.

[PATCH] of: overlay: validate offset from property fixups

2018-05-16 Thread frowand . list
From: Frank Rowand The smatch static checker marks the data in offset as untrusted, leading it to warn: drivers/of/resolver.c:125 update_usages_of_a_phandle_reference() error: buffer underflow 'prop->value' 's32min-s32max' Add check to verify that offset is within the property data.

[PATCH v2 12/12] of: overlay: remove unneeded check for NULL kbasename()

2017-10-16 Thread frowand . list
From: Frank Rowand kbasename() will not return NULL if passed a valid string. If the parameter passed to kbasename() in this case is already NULL then the devicetree has been corrupted. Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 2 -- 1 file changed, 2 deletions(-) diff --git

[PATCH v2 07/12] of: overlay: expand check of whether overlay changeset can be removed

2017-10-16 Thread frowand . list
From: Frank Rowand The test of whether it is safe to remove an overlay changeset looked at whether any node in the overlay changeset was in a subtree rooted at any more recently applied overlay changeset node. The test failed to determine whether any node in the overlay changeset was the root

[PATCH v2 00/12] of: overlay: clean up device tree overlay code

2017-10-16 Thread frowand . list
From: Frank Rowand I have found the device tree overlay code to be difficult to read and maintain. This patch series attempts to improve that situation. The cleanup includes some changes visible to users of overlays. The only in kernel user of overlays is fixed up for those changes. The in

[PATCH v2 11/12] of: overlay: remove a dependency on device node full_name

2017-10-16 Thread frowand . list
From: Frank Rowand The "%pOF" printf format was recently added to print the full name of a device tree node, with the intent of changing the node full_name field to contain only the node name instead of the full path of the node. dup_and_fixup_symbol_prop() duplicates a property from the

[PATCH v2 09/12] of: overlay: avoid race condition between applying multiple overlays

2017-10-16 Thread frowand . list
From: Frank Rowand The process of applying an overlay consists of: - unflatten an overlay FDT (flattened device tree) into an EDT (expanded device tree) - fixup the phandle values in the overlay EDT to fit in a range above the phandle values in the live device tree - create the

[PATCH v2 10/12] of: overlay: simplify applying symbols from an overlay

2017-10-16 Thread frowand . list
From: Frank Rowand The code to apply symbols from an overlay to the live device tree was implemented with the intent to be minimally intrusive on the existing code. After recent restructuring of the overlay apply code, it is easier to disintangle the code that applies the symbols, and to make

[PATCH v2 03/12] of: overlay: rename identifiers to more reflect what they do

2017-10-16 Thread frowand . list
From: Frank Rowand This patch is aimed primarily at drivers/of/overlay.c, but those changes also have a small impact in a few other files. overlay.c is difficult to read and maintain. Improve readability: - Rename functions, types and variables to better reflect what they do and to be

[PATCH v2 08/12] of: overlay: loosen overly strict phandle clash check

2017-10-16 Thread frowand . list
From: Frank Rowand When an overlay contains a node that already exists in the live device tree, the overlay node is not allowed to change the phandle of the existing node. The existing check refused to allow an overlay node to set the node phandle even when the existing node did not have a

[PATCH v2 06/12] of: overlay: detect cases where device tree may become corrupt

2017-10-16 Thread frowand . list
From: Frank Rowand When an attempt to apply an overlay changeset fails, an effort is made to revert any partial application of the changeset. When an attempt to remove an overlay changeset fails, an effort is made to re-apply any partial reversion of the changeset. The existing code does not

[PATCH v2 05/12] of: overlay: minor restructuring

2017-10-16 Thread frowand . list
From: Frank Rowand Continue improving the readability of overlay.c. The previous patches renamed identifiers. This patch is split out from the previous patches to make the previous patches easier to review. Changes are: - minor code restructuring - some initialization of an overlay

[PATCH v2 01/12] of: overlay.c: Remove comments that state the obvious, to reduce clutter

2017-10-16 Thread frowand . list
From: Frank Rowand Follows recommendations in Documentation/process/coding-style.rst, section 8, Commenting. Some in function comments are promoted to function header comments. Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 53 1

[PATCH v2 04/12] of: overlay: rename identifiers in dup_and_fixup_symbol_prop()

2017-10-16 Thread frowand . list
From: Frank Rowand More renaming of identifiers to better reflect what they do. Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 24 ++-- 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/drivers/of/overlay.c b/drivers/of/overlay.c index

[PATCH v2 02/12] of: overlay.c: Convert comparisons to zero or NULL to logical expressions

2017-10-16 Thread frowand . list
From: Frank Rowand Use normal shorthand for comparing a variable to zero. For variable "XXX": convert (XXX == 0) to (!XXX) convert (XXX != 0) to (XXX) Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 36 ++-- 1 file changed, 18 insertions(+), 18

[PATCH v3 00/12] of: overlay: clean up device tree overlay code

2017-10-17 Thread frowand . list
From: Frank Rowand I have found the device tree overlay code to be difficult to read and maintain. This patch series attempts to improve that situation. The cleanup includes some changes visible to users of overlays. The only in kernel user of overlays is fixed up for those changes. The in

[PATCH v3 04/12] of: overlay: rename identifiers in dup_and_fixup_symbol_prop()

2017-10-17 Thread frowand . list
From: Frank Rowand More renaming of identifiers to better reflect what they do. Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 24 ++-- 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/drivers/of/overlay.c b/drivers/of/overlay.c index

[PATCH v3 12/12] of: overlay: remove unneeded check for NULL kbasename()

2017-10-17 Thread frowand . list
From: Frank Rowand kbasename() will not return NULL if passed a valid string. If the parameter passed to kbasename() in this case is already NULL then the devicetree has been corrupted. Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 2 -- 1 file changed, 2 deletions(-) diff --git

[PATCH v3 11/12] of: overlay: remove a dependency on device node full_name

2017-10-17 Thread frowand . list
From: Frank Rowand The "%pOF" printf format was recently added to print the full name of a device tree node, with the intent of changing the node full_name field to contain only the node name instead of the full path of the node. dup_and_fixup_symbol_prop() duplicates a property from the

[PATCH v3 10/12] of: overlay: simplify applying symbols from an overlay

2017-10-17 Thread frowand . list
From: Frank Rowand The code to apply symbols from an overlay to the live device tree was implemented with the intent to be minimally intrusive on the existing code. After recent restructuring of the overlay apply code, it is easier to disintangle the code that applies the symbols, and to make

[PATCH v3 03/12] of: overlay: rename identifiers to more reflect what they do

2017-10-17 Thread frowand . list
From: Frank Rowand This patch is aimed primarily at drivers/of/overlay.c, but those changes also have a small impact in a few other files. overlay.c is difficult to read and maintain. Improve readability: - Rename functions, types and variables to better reflect what they do and to be

[PATCH v3 09/12] of: overlay: avoid race condition between applying multiple overlays

2017-10-17 Thread frowand . list
From: Frank Rowand The process of applying an overlay consists of: - unflatten an overlay FDT (flattened device tree) into an EDT (expanded device tree) - fixup the phandle values in the overlay EDT to fit in a range above the phandle values in the live device tree - create the

[PATCH v3 05/12] of: overlay: minor restructuring

2017-10-17 Thread frowand . list
From: Frank Rowand Continue improving the readability of overlay.c. The previous patches renamed identifiers. This patch is split out from the previous patches to make the previous patches easier to review. Changes are: - minor code restructuring - some initialization of an overlay

[PATCH v3 07/12] of: overlay: expand check of whether overlay changeset can be removed

2017-10-17 Thread frowand . list
From: Frank Rowand The test of whether it is safe to remove an overlay changeset looked at whether any node in the overlay changeset was in a subtree rooted at any more recently applied overlay changeset node. The test failed to determine whether any node in the overlay changeset was the root

[PATCH v3 08/12] of: overlay: loosen overly strict phandle clash check

2017-10-17 Thread frowand . list
From: Frank Rowand When an overlay contains a node that already exists in the live device tree, the overlay node is not allowed to change the phandle of the existing node. The existing check refused to allow an overlay node to set the node phandle even when the existing node did not have a

[PATCH v3 06/12] of: overlay: detect cases where device tree may become corrupt

2017-10-17 Thread frowand . list
From: Frank Rowand When an attempt to apply an overlay changeset fails, an effort is made to revert any partial application of the changeset. When an attempt to remove an overlay changeset fails, an effort is made to re-apply any partial reversion of the changeset. The existing code does not

[PATCH v3 02/12] of: overlay.c: Convert comparisons to zero or NULL to logical expressions

2017-10-17 Thread frowand . list
From: Frank Rowand Use normal shorthand for comparing a variable to zero. For variable "XXX": convert (XXX == 0) to (!XXX) convert (XXX != 0) to (XXX) Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 36 ++-- 1 file changed, 18 insertions(+), 18

[PATCH v3 01/12] of: overlay.c: Remove comments that state the obvious, to reduce clutter

2017-10-17 Thread frowand . list
From: Frank Rowand Follows recommendations in Documentation/process/coding-style.rst, section 8, Commenting. Some in function comments are promoted to function header comments. Signed-off-by: Frank Rowand --- drivers/of/overlay.c | 47 ++- 1 file

<    1   2   3   4   5   6   >