NetBSD Problem Report #58006

From gson@gson.org  Thu Mar  7 12:48:53 2024
Return-Path: <gson@gson.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 986B41A923B
	for <gnats-bugs@gnats.NetBSD.org>; Thu,  7 Mar 2024 12:48:53 +0000 (UTC)
Message-Id: <20240307124845.B40832546A9@guava.gson.org>
Date: Thu,  7 Mar 2024 14:48:45 +0200 (EET)
From: gson@gson.org (Andreas Gustafsson)
Reply-To: gson@gson.org (Andreas Gustafsson)
To: gnats-bugs@NetBSD.org
Subject: ATF tests no longer complete on riscv-riscv64
X-Send-Pr-Version: 3.95

>Number:         58006
>Category:       port-riscv
>Synopsis:       ATF tests no longer complete on riscv-riscv64
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    port-riscv-maintainer
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Mar 07 12:50:00 +0000 2024
>Closed-Date:    Sat Apr 20 06:55:45 +0000 2024
>Last-Modified:  Sat Apr 20 06:55:45 +0000 2024
>Originator:     Andreas Gustafsson
>Release:        NetBSD-current, source date >= 2023.09.03.08.48.20
>Organization:
>Environment:
System: NetBSD
Architecture: riscv
Machine: riscv64
>Description:

When running the ATF test suite on the riscv-riscv64 port under qemu,
the OS crashes or hangs, usually during the raidframe tests as in this
log:

  https://www.gson.org/netbsd/bugs/build/riscv-riscv64/2024/2024.02.01.02.41.56/test.log

The problem started with the commit to "Fix and enable MULTIPROCESSOR":

  2023.09.03.08.48.19 skrll src/sys/arch/riscv/conf/GENERIC.common 1.7
  2023.09.03.08.48.19 skrll src/sys/arch/riscv/conf/files.riscv 1.14
  2023.09.03.08.48.19 skrll src/sys/arch/riscv/fdt/cpu_fdt.c 1.3
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/include/cpu.h 1.14
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/include/intr.h 1.5
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/include/pmap.h 1.21
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/cpu.c 1.5
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/cpu_subr.c 1.4
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/db_interface.c 1.4
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/ipifuncs.c 1.2
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/locore.S 1.43
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/pmap_machdep.c 1.19
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/riscv_machdep.c 1.34
  2023.09.03.08.48.20 skrll src/sys/arch/riscv/riscv/riscv_tlb.c 1.2

Logs from around the time of that commit are at:

  https://www.gson.org/netbsd/bugs/build/riscv-riscv64/commits-2023.09.html#2023.09.02.21.54.55

>How-To-Repeat:

Install misc/py-anita >= 2.11 and emulators/qemu, and run

  anita test http://nycdn.netbsd.org/pub/NetBSD-daily/HEAD/latest/riscv-riscv64/

>Fix:

>Release-Note:

>Audit-Trail:

State-Changed-From-To: open->feedback
State-Changed-By: skrll@NetBSD.org
State-Changed-When: Mon, 08 Apr 2024 07:05:00 +0000
State-Changed-Why:
Candidate fix in sys/arch/riscv/riscv/cpu.c:1.6
Please update and test


From: Andreas Gustafsson <gson@gson.org>
To: gnats-bugs@netbsd.org
Cc: port-riscv-maintainer@netbsd.org,
    skrll@NetBSD.org
Subject: Re: port-riscv/58006 (ATF tests no longer complete on riscv-riscv64)
Date: Mon, 8 Apr 2024 11:41:59 +0300

 skrll@NetBSD.org wrote:
 > Candidate fix in sys/arch/riscv/riscv/cpu.c:1.6
 > Please update and test

 I'm now running the tests on babylon5.netbsd.org, and although they
 have not timed out yet, they appear to have hung during the
 raid1_comp0fail test case:

   babylon5.netbsd.org$ tail /bracket/riscv-riscv64/test/2024.04.08.04.29.52/test.log
       ymdhms_to_secs: [0.085812s] Passed.
   [0.177565s]

   dev/fss/t_fss (40/946): 1 test cases
       basic: [3.245339s] Skipped: FSS not available
   [3.255803s]

   dev/raidframe/t_raid (41/946): 7 test cases
       old_numrows_config: [2.119633s] Passed.
       raid1_comp0fail: 

 -- 
 Andreas Gustafsson, gson@gson.org

State-Changed-From-To: feedback->open
State-Changed-By: skrll@NetBSD.org
State-Changed-When: Fri, 19 Apr 2024 06:22:13 +0000
State-Changed-Why:
sys/arch/riscv/riscv/cpu.c:1.6
wasn't a fix.


State-Changed-From-To: open->feedback
State-Changed-By: skrll@NetBSD.org
State-Changed-When: Fri, 19 Apr 2024 06:24:18 +0000
State-Changed-Why:
sys/uvm/pmap/pmap.c:1.78
sys/uvm/pmap/pmap.h:1.27
fix the ATF run for me


State-Changed-From-To: feedback->closed
State-Changed-By: skrll@NetBSD.org
State-Changed-When: Sat, 20 Apr 2024 06:55:45 +0000
State-Changed-Why:
babylon5 run ran to completion.
Latest build results: 2024.04.19.05.04.06
build: OK with 498877 lines of log, install: OK, tests: 9312 passed, 541 skipped, 58 expected_failure, 212 failed


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.47 2022/09/11 19:34:41 kim Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2024 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.