Source-Changes-HG archive

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

[src/trunk]: src/sys/arch/arm/pic intr_ipi_send: assert that kcp is either NU...



details:   https://anonhg.NetBSD.org/src/rev/8cf91b5bed49
branches:  trunk
changeset: 977777:8cf91b5bed49
user:      jmcneill <jmcneill%NetBSD.org@localhost>
date:      Sun Nov 01 14:42:05 2020 +0000

description:
intr_ipi_send: assert that kcp is either NULL or contains exactly one CPU

diffstat:

 sys/arch/arm/pic/pic.c |  5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)

diffs (26 lines):

diff -r 458f46381102 -r 8cf91b5bed49 sys/arch/arm/pic/pic.c
--- a/sys/arch/arm/pic/pic.c    Sun Nov 01 14:36:25 2020 +0000
+++ b/sys/arch/arm/pic/pic.c    Sun Nov 01 14:42:05 2020 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: pic.c,v 1.60 2020/10/26 07:16:41 skrll Exp $   */
+/*     $NetBSD: pic.c,v 1.61 2020/11/01 14:42:05 jmcneill Exp $        */
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
  * All rights reserved.
@@ -33,7 +33,7 @@
 #include "opt_multiprocessor.h"
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: pic.c,v 1.60 2020/10/26 07:16:41 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: pic.c,v 1.61 2020/11/01 14:42:05 jmcneill Exp $");
 
 #include <sys/param.h>
 #include <sys/atomic.h>
@@ -197,6 +197,7 @@
 {
        struct cpu_info * const ci = curcpu();
        KASSERT(ipi < NIPI);
+       KASSERT(kcp == NULL || kcpuset_countset(kcp) == 1);
        bool __diagused sent_p = false;
        for (size_t slot = 0; slot < PIC_MAXPICS; slot++) {
                struct pic_softc * const pic = pic_list[slot];



Home | Main Index | Thread Index | Old Index