James, while reviewing code derived from that function I found this calculation to be suspicious: I would think that it should get it wrong when both start and end of the buffer area are misaligned (e.g. consider the case where sgl->offset equals PAGE_SIZE-1 and bufflen equals 2 - the result would be 1 when it should have been 2). Is there something preventing this from happening? Thanks, Jan -- To unsubscribe from this list: send the line "unsubscribe linux-scsi" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html