Re: [PATCH] ALSA: ctl: Fix copy of updated id with element read/write

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 02 Dec 2021 16:06:07 +0100,
Alan Young wrote:
> 
> When control_compat.c:copy_ctl_value_to_user() is used, by
> ctl_elem_read_user() & ctl_elem_write_user(), it must also copy back the
> snd_ctl_elem_id value that may have been updated (filled in) by the call
> to snd_ctl_elem_read/snd_ctl_elem_write().
> 
> This matches the functionality provided by snd_ctl_elem_read_user() and
> snd_ctl_elem_write_user(), via snd_ctl_build_ioff().
> 
> Without this, and without making additional calls to snd_ctl_info()
> which are unnecessary when using the non-compat calls, a userspace
> application will not know the numid value for the element and
> consequently will not be able to use the poll/read interface on the
> control file to determine which elements have updates.
> 
> Signed-off-by: Alan Young <consult.awy@xxxxxxxxx>

Thanks, applied (with Cc to stable).


Takashi



[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux