Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/sdmmc Sync with POSTREAD before memcpy.
details: https://anonhg.NetBSD.org/src/rev/aae92c5d75c8
branches: trunk
changeset: 757738:aae92c5d75c8
user: kiyohara <kiyohara%NetBSD.org@localhost>
date: Mon Sep 20 09:19:31 2010 +0000
description:
Sync with POSTREAD before memcpy.
diffstat:
sys/dev/sdmmc/sdmmc_mem.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (44 lines):
diff -r bd4fff6861c2 -r aae92c5d75c8 sys/dev/sdmmc/sdmmc_mem.c
--- a/sys/dev/sdmmc/sdmmc_mem.c Mon Sep 20 09:06:03 2010 +0000
+++ b/sys/dev/sdmmc/sdmmc_mem.c Mon Sep 20 09:19:31 2010 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: sdmmc_mem.c,v 1.5 2010/05/01 21:14:39 reinoud Exp $ */
+/* $NetBSD: sdmmc_mem.c,v 1.6 2010/09/20 09:19:31 kiyohara Exp $ */
/* $OpenBSD: sdmmc_mem.c,v 1.10 2009/01/09 10:55:22 jsg Exp $ */
/*
@@ -46,7 +46,7 @@
/* Routines for SD/MMC memory cards. */
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sdmmc_mem.c,v 1.5 2010/05/01 21:14:39 reinoud Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sdmmc_mem.c,v 1.6 2010/09/20 09:19:31 kiyohara Exp $");
#include <sys/param.h>
#include <sys/kernel.h>
@@ -686,11 +686,11 @@
error = sdmmc_app_command(sc, sf, &cmd);
if (error == 0) {
- memcpy(scr, ptr, datalen);
if (ISSET(sc->sc_caps, SMC_CAPS_DMA)) {
bus_dmamap_sync(sc->sc_dmat, sc->sc_dmap, 0, datalen,
BUS_DMASYNC_POSTREAD);
}
+ memcpy(scr, ptr, datalen);
}
out:
@@ -788,11 +788,11 @@
error = sdmmc_mmc_command(sc, &cmd);
if (error == 0) {
- memcpy(data, ptr, datalen);
if (ISSET(sc->sc_caps, SMC_CAPS_DMA)) {
bus_dmamap_sync(sc->sc_dmat, sc->sc_dmap, 0, datalen,
BUS_DMASYNC_POSTREAD);
}
+ memcpy(data, ptr, datalen);
}
out:
Home |
Main Index |
Thread Index |
Old Index