Alsa-Devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Russell King (Oracle)" <linux@armlinux.org.uk>
To: Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
Cc: alsa-devel@alsa-project.org, Takashi Iwai <tiwai@suse.de>,
	Jaroslav Kysela <perex@perex.cz>
Subject: Re: [PATCH] ALSA: aaci: report FIFO size in frames
Date: Mon, 1 Apr 2024 21:59:10 +0100	[thread overview]
Message-ID: <ZgsgHiFbbmjuD+tT@shell.armlinux.org.uk> (raw)
In-Reply-To: <ZgrCEU6rHuEtT6/8@ugly>

On Mon, Apr 01, 2024 at 04:17:53PM +0200, Oswald Buddenhagen wrote:
> On Mon, Apr 01, 2024 at 02:34:20PM +0100, Russell King (Oracle) wrote:
> > Oh FFS. So you generated a patch based on the contents of a mere
> > comment? That is NOT how kernel development should be done. Do not do
> > this.
> > 
> i think that speculative/rfc patches are a perfectly fine way to get
> things clarified, and the linux kernel is no exception to that.

This wasn't a "speculative/rfc" patch. Such patches get marked with
"RFC" in the tag.

> > Comments are not always correct.
> > 
> so how about taking the opportunity to fix this one?

I don't think this comment is incorrect.

"ALSA wants the byte-size of the FIFOs."

That is a fact when the flag you refer to is not set.

"As we only support 16-bit samples"

That is also a fact - the driver doesn't support anything but 16-bit
samples.

"this is twice the FIFO depth irrespective of whether it's in compact
mode or not."

The only ambiguity there is what "compact" mode is, and one can find
that out by reading the documentation referenced at the top of the file
which is a public document.

Why should the comment go into all the nitty gritty that is described
in the _public_ document, like "the FIFO is shared between all channels"
and "the FIFO has a fixed width". Maybe it should also state that
compact mode is reading 32-bits per transfer and thus takes up two FIFO
entries. Maybe it should describe that each 32-bit transfer contains
two samples. Maybe it should describe the bit order of those samples.
Maybe it should describe what a computer is as well?

At some point, knowledge has to be assumed. I assume that, because the
public document is referenced at the top of the file, anyone who wishes
to patch this driver should refer to the public documentation to get an
understanding of the hardware first.

-- 
RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

  reply	other threads:[~2024-04-01 21:00 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-01 10:13 [PATCH] ALSA: aaci: report FIFO size in frames Oswald Buddenhagen
2024-04-01 10:31 ` Russell King (Oracle)
2024-04-01 10:37   ` Russell King (Oracle)
2024-04-01 10:53     ` Oswald Buddenhagen
2024-04-01 11:04       ` Russell King (Oracle)
2024-04-01 11:45         ` Oswald Buddenhagen
2024-04-01 13:34           ` Russell King (Oracle)
2024-04-01 14:17             ` Oswald Buddenhagen
2024-04-01 20:59               ` Russell King (Oracle) [this message]
2024-04-01 23:01                 ` Oswald Buddenhagen
2024-04-01 23:25                   ` Russell King (Oracle)
2024-04-02 10:46                     ` Oswald Buddenhagen

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=ZgsgHiFbbmjuD+tT@shell.armlinux.org.uk \
    --to=linux@armlinux.org.uk \
    --cc=alsa-devel@alsa-project.org \
    --cc=oswald.buddenhagen@gmx.de \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.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