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 style



details:   https://anonhg.NetBSD.org/src/rev/5b50bf23f3e7
branches:  trunk
changeset: 319268:5b50bf23f3e7
user:      ryo <ryo%NetBSD.org@localhost>
date:      Wed May 23 08:20:12 2018 +0000

description:
style

diffstat:

 sys/arch/aarch64/aarch64/aarch64_machdep.c |  9 +++++----
 1 files changed, 5 insertions(+), 4 deletions(-)

diffs (33 lines):

diff -r 94cf46ca68d7 -r 5b50bf23f3e7 sys/arch/aarch64/aarch64/aarch64_machdep.c
--- a/sys/arch/aarch64/aarch64/aarch64_machdep.c        Wed May 23 07:45:35 2018 +0000
+++ b/sys/arch/aarch64/aarch64/aarch64_machdep.c        Wed May 23 08:20:12 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: aarch64_machdep.c,v 1.3 2018/05/03 15:47:22 ryo Exp $ */
+/* $NetBSD: aarch64_machdep.c,v 1.4 2018/05/23 08:20:12 ryo Exp $ */
 
 /*-
  * Copyright (c) 2014 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(1, "$NetBSD: aarch64_machdep.c,v 1.3 2018/05/03 15:47:22 ryo Exp $");
+__KERNEL_RCSID(1, "$NetBSD: aarch64_machdep.c,v 1.4 2018/05/23 08:20:12 ryo Exp $");
 
 #include "opt_arm_debug.h"
 #include "opt_ddb.h"
@@ -268,11 +268,12 @@
 aarch64_sysctl_machdep_sysreg_helper(SYSCTLFN_ARGS)
 {
        struct sysctlnode node;
-       uint64_t databuf[8];
+#define MAX_SYSCTLREGS 8
+       uint64_t databuf[MAX_SYSCTLREGS];
        void *data;
 
        node = *rnode;
-       node.sysctl_data = data = &databuf;
+       node.sysctl_data = data = (void *)databuf;
 
        /*
         * Don't keep values in advance due to system registers may have



Home | Main Index | Thread Index | Old Index