Re: [PATCH 08/25] ALSA: korg1212: Convert to generic PCM copy ops

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

 



On Mon, Aug 14, 2023 at 01:55:06PM +0200, Takashi Iwai wrote:
> This patch converts the korg1212 driver code to use the new unified
> PCM copy callback.  The open-coded conditional memory copies are
> replaced with simpler copy_from/to_iter() calls.
> 
> Note that copy_from/to_iter() returns the copied bytes, hence the
> error condition is inverted from copy_from/to_user().

...

> +		if (!copy_to_iter(src, size, dst))

	!= size ?


>  			return -EFAULT;

...

> +		if (!copy_from_iter(dst, size, src))
>  			return -EFAULT;

Ditto.

-- 
With Best Regards,
Andy Shevchenko





[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