Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/acpi Add NXP/Freescale ESDHC specific support
details: https://anonhg.NetBSD.org/src/rev/53f837c8cca3
branches: trunk
changeset: 968933:53f837c8cca3
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Sat Feb 01 13:40:55 2020 +0000
description:
Add NXP/Freescale ESDHC specific support
diffstat:
sys/dev/acpi/sdhc_acpi.c | 14 ++++++++++++--
1 files changed, 12 insertions(+), 2 deletions(-)
diffs (56 lines):
diff -r e86150499e45 -r 53f837c8cca3 sys/dev/acpi/sdhc_acpi.c
--- a/sys/dev/acpi/sdhc_acpi.c Sat Feb 01 13:35:11 2020 +0000
+++ b/sys/dev/acpi/sdhc_acpi.c Sat Feb 01 13:40:55 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sdhc_acpi.c,v 1.10 2020/02/01 13:09:08 jmcneill Exp $ */
+/* $NetBSD: sdhc_acpi.c,v 1.11 2020/02/01 13:40:55 jmcneill Exp $ */
/*
* Copyright (c) 2016 Kimihiro Nonaka <nonaka%NetBSD.org@localhost>
@@ -26,7 +26,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sdhc_acpi.c,v 1.10 2020/02/01 13:09:08 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sdhc_acpi.c,v 1.11 2020/02/01 13:40:55 jmcneill Exp $");
#include <sys/param.h>
#include <sys/device.h>
@@ -41,6 +41,10 @@
#include <dev/sdmmc/sdhcvar.h>
#include <dev/sdmmc/sdmmcvar.h>
+/* Freescale ESDHC */
+#define SDHC_ESDHC_FLAGS \
+ (SDHC_FLAG_HAVE_DVS|SDHC_FLAG_NO_PWR0|SDHC_FLAG_32BIT_ACCESS|SDHC_FLAG_ENHANCED)
+
#define _COMPONENT ACPI_RESOURCE_COMPONENT
ACPI_MODULE_NAME ("sdhc_acpi")
@@ -72,6 +76,7 @@
int type;
#define SLOT_TYPE_SD 0 /* SD or SDIO */
#define SLOT_TYPE_EMMC 1 /* eMMC */
+ uint32_t flags;
} sdhc_acpi_slot_map[] = {
{ "80865ACA", NULL, SLOT_TYPE_SD },
{ "80865ACC", NULL, SLOT_TYPE_EMMC },
@@ -84,6 +89,9 @@
{ "INT33C6", NULL, SLOT_TYPE_SD },
{ "INT3436", NULL, SLOT_TYPE_SD },
{ "INT344D", NULL, SLOT_TYPE_SD },
+ { "NXP0003", "0", SLOT_TYPE_SD, SDHC_ESDHC_FLAGS },
+ { "NXP0003", "1", SLOT_TYPE_EMMC, SDHC_ESDHC_FLAGS },
+ /* Generic IDs last */
{ "PNP0D40", NULL, SLOT_TYPE_SD },
{ "PNP0FFF", "3", SLOT_TYPE_SD },
};
@@ -192,6 +200,8 @@
sc->sc.sc_host = kmem_zalloc(sizeof(struct sdhc_host *), KM_SLEEP);
+ sc->sc.sc_flags |= slot->flags;
+
/* Enable DMA transfer */
sc->sc.sc_flags |= SDHC_FLAG_USE_DMA;
Home |
Main Index |
Thread Index |
Old Index