Linux Sound subsystem development
 help / color / mirror / Atom feed
From: Takashi Iwai <tiwai@suse.de>
To: yangchenyuan <chenyuan0y@gmail.com>
Cc: perex@perex.cz, tiwai@suse.com, viro@zeniv.linux.org.uk,
	brauner@kernel.org, pavel.hofman@ivitera.com,
	jbrunet@baylibre.com, linux-sound@vger.kernel.org,
	linux-kernel@vger.kernel.org, zijie98@gmail.com
Subject: Re: [PATCH] ALSA: pcm: use new array-copying-wrapper
Date: Tue, 28 Jan 2025 08:49:17 +0100	[thread overview]
Message-ID: <87zfjb9y4i.wl-tiwai@suse.de> (raw)
In-Reply-To: <20250127160655.3119470-1-cy1yang@outlook.com>

On Mon, 27 Jan 2025 17:06:55 +0100,
yangchenyuan wrote:
> 
> From: Chenyuan Yang <chenyuan0y@gmail.com>
> 
> This is found by our static analysis tool.
> 
> pcm_native.c utilizes memdup_user() to copy an array from userspace.
> 
> There is a new wrapper, specifically designed for copying arrays. Use
> this one instead.
> 
> This is similar to the 
> commit 3e91a38de1dc ("fbdev: viafb: use new array-copying-wrapper").
> 
> Fixes: 67616feda99e ("ALSA: pcm: Unify ioctl functions for playback and capture streams")

This use of Fixes tag is misleading: the original code is correct, per
se, and the original commit was 4.14, where it had no no
memdup_array_user() available (introduced since 6.7).

So I applied with the drop of Fixes tag.


thanks,

Takashi

  reply	other threads:[~2025-01-28  7:49 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-27 16:06 [PATCH] ALSA: pcm: use new array-copying-wrapper yangchenyuan
2025-01-28  7:49 ` Takashi Iwai [this message]
2025-01-28 16:06   ` Chenyuan Yang

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=87zfjb9y4i.wl-tiwai@suse.de \
    --to=tiwai@suse.de \
    --cc=brauner@kernel.org \
    --cc=chenyuan0y@gmail.com \
    --cc=jbrunet@baylibre.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-sound@vger.kernel.org \
    --cc=pavel.hofman@ivitera.com \
    --cc=perex@perex.cz \
    --cc=tiwai@suse.com \
    --cc=viro@zeniv.linux.org.uk \
    --cc=zijie98@gmail.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