Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch constify
details: https://anonhg.NetBSD.org/src/rev/b5359ab7af1f
branches: trunk
changeset: 1006920:b5359ab7af1f
user: maxv <maxv%NetBSD.org@localhost>
date: Fri Jan 31 08:21:11 2020 +0000
description:
constify
diffstat:
sys/arch/amd64/amd64/machdep.c | 6 +++---
sys/arch/i386/i386/machdep.c | 6 +++---
sys/arch/i386/i386/mtrr_k6.c | 6 +++---
sys/arch/x86/include/mtrr.h | 8 ++++----
sys/arch/x86/x86/mtrr_i686.c | 6 +++---
5 files changed, 16 insertions(+), 16 deletions(-)
diffs (130 lines):
diff -r f74ee1235470 -r b5359ab7af1f sys/arch/amd64/amd64/machdep.c
--- a/sys/arch/amd64/amd64/machdep.c Fri Jan 31 06:54:19 2020 +0000
+++ b/sys/arch/amd64/amd64/machdep.c Fri Jan 31 08:21:11 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: machdep.c,v 1.345 2020/01/09 00:42:24 manu Exp $ */
+/* $NetBSD: machdep.c,v 1.346 2020/01/31 08:21:11 maxv Exp $ */
/*
* Copyright (c) 1996, 1997, 1998, 2000, 2006, 2007, 2008, 2011
@@ -110,7 +110,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.345 2020/01/09 00:42:24 manu Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.346 2020/01/31 08:21:11 maxv Exp $");
#include "opt_modular.h"
#include "opt_user_ldt.h"
@@ -232,7 +232,7 @@
int cpu_class = CPUCLASS_686;
#ifdef MTRR
-struct mtrr_funcs *mtrr_funcs;
+const struct mtrr_funcs *mtrr_funcs;
#endif
int cpu_class;
diff -r f74ee1235470 -r b5359ab7af1f sys/arch/i386/i386/machdep.c
--- a/sys/arch/i386/i386/machdep.c Fri Jan 31 06:54:19 2020 +0000
+++ b/sys/arch/i386/i386/machdep.c Fri Jan 31 08:21:11 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: machdep.c,v 1.824 2019/12/10 18:04:54 ad Exp $ */
+/* $NetBSD: machdep.c,v 1.825 2020/01/31 08:21:11 maxv Exp $ */
/*
* Copyright (c) 1996, 1997, 1998, 2000, 2004, 2006, 2008, 2009, 2017
@@ -67,7 +67,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.824 2019/12/10 18:04:54 ad Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.825 2020/01/31 08:21:11 maxv Exp $");
#include "opt_beep.h"
#include "opt_compat_freebsd.h"
@@ -203,7 +203,7 @@
#endif
#ifdef MTRR
-struct mtrr_funcs *mtrr_funcs;
+const struct mtrr_funcs *mtrr_funcs;
#endif
int cpu_class;
diff -r f74ee1235470 -r b5359ab7af1f sys/arch/i386/i386/mtrr_k6.c
--- a/sys/arch/i386/i386/mtrr_k6.c Fri Jan 31 06:54:19 2020 +0000
+++ b/sys/arch/i386/i386/mtrr_k6.c Fri Jan 31 08:21:11 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mtrr_k6.c,v 1.14 2019/11/10 21:16:28 chs Exp $ */
+/* $NetBSD: mtrr_k6.c,v 1.15 2020/01/31 08:21:11 maxv Exp $ */
/*
* Copyright 2001 Wasabi Systems, Inc.
@@ -40,7 +40,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: mtrr_k6.c,v 1.14 2019/11/10 21:16:28 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: mtrr_k6.c,v 1.15 2020/01/31 08:21:11 maxv Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -71,7 +71,7 @@
static struct mtrr *mtrr_var;
-struct mtrr_funcs k6_mtrr_funcs = {
+const struct mtrr_funcs k6_mtrr_funcs = {
k6_mtrr_init_cpu,
k6_mtrr_reload_cpu,
k6_mtrr_clean,
diff -r f74ee1235470 -r b5359ab7af1f sys/arch/x86/include/mtrr.h
--- a/sys/arch/x86/include/mtrr.h Fri Jan 31 06:54:19 2020 +0000
+++ b/sys/arch/x86/include/mtrr.h Fri Jan 31 08:21:11 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mtrr.h,v 1.5 2011/12/15 09:38:21 abs Exp $ */
+/* $NetBSD: mtrr.h,v 1.6 2020/01/31 08:21:11 maxv Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@@ -124,9 +124,9 @@
void (*dump)(const char *tag);
};
-extern struct mtrr_funcs i686_mtrr_funcs;
-extern struct mtrr_funcs k6_mtrr_funcs;
-extern struct mtrr_funcs *mtrr_funcs;
+extern const struct mtrr_funcs i686_mtrr_funcs;
+extern const struct mtrr_funcs k6_mtrr_funcs;
+extern const struct mtrr_funcs *mtrr_funcs;
#define mtrr_init_cpu(ci) mtrr_funcs->init_cpu(ci)
#define mtrr_reload_cpu(ci) mtrr_funcs->reload_cpu(ci)
diff -r f74ee1235470 -r b5359ab7af1f sys/arch/x86/x86/mtrr_i686.c
--- a/sys/arch/x86/x86/mtrr_i686.c Fri Jan 31 06:54:19 2020 +0000
+++ b/sys/arch/x86/x86/mtrr_i686.c Fri Jan 31 08:21:11 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: mtrr_i686.c,v 1.30 2018/03/04 10:02:10 jdolecek Exp $ */
+/* $NetBSD: mtrr_i686.c,v 1.31 2020/01/31 08:21:11 maxv Exp $ */
/*-
* Copyright (c) 2000, 2011 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: mtrr_i686.c,v 1.30 2018/03/04 10:02:10 jdolecek Exp $");
+__KERNEL_RCSID(0, "$NetBSD: mtrr_i686.c,v 1.31 2020/01/31 08:21:11 maxv Exp $");
#include "opt_multiprocessor.h"
@@ -124,7 +124,7 @@
static struct mtrr *mtrr_fixed;
static struct mtrr *mtrr_var;
-struct mtrr_funcs i686_mtrr_funcs = {
+const struct mtrr_funcs i686_mtrr_funcs = {
i686_mtrr_init_cpu,
i686_mtrr_reload_cpu,
i686_mtrr_clean,
Home |
Main Index |
Thread Index |
Old Index