Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/arm/amlogic hook up card detect gpio
details: https://anonhg.NetBSD.org/src/rev/6b50912b38ff
branches: trunk
changeset: 339759:6b50912b38ff
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Sat Aug 08 14:48:41 2015 +0000
description:
hook up card detect gpio
diffstat:
sys/arch/arm/amlogic/amlogic_sdhc.c | 8 +++++---
sys/arch/arm/amlogic/amlogic_sdio.c | 8 +++++---
2 files changed, 10 insertions(+), 6 deletions(-)
diffs (58 lines):
diff -r 78d90deabbb1 -r 6b50912b38ff sys/arch/arm/amlogic/amlogic_sdhc.c
--- a/sys/arch/arm/amlogic/amlogic_sdhc.c Sat Aug 08 14:35:06 2015 +0000
+++ b/sys/arch/arm/amlogic/amlogic_sdhc.c Sat Aug 08 14:48:41 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: amlogic_sdhc.c,v 1.9 2015/08/08 14:01:44 jmcneill Exp $ */
+/* $NetBSD: amlogic_sdhc.c,v 1.10 2015/08/08 14:48:41 jmcneill Exp $ */
/*-
* Copyright (c) 2015 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -29,7 +29,7 @@
#include "locators.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: amlogic_sdhc.c,v 1.9 2015/08/08 14:01:44 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: amlogic_sdhc.c,v 1.10 2015/08/08 14:48:41 jmcneill Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -443,7 +443,9 @@
static int
amlogic_sdhc_card_detect(sdmmc_chipset_handle_t sch)
{
- return 1;
+ struct amlogic_sdhc_softc *sc = sch;
+
+ return amlogic_sdhc_is_card_present(sc->sc_port);
}
static int
diff -r 78d90deabbb1 -r 6b50912b38ff sys/arch/arm/amlogic/amlogic_sdio.c
--- a/sys/arch/arm/amlogic/amlogic_sdio.c Sat Aug 08 14:35:06 2015 +0000
+++ b/sys/arch/arm/amlogic/amlogic_sdio.c Sat Aug 08 14:48:41 2015 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: amlogic_sdio.c,v 1.4 2015/08/08 14:01:44 jmcneill Exp $ */
+/* $NetBSD: amlogic_sdio.c,v 1.5 2015/08/08 14:48:41 jmcneill Exp $ */
/*-
* Copyright (c) 2015 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -29,7 +29,7 @@
#include "locators.h"
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: amlogic_sdio.c,v 1.4 2015/08/08 14:01:44 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: amlogic_sdio.c,v 1.5 2015/08/08 14:48:41 jmcneill Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -331,7 +331,9 @@
static int
amlogic_sdio_card_detect(sdmmc_chipset_handle_t sch)
{
- return 1;
+ struct amlogic_sdio_softc *sc = sch;
+
+ return amlogic_sdhc_is_card_present(sc->sc_cur_port);
}
static int
Home |
Main Index |
Thread Index |
Old Index