Re: [PATCH 4 of 7] block: bio data integrity support

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Martin K. Petersen
Date: Tuesday, June 10, 2008 - 9:05 pm

>>>>> "Jeff" == Jeff Moyer <jmoyer@redhat.com> writes:


Jeff> That assignment isn't necessary.

Zap!


Jeff>         nr_sectors = (len + bi->tag_size - 1) / bi->tag_size;

Jeff> why not simply use DIV_ROUND_UP?

Fixed.


Jeff> set_tag and get_tag are almost identical.  Any chance you want
Jeff> to factor out that code?

Done.


Jeff> Hmm, up until this point you use bi to mean bio_integrity, but
Jeff> now it means blk_integrity.  Confusion will ensue.  ;)

Err, uhm.  There is no bio_integrity.  There's the bio integrity
payload which I always refer to as struct bip *bip.  And struct
blk_integrity which is always bi.  I'm also anal about using bv for
the data bio_vec and iv for the integrity bio_vec.  I can't see any
place where I'm inconsistent.


Jeff> struct blk_integrity_exchg is not yet defined in your patch set,
Jeff> so this will likely break git bisect.

bio-integrity.patch and blk-integrity.patch are artificially split up
to ease the review process.  They are not meant to be separate
changesets.



Jeff> Does this actually need to be zeroed?

Nope.



Jeff> The above two loops look pretty much the same to me.  Can you
Jeff> factor that out to a helper?

I've created helpers for marking head and tail of the ivec.

-- 
Martin K. Petersen	Oracle Linux Engineering
--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
[PATCH 0 of 7] Block/SCSI Data Integrity Support, Martin K. Petersen, (Fri Jun 6, 9:55 pm)
[PATCH 1 of 7] lib: Add support for the T10 Data Integrity ..., Martin K. Petersen, (Fri Jun 6, 9:55 pm)
[PATCH 2 of 7] block: Globalize bio_set and bio_vec_slab, Martin K. Petersen, (Fri Jun 6, 9:55 pm)
[PATCH 3 of 7] block: Find bio sector offset given idx and ..., Martin K. Petersen, (Fri Jun 6, 9:55 pm)
[PATCH 4 of 7] block: bio data integrity support, Martin K. Petersen, (Fri Jun 6, 9:55 pm)
[PATCH 5 of 7] block: Block/request layer data integrity s ..., Martin K. Petersen, (Fri Jun 6, 9:55 pm)
[PATCH 6 of 7] scsi: Support devices with protection infor ..., Martin K. Petersen, (Fri Jun 6, 9:55 pm)
[PATCH 7 of 7] Support for SCSI disk (SBC) Data Integrity ..., Martin K. Petersen, (Fri Jun 6, 9:55 pm)
Re: [PATCH 4 of 7] block: bio data integrity support, Monakhov Dmitri, (Sat Jun 7, 7:45 am)
Re: [PATCH 4 of 7] block: bio data integrity support, Martin K. Petersen, (Mon Jun 9, 8:05 am)
Re: [PATCH 5 of 7] block: Block/request layer data integri ..., Martin K. Petersen, (Mon Jun 9, 8:06 am)
Re: [PATCH 3 of 7] block: Find bio sector offset given idx ..., Martin K. Petersen, (Mon Jun 9, 9:15 am)
Re: [PATCH 0 of 7] Block/SCSI Data Integrity Support, Jeff Moyer, (Tue Jun 10, 7:41 am)
Re: [PATCH 0 of 7] Block/SCSI Data Integrity Support, Martin K. Petersen, (Tue Jun 10, 8:28 am)
Re: [PATCH 0 of 7] Block/SCSI Data Integrity Support, Jeff Moyer, (Tue Jun 10, 11:49 am)
Re: [PATCH 0 of 7] Block/SCSI Data Integrity Support, Martin K. Petersen, (Tue Jun 10, 1:47 pm)
Re: [PATCH 4 of 7] block: bio data integrity support, Jeff Moyer, (Tue Jun 10, 1:52 pm)
Re: [PATCH 0 of 7] Block/SCSI Data Integrity Support, Jeff Moyer, (Tue Jun 10, 1:53 pm)
Re: [PATCH 4 of 7] block: bio data integrity support, Martin K. Petersen, (Tue Jun 10, 9:05 pm)
Re: [PATCH 4 of 7] block: bio data integrity support, Jeff Moyer, (Wed Jun 11, 10:41 am)
Re: [PATCH 0 of 7] Block/SCSI Data Integrity Support, Mike Snitzer, (Thu Jul 17, 6:55 am)
Re: [PATCH 0 of 7] Block/SCSI Data Integrity Support, Martin K. Petersen, (Thu Jul 17, 8:35 am)