int (*trigger)(struct snd_compr_stream *stream, int cmd);
        int (*pointer)(struct snd_compr_stream *stream,
                        struct snd_compr_tstamp *tstamp);
-       int (*copy)(struct snd_compr_stream *stream, const char __user *buf,
+       int (*copy)(struct snd_compr_stream *stream, char __user *buf,
                       size_t count);
        int (*mmap)(struct snd_compr_stream *stream,
                        struct vm_area_struct *vma);
 
        if (avail > count)
                avail = count;
 
-       if (stream->ops->copy)
-               retval = stream->ops->copy(stream, buf, avail);
-       else
+       if (stream->ops->copy) {
+               char __user* cbuf = (char __user*)buf;
+               retval = stream->ops->copy(stream, cbuf, avail);
+       } else {
                retval = snd_compr_write_data(stream, buf, avail);
+       }
        if (retval > 0)
                stream->runtime->total_bytes_available += retval;
 
 
 }
 
 static int soc_compr_copy(struct snd_compr_stream *cstream,
-                         const char __user *buf, size_t count)
+                         char __user *buf, size_t count)
 {
        struct snd_soc_pcm_runtime *rtd = cstream->private_data;
        struct snd_soc_platform *platform = rtd->platform;