Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/aarch64/aarch64 Fix mis-incrementing pointer size i...



details:   https://anonhg.NetBSD.org/src/rev/49dd9e4f83b0
branches:  trunk
changeset: 467109:49dd9e4f83b0
user:      ryo <ryo%NetBSD.org@localhost>
date:      Mon Jan 13 17:23:07 2020 +0000

description:
Fix mis-incrementing pointer size in bus_space_read_region_{4,8}

pointed out by jmcneill@. thanks.

diffstat:

 sys/arch/aarch64/aarch64/bus_space_asm_generic.S |  12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diffs (54 lines):

diff -r 016bff6681e8 -r 49dd9e4f83b0 sys/arch/aarch64/aarch64/bus_space_asm_generic.S
--- a/sys/arch/aarch64/aarch64/bus_space_asm_generic.S  Mon Jan 13 16:11:53 2020 +0000
+++ b/sys/arch/aarch64/aarch64/bus_space_asm_generic.S  Mon Jan 13 17:23:07 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: bus_space_asm_generic.S,v 1.1 2018/04/01 04:35:03 ryo Exp $    */
+/*     $NetBSD: bus_space_asm_generic.S,v 1.2 2020/01/13 17:23:07 ryo Exp $    */
 
 /*
  * Copyright (c) 2017 Ryo Shimizu <ryo%nerv.org@localhost>
@@ -29,7 +29,7 @@
 #include <aarch64/asm.h>
 #include "assym.h"
 
-RCSID("$NetBSD: bus_space_asm_generic.S,v 1.1 2018/04/01 04:35:03 ryo Exp $")
+RCSID("$NetBSD: bus_space_asm_generic.S,v 1.2 2020/01/13 17:23:07 ryo Exp $")
 
 .macro generate_bsfunc funcname, dsbop
 /* uint8_t {funcname}_bs_r_1(x0:tag, x1:addr, x2:offset) */
@@ -334,7 +334,7 @@
        ldr     w8, [x1, x2]    /* value = *src */
        subs    x4, x4, #1      /* count-- */
        add     x2, x2, x9      /* src += delta */
-       str     w8, [x3], #2    /* *dst++ = value */
+       str     w8, [x3], #4    /* *dst++ = value */
        b.ne    1b
        ret
 #ifdef DIAGNOSTIC
@@ -363,7 +363,7 @@
        ldr     x8, [x1, x2]    /* value = *src */
        subs    x4, x4, #1      /* count-- */
        add     x2, x2, x9      /* src += delta */
-       str     x8, [x3], #2    /* *dst++ = value */
+       str     x8, [x3], #8    /* *dst++ = value */
        b.ne    1b
        ret
 #ifdef DIAGNOSTIC
@@ -423,7 +423,7 @@
        subs    x4, x4, #1      /* count-- */
        add     x2, x2, x9      /* src += delta */
        rev     w8, w8
-       str     w8, [x3], #2    /* *dst++ = value */
+       str     w8, [x3], #4    /* *dst++ = value */
        b.ne    1b
        ret
 #ifdef DIAGNOSTIC
@@ -453,7 +453,7 @@
        subs    x4, x4, #1      /* count-- */
        add     x2, x2, x9      /* src += delta */
        rev     x8, x8
-       str     x8, [x3], #2    /* *dst++ = value */
+       str     x8, [x3], #8    /* *dst++ = value */
        b.ne    1b
        ret
 #ifdef DIAGNOSTIC



Home | Main Index | Thread Index | Old Index