From 5674f55d0084f426473ea617fa2d36537a74f730 Mon Sep 17 00:00:00 2001 From: tedu Date: Tue, 16 Aug 2016 18:19:15 +0000 Subject: [PATCH] move static variable up to first --- sys/arch/i386/i386/mem.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/arch/i386/i386/mem.c b/sys/arch/i386/i386/mem.c index d8c4a565361..5282cca2683 100644 --- a/sys/arch/i386/i386/mem.c +++ b/sys/arch/i386/i386/mem.c @@ -1,5 +1,5 @@ /* $NetBSD: mem.c,v 1.31 1996/05/03 19:42:19 christos Exp $ */ -/* $OpenBSD: mem.c,v 1.49 2016/08/15 22:01:59 tedu Exp $ */ +/* $OpenBSD: mem.c,v 1.50 2016/08/16 18:19:15 tedu Exp $ */ /* * Copyright (c) 1988 University of Utah. * Copyright (c) 1982, 1986, 1990, 1993 @@ -115,11 +115,11 @@ mmclose(dev_t dev, int flag, int mode, struct proc *p) int mmrw(dev_t dev, struct uio *uio, int flags) { + static struct rwlock physlock = RWLOCK_INITIALIZER("mmrw"); vaddr_t o, v; size_t c; struct iovec *iov; int error = 0; - static struct rwlock physlock = RWLOCK_INITIALIZER("mmrw"); if (minor(dev) == 0) { /* lock against other uses of shared vmmap */ -- 2.20.1