* - Maybe make an ALSA interface, that is, create a file_ops
* implementation that recognizes ALSA ioctls and uses defaults for
* things that can't be controlled through ALSA (iso channel).
+ *
+ * Changes:
+ *
+ * - Audit copy_from_user in amdtp_write.
+ * Daniele Bellucci <bellucda@tiscali.it>
+ *
*/
#include <linux/module.h>
for (i = 0; i < count; i += length) {
p = buffer_put_bytes(s->input, count - i, &length);
- copy_from_user(p, buffer + i, length);
+ if (copy_from_user(p, buffer + i, length))
+ return -EFAULT;
if (s->input->length < s->input->size)
continue;