Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/sparc64/sparc64 sun4v: enable sun4v_intr_xxx() func...



details:   https://anonhg.NetBSD.org/src/rev/99d1aff87102
branches:  trunk
changeset: 359566:99d1aff87102
user:      palle <palle%NetBSD.org@localhost>
date:      Sun Jan 09 20:30:04 2022 +0000

description:
sun4v: enable sun4v_intr_xxx() function previously imported from OpenBSD. Note that the sun4v_intr_devino_to_sysino() function is adapted to match OpenBSD version 1.57 (the introduction of 
INTR_DEVINO is done in revision 1.58)

diffstat:

 sys/arch/sparc64/sparc64/intr.c |  24 ++++--------------------
 1 files changed, 4 insertions(+), 20 deletions(-)

diffs (83 lines):

diff -r 419857ebf88f -r 99d1aff87102 sys/arch/sparc64/sparc64/intr.c
--- a/sys/arch/sparc64/sparc64/intr.c   Sun Jan 09 20:21:44 2022 +0000
+++ b/sys/arch/sparc64/sparc64/intr.c   Sun Jan 09 20:30:04 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: intr.c,v 1.70 2021/07/03 19:18:55 palle Exp $ */
+/*     $NetBSD: intr.c,v 1.71 2022/01/09 20:30:04 palle Exp $ */
 
 /*
  * Copyright (c) 1992, 1993
@@ -41,7 +41,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.70 2021/07/03 19:18:55 palle Exp $");
+__KERNEL_RCSID(0, "$NetBSD: intr.c,v 1.71 2022/01/09 20:30:04 palle Exp $");
 
 #include "opt_ddb.h"
 #include "opt_multiprocessor.h"
@@ -368,22 +368,16 @@
 
 uint64_t sun4v_group_interrupt_major;
 
-#if 0
-XXX notyet
-wint64_t
+int64_t
 sun4v_intr_devino_to_sysino(uint64_t devhandle, uint64_t devino, uint64_t *ino)
 {
        if (sun4v_group_interrupt_major < 3)
                return hv_intr_devino_to_sysino(devhandle, devino, ino);
 
-       KASSERT(INTVEC(devino) == devino);
-       *ino = devino | INTR_DEVINO;
+       *ino = devino;
        return H_EOK;
 }
-#endif
 
-#if 0
-XXX notyet             
 int64_t
 sun4v_intr_setcookie(uint64_t devhandle, uint64_t ino, uint64_t cookie_value)
 {
@@ -392,10 +386,7 @@
        
        return hv_vintr_setcookie(devhandle, ino, cookie_value);
 }
-#endif
 
-#if 0
-XXX notyet             
 int64_t
 sun4v_intr_setenabled(uint64_t devhandle, uint64_t ino, uint64_t intr_enabled)
 {
@@ -404,10 +395,7 @@
 
        return hv_vintr_setenabled(devhandle, ino, intr_enabled);
 }
-#endif
 
-#if 0
-XXX notyet             
 int64_t
 sun4v_intr_setstate(uint64_t devhandle, uint64_t ino, uint64_t intr_state)
 {
@@ -416,10 +404,7 @@
 
        return hv_vintr_setstate(devhandle, ino, intr_state);
 }
-#endif
 
-#if 0
-XXX notyet             
 int64_t
 sun4v_intr_settarget(uint64_t devhandle, uint64_t ino, uint64_t cpuid)
 {
@@ -428,6 +413,5 @@
 
        return hv_vintr_settarget(devhandle, ino, cpuid);
 }
-#endif
 
 #endif



Home | Main Index | Thread Index | Old Index