- Oct 18, 2017
-
-
Frank Rowand authored
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 of a subtree that contained a more recently applied overlay changeset node. Add this additional check to the test. The test is still lacking any check for any phandle dependencies. Signed-off-by:
Frank Rowand <frank.rowand@sony.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Frank Rowand authored
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 check for failure to recover a failed overlay changeset application or overlay changeset revert. Add the missing checks and flag the devicetree as corrupt if the state of the devicetree can not be determined. Improve and expand the returned errors to more fully reflect the result of the effort to undo the partial effects of a failed attempt to apply or remove an overlay changeset. If the device tree might be corrupt, do not allow further attempts to apply or remove an overlay changeset. When creating an overlay changeset from an overlay device tree, add some additional warnings if the state of the overlay device tree is not as expected. Signed-off-by:
Frank Rowand <frank.rowand@sony.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Frank Rowand authored
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 changeset occurred outside of init_overlay_changeset(), move that into init_overlay_changeset() - consolidate freeing an overlay changeset into free_overlay_changeset() This patch is intended to not introduce any functional change. Signed-off-by:
Frank Rowand <frank.rowand@sony.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Frank Rowand authored
More renaming of identifiers to better reflect what they do. Signed-off-by:
Frank Rowand <frank.rowand@sony.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Frank Rowand authored
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 consistent with names in other places, such as the device tree overlay FDT (flattened device tree), and make the algorithms more clear - Use the same names consistently throughout the file - Update comments for name changes - Fix incorrect comments This patch is intended to not introduce any functional change. Signed-off-by:
Frank Rowand <frank.rowand@sony.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Frank Rowand authored
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 <frank.rowand@sony.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Frank Rowand authored
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 <frank.rowand@sony.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Tom McLeod authored
Opal Kelly is a manufacturer of FPGA Integration Modules. Signed-off-by:
Tom McLeod <tom.mcleod@opalkelly.com> Cc: Rob Herring <robh+dt@kernel.org> Cc: Mark Rutland <mark.rutland@arm.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
- Oct 17, 2017
-
-
Lixin Wang authored
Function of_changeset_add_property or of_changeset_update_property may fails. In this case the property just allocated is never deallocated. Signed-off-by:
Lixin Wang <alan.1.wang@nokia-sbell.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Stephen Boyd authored
of_fdt_unflatten_tree() already sets the flag on the node to OF_DETACHED, because of_fdt_unflatten_tree() calls __unflatten_device_tree() with the detached bool set to true. Signed-off-by:
Stephen Boyd <stephen.boyd@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Stephen Boyd authored
This wasn't documented. Signed-off-by:
Stephen Boyd <stephen.boyd@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Stephen Boyd authored
Save one line. Signed-off-by:
Stephen Boyd <stephen.boyd@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Stephen Boyd authored
This is the same as be32_add_cpu(), so simplify the code and remove the now unused local variable. Signed-off-by:
Stephen Boyd <stephen.boyd@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
For static DT usecases, we don't need the disabled nodes and can skip unflattening. This saves a significant amount of RAM in memory constrained cases. In one example on STM32F469, the RAM usage goes from 118K to 26K. There are a few cases in the kernel that modify the status property dynamically. These all are changes from enabled to disabled, depend on OF_DYNAMIC or are not FDT based (PDT based). Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
Add an equivalent function to of_device_is_available for flattened DT, and convert the one existing open coded occurrence. Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
Having device_nodes be kobjects is only needed if sysfs or OF_DYNAMIC is enabled. Otherwise, having a kobject in struct device_node is unnecessary bloat in minimal kernel configurations. Likewise, bin_attribute is only needed in struct property when sysfs is enabled, so we can make it configurable too. Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Acked-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
In preparation to make kobject element in struct device_node optional, provide and use a macro to return the kobject pointer. The only user outside the DT core is the driver core. Acked-by:
Greg Kroah-Hartman <gregkh@linuxfoundation.org> Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Acked-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
The only user of kobj_to_device_node() is in dynamic.c, so move it there. This avoids having to make it conditional once kobject is configurable. Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Acked-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
Only Sparc and CONFIG_OF_DYNAMIC use the struct property._flags field, so make it conditional shrinking struct property a bit. Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Acked-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
Only Sparc uses unique_id, so remove it for FDT builds and shrink struct property a bit making the unflattened DT less of a memory hog. Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Acked-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
The ref counting is broken for OF_DYNAMIC when sysfs is disabled because the kobject initialization is skipped. Only the properties add/remove/update should be skipped for !SYSFS config. Tested-by:
Nicolas Pitre <nico@linaro.org> Reviewed-by:
Frank Rowand <frowand.list@gmail.com> Acked-by:
Grant Likely <grant.likely@secretlab.ca> Signed-off-by:
Rob Herring <robh@kernel.org>
-
- Oct 14, 2017
-
-
Marek Vasut authored
Add vendor prefix for DH electronics GmbH, https://www.dh-electronics.com . The company is a SoM and evaluation board manufacturer. Signed-off-by:
Marek Vasut <marex@denx.de> Cc: Rob Herring <robh@kernel.org> Signed-off-by:
Rob Herring <robh@kernel.org>
-
- Oct 13, 2017
-
-
Geert Uytterhoeven authored
Use the preferred generic node name in the example. Signed-off-by:
Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by:
Simon Horman <horms+renesas@verge.net.au> Signed-off-by:
Rob Herring <robh@kernel.org>
-
- Oct 06, 2017
-
-
Alexandre Belloni authored
Now that there is documentation for the ds1307 and compatible RTCs, merge the ds1339 documentation in it. Signed-off-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Alexandre Belloni authored
The ST M41T80 family of RTC are not trivial devices, document them. Signed-off-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Alexandre Belloni authored
Document optional properties for ds1307 and compatible RTCs Signed-off-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Alexandre Belloni authored
Add device tree bindings for the SiRFSoC Real Time Clock. Signed-off-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Alexandre Belloni authored
Add device tree bindings for the ST-Ericsson COH 901 331 Real Time Clock Signed-off-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Reviewed-by:
Linus Walleij <linus.walleij@linaro.org> Signed-off-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Alexandre Belloni authored
Add remaining trivial RTC bindings. Signed-off-by:
Alexandre Belloni <alexandre.belloni@free-electrons.com> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Dmitry Dunaev authored
Signed-off-by:
Dmitry Dunaev <dunaev@tecon.ru> Signed-off-by:
Rob Herring <robh@kernel.org>
-
- Oct 04, 2017
-
-
Rob Herring authored
This adds the following commits from upstream: b1a60033c110 tests: Add a test for overlays syntactic sugar 737b2df39cc8 overlay: Add syntactic sugar version of overlays 497432fd2131 checks: Use proper format modifier for size_t 22a65c5331c2 dtc: Bump version to v1.4.5 c575d8059fff Add fdtoverlay to .gitignore b6a6f9490d19 fdtoverlay: Sanity check blob size 8c1eb1526d2d pylibfdt: Use Python2 explicitly ee3d26f6960b checks: add interrupts property check c1e7738988f5 checks: add gpio binding properties check b3bbac02d5e3 checks: add phandle with arg property checks fe50bd1ecc1d fdtget: Split out cell list display into a new function 62d812308d11 README: Add a note about test_tree1.dts 5bed86aee9e8 pylibfdt: Add support for fdt_subnode_offset() 46f31b65b3b3 pylibfdt: Add support for fdt_node_offset_by_phandle() a3ae43723687 pylibfdt: Add support for fdt_parent_offset() a198af80344c pylibfdt: Add support for fdt_get_phandle() b9eba92ea50f tests: Return a failure code when any tests fail 155faf6cc209 pylibfdt: Use local pylibfdt module 50e5cd07f325 pylibfdt: Add a test for use of uint32_t ab78860f09f5 pylibfdt: Add stdint include to fix uint32_t 36f511fb1113 tests: Add stacked overlay tests on fdtoverlay 1bb00655d3e5 fdt: Allow stacked overlays phandle references a33c2247ac8d Introduce fdt_setprop_placeholder() method 0016f8c2aa32 dtc: change default phandles to ePAPR style instead of both e3b9a9588a35 tests: fdtoverlay unit test 42409146f2db fdtoverlay: A tool that applies overlays aae22722fc8d manual: Document missing options 13ce6e1c2fc4 dtc: fix sprintf() format string error, again d990b8013889 Makefile: Fix build on MSYS2 and Cygwin 51f56dedf8ea Clean up shared library compile/link options 21a2bc896e3d Suppress expected error message in fdtdump test 2a42b14d0d03 dtc: check.c fix compile error a10cb3c818d3 Fix get_node_by_path string equality check 548aea2c436a fdtdump: Discourage use of fdtdump c2258841a785 fdtdump: Fix over-zealous version check 9067ee4be0e6 Fix a few whitespace and style nits e56f2b07be38 pylibfdt: Use setup.py to build the swig file 896f1c133265 pylibfdt: Use Makefile constructs to implement NO_PYTHON 90db6d9989ca pylibfdt: Allow setup.py to operate stand-alone e20d9658cd8f Add Coverity Scan support b04a2cf08862 pylibfdt: Fix code style in setup.py 1c5170d3a466 pylibfdt: Rename libfdt.swig to libfdt.i 580a9f6c2880 Add a libfdt function to write a property placeholder ab15256d8d02 pylibfdt: Use the call function to simplify the Makefile 9f2e3a3a1f19 pylibfdt: Use the correct libfdt version in the module e91c652af215 pylibfdt: Enable installation of Python module 8a892fd85d94 pylibfdt: Allow building to be disabled 741cdff85d3e .travis.yml: Add builds with and without Python library prerequisites 14c4171f4f9a pylibfdt: Use package_dir to set the package directory 89a5062ab231 pylibfdt: Use environment to pass C flags and files 4e0e0d049757 pylibfdt: Allow pkg-config to be supplied in the environment 6afd7d9688f5 Correct typo: s/pylibgfdt/pylibfdt/ Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
libfdt has gained some new files. We need to include them in the kernel's copy. Reported-by:
Kyle Yan <kyan@codeaurora.org> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
-
Rob Herring authored
With dependencies on a statically allocated full path name converted to use %pOF format specifier, we can store just the basename of node, and the unflattening of the FDT can be simplified. This commit will affect the remaining users of full_name. After analyzing these users, the remaining cases should only change some print messages. The main users of full_name are providing a name for struct resource. The resource names shouldn't be important other than providing /proc/iomem names. We no longer distinguish between pre and post 0x10 dtb formats as either a full path or basename will work. However, less than 0x10 formats have been broken since the conversion to use libfdt (and no one has cared). The conversion of the unflattening code to be non-recursive also broke pre 0x10 formats as the populate_node function would return 0 in that case. Signed-off-by:
Rob Herring <robh@kernel.org>
-
Rob Herring authored
With dependencies on full_name containing the entire device node path removed, stop storing the full_name in nodes created by dlpar_configure_connector() and pSeries_reconfig_add_node(). Signed-off-by:
Rob Herring <robh@kernel.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Michael Ellerman <mpe@ellerman.id.au> Cc: linuxppc-dev@lists.ozlabs.org
-
- Sep 20, 2017
-
-
Vladimir Barinov authored
Add Shimafuji Electric, Inc. to the list of device tree vendor prefixes Signed-off-by:
Vladimir Barinov <vladimir.barinov@cogentembedded.com> Acked-by:
Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by:
Rob Herring <robh@kernel.org>
-
- Sep 19, 2017
-
-
Fabrizio Castro authored
Add Silicon Storage Technology Inc. to the list of devicetree vendor prefixes. Signed-off-by:
Fabrizio Castro <fabrizio.castro@bp.renesas.com> Reviewed-by:
Andreas Färber <afaerber@suse.de> Signed-off-by:
Rob Herring <robh@kernel.org>
-
YuanCheng Cheng authored
NutsBoard (http://nutsboard.org/) is an organization and focus on ARM based embedded boards with open source software. Signed-off-by:
YuanCheng Cheng <onlywig@gmail.com> Reviewed-by:
Fabio Estevam <fabio.estevam@nxp.com> Reviewed-by:
Andreas Färber <afaerber@suse.de> Signed-off-by:
Rob Herring <robh@kernel.org>
-
Geert Uytterhoeven authored
Use the preferred generic node name in the example. Signed-off-by:
Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by:
Rob Herring <robh@kernel.org>
-
- Sep 17, 2017
-
-
Linus Torvalds authored
-