aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2017-06-02fdt: Add all source files to the libfdt buildSimon Glass1-3/+5
At present only a subset of source files are build. Add the rest and refactor this so that a source file list is available also. This will be used in later commit. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-02fdt: Allow swig options to be provided by MakefileSimon Glass1-2/+2
U-Boot needs to provide some swig include directories. Add this feature. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-02fdt: Move header files into lib/libfdtSimon Glass4-2160/+2213
These header files are actually part of libfdt. Move them there to make it easier to build pylibfdt and easier to merge changes from upstream. Update the license header to use SPDX at the same time. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-02fdt: Use SPDX format for licenses in the libfdt headersSimon Glass2-90/+2
These should follow the UBoot standard. Update them. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-02fdt: Correct cast for sandbox in fdtdec_setup_memory_size()Simon Glass1-1/+2
This gives a warning with some native compilers: lib/fdtdec.c:1203:8: warning: format ‘%llx’ expects argument of type ‘long long unsigned int’, but argument 3 has type ‘long unsigned int’ [-Wformat=] Fix it with a cast. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-02pci: Correct cast for sandboxSimon Glass1-1/+2
This gives a warning with some native compilers: cmd/pci.c:152:11: warning: format ‘%llx’ expects argument of type ‘long long unsigned int’, but argument 3 has type ‘u64 {aka long unsigned int}’ [-Wformat=] Fix it with a cast. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-02fdt: Add Python bindingsSimon Glass2-0/+512
An early version of this is available upstream. Bring it in as a starting point. This is from dtc upstream commit e56f2b0. Future work will plumb it into dtoc and remove the now-unnecessary local libraries. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01sandbox: Move to use live treeSimon Glass1-0/+1
This updates sandbox to use a live device tree. This means that after relocation (from board_init_r() onwards) it no-longer uses flat device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: gpio: power: Convert pm8916 drivers to livetreeSimon Glass2-6/+4
This PMIC driver (power and GPIO) is used by the sandbox SPMI tests. Update the drivers to support a live device tree so that the tests pass. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: test: Fix nit with position of backslashSimon Glass1-1/+1
Line up this backslash with all the others. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: sandbox: sysreset: Convert driver to livetreeSimon Glass1-1/+1
Update this driver to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: sandbox: spi: Convert driver to support livetreeSimon Glass1-4/+2
Update this driver to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: spi-flash: Convert uclass to livetreeSimon Glass1-4/+3
Update the SPI flash uclass to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: sandbox: i2c_rtc: Drop fdtdec.h headerSimon Glass1-1/+0
This is not needed in this driver. Drop it. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: sandbox: i2c: Drop fdtdec.h headerSimon Glass1-1/+0
This is not needed in this driver. Drop it. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: spi: Convert uclass to livetreeSimon Glass2-18/+15
Update the SPI uclass to support a live device tree. Also adjust spi_slave_ofdata_to_platdata() to accept a device instead of a blob and offset. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01cros_ec: Update the cros_ec keyboard driver to livetreeSimon Glass4-26/+23
Update this driver and key_matrix to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: Update the I2C eeprom driver for livetreeSimon Glass1-5/+2
Update this driver so that it works with livetree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: pci: Update uclass to support livetreeSimon Glass1-14/+12
Update the PCI uclass to support livetree. This mostly involves fixing the address decoding from the device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: reset: Update uclass to support livetreeSimon Glass2-13/+12
Update the reset domain uclass to support livetree. Fix the xlate() method which has no callers. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: power-domain: Update uclass to support livetreeSimon Glass2-12/+9
Update the power domain uclass to support livetree. Fix the xlate() method which has no callers. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01sandbox: phy: Update driver for livetreeSimon Glass1-2/+1
Update the sandbox phy driver to support livetree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: phy: Update uclass to support livetreeSimon Glass2-14/+10
Update the phy uclass to support livetree. Fix the xlate() method which has no callers. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: mailbox: Update uclass to support livetreeSimon Glass3-14/+10
Update the mailbox uclass to support livetree. Fix the xlate() method in all callers. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: phy: Update tests to use ut_asserteq()Simon Glass1-6/+9
Use ut_asserteq() to test equality since this gives a better error message on failure. Also make a few of the tests more specific. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: test: Disable the fdt_offset test with livetreeSimon Glass1-1/+2
We cannot run this test with livetree since it uses device tree offsets. Mark it as flat tree only. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: test: Separate out the bus DT offset testSimon Glass1-1/+15
We cannot access the device tree via an offset when running in livetree mode. Separate out that part of the bus' children tests and mark it as for the flat tree only. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: clk: fixed: Update to support livetreeSimon Glass1-3/+2
Update the fixed-rate clock driver to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: clk: Update uclass to support livetreeSimon Glass2-11/+8
Update the clk uclass to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01clk: Modify xlate() method for livetreeSimon Glass5-9/+10
Update the xlate() method to use ofnode_phandle_args instead of the fdtdec variant. This will allow drivers to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01sandbox: usb: Convert emulators to livetreeSimon Glass2-5/+2
Update the sandbox flash and hub USB emulators to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: usb: Convert uclass to livetreeSimon Glass1-5/+3
Update the usb uclass to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: adc: Convert uclass to livetreeSimon Glass1-8/+6
Update the adc uclass to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: mmc: Convert uclass to livetreeSimon Glass1-1/+2
Update the mmc uclass to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: regulator: Update fixed regulator to support livetree.Simon Glass1-8/+9
Update this driver to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: regulator: Convert regulator uclass to support livetreeSimon Glass1-23/+16
Update the regulator uclass to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01sandbox: pmic: Convert pmic emulator to support livetreeSimon Glass1-4/+2
Update this driver to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: pmic: Convert uclass to livetreeSimon Glass11-59/+42
Update the pmic uclass and all pmics to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01samsung: Move pmic header out of config fileSimon Glass4-3/+13
We should not be including a PMIC header file in the board config. Move it to a C file. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: i2c: Convert uclass to livetreeSimon Glass2-17/+14
Update the i2c uclass to support a live device tree. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01string: Add strcspn()Simon Glass2-0/+39
Add an implementation of strcspn() which returns the number of initial characters that do not match any in a rejection list. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01string: Add strchrnul()Simon Glass2-0/+21
This functions works like strchr() but returns the end of the string if the character is not found. Add an implementation of this. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: Add more livetree helpers and definitionsSimon Glass2-2/+38
Add some definitions and helpers for livetree in the main of.h header file. These include: - reading multi-cell integers - default number of address/size cells - functions for comparing names Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01fdt: Rename a few functions in fdt_supportSimon Glass9-25/+25
These two functions have an of_ prefix which conflicts with naming used in of_addr. Rename them: fdt_read_number fdt_support_bus_default_count_cells Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01test: Update 'make test' to run more testsSimon Glass1-1/+7
The standard sandbox board cannot run the of-platdata test since it needs SPL. Also, we should test the flat tree version of sandbox. Add these tests to the default test script. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01sandbox: Add a new sandbox_flattree boardSimon Glass2-0/+186
Add a sandbox board to test the non-livetree build (i.e. with CONFIG_OF_FLAT disabled). This increases our build and test coverage. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01cros_ec: Convert to support live treeSimon Glass5-81/+27
Convert this driver to support the live device tree and remove the old fdtdec support. The keyboard is not yet converted. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01cros_ec: Fix debug() statement in ec_command_inptr()Simon Glass1-2/+1
This prints out the wrong pointers. Fix it. Signed-off-by: Simon Glass <sjg@chromium.org>
2017-06-01dm: gpio: Add live tree supportSimon Glass17-70/+68
Add support for requesting GPIOs with a live device tree. This involves adjusting the function signature for the legacy function gpio_request_by_name_nodev(), so fix up all callers. Signed-off-by: Simon Glass <sjg@chromium.org> Fixes to stm32f746-disco.c: Signed-off-by: Tom Rini <trini@konsulko.com>
2017-06-01dm: gpio: sandbox: Use dev_read...() functions to access DTSimon Glass1-6/+3
Use the new dev_read...() functions to access the device tree, so that a live tree can be used. Signed-off-by: Simon Glass <sjg@chromium.org>