linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Geert Uytterhoeven <geert@linux-m68k.org>
To: Finn Thain <fthain@telegraphics.com.au>
Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de>,
	Michael Schmitz <schmitzmic@gmail.com>,
	"James E.J. Bottomley" <jejb@linux.ibm.com>,
	"Martin K. Petersen" <martin.petersen@oracle.com>,
	"Ahmed S. Darwish" <a.darwish@linutronix.de>,
	Thomas Gleixner <tglx@linutronix.de>,
	scsi <linux-scsi@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] scsi/NCR5380: Remove in_interrupt() test
Date: Fri, 4 Dec 2020 09:38:25 +0100	[thread overview]
Message-ID: <CAMuHMdUYwUPWzhBD+MWJsjBvmb31T0=2j8d0_-f9Q0ocfBAs9A@mail.gmail.com> (raw)
In-Reply-To: <alpine.LNX.2.23.453.2012040953030.6@nippy.intranet>

Hi Finn,

On Fri, Dec 4, 2020 at 12:11 AM Finn Thain <fthain@telegraphics.com.au> wrote:
> > --- a/drivers/scsi/g_NCR5380.c
> > +++ b/drivers/scsi/g_NCR5380.c
> > @@ -529,14 +529,14 @@ static inline int generic_NCR5380_precv(struct NCR5380_hostdata *hostdata,
> >               if (start == len - 128) {
> >                       /* Ignore End of DMA interrupt for the final buffer */
> >                       if (NCR5380_poll_politely(hostdata, hostdata->c400_ctl_status,
> > -                                               CSR_HOST_BUF_NOT_RDY, 0, HZ / 64) < 0)
> > +                                               CSR_HOST_BUF_NOT_RDY, 0, 0) < 0)
>
> You've put your finger on a known problem with certain
> NCR5380_poll_politely() call sites. That is, the nominal timeout, HZ / 64,
> is meaningless because it is ignored in atomic context. So you may as well
> specify 0 jiffies at these call sites. (There will be a 1 jiffy timeout
> applied regardless.)

Notwithstanding HZ / 64 breaks if HZ < 64.

Possible values of HZ in the kernel:

24
32
48
64
100
128
200
250
256
300
500
1000
1024
1200

Gr{oetje,eeting}s,

                        Geert

-- 
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
                                -- Linus Torvalds

  reply	other threads:[~2020-12-04  8:39 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-12-01  6:46 [PATCH] scsi/NCR5380: Remove in_interrupt() test Finn Thain
2020-12-01 17:05 ` Sebastian Andrzej Siewior
2020-12-03 23:08   ` Finn Thain
2020-12-04  8:38     ` Geert Uytterhoeven [this message]
2020-12-04 16:08     ` Ahmed S. Darwish
2020-12-01 18:01 ` Michael Schmitz
2020-12-04 15:32 ` [PATCH v2] scsi: NCR5380: Remove context check Ahmed S. Darwish
2020-12-05  4:28   ` Finn Thain
2020-12-06  7:51     ` [PATCH v3] " Ahmed S. Darwish
2020-12-08  0:12       ` Finn Thain
2020-12-08  1:26       ` Martin K. Petersen
2020-12-09 17:23       ` Martin K. Petersen

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='CAMuHMdUYwUPWzhBD+MWJsjBvmb31T0=2j8d0_-f9Q0ocfBAs9A@mail.gmail.com' \
    --to=geert@linux-m68k.org \
    --cc=a.darwish@linutronix.de \
    --cc=bigeasy@linutronix.de \
    --cc=fthain@telegraphics.com.au \
    --cc=jejb@linux.ibm.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=schmitzmic@gmail.com \
    --cc=tglx@linutronix.de \
    /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).