Module Name: src Committed By: jmcneill Date: Sat Jun 22 19:47:28 UTC 2019
Modified Files: src/sys/arch/arm/acpi: acpi_platform.c src/sys/arch/arm/fdt: acpi_fdt.c Log Message: Finish the job To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/sys/arch/arm/acpi/acpi_platform.c cvs rdiff -u -r1.11 -r1.12 src/sys/arch/arm/fdt/acpi_fdt.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/arch/arm/acpi/acpi_platform.c diff -u src/sys/arch/arm/acpi/acpi_platform.c:1.13 src/sys/arch/arm/acpi/acpi_platform.c:1.14 --- src/sys/arch/arm/acpi/acpi_platform.c:1.13 Wed Jun 19 13:39:18 2019 +++ src/sys/arch/arm/acpi/acpi_platform.c Sat Jun 22 19:47:27 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_platform.c,v 1.13 2019/06/19 13:39:18 jmcneill Exp $ */ +/* $NetBSD: acpi_platform.c,v 1.14 2019/06/22 19:47:27 jmcneill Exp $ */ /*- * Copyright (c) 2018 The NetBSD Foundation, Inc. @@ -35,7 +35,7 @@ #include "opt_multiprocessor.h" #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: acpi_platform.c,v 1.13 2019/06/19 13:39:18 jmcneill Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_platform.c,v 1.14 2019/06/22 19:47:27 jmcneill Exp $"); #include <sys/param.h> #include <sys/bus.h> @@ -94,18 +94,8 @@ extern struct bus_space arm_generic_a4x_ static struct plcom_instance plcom_console; #endif -struct arm32_bus_dma_tag acpi_coherent32_dma_tag; -static struct arm32_dma_range acpi_coherent32_ranges[] = { - [0] = { - .dr_sysbase = 0, - .dr_busbase = 0, - .dr_len = 0xffffffffU, - .dr_flags = _BUS_DMAMAP_COHERENT, - } -}; - -struct arm32_bus_dma_tag acpi_coherent64_dma_tag; -static struct arm32_dma_range acpi_coherent64_ranges[] = { +struct arm32_bus_dma_tag acpi_coherent_dma_tag; +static struct arm32_dma_range acpi_coherent_ranges[] = { [0] = { .dr_sysbase = 0, .dr_busbase = 0, @@ -129,13 +119,9 @@ acpi_platform_bootstrap(void) { extern struct arm32_bus_dma_tag arm_generic_dma_tag; - acpi_coherent32_dma_tag = arm_generic_dma_tag; - acpi_coherent32_dma_tag._ranges = acpi_coherent32_ranges; - acpi_coherent32_dma_tag._nranges = __arraycount(acpi_coherent32_ranges); - - acpi_coherent64_dma_tag = arm_generic_dma_tag; - acpi_coherent64_dma_tag._ranges = acpi_coherent64_ranges; - acpi_coherent64_dma_tag._nranges = __arraycount(acpi_coherent64_ranges); + acpi_coherent_dma_tag = arm_generic_dma_tag; + acpi_coherent_dma_tag._ranges = acpi_coherent_ranges; + acpi_coherent_dma_tag._nranges = __arraycount(acpi_coherent_ranges); } static void @@ -256,7 +242,7 @@ acpi_platform_init_attach_args(struct fd faa->faa_bst = &arm_generic_bs_tag; faa->faa_a4x_bst = &arm_generic_a4x_bs_tag; - faa->faa_dmat = &acpi_coherent64_dma_tag; + faa->faa_dmat = &acpi_coherent_dma_tag; } static void Index: src/sys/arch/arm/fdt/acpi_fdt.c diff -u src/sys/arch/arm/fdt/acpi_fdt.c:1.11 src/sys/arch/arm/fdt/acpi_fdt.c:1.12 --- src/sys/arch/arm/fdt/acpi_fdt.c:1.11 Sat Jun 22 17:57:10 2019 +++ src/sys/arch/arm/fdt/acpi_fdt.c Sat Jun 22 19:47:27 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: acpi_fdt.c,v 1.11 2019/06/22 17:57:10 jakllsch Exp $ */ +/* $NetBSD: acpi_fdt.c,v 1.12 2019/06/22 19:47:27 jmcneill Exp $ */ /*- * Copyright (c) 2015-2017 Jared McNeill <jmcne...@invisible.ca> @@ -30,7 +30,7 @@ #include "opt_efi.h" #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: acpi_fdt.c,v 1.11 2019/06/22 17:57:10 jakllsch Exp $"); +__KERNEL_RCSID(0, "$NetBSD: acpi_fdt.c,v 1.12 2019/06/22 19:47:27 jmcneill Exp $"); #include <sys/param.h> #include <sys/bus.h> @@ -70,7 +70,7 @@ static int acpi_fdt_efi_rtc_settime(todr static void acpi_fdt_sysctl_init(void); -extern struct arm32_bus_dma_tag acpi_coherent64_dma_tag; +extern struct arm32_bus_dma_tag acpi_coherent_dma_tag; #if NPCI > 0 static struct acpi_pci_context acpi_fdt_pci_context; @@ -136,9 +136,9 @@ acpi_fdt_attach(device_t parent, device_ #endif aa.aa_memt = faa->faa_bst; - aa.aa_dmat = &acpi_coherent64_dma_tag; + aa.aa_dmat = &acpi_coherent_dma_tag; #ifdef _PCI_HAVE_DMA64 - aa.aa_dmat64 = &acpi_coherent64_dma_tag; + aa.aa_dmat64 = &acpi_coherent_dma_tag; #endif config_found_ia(self, "acpibus", &aa, 0);