From eb59b5064aad50871ab856924913c83797711ca6 Mon Sep 17 00:00:00 2001 From: vojo Date: Fri, 9 Feb 2018 10:01:07 +0100 Subject: Grapeboard related license headers updated diff --git a/board/scalys/grapeboard/Makefile b/board/scalys/grapeboard/Makefile index 3380a93..a8632b6 100644 --- a/board/scalys/grapeboard/Makefile +++ b/board/scalys/grapeboard/Makefile @@ -1,5 +1,5 @@ # -# Copyright 2017 Scalys B.V. +# Copyright 2018 Scalys B.V. # opensource@scalys.com # # SPDX-License-Identifier: GPL-2.0+ @@ -10,6 +10,6 @@ obj-y += eth.o obj-y += usb_grapeboard.o obj-y += board_configuration_data.o -obj-$(CONFIG_LAYERSCAPE_NS_ACCESS) += ns_access.o +obj-$(CONFIG_LAYERSCAPE_NS_ACCESS) += ../../freescale/common/ns_access.o diff --git a/board/scalys/grapeboard/board_configuration_data.c b/board/scalys/grapeboard/board_configuration_data.c index a730c11..6f3116f 100644 --- a/board/scalys/grapeboard/board_configuration_data.c +++ b/board/scalys/grapeboard/board_configuration_data.c @@ -1,5 +1,5 @@ /* - * Copyright 2017 Scalys B.V. + * Copyright 2018 Scalys B.V. * opensource@scalys.com * * SPDX-License-Identifier: GPL-2.0+ diff --git a/board/scalys/grapeboard/board_configuration_data.h b/board/scalys/grapeboard/board_configuration_data.h index f6e253c..f08eea8 100644 --- a/board/scalys/grapeboard/board_configuration_data.h +++ b/board/scalys/grapeboard/board_configuration_data.h @@ -1,3 +1,10 @@ +/* + * Copyright 2018 Scalys B.V. + * opensource@scalys.com + * + * SPDX-License-Identifier: GPL-2.0+ + */ + #ifndef _BCD_H #define _BCD_H diff --git a/board/scalys/grapeboard/eth.c b/board/scalys/grapeboard/eth.c index 16885cc..c854ed1 100644 --- a/board/scalys/grapeboard/eth.c +++ b/board/scalys/grapeboard/eth.c @@ -1,10 +1,7 @@ /* - * Copyright 2017 Scalys B.V. + * Copyright 2018 Scalys B.V. * opensource@scalys.com * - * Copyright 2015-2016 Freescale Semiconductor, Inc. - * Copyright 2017 NXP - * * SPDX-License-Identifier:GPL-2.0+ */ diff --git a/board/scalys/grapeboard/gpio_grapeboard.h b/board/scalys/grapeboard/gpio_grapeboard.h index ae79932..1792013 100644 --- a/board/scalys/grapeboard/gpio_grapeboard.h +++ b/board/scalys/grapeboard/gpio_grapeboard.h @@ -1,5 +1,5 @@ /* - * Copyright 2017 Scalys B.V. + * Copyright 2018 Scalys B.V. * opensource@scalys.com * * SPDX-License-Identifier: GPL-2.0+ diff --git a/board/scalys/grapeboard/grapeboard.c b/board/scalys/grapeboard/grapeboard.c index bd5e640..d86de30 100644 --- a/board/scalys/grapeboard/grapeboard.c +++ b/board/scalys/grapeboard/grapeboard.c @@ -1,9 +1,7 @@ /* - * Copyright 2017 Scalys B.V. + * Copyright 2018 Scalys B.V. * opensource@scalys.com * - * Copyright 2016 Freescale Semiconductor, Inc. - * * SPDX-License-Identifier: GPL-2.0+ */ diff --git a/board/scalys/grapeboard/ns_access.c b/board/scalys/grapeboard/ns_access.c deleted file mode 100644 index 0c3a54c..0000000 --- a/board/scalys/grapeboard/ns_access.c +++ /dev/null @@ -1,73 +0,0 @@ -/* - * Copyright 2014 Freescale Semiconductor - * - * SPDX-License-Identifier: GPL-2.0+ - */ - -#include -#include -#include -#include -#include - -void set_devices_ns_access(unsigned long index, u16 val) -{ - u32 *base = (u32 *)CONFIG_SYS_FSL_CSU_ADDR; - u32 *reg; - uint32_t tmp; - - reg = base + index / 2; - tmp = in_be32(reg); - if (index % 2 == 0) { - tmp &= 0x0000ffff; - tmp |= val << 16; - } else { - tmp &= 0xffff0000; - tmp |= val; - } - - out_be32(reg, tmp); -} - -static void enable_devices_ns_access(struct csu_ns_dev *ns_dev, uint32_t num) -{ - int i; - - for (i = 0; i < num; i++) - set_devices_ns_access(ns_dev[i].ind, ns_dev[i].val); -} - -void enable_layerscape_ns_access(void) -{ -#ifdef CONFIG_ARM64 - if (current_el() == 3) -#endif - enable_devices_ns_access(ns_dev, ARRAY_SIZE(ns_dev)); -} - -void set_pcie_ns_access(int pcie, u16 val) -{ - switch (pcie) { -#ifdef CONFIG_PCIE1 - case PCIE1: - set_devices_ns_access(CSU_CSLX_PCIE1, val); - set_devices_ns_access(CSU_CSLX_PCIE1_IO, val); - return; -#endif -#ifdef CONFIG_PCIE2 - case PCIE2: - set_devices_ns_access(CSU_CSLX_PCIE2, val); - set_devices_ns_access(CSU_CSLX_PCIE2_IO, val); - return; -#endif -#ifdef CONFIG_PCIE3 - case PCIE3: - set_devices_ns_access(CSU_CSLX_PCIE3, val); - set_devices_ns_access(CSU_CSLX_PCIE3_IO, val); - return; -#endif - default: - debug("The PCIE%d doesn't exist!\n", pcie); - return; - } -} diff --git a/board/scalys/grapeboard/usb_grapeboard.c b/board/scalys/grapeboard/usb_grapeboard.c index f8fbd59..648b5c7 100644 --- a/board/scalys/grapeboard/usb_grapeboard.c +++ b/board/scalys/grapeboard/usb_grapeboard.c @@ -1,5 +1,5 @@ /* - * Copyright 2017 Scalys B.V. + * Copyright 2018 Scalys B.V. * opensource@scalys.com * * SPDX-License-Identifier: GPL-2.0+ diff --git a/board/scalys/grapeboard/usb_grapeboard.h b/board/scalys/grapeboard/usb_grapeboard.h index 6bffe41..352550c 100644 --- a/board/scalys/grapeboard/usb_grapeboard.h +++ b/board/scalys/grapeboard/usb_grapeboard.h @@ -1,5 +1,5 @@ /* - * Copyright 2017 Scalys B.V. + * Copyright 2018 Scalys B.V. * opensource@scalys.com * * SPDX-License-Identifier: GPL-2.0+ diff --git a/include/configs/grapeboard.h b/include/configs/grapeboard.h index c1149f6..94a8abb 100644 --- a/include/configs/grapeboard.h +++ b/include/configs/grapeboard.h @@ -1,9 +1,7 @@ /* - * Copyright 2017 Scalys B.V. + * Copyright 2018 Scalys B.V. * opensource@scalys.com * - * Copyright 2016 Freescale Semiconductor, Inc. - * * SPDX-License-Identifier: GPL-2.0+ */ -- cgit v0.10.2