block: move dif_prepare/dif_complete functions to block layer
Currently these functions are implemented in the scsi layer, but their actual place should be the block layer since T10-PI is a general data integrity feature that is used in the nvme protocol as well. Also, use the tuple size from the integrity profile since it may vary between integrity types. Suggested-by:Christoph Hellwig <hch@lst.de> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by:
Max Gurtovoy <maxg@mellanox.com> Signed-off-by:
Jens Axboe <axboe@kernel.dk>
Showing
- block/t10-pi.c 110 additions, 0 deletionsblock/t10-pi.c
- drivers/scsi/sd.c 5 additions, 3 deletionsdrivers/scsi/sd.c
- drivers/scsi/sd.h 0 additions, 9 deletionsdrivers/scsi/sd.h
- drivers/scsi/sd_dif.c 0 additions, 113 deletionsdrivers/scsi/sd_dif.c
- include/linux/t10-pi.h 3 additions, 0 deletionsinclude/linux/t10-pi.h
Loading
Please register or sign in to comment