From: "Martin K. Petersen" <martin.petersen@oracle.com>
To: "Ivanov, Dmitry (HPC)" <dmitry.ivanov2@hpe.com>
Cc: "Martin K. Petersen" <martin.petersen@oracle.com>,
Damien Le Moal <damien.lemoal@wdc.com>,
Jens Axboe <axboe@kernel.dk>,
Bart Van Assche <bvanassche@acm.org>,
"Lyashkov, Alexey" <alexey.lyashkov@hpe.com>,
Dmitry Fomichev <dmitry.fomichev@wdc.com>,
"linux-block@vger.kernel.org" <linux-block@vger.kernel.org>,
"linux-scsi@vger.kernel.org" <linux-scsi@vger.kernel.org>,
Milan Broz <gmazyland@gmail.com>,
Mike Snitzer <snitzer@redhat.com>
Subject: Re: [PATCH 0/1] t10-pi bio split fix
Date: Thu, 03 Feb 2022 22:44:54 -0500 [thread overview]
Message-ID: <yq1tudfz49v.fsf@ca-mkp.ca.oracle.com> (raw)
In-Reply-To: <SJ0PR84MB18220278F9CA4C597E2467E8C2279@SJ0PR84MB1822.NAMPRD84.PROD.OUTLOOK.COM> (Dmitry Ivanov's message of "Wed, 2 Feb 2022 17:42:26 +0000")
Dmitry,
> My only concern is dm_crypt target which operates on bip_iter directly
> with the code copy-pasted from bio_integrity_advance:
>
> static int dm_crypt_integrity_io_alloc(struct dm_crypt_io *io, struct bio *bio)
> {
> struct bio_integrity_payload *bip;
> unsigned int tag_len;
> int ret;
>
> if (!bio_sectors(bio) || !io->cc->on_disk_tag_size)
> return 0;
>
> bip = bio_integrity_alloc(bio, GFP_NOIO, 1);
> if (IS_ERR(bip))
> return PTR_ERR(bip);
>
> tag_len = io->cc->on_disk_tag_size * (bio_sectors(bio) >> io->cc->sector_shift);
>
> bip->bip_iter.bi_size = tag_len;
> bip->bip_iter.bi_sector = io->cc->start + io->sector;
> ^^^
>
> ret = bio_integrity_add_page(bio, virt_to_page(io->integrity_metadata),
> tag_len, offset_in_page(io->integrity_metadata));
> ...
> }
I copied Milan and Mike who are more familiar with the dm-drypt internals.
--
Martin K. Petersen Oracle Linux Engineering
next prev parent reply other threads:[~2022-02-04 3:45 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-02-02 17:42 [PATCH 0/1] t10-pi bio split fix Ivanov, Dmitry (HPC)
2022-02-04 3:44 ` Martin K. Petersen [this message]
2022-02-04 7:43 ` Milan Broz
2022-02-04 7:58 ` Lyashkov, Alexey
2022-02-05 3:03 ` Ivanov, Dmitry (HPC)
[not found] <20211220134422.1045336-1-alexey.lyashkov@hpe.com>
[not found] ` <yq1wnjzi6oc.fsf@ca-mkp.ca.oracle.com>
[not found] ` <82F812AE-BEFA-4F57-A134-C1EED7F1928E@hpe.com>
2021-12-30 2:23 ` Damien Le Moal
2022-01-13 11:13 ` Lyashkov, Alexey
2022-01-13 19:59 ` Martin K. Petersen
2022-01-14 12:25 ` Lyashkov, Alexey
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=yq1tudfz49v.fsf@ca-mkp.ca.oracle.com \
--to=martin.petersen@oracle.com \
--cc=alexey.lyashkov@hpe.com \
--cc=axboe@kernel.dk \
--cc=bvanassche@acm.org \
--cc=damien.lemoal@wdc.com \
--cc=dmitry.fomichev@wdc.com \
--cc=dmitry.ivanov2@hpe.com \
--cc=gmazyland@gmail.com \
--cc=linux-block@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=snitzer@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).