[dm-devel] dm-io async WRITE_SAME results in iSCSI NULL pointer [was: Re: Write same support]

Martin K. Petersen martin.petersen at oracle.com
Tue Feb 21 12:31:53 UTC 2012


>>>>> "Mike" == Mike Snitzer <snitzer at redhat.com> writes:

Mike> This patch fixed the issue for me (though I'm still missing why
Mike> bio->bi_phys_segments was 0 given blkdev_issue_write_same() sets
Mike> it):

Ok, I see what's going on. You have your own dm-specific make request
function. When cloning the original bio phys_segments isn't carried
over. And that's why we see 0 in sd.

For discard this is not a problem because we hardwire things in sd.c
regardless of what was passed down. And besides you have special
handling for mapping discards in DM.

I was trying to avoid perpetuating Christoph's horrible hack (his words,
not mine). But maybe it's better to do it the same way as for discard so
we only have to have to deal with pure evil in one place.

I'll contemplate a bit...


PS. The good news is that your async stuff works when I set phys_segs to
1 in sd.

-- 
Martin K. Petersen	Oracle Linux Engineering




More information about the dm-devel mailing list