Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/sparc64/dev reduce the scope of 'ci' variable.



details:   https://anonhg.NetBSD.org/src/rev/f08887e4ee07
branches:  trunk
changeset: 949794:f08887e4ee07
user:      mrg <mrg%NetBSD.org@localhost>
date:      Sun Jan 17 00:18:28 2021 +0000

description:
reduce the scope of 'ci' variable.

diffstat:

 sys/arch/sparc64/dev/psycho.c |  6 +++---
 sys/arch/sparc64/dev/pyro.c   |  6 +++---
 sys/arch/sparc64/dev/schizo.c |  6 +++---
 3 files changed, 9 insertions(+), 9 deletions(-)

diffs (100 lines):

diff -r 8b6c1d781f00 -r f08887e4ee07 sys/arch/sparc64/dev/psycho.c
--- a/sys/arch/sparc64/dev/psycho.c     Sun Jan 17 00:17:40 2021 +0000
+++ b/sys/arch/sparc64/dev/psycho.c     Sun Jan 17 00:18:28 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: psycho.c,v 1.131 2021/01/07 07:40:39 nakayama Exp $    */
+/*     $NetBSD: psycho.c,v 1.132 2021/01/17 00:18:28 mrg Exp $ */
 
 /*
  * Copyright (c) 1999, 2000 Matthew R. Green
@@ -55,7 +55,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: psycho.c,v 1.131 2021/01/07 07:40:39 nakayama Exp $");
+__KERNEL_RCSID(0, "$NetBSD: psycho.c,v 1.132 2021/01/17 00:18:28 mrg Exp $");
 
 #include "opt_ddb.h"
 
@@ -1382,7 +1382,6 @@
 {
        struct psycho_pbm *pp = pc->cookie;
        struct psycho_softc *sc = pp->pp_sc;
-       struct cpu_info *ci = curcpu();
        pcireg_t val = (pcireg_t)~0;
        int s;
 
@@ -1397,6 +1396,7 @@
                        (int)PCITAG_OFFSET(tag) + reg));
 
                s = splhigh();
+               struct cpu_info *ci = curcpu();
                ci->ci_pci_probe = true;
                membar_Sync();
                val = bus_space_read_4(sc->sc_configtag, sc->sc_configaddr,
diff -r 8b6c1d781f00 -r f08887e4ee07 sys/arch/sparc64/dev/pyro.c
--- a/sys/arch/sparc64/dev/pyro.c       Sun Jan 17 00:17:40 2021 +0000
+++ b/sys/arch/sparc64/dev/pyro.c       Sun Jan 17 00:18:28 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pyro.c,v 1.21 2021/01/04 14:48:51 thorpej Exp $        */
+/*     $NetBSD: pyro.c,v 1.22 2021/01/17 00:18:28 mrg Exp $    */
 /*     from: $OpenBSD: pyro.c,v 1.20 2010/12/05 15:15:14 kettenis Exp $        */
 
 /*
@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pyro.c,v 1.21 2021/01/04 14:48:51 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pyro.c,v 1.22 2021/01/17 00:18:28 mrg Exp $");
 
 #include <sys/param.h>
 #include <sys/device.h>
@@ -283,13 +283,13 @@
 pyro_conf_read(pci_chipset_tag_t pc, pcitag_t tag, int reg)
 {
        struct pyro_pbm *pp = pc->cookie;
-       struct cpu_info *ci = curcpu();
        pcireg_t val = (pcireg_t)~0;
        int s;
 
        DPRINTF(PDB_CONF, ("%s: tag %lx reg %x ", __func__, (long)tag, reg));
        if (PCITAG_NODE(tag) != -1 && (unsigned int)reg < PCI_CONF_SIZE) {
                s = splhigh();
+               struct cpu_info *ci = curcpu();
                ci->ci_pci_probe = true;
                membar_Sync();
                val = bus_space_read_4(pp->pp_cfgt, pp->pp_cfgh,
diff -r 8b6c1d781f00 -r f08887e4ee07 sys/arch/sparc64/dev/schizo.c
--- a/sys/arch/sparc64/dev/schizo.c     Sun Jan 17 00:17:40 2021 +0000
+++ b/sys/arch/sparc64/dev/schizo.c     Sun Jan 17 00:18:28 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: schizo.c,v 1.42 2019/10/01 18:00:07 chs Exp $  */
+/*     $NetBSD: schizo.c,v 1.43 2021/01/17 00:18:28 mrg Exp $  */
 /*     $OpenBSD: schizo.c,v 1.55 2008/08/18 20:29:37 brad Exp $        */
 
 /*
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: schizo.c,v 1.42 2019/10/01 18:00:07 chs Exp $");
+__KERNEL_RCSID(0, "$NetBSD: schizo.c,v 1.43 2021/01/17 00:18:28 mrg Exp $");
 
 #include <sys/param.h>
 #include <sys/device.h>
@@ -526,13 +526,13 @@
 schizo_conf_read(pci_chipset_tag_t pc, pcitag_t tag, int reg)
 {
        struct schizo_pbm *sp = pc->cookie;
-       struct cpu_info *ci = curcpu();
        pcireg_t val = (pcireg_t)~0;
        int s;
 
        DPRINTF(SDB_CONF, ("%s: tag %lx reg %x ", __func__, (long)tag, reg));
        if (PCITAG_NODE(tag) != -1 && (unsigned int)reg < PCI_CONF_SIZE) {
                s = splhigh();
+               struct cpu_info *ci = curcpu();
                ci->ci_pci_probe = true;
                membar_Sync();
                val = bus_space_read_4(sp->sp_cfgt, sp->sp_cfgh,



Home | Main Index | Thread Index | Old Index