/* This is the pointer to the data buffer */
sg = &data->sg[host->pio.index];
- sg_ptr = kmap_atomic(sg_page(sg)) + sg->offset + host->pio.offset;
+ sg_ptr = kmap_local_page(sg_page(sg)) + sg->offset + host->pio.offset;
/* This is the space left inside the buffer */
sg_len = data->sg[host->pio.index].length - host->pio.offset;
__raw_writel((unsigned long)val, HOST_TXPORT(host));
wmb(); /* drain writebuffer */
}
- kunmap_atomic(sg_ptr);
+ kunmap_local(sg_ptr);
host->pio.len -= count;
host->pio.offset += count;
if (host->pio.index < host->dma.len) {
sg = &data->sg[host->pio.index];
- sg_ptr = kmap_atomic(sg_page(sg)) + sg->offset + host->pio.offset;
+ sg_ptr = kmap_local_page(sg_page(sg)) + sg->offset + host->pio.offset;
/* This is the space left inside the buffer */
sg_len = sg_dma_len(&data->sg[host->pio.index]) - host->pio.offset;
sg_ptr[count] = (unsigned char)(val & 0xFF);
}
if (sg_ptr)
- kunmap_atomic(sg_ptr);
+ kunmap_local(sg_ptr);
host->pio.len -= count;
host->pio.offset += count;