summaryrefslogtreecommitdiff
path: root/board/synopsys
Commit message (Collapse)AuthorAgeFilesLines
* dm: core: Access device ofnode through functionsSimon Glass2021-01-051-1/+1
| | | | | | | | At present ofnode is present in the device even if it is never used. With of-platdata this field is not used, so can be removed. In preparation for this, change the access to go through inline functions. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Drop linux/bitops.h from common headerWIP/2020-05-18-reduce-size-of-common.hSimon Glass2020-05-184-0/+4
| | | | | | Move this uncommon header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Drop linux/delay.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-183-0/+3
| | | | | | Move this header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
* command: Remove the cmd_tbl_t typedefSimon Glass2020-05-182-13/+20
| | | | | | | | | | | | | We should not use typedefs in U-Boot. They cannot be used as forward declarations which means that header files must include the full header to access them. Drop the typedef and rename the struct to remove the _s suffix which is now not useful. This requires quite a few header-file additions. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Drop init.h from common headerSimon Glass2020-05-184-0/+4
| | | | | | Move this uncommon header out of the common header. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Drop image.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 net.h from common headerSimon Glass2020-05-182-0/+2
| | | | | | | | | | | Move this header out of the common header. Network support is used in quite a few places but it still does not warrant blanket inclusion. Note that this net.h header itself has quite a lot in it. It could be split into the driver-mode support, functions, structures, checksumming, etc. Signed-off-by: Simon Glass <sjg@chromium.org>
* ARC: HSDK: anounce state of BIM switchEugeniy Paltsev2020-05-131-0/+7
| | | | | | | | Anounce state of BIM switch which defines if U-boot is loaded and started by preloader or not. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: make init status resistant to U-boot reloadingEugeniy Paltsev2020-04-271-3/+25
| | | | | | | | | | | Use register intstead of static variable to store HSDK init status as we want to avoid the situation when we reload U-boot via MDB after previous init is done but HW reset (board reset) isn't done. So let's store the init status in unused register - CREG_CPU_0_ENTRY so status will survive after U-boot is reloaded via MDB. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: use separate config fileEugeniy Paltsev2020-04-272-1/+4
| | | | | | | | HSDK-4xD has quite different environment so let's split HSDK and HSDK-4xD configs file. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: tweak memory mapEugeniy Paltsev2020-04-271-0/+58
| | | | | | | | | | | For HSDK-4xD we do additional AXI bridge tweaking while doing hsdk_init command: - we shrink IOC region. - we configure ARC HS CORE SLV1 aperture depending on haps_apb_location environment variable. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: add CSM configuration supportEugeniy Paltsev2020-04-271-0/+27
| | | | | | | | | Add support for CSM enable/disable and CSM relocation via hsdk_init command. We allow to relocate CSM to the beginning of any aperture even if HW support finer granularity. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: add support for SLC enable/disableEugeniy Paltsev2020-04-271-0/+22
| | | | | | | Add support for SLC enable/disable via hsdk_init command. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: print timer clock valueEugeniy Paltsev2020-04-271-0/+2
| | | | | | | Print timer clock value in hsdk_clock print_all command. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: drop additional GPU clock infoEugeniy Paltsev2020-04-271-2/+4
| | | | | | | | | | HSDK-4xD has other GPU type so it consumes only GPU core clock. Even we have additional GPU clock dividers they are not routed to anything. So drop information about those additional clocks in hsdk_clock print_all command. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: print info about HDMI clocksEugeniy Paltsev2020-04-271-4/+7
| | | | | | | HSDK-4xD has HDMI working so let's print info about HDMI clocks. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: fix headerize script for HSDK-4xD compatibilityEugeniy Paltsev2020-04-272-3/+11
| | | | | | | | ARC HS CPU in HSDK-4xD has ARC ID = 0x54, so fix headerize script accordingly. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: use active low polarity of cpu_start pulseEugeniy Paltsev2020-04-271-7/+19
| | | | | | | | | | Add quirk for HSDK-4xD - due to HW issues HSDK can use any pulse polarity but HSDK-4xD require active low polarity of cpu_start pulse. So use low polarity of cpu_start pulse for both board. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: HSDK-4xD: add initial board supportEugeniy Paltsev2020-04-274-3/+96
| | | | | | | | | | | Add initial HSDK-4xD board support. The ARC HS4x/HS4xD Development Kit includes a multicore ARC HS4xD-based chip that integrates a wide range of interfaces including Ethernet, HDMI, WiFi, Bluetooth, USB, SDIO, I2C, SPI, UART, I2S, ADC, PWM and GPIO, as well as a Think Silicon GPU. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: rework setting of ARC CPU specific compiler optionsEugeniy Paltsev2020-02-126-2/+30
| | | | | | | | | | | | | It's a very rare if at all existing occasion when ARC CPU template is used as is w/o any changes - in the end it's a beauty and competitive advantage of ARC cores to be tailored for a particular use-case - and so it doesn't make a lot of sense to offer template-based "-mcpu" selection. Given for each and every platform we end-up adding quite a few more flags it's logical to move "-mcpu" selection to platform's definition as well which we exactly do here. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: nsim_hs38: Add support of Virtio NET & BLKAlexey Brodkin2020-02-124-0/+42
| | | | | | | | | Given now nsim_hs38 configuration is usable on QEMU and in QEMU we have Virtio working perfectly fine the next logical step is to add support of supported & known to work net & bkl to this config. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* dm: core: Create a new header file for 'compat' featuresSimon Glass2020-02-051-0/+1
| | | | | | | | | | | | At present dm/device.h includes the linux-compatible features. This requires including linux/compat.h which in turn includes a lot of headers. One of these is malloc.h which we thus end up including in every file in U-Boot. Apart from the inefficiency of this, it is problematic for sandbox which needs to use the system malloc() in some files. Move the compatibility features into a separate header file. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Move reset_cpu() to the CPU headerSimon Glass2020-01-172-0/+2
| | | | | | Move this function out of common.h and into a relevant header file. Signed-off-by: Simon Glass <sjg@chromium.org>
* common: Move some board functions out of common.hSimon Glass2019-12-021-0/+1
| | | | | | | A number of board function belong in init.h with the others. Move them. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
* common: Move enable/disable_interrupts out of common.hSimon Glass2019-12-021-0/+1
| | | | | | | | Move these two functions into the irq_funcs.h header file. Also move interrupt_handler_t as this is used by the irq_install_handler() function. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
* common: Move some cache and MMU functions out of common.hSimon Glass2019-12-021-0/+1
| | | | | | | | | | | | These functions belong in cpu_func.h. Another option would be cache.h but that code uses driver model and we have not moved these cache functions to use driver model. Since they are CPU-related it seems reasonable to put them here. Move them over. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
* common: Move some SMP functions out of common.hSimon Glass2019-12-021-0/+1
| | | | | | | These functions belong in cpu_func.h so move them over. Signed-off-by: Simon Glass <sjg@chromium.org> Reviewed-by: Tom Rini <trini@konsulko.com>
* arc: emsdp: docs: Prefer Degilent over Opella-XDAlexey Brodkin2019-11-011-1/+1
| | | | | | | | | | Back in the day on early board samples built-in Digilent JTAG probe was not functional so we used externally attached Ashling Opella-XD probe. But now with production units everything works as expected and so we anybody may enjoy readily avaialble built-in JTAG probe so we specify Digilent oprion on MDB's command line example. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* arc: emsdp/iotdk: Switch to DM_MMCAlexey Brodkin2019-11-012-61/+0
| | | | | | | Somehow EMSDP & IoT DK boards were skipped on ARC boads conversion to DM MMC. So doing it now. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* arc: emsdp: Add more platform-specific compiler optionsAlexey Brodkin2019-09-031-0/+2
| | | | | | | | | | | | | | | | | | | | | | Even though EM SDP is FPGA-based board and different FPGA images (known as .bit-files) are awailable for the board still there's a common subset of options we may rely on for all configs. These are: * Normalizer * Swap instructions * Simple multiplier * Barrel-shifter * Floating-point unit * Shorter instructions (code density) This among other improvements allows to compile code with 64-bit divisions, see [1]. [1] https://patchwork.ozlabs.org/patch/1156541/ Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Cc: Kever Yang <kever.yang@rock-chips.com>
* arc: emsdp: Add initialization of PSRAMAlexey Brodkin2019-09-031-0/+37
| | | | | | | If the "Page Mode" is not enabled on the device, read operations from PSRAM may result in incorrect data. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* env: Move env_get_ulong() to env.hSimon Glass2019-08-111-0/+1
| | | | | | | Move env_get_ulong() over to the new header file. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
* env: Move env_set_ulong() to env.hSimon Glass2019-08-111-0/+1
| | | | | | | Move env_set_ulong() over to the new header file. Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Joe Hershberger <joe.hershberger@ni.com>
* ARC: [plat-axs10x]: migrate to DM_MMCEugeniy Paltsev2019-04-181-29/+0
| | | | | Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* ARC: [plat-hsdk]: migrate to DM_MMCEugeniy Paltsev2019-04-181-35/+6
| | | | | Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* hsdk: readme: Suggest getting pyelftools with pipAlexey Brodkin2019-03-281-3/+4
| | | | | Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com> Suggested-by: Yunir Salimzyanov <yunir@synopsys.com>
* ARC: AXS10x: drop NAND supportEugeniy Paltsev2019-03-282-243/+0
| | | | | | | | | | | | | | On AXS10x boards we have non-standard NAND controller which was never really used a lot as there're other much more convenient [as they are standard & removable] persistent media like SD-card and USB mass storage. Moreover after recent changes we face with some NAND controller runtime issues. So instead of keeping support of yet another non-standard peripheral we're dropping its support for good. Signed-off-by: Eugeniy Paltsev <Eugeniy.Paltsev@synopsys.com> Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* arc: devboards: Implement checkboard()Alexey Brodkin2018-12-033-0/+24
| | | | | | This allows us to print nice board name on boot. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* arc: emsdp: Refactor register and bit accessesAlexey Brodkin2018-12-031-9/+9
| | | | | | | | | Instead of "base + offset" define all registers right away and access them later via direct defines. Generate bit masks with "BIT" macro. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* arc: emsdp: Read real CPU clock value from hardwareAlexey Brodkin2018-12-031-3/+39
| | | | | | | | | | | | We do real CPU clock measurement with help of built-in counters. Thus we may accommodate different real clock values that appear in different FPA images instead of relying on something hard-coded in the .dtb. And while at it make make SDIO base address define look similar to others with casting to "(void *)". Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* arc: Get rid of board-specific print_cpuinfo()Alexey Brodkin2018-12-032-18/+0
| | | | | | | | Since we now do advanced CPU identification in generic ARC code there's no need to have per-board hardcoded data. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* iot_dk: Add READMEAlexey Brodkin2018-11-011-0/+145
| | | | Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* emdk->emsdp: Rename boardAlexey Brodkin2018-11-015-20/+22
| | | | | | | | Real marketing name of the board was recently updated so to accommodate that change renaming the board and all related to it. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* axs10x/emdk/hsdk/iot_dk: Implement board_mmc_getcd()Alexey Brodkin2018-10-124-0/+28
| | | | | | | | | | | | | | | So now we may detect MMC/SD-card existence and instead of completely misleading message on missing card: ------------------------>8----------------------- Loading Environment from FAT... Card did not respond to voltage select! ------------------------>8----------------------- we now get very clear one: ------------------------>8----------------------- Loading Environment from FAT... MMC: no card present ------------------------>8----------------------- Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* iot_dk: Save CPU clock value to gd->cpu_clkAlexey Brodkin2018-10-121-6/+8
| | | | | | | Since gd->cpu_clk is a global item we may once populate it from .dtb ans use it then in other places like for printing CPU info etc. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* iot_dk: Add support of 136 MHz clockAlexey Brodkin2018-10-121-0/+8
| | | | Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* iot_dk: Implement board resetAlexey Brodkin2018-10-121-0/+8
| | | | | | It is done by writing some magic sequence in a special register. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* iot_dk/hsdk: Implement its own print_cpuinfo()Alexey Brodkin2018-10-122-0/+16
| | | | | | | | | ARC IDENTITY register only encodes major architecture type and version while for a particular board/silicon we may know better which template was used and so we may identify CPU more precise, which exactly we do here. Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
* arc: Add support for IoT development kitAlexey Brodkin2018-10-056-0/+271
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The DesignWare ARC IoT Development Kit is a versatile platform that includes the necessary hardware and software to accelerate software development and debugging of sensor fusion, voice recognition and face detection designs. More information is avaialble here [1] and here [2]. The board is based on real silicon with ARC EM9D-based Data Fusion IP Subsystem. It sports a rich set of I/O including * DW USB OTG * DW MobileStorage (used for micro SD-card) * GPIO * multiple serial interface including DW APB UART * ADC, PWM and eFlash, SRAM and SPI Flash memory * Real-Time Clock (RTC) * Bluetooth module with worldwide regulatory compliance (FCC, IC, CE, ETSI, TELEC) * On-board 9-axis sensor (gyro, accelerometer and compass) Extensible with Arduino, Pmod, mikroBUS connectors and a 2x18 extension header. One of the most interesting features for developers is built-in Digilent USB JTAG probe so only micro-USB cable is needed! [1] https://www.synopsys.com/dw/ipdir.php?ds=arc_iot_development_kit [2] https://www.synopsys.com/dw/doc.php/ds/cc/iot_dev_kit.pdf Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>