NetBSD Problem Report #52657

From www@NetBSD.org  Wed Oct 25 20:23:15 2017
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-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 F3DFA7A1C4
	for <gnats-bugs@gnats.NetBSD.org>; Wed, 25 Oct 2017 20:23:14 +0000 (UTC)
Message-Id: <20171025202314.29B247A1E8@mollari.NetBSD.org>
Date: Wed, 25 Oct 2017 20:23:14 +0000 (UTC)
From: bruno@clisp.org
Reply-To: bruno@clisp.org
To: gnats-bugs@NetBSD.org
Subject: current time does not advance on NetBSD sparc64
X-Send-Pr-Version: www-1.0

>Number:         52657
>Category:       port-sparc64
>Synopsis:       current time does not advance on NetBSD sparc64
>Confidential:   no
>Severity:       serious
>Priority:       high
>Responsible:    martin
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Oct 25 20:25:00 +0000 2017
>Closed-Date:    Sun Jan 20 09:55:14 +0000 2019
>Last-Modified:  Sun Jan 20 10:05:01 +0000 2019
>Originator:     Bruno Haible
>Release:        8.0_BETA
>Organization:
GNU
>Environment:
NetBSD sparin.bruno.haible.de 8.0_BETA NetBSD 8.0_BETA (GENERIC.201709170600Z) sparc64

>Description:
A C program that calls sleep(1) never terminates.
The cause it that indeed the current time does not seem to advance:

sparin$ date
Wed Oct 25 20:37:20 CEST 2017
sparin$ date
Wed Oct 25 20:37:19 CEST 2017
sparin$ date
Wed Oct 25 20:37:20 CEST 2017
sparin$ date
Wed Oct 25 20:37:20 CEST 2017
sparin$ date
Wed Oct 25 20:37:20 CEST 2017

$ uptime
 8:37PM  up 7 mins, 1 user, load averages: 0.92, 0.51, 0.27

The machine is running for 1.5 hours.
It's emulated in qemu-system-sparc64 (qemu 2.10.0), which for fine for Linux guests.

Also, after logging out, I don't get a new login prompt (probably because that is triggered by a timer as well).
>How-To-Repeat:

>Fix:

>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: kern-bug-people->martin
Responsible-Changed-By: martin@NetBSD.org
Responsible-Changed-When: Thu, 26 Oct 2017 09:09:08 +0000
Responsible-Changed-Why:
Take


From: Martin Husemann <martin@duskware.de>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: port-sparc64/52657 (current time does not advance on NetBSD
 sparc64)
Date: Thu, 26 Oct 2017 11:14:14 +0200

 This is probably some emulation problem with interrupt dispatching.

 We do not see it on real hardware, and it seems to be hard to reproduce
 on qemu too (I tried but it all works fine, using qemu 2.10.1).

 Anything special you did to trigger it quickly?

 Martin

From: Bruno Haible <bruno@clisp.org>
To: gnats-bugs@netbsd.org
Cc: martin@netbsd.org, gnats-admin@netbsd.org, netbsd-bugs@netbsd.org
Subject: Re: port-sparc64/52657 (current time does not advance on NetBSD sparc64)
Date: Thu, 26 Oct 2017 17:14:28 +0200

 >  We do not see it on real hardware, and it seems to be hard to reproduce
 >  on qemu too (I tried but it all works fine, using qemu 2.10.1).
 >  
 >  Anything special you did to trigger it quickly?

 Nothing special; I was just running a configure script for 1 hour, and it hung
 at the first test program that happened to invoke sleep(3).

 Bruno

From: Bruno Haible <bruno@clisp.org>
To: gnats-bugs@netbsd.org
Cc: martin@netbsd.org, gnats-admin@netbsd.org, netbsd-bugs@netbsd.org
Subject: Re: port-sparc64/52657 (current time does not advance on NetBSD sparc64)
Date: Thu, 26 Oct 2017 21:37:32 +0200

 Martin Husemann wrote:
 >  This is probably some emulation problem with interrupt dispatching.

 On this machine, I occasionally see messages on the console:

 cmdide0:0:0: lost interrupt
         type: ata tc_bcount: 4096 tc_skip: 0

 Is this what you mean? Could this be related?

 Bruno

State-Changed-From-To: open->feedback
State-Changed-By: martin@NetBSD.org
State-Changed-When: Thu, 17 Jan 2019 10:05:59 +0000
State-Changed-Why:
I can not reproduce this, guessing the qemu guys have fixed it in between
(I am testing wiht qemu 3.1). We also now run automatic tests of -current
on qemu, which would show fallout like this too.


State-Changed-From-To: feedback->closed
State-Changed-By: martin@NetBSD.org
State-Changed-When: Sun, 20 Jan 2019 09:55:14 +0000
State-Changed-Why:
confirmed fixed
(the "No counter-timer" message happens on real U5/U10 as well)


From: Bruno Haible <bruno@clisp.org>
To: gnats-bugs@netbsd.org
Cc: martin@netbsd.org, netbsd-bugs@netbsd.org, gnats-admin@netbsd.org
Subject: Re: port-sparc64/52657 (current time does not advance on NetBSD sparc64)
Date: Sun, 20 Jan 2019 10:53:08 +0100

 Hi,

 > I can not reproduce this, guessing the qemu guys have fixed it in between
 > (I am testing wiht qemu 3.1). We also now run automatic tests of -current
 > on qemu, which would show fallout like this too.

 Indeed, the combination of qemu-3.1.0 and NetBSD-8.0-sparc64.iso leads to
 a solidly working system. At boot time the message

   No counter-timer -- using %tick at 100MHz as system clock.

 is displayed. But it appears to be harmless.

 You can close this ticket.

 Bruno

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.