qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Sven Schnelle <svens@stackframe.org>
To: Thomas Huth <thuth@redhat.com>
Cc: Fam Zheng <fam@euphon.net>,  Paolo Bonzini <pbonzini@redhat.com>,
	qemu-devel@nongnu.org,  deller@gmx.de,
	 Alexander Bulekov <alxndr@bu.edu>
Subject: Re: [PATCH] hw/scsi/lsi53c895a: add missing decrement of reentrancy counter
Date: Mon, 29 Jan 2024 07:17:14 +0100	[thread overview]
Message-ID: <87bk94k6j9.fsf@t14.stackframe.org> (raw)
In-Reply-To: <a7ee1d55-f550-4ad9-9907-f9dd13600aa0@redhat.com> (Thomas Huth's message of "Mon, 29 Jan 2024 05:16:00 +0100")

Thomas Huth <thuth@redhat.com> writes:

> On 28/01/2024 21.22, Sven Schnelle wrote:
>> When the maximum count of SCRIPTS instructions is reached, the code
>> stops execution and returns, but fails to decrement the reentrancy
>> counter. This effectively renders the SCSI controller unusable
>> because on next entry the reentrancy counter is still above the limit.
>> This bug was seen on HP-UX 10.20 which seems to trigger SCRIPTS
>> loops.
>
> Out of curiosity: What happened there before we introduced the
> reentrancy_level fix? Did it end up in an endless loop, or was it
> finishing at one point? In the latter case, we might need to adjust
> the "reentrancy_level > 8" to allow deeper nesting.

Without the reentrancy counter it was triggering the insn_processed
limit. The HP-UX scsi driver seems to spin on some memory value during
some SCSI writes (CDB with command 0x2a). So it is spinning in an
endless loop until the insn_processed counter will trigger the exit.
In HP-UX you will see a SCSI command timeout error in the kernel log
- at least i'm assuming that's related, but can't say for sure as
there's no kernel source available.


  reply	other threads:[~2024-01-29  6:18 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-28 20:22 [PATCH] hw/scsi/lsi53c895a: add missing decrement of reentrancy counter Sven Schnelle
2024-01-29  4:16 ` Thomas Huth
2024-01-29  6:17   ` Sven Schnelle [this message]
2024-01-29  6:24 ` Michael Tokarev
2024-01-30 18:41 ` Helge Deller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87bk94k6j9.fsf@t14.stackframe.org \
    --to=svens@stackframe.org \
    --cc=alxndr@bu.edu \
    --cc=deller@gmx.de \
    --cc=fam@euphon.net \
    --cc=pbonzini@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=thuth@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).