Source-Changes-HG archive

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

[src/trunk]: src/sys/dev/sdmmc Define SD_ARG_CMD52_WRITE macro correctly. Fou...



details:   https://anonhg.NetBSD.org/src/rev/a408df218fa0
branches:  trunk
changeset: 962511:a408df218fa0
user:      msaitoh <msaitoh%NetBSD.org@localhost>
date:      Wed Jul 24 05:45:42 2019 +0000

description:
Define SD_ARG_CMD52_WRITE macro correctly. Found by KUBSan. This macro is
used in sdmmc_io_write_1() and sdmmc_io_reset.

diffstat:

 sys/dev/sdmmc/sdmmc_ioreg.h |  4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diffs (18 lines):

diff -r 80a8efd0b979 -r a408df218fa0 sys/dev/sdmmc/sdmmc_ioreg.h
--- a/sys/dev/sdmmc/sdmmc_ioreg.h       Wed Jul 24 05:25:32 2019 +0000
+++ b/sys/dev/sdmmc/sdmmc_ioreg.h       Wed Jul 24 05:45:42 2019 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: sdmmc_ioreg.h,v 1.2 2010/10/07 12:40:34 kiyohara Exp $ */
+/*     $NetBSD: sdmmc_ioreg.h,v 1.3 2019/07/24 05:45:42 msaitoh Exp $  */
 /*     $OpenBSD: sdmmc_ioreg.h,v 1.4 2007/06/02 01:48:37 uwe Exp $     */
 
 /*
@@ -27,7 +27,7 @@
 
 /* CMD52 arguments */
 #define SD_ARG_CMD52_READ              (0<<31)
-#define SD_ARG_CMD52_WRITE             (1<<31)
+#define SD_ARG_CMD52_WRITE             (1UL<<31)
 #define SD_ARG_CMD52_FUNC_SHIFT                28
 #define SD_ARG_CMD52_FUNC_MASK         0x7
 #define SD_ARG_CMD52_EXCHANGE          (1<<27)



Home | Main Index | Thread Index | Old Index