Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/arch Remove FDT support for AMD Seattle platform. This S...



details:   https://anonhg.NetBSD.org/src/rev/d9510fdcccff
branches:  trunk
changeset: 994126:d9510fdcccff
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Sun Oct 21 00:56:43 2018 +0000

description:
Remove FDT support for AMD Seattle platform. This SoC is supported in ACPI
mode.

diffstat:

 sys/arch/arm/amd/files.seattle       |    9 -
 sys/arch/arm/amd/seattle_platform.c  |  160 -----------------------------------
 sys/arch/evbarm/conf/files.generic64 |    3 +-
 3 files changed, 1 insertions(+), 171 deletions(-)

diffs (194 lines):

diff -r b91f00623b34 -r d9510fdcccff sys/arch/arm/amd/files.seattle
--- a/sys/arch/arm/amd/files.seattle    Sun Oct 21 00:51:12 2018 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,9 +0,0 @@
-#      $NetBSD: files.seattle,v 1.1 2018/09/08 00:49:06 jmcneill Exp $
-#
-# Configuration info for AMD ARM SoCs
-#
-#
-
-file   arch/arm/amd/seattle_platform.c         soc_seattle
-
-defflag        opt_soc.h                               SOC_SEATTLE
diff -r b91f00623b34 -r d9510fdcccff sys/arch/arm/amd/seattle_platform.c
--- a/sys/arch/arm/amd/seattle_platform.c       Sun Oct 21 00:51:12 2018 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,160 +0,0 @@
-/* $NetBSD: seattle_platform.c,v 1.4 2018/10/19 20:33:23 jakllsch Exp $ */
-
-/*-
- * Copyright (c) 2018 Jared McNeill <jmcneill%invisible.ca@localhost>
- * All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
- * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
- * AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
- * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- * SUCH DAMAGE.
- */
-
-#include "opt_soc.h"
-#include "opt_multiprocessor.h"
-#include "opt_console.h"
-
-#define _ARM32_BUS_DMA_PRIVATE
-
-#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: seattle_platform.c,v 1.4 2018/10/19 20:33:23 jakllsch Exp $");
-
-#include <sys/param.h>
-#include <sys/bus.h>
-#include <sys/cpu.h>
-#include <sys/device.h>
-#include <sys/termios.h>
-
-#include <dev/fdt/fdtvar.h>
-#include <arm/fdt/arm_fdtvar.h>
-
-#include <uvm/uvm_extern.h>
-
-#include <machine/bootconfig.h>
-#include <arm/cpufunc.h>
-
-#include <arm/cortex/gtmr_var.h>
-
-#include <evbarm/fdt/platform.h>
-
-#include <evbarm/dev/plcomreg.h>
-#include <evbarm/dev/plcomvar.h>
-
-#include <dev/ic/ns16550reg.h>
-#include <dev/ic/comreg.h>
-
-#include <arm/arm/psci.h>
-#include <arm/fdt/psci_fdtvar.h>
-
-#include <libfdt.h>
-
-#define        SEATTLE_CORE_VBASE      KERNEL_IO_VBASE
-#define        SEATTLE_CORE_PBASE      0xe0000000
-#define        SEATTLE_CORE_SIZE       0x02000000
-
-#define        SEATTLE_UART_FREQ       100000000
-
-extern struct arm32_bus_dma_tag arm_generic_dma_tag;
-extern struct bus_space arm_generic_bs_tag;
-extern struct bus_space arm_generic_a4x_bs_tag;
-
-static struct arm32_dma_range seattle_dma_ranges[] = {
-       [0] = {
-               .dr_sysbase = 0,
-               .dr_busbase = 0,
-               .dr_len = 0x10000000000,
-               .dr_flags = _BUS_DMAMAP_COHERENT,
-       }
-};
-
-static struct arm32_bus_dma_tag seattle_bus_dma_tag = {
-       ._ranges = seattle_dma_ranges,
-       ._nranges = __arraycount(seattle_dma_ranges),
-        _BUS_DMAMAP_FUNCS,
-       _BUS_DMAMEM_FUNCS,
-       _BUS_DMATAG_FUNCS,
-};
-
-static void
-seattle_platform_init_attach_args(struct fdt_attach_args *faa)
-{
-       faa->faa_bst = &arm_generic_bs_tag;
-       faa->faa_a4x_bst = &arm_generic_a4x_bs_tag;
-       faa->faa_dmat = &seattle_bus_dma_tag;
-}
-
-static void
-seattle_platform_device_register(device_t self, void *aux)
-{
-}
-
-static const struct pmap_devmap *
-seattle_platform_devmap(void)
-{
-       static const struct pmap_devmap devmap[] = {
-               DEVMAP_ENTRY(SEATTLE_CORE_VBASE,
-                            SEATTLE_CORE_PBASE,
-                            SEATTLE_CORE_SIZE),
-               DEVMAP_ENTRY_END
-       };
-
-       return devmap;
-}
-
-void seattle_platform_early_putchar(char);
-
-void
-seattle_platform_early_putchar(char c)
-{
-#ifdef CONSADDR
-#define CONSADDR_VA    ((CONSADDR - SEATTLE_CORE_PBASE) + SEATTLE_CORE_VBASE)
-       volatile uint32_t *uartaddr = cpu_earlydevice_va_p() ?
-           (volatile uint32_t *)CONSADDR_VA :
-           (volatile uint32_t *)CONSADDR;
-
-       while ((uartaddr[PL01XCOM_FR / 4] & PL01X_FR_TXFF) != 0)
-               continue;
-
-       uartaddr[PL01XCOM_DR / 4] = c;
-
-       while ((uartaddr[PL01XCOM_FR / 4] & PL01X_FR_TXFE) == 0)
-               continue;
-#undef CONSADDR_VA
-#endif
-}
-
-static u_int
-seattle_platform_uart_freq(void)
-{
-       return SEATTLE_UART_FREQ;
-}
-
-static const struct arm_platform seattle_platform = {
-       .ap_devmap = seattle_platform_devmap,
-       .ap_bootstrap = arm_fdt_cpu_bootstrap,
-       .ap_init_attach_args = seattle_platform_init_attach_args,
-       .ap_early_putchar = seattle_platform_early_putchar,
-       .ap_device_register = seattle_platform_device_register,
-       .ap_reset = psci_fdt_reset,
-       .ap_delay = gtmr_delay,
-       .ap_uart_freq = seattle_platform_uart_freq,
-       .ap_mpstart = arm_fdt_cpu_mpstart,
-};
-
-ARM_PLATFORM(seattle, "amd,seattle", &seattle_platform);
diff -r b91f00623b34 -r d9510fdcccff sys/arch/evbarm/conf/files.generic64
--- a/sys/arch/evbarm/conf/files.generic64      Sun Oct 21 00:51:12 2018 +0000
+++ b/sys/arch/evbarm/conf/files.generic64      Sun Oct 21 00:56:43 2018 +0000
@@ -1,4 +1,4 @@
-#      $NetBSD: files.generic64,v 1.8 2018/10/18 09:01:54 skrll Exp $
+#      $NetBSD: files.generic64,v 1.9 2018/10/21 00:56:44 jmcneill Exp $
 #
 # A generic (aarch64) kernel configuration info
 #
@@ -11,7 +11,6 @@
 # Add other board files here
 #
 include "arch/arm/acpi/files.acpi"
-include "arch/arm/amd/files.seattle"
 include "arch/arm/broadcom/files.bcm2835"
 include "arch/arm/cavium/files.thunderx"
 include "arch/arm/nvidia/files.tegra"



Home | Main Index | Thread Index | Old Index