Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6
[pandora-kernel.git] / drivers / staging / iio / ring_sw.c
index 1f14cd4..294272d 100644 (file)
@@ -20,7 +20,7 @@ static inline int __iio_allocate_sw_ring_buffer(struct iio_sw_ring_buffer *ring,
        if ((length == 0) || (bytes_per_datum == 0))
                return -EINVAL;
        __iio_update_ring_buffer(&ring->buf, bytes_per_datum, length);
-       ring->data = kmalloc(length*ring->buf.bpd, GFP_KERNEL);
+       ring->data = kmalloc(length*ring->buf.bpd, GFP_ATOMIC);
        ring->read_p = NULL;
        ring->write_p = NULL;
        ring->last_written_p = NULL;