2018-11-16 12:10:55 +08:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2018 Synopsys, Inc. All rights reserved.
|
|
|
|
*
|
|
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* @brief Linker script for the Synopsys ARC IoT Development Kit
|
|
|
|
*/
|
|
|
|
|
2020-01-16 20:29:53 +08:00
|
|
|
#include <devicetree.h>
|
2018-12-12 23:33:11 +08:00
|
|
|
#include <autoconf.h>
|
2018-11-16 12:10:55 +08:00
|
|
|
|
|
|
|
/*
|
|
|
|
* SRAM base address and size
|
|
|
|
*
|
|
|
|
*/
|
2020-04-30 22:34:04 +08:00
|
|
|
#if DT_NODE_HAS_PROP(DT_CHOSEN(zephyr_sram), reg) && \
|
|
|
|
(DT_REG_SIZE(DT_CHOSEN(zephyr_sram)) > 0)
|
|
|
|
#define SRAM_START DT_REG_ADDR(DT_CHOSEN(zephyr_sram))
|
|
|
|
#define SRAM_SIZE DT_REG_SIZE(DT_CHOSEN(zephyr_sram))
|
2018-11-16 12:10:55 +08:00
|
|
|
#endif
|
|
|
|
|
2020-04-30 22:34:04 +08:00
|
|
|
#if DT_NODE_HAS_PROP(DT_CHOSEN(zephyr_flash), reg) && \
|
|
|
|
(DT_REG_SIZE(DT_CHOSEN(zephyr_flash)) > 0)
|
|
|
|
#define FLASH_START DT_REG_ADDR(DT_CHOSEN(zephyr_flash))
|
|
|
|
#define FLASH_SIZE DT_REG_SIZE(DT_CHOSEN(zephyr_flash))
|
2018-11-16 12:10:55 +08:00
|
|
|
#endif
|
|
|
|
|
|
|
|
/* Instruction Closely Coupled Memory (ICCM) base address and size */
|
2020-04-30 22:34:04 +08:00
|
|
|
#if DT_NODE_HAS_PROP(DT_INST(0, arc_iccm), reg) && \
|
|
|
|
(DT_REG_SIZE(DT_INST(0, arc_iccm)) > 0)
|
|
|
|
#define ICCM_START DT_REG_ADDR(DT_INST(0, arc_iccm))
|
|
|
|
#define ICCM_SIZE DT_REG_SIZE(DT_INST(0, arc_iccm))
|
2018-11-16 12:10:55 +08:00
|
|
|
#endif
|
|
|
|
|
|
|
|
/*
|
|
|
|
* DCCM base address and size. DCCM is the data memory.
|
|
|
|
*/
|
2020-04-30 22:34:04 +08:00
|
|
|
#if DT_NODE_HAS_PROP(DT_INST(0, arc_dccm), reg) && \
|
|
|
|
(DT_REG_SIZE(DT_INST(0, arc_dccm)) > 0)
|
|
|
|
#define DCCM_START DT_REG_ADDR(DT_INST(0, arc_dccm))
|
|
|
|
#define DCCM_SIZE DT_REG_SIZE(DT_INST(0, arc_dccm))
|
2018-11-16 12:10:55 +08:00
|
|
|
#endif
|
|
|
|
|
|
|
|
#include <arch/arc/v2/linker.ld>
|