aboutsummaryrefslogtreecommitdiff
path: root/fs/sysfs/file.c
diff options
context:
space:
mode:
authorJames Bottomley <James.Bottomley@HansenPartnership.com>2008-01-22 13:43:48 -0600
committerJames Bottomley <James.Bottomley@HansenPartnership.com>2008-01-23 11:27:54 -0600
commitd0ad3bc97c06fba5d37b4ca03c03b7eeeda39c47 (patch)
tree5aaecdc97e807dc9be911243604c9b9e0f22bde6 /fs/sysfs/file.c
parent465ff3185e0cb76d46137335a4d21d0d9d3ac8a2 (diff)
[SCSI] libata: fix corruption induced by relaxed DMA alignment in SCSI
Hugh Dickens noticed that SMART commands issued from user space can end up corupting memory. The problem occurs if the buffer used to read data spans two pages. The reason is that the PIO sector routines in libata are expecting physically contiguous pages when they do sector operations, so the left overs on the second page go into the next physically adjacent page rather than the next page in the sg mapping. Fix this by enforcing strict 512 byte alignment on all buffers from userspace. Acked-by: Hugh Dickins <hugh@veritas.com> Acked-by: Jeff Garzik <jeff@garzik.org> Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Diffstat (limited to 'fs/sysfs/file.c')
0 files changed, 0 insertions, 0 deletions