Source-Changes-HG archive

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

[src/trunk]: src/common/lib/libc/atomic PR 55239: initialize all RAS sections...



details:   https://anonhg.NetBSD.org/src/rev/72d993edac17
branches:  trunk
changeset: 972090:72d993edac17
user:      martin <martin%NetBSD.org@localhost>
date:      Fri May 15 15:20:40 2020 +0000

description:
PR 55239: initialize all RAS sections for non-MP configurations

diffstat:

 common/lib/libc/atomic/atomic_init_testset.c |  10 ++++------
 1 files changed, 4 insertions(+), 6 deletions(-)

diffs (51 lines):

diff -r ed5e22e45b24 -r 72d993edac17 common/lib/libc/atomic/atomic_init_testset.c
--- a/common/lib/libc/atomic/atomic_init_testset.c      Fri May 15 14:57:33 2020 +0000
+++ b/common/lib/libc/atomic/atomic_init_testset.c      Fri May 15 15:20:40 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: atomic_init_testset.c,v 1.16 2019/02/18 11:22:56 martin Exp $  */
+/*     $NetBSD: atomic_init_testset.c,v 1.17 2020/05/15 15:20:40 martin Exp $  */
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -36,7 +36,7 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: atomic_init_testset.c,v 1.16 2019/02/18 11:22:56 martin Exp $");
+__RCSID("$NetBSD: atomic_init_testset.c,v 1.17 2020/05/15 15:20:40 martin Exp $");
 
 #include "atomic_op_namespace.h"
 
@@ -296,30 +296,28 @@
                return;
        if (ncpu > 1)
                return;
+
        if (rasctl(RAS_ADDR(_atomic_cas), RAS_SIZE(_atomic_cas),
            RAS_INSTALL) == 0) {
                _atomic_cas_fn = _atomic_cas_up;
-               return;
        }
 
+
 #ifdef __HAVE_ATOMIC_CAS_64_UP
        if (rasctl(RAS_ADDR(_atomic_cas_64), RAS_SIZE(_atomic_cas_64),
            RAS_INSTALL) == 0) {
                _atomic_cas_64_fn = _atomic_cas_64_up;
-               return;
        }
 #endif
 
        if (rasctl(RAS_ADDR(_atomic_cas_16), RAS_SIZE(_atomic_cas_16),
            RAS_INSTALL) == 0) {
                _atomic_cas_16_fn = _atomic_cas_16_up;
-               return;
        }
 
        if (rasctl(RAS_ADDR(_atomic_cas_8), RAS_SIZE(_atomic_cas_8),
            RAS_INSTALL) == 0) {
                _atomic_cas_8_fn = _atomic_cas_8_up;
-               return;
        }
 }
 



Home | Main Index | Thread Index | Old Index