summaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-snapdragon
Commit message (Collapse)AuthorAgeFilesLines
* common: Drop asm/global_data.h from common headerSimon Glass2021-02-021-1/+1
| | | | | | | | | | | | Move this out of the common header and include it only where needed. In a number of cases this requires adding "struct udevice;" to avoid adding another large header or in other cases replacing / adding missing header files that had been pulled in, very indirectly. Finally, we have a few cases where we did not need to include <asm/global_data.h> at all, so remove that include. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Rini <trini@konsulko.com>
* dm: treewide: Rename auto_alloc_size members to be shorterSimon Glass2020-12-132-2/+2
| | | | | | | | | | | | This construct is quite long-winded. In earlier days it made some sense since auto-allocation was a strange concept. But with driver model now used pretty universally, we can shorten this to 'auto'. This reduces verbosity and makes it easier to read. Coincidentally it also ensures that every declaration is on one line, thus making dtoc's job easier. Signed-off-by: Simon Glass <sjg@chromium.org>
* treewide: convert devfdt_get_addr() to dev_read_addr()Masahiro Yamada2020-07-252-2/+2
| | | | | | | | | | | | | | | | | | | | When you enable CONFIG_OF_LIVE, you will end up with a lot of conversions. To generate this commit, I used coccinelle excluding drivers/core/, include/dm/, and test/ The semantic patch that makes this change is as follows: <smpl> @@ expression dev; @@ -devfdt_get_addr(dev) +dev_read_addr(dev) </smpl> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* Revert "Merge tag 'dm-pull-20jul20' of git://git.denx.de/u-boot-dm"Tom Rini2020-07-242-2/+2
| | | | | | | | | | This reverts commit 5d3a21df6694ebd66d5c34c9d62a26edc7456fc7, reversing changes made to 56d37f1c564107e27d873181d838571b7d7860e7. Unfortunately this is causing CI failures: https://travis-ci.org/github/trini/u-boot/jobs/711313649 Signed-off-by: Tom Rini <trini@konsulko.com>
* treewide: convert devfdt_get_addr() to dev_read_addr()Masahiro Yamada2020-07-202-2/+2
| | | | | | | | | | | | | | | | | | | | When you enable CONFIG_OF_LIVE, you will end up with a lot of conversions. To generate this commit, I used coccinelle excluding drivers/core/, include/dm/, and test/ The semantic patch that makes this change is as follows: <smpl> @@ expression dev; @@ -devfdt_get_addr(dev) +dev_read_addr(dev) </smpl> Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
* common: Drop linux/bitops.h from common headerSimon Glass2020-05-181-0/+1
| | | | | | Move this uncommon header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Drop log.h from common headerSimon Glass2020-05-181-0/+1
| | | | | | Move this header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Drop part.h from common headerSimon Glass2020-05-181-0/+1
| | | | | | Move this uncommon header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
* mach-snapdragon: Fix overwriting last digit of serial numberJan-Christoph Tebbe2020-04-031-1/+1
| | | | | | | | | When generating the MAC address based on the boards serial number the last digit was overwritten with the null termination. That way boards with serial numbers close to each other would use the same MAC address. Signed-off-by: Jan-Christoph Tebbe <Jan-Christoph.Tebbe@ithinx.io>
* arm: mach-snapdragon: pinctrl: clarify gpio disable bitRamon Fried2019-01-251-2/+2
| | | | | | | The TLMM_GPIO_ENABLE bit is actually use to disable the GPIO. change it to TLMM_GPIO_DISABLE so it's clearer. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* arm: mach-snapdragon: add pinctrl driver for db820cRamon Fried2019-01-254-3/+61
| | | | | | | Add pinctrl driver for Dragonboard820c, currently with only one mux func to initialize pins for serial console. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* arm: mach-snapdragon: db820c: Actually init PLL for serialRamon Fried2019-01-252-0/+43
| | | | | | | The PLL for the UART was not set, and relied on previous initializtion made by LK. add the appropriate initialization. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* mach-snapdragon: db410: pinctrl: fix pin countRamon Fried2019-01-181-3/+3
| | | | | | | Pin count in APQ8016 was wrong, fix that. Fixes: ad97051b7ff6 ("mach-snapdragon: Introduce pinctrl driver") Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* db410c: serial# env using msm board serialRamon Fried2018-09-301-0/+1
| | | | | | | | The serial# environment variable needs to be defined so it will be used by fastboot as serial for the endpoint descriptor. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* snapdragon: added MAC generation functionsRamon Fried2018-08-132-0/+17
| | | | | | | | Add support for generation of unique MAC address that is derived from board serial. Algorithm for generation of MAC taken from LK. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* snapdragon: added msm_board_serial() funcRamon Fried2018-08-133-0/+50
| | | | | | | | | | | This commit adds a function to get the board serial number. In snapdragon it's actually the eMMC serial number. Function added in a new file misc.c that will include further snapdragon miscellaneous functions. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* snapdragon: Add DRAM detection & FDT fixupRamon Fried2018-08-103-0/+111
| | | | | | | | Fixup the Linux FDT with the detection of onboard DRAM as provided by SBL (Secondary boot loader) by reading the shared-memory region. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* mach-snapdragon: increase size of malloc poolRamon Fried2018-05-291-0/+6
| | | | | | | Pool size must be increased to support new additionals drivers. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* mach-snapdragon: Introduce pinctrl driverRamon Fried2018-05-264-0/+222
| | | | | | | | | | | | | This patch adds pinmux and pinctrl driver for TLMM subsystem in snapdragon chipsets. Currently, supporting only 8016, but implementation is generic and 8096 can be added easily. Driver is using the generic dt-bindings and doesn't introduce any new bindings (yet). Signed-off-by: Ramon Fried <ramon.fried@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
* mach-snapdragon: Fix UART clock flowRamon Fried2018-05-265-12/+43
| | | | | | | UART clock enabling flow was wrong. Changed the flow according to downstream implementation in LK. Signed-off-by: Ramon Fried <ramon.fried@gmail.com>
* SPDX: Convert all of our single license tags to Linux Kernel styleTom Rini2018-05-0710-21/+10
| | | | | | | | | | | | | | | | | | | | When U-Boot started using SPDX tags we were among the early adopters and there weren't a lot of other examples to borrow from. So we picked the area of the file that usually had a full license text and replaced it with an appropriate SPDX-License-Identifier: entry. Since then, the Linux Kernel has adopted SPDX tags and they place it as the very first line in a file (except where shebangs are used, then it's second line) and with slightly different comment styles than us. In part due to community overlap, in part due to better tag visibility and in part for other minor reasons, switch over to that style. This commit changes all instances where we have a single declared license in the tag as both the before and after are identical in tag contents. There's also a few places where I found we did not have a tag and have introduced one. Signed-off-by: Tom Rini <trini@konsulko.com>
* db820c: add qualcomm dragonboard 820C supportJorge Ramirez-Ortiz2018-01-155-0/+135
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for 96Boards Dragonboard820C. The board is based on APQ8086 Qualcomm Soc, complying with the 96Boards specification. Features - 4x Kyro CPU (64 bit) up to 2.15GHz - USB2.0 - USB3.0 - ISP - Qualcomm Hexagon DSP - SD 3.0 (UHS-I) - UFS 2.0 - Qualcomm Adreno 530 GPU - GPS - BT 4.2 - Wi-Fi 2.4GHz, 5GHz (802.11ac) - PCIe 2.0 - MIPI-CSI, MIPI-DSI - I2S U-Boot boots chained from LK (LK implements the fastboot protocol) in 64-bit mode. For detailed build instructions see readme.txt in the board directory. Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org>
* arm: mach-snapdragon: refactor clock driverJorge Ramirez-Ortiz2018-01-155-173/+216
| | | | | | | | | In preparation to add support for the Dragonboard820c (APQ8096), refactor the current Snapdragon clock driver. No new functionality has been added. Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez-ortiz@linaro.org>
* dm: Rename dev_addr..() functionsSimon Glass2017-06-011-1/+1
| | | | | | | | | | | | | | | | | | | These support the flat device tree. We want to use the dev_read_..() prefix for functions that support both flat tree and live tree. So rename the existing functions to avoid confusion. In the end we will have: 1. dev_read_addr...() - works on devices, supports flat/live tree 2. devfdt_get_addr...() - current functions, flat tree only 3. of_get_address() etc. - new functions, live tree only All drivers will be written to use 1. That function will in turn call either 2 or 3 depending on whether the flat or live tree is in use. Note this involves changing some dead code - the imx_lpi2c.c file. Signed-off-by: Simon Glass <sjg@chromium.org>
* drivers/sysreset: group sysreset driversMax Filippov2016-08-122-41/+0
| | | | | | | | Create drivers/sysreset and move sysreset-uclass and all sysreset drivers there. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com> Acked-by: Simon Glass <sjg@chromium.org>
* armv8: mmu: Add support of non-identical mappingYork Sun2016-07-151-2/+4
| | | | | | | Introduce virtual and physical addresses in the mapping table. This change have no impact on existing boards because they all use idential mapping. Signed-off-by: York Sun <york.sun@nxp.com>
* clk: convert API to match reset/mailbox styleStephen Warren2016-06-191-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The following changes are made to the clock API: * The concept of "clocks" and "peripheral clocks" are unified; each clock provider now implements a single set of clocks. This provides a simpler conceptual interface to clients, and better aligns with device tree clock bindings. * Clocks are now identified with a single "struct clk", rather than requiring clients to store the clock provider device and clock identity values separately. For simple clock consumers, this isolates clients from internal details of the clock API. * clk.h is split so it only contains the client/consumer API, whereas clk-uclass.h contains the provider API. This aligns with the recently added reset and mailbox APIs. * clk_ops .of_xlate(), .request(), and .free() are added so providers can customize these operations if needed. This also aligns with the recently added reset and mailbox APIs. * clk_disable() is added. * All users of the current clock APIs are updated. * Sandbox clock tests are updated to exercise clock lookup via DT, and clock enable/disable. * rkclk_get_clk() is removed and replaced with standard APIs. Buildman shows no clock-related errors for any board for which buildman can download a toolchain. test/py passes for sandbox (which invokes the dm clk test amongst others). Signed-off-by: Stephen Warren <swarren@nvidia.com> Acked-by: Simon Glass <sjg@chromium.org>
* Rename reset to sysresetStephen Warren2016-05-261-9/+9
| | | | | | | | | | | | | | The current reset API implements a method to reset the entire system. In the near future, I'd like to introduce code that implements the device tree reset bindings; i.e. the equivalent of the Linux kernel's reset API. This controls resets to individual HW blocks or external chips with reset signals. It doesn't make sense to merge the two APIs into one since they have different semantic purposes. Resolve the naming conflict by renaming the existing reset API to sysreset instead, so the new reset API can be called just reset. Signed-off-by: Stephen Warren <swarren@nvidia.com> Acked-by: Simon Glass <sjg@chromium.org>
* board: Add Qualcomm Dragonboard 410C supportMateusz Kulikowski2016-04-011-0/+20
| | | | | | | | | | | | | | | | | | | | | | This commit add support for 96Boards Dragonboard410C. It is board based on APQ8016 Qualcomm SoC, complying with 96boards specification. Features (present out of the box): - 4x Cortex A53 (ARMv8) - 2x USB Host port - 1x USB Device port - 4x LEDs - 1x HDMI connector - 1x uSD connector - 3x buttons (Power, Vol+, Vol-/Reset) - WIFI, Bluetooth with integrated antenna - 8GiB eMMC U-Boot boots chained with fastboot in 64-bit mode. For detailed build instructions see readme.txt in board directory. Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Tested-by: Simon Glass <sjg@chromium.org>
* arm: Add support for Qualcomm Snapdragon familyMateusz Kulikowski2016-04-017-0/+370
First supported chip is APQ8016 (that is compatible with MSM8916). Drivers in SoC code: - Reset controller (PSHOLD) - Clock controller (very simple clock configuration for MMC and UART) Signed-off-by: Mateusz Kulikowski <mateusz.kulikowski@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>