arc: Adding EM9D SOC
EM9D is a ARC CPU configuration that can be selected for the ARC EM Starter Kit. The board support for this board will be submitted separately to expidite review. Change-Id: I2c85bdab6ea7bfb257e94e4c72b11b4568dbac19 Signed-off-by: Chuck Jordan <cjordan@synopsys.com>
This commit is contained in:
parent
489f42328c
commit
7bfe11b3e1
8 changed files with 546 additions and 0 deletions
45
arch/arc/soc/em9d/soc_config.c
Normal file
45
arch/arc/soc/em9d/soc_config.c
Normal file
|
@ -0,0 +1,45 @@
|
|||
/*
|
||||
* Copyright (c) 2016 Synopsys, Inc. All rights reserved.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
#include <device.h>
|
||||
#include <init.h>
|
||||
#include "soc.h"
|
||||
|
||||
|
||||
#ifdef CONFIG_UART_NS16550
|
||||
|
||||
static int uart_ns16550_init(struct device *dev)
|
||||
{
|
||||
ARG_UNUSED(dev);
|
||||
|
||||
/* On ARC EM Starter kit board,
|
||||
* send the UART the command to clear the interrupt
|
||||
*/
|
||||
#ifdef CONFIG_UART_NS16550_PORT_0
|
||||
sys_write32(0, UART_NS16550_PORT_0_BASE_ADDR+0x4);
|
||||
sys_write32(0, UART_NS16550_PORT_0_BASE_ADDR+0x10);
|
||||
#endif /* CONFIG_UART_NS16550_PORT_0 */
|
||||
#ifdef CONFIG_UART_NS16550_PORT_1
|
||||
sys_write32(0, UART_NS16550_PORT_1_BASE_ADDR+0x4);
|
||||
sys_write32(0, UART_NS16550_PORT_1_BASE_ADDR+0x10);
|
||||
#endif /* CONFIG_UART_NS16550_PORT_1 */
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
SYS_INIT(uart_ns16550_init, PRIMARY, CONFIG_KERNEL_INIT_PRIORITY_DEFAULT);
|
||||
|
||||
#endif /* CONFIG_UART_NS16550 */
|
Loading…
Add table
Add a link
Reference in a new issue