From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.3 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id AD609C3A59E for ; Wed, 21 Aug 2019 12:10:08 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 7CC5822D6D for ; Wed, 21 Aug 2019 12:10:08 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="ufwEe6b9"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=kernel-dk.20150623.gappssmtp.com header.i=@kernel-dk.20150623.gappssmtp.com header.b="1mTbly5h" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 7CC5822D6D Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=kernel.dk Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:Date: Message-ID:From:References:To:Subject:Reply-To:Content-ID:Content-Description :Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=PbFb2hHeggOhAMonxMOVm8/7xYQxRJuHCBq2niRt2I0=; b=ufwEe6b9yKe9gV Qe2XTEYETO5OEZJPLiYfCWI3KT7I6Ymuz+woNbDiO3gfg6MxYCVAHMelNCysJn2JQR52CFifOV0qK 1pWszfQ0gKbTgE/EmNxSUVX/FveGqeKPBXu0JVDZdXlG84GT5LZtZg2TH2rZN6/Hbh289/jYffrNs E6LyAqL64f8LfF/2n7SydYYnpZ9ZJ5nYKVKSVCn/3sSDr2zp9woY3KgcsWtW9SPDlT/JFq8fU+1gC cjiJmglrm9zgrdd1j/An8Y6gVHfCVUrBeGeq/FnqIGsK2T5zNsqWYlbZ3BehQmAwGSvDjeILm564T SVbunlytkzagqdzYOJvw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92 #3 (Red Hat Linux)) id 1i0PRA-0006Iu-An; Wed, 21 Aug 2019 12:10:00 +0000 Received: from mail-pl1-x641.google.com ([2607:f8b0:4864:20::641]) by bombadil.infradead.org with esmtps (Exim 4.92 #3 (Red Hat Linux)) id 1i0PR6-0006Hi-NK for linux-arm-kernel@lists.infradead.org; Wed, 21 Aug 2019 12:09:58 +0000 Received: by mail-pl1-x641.google.com with SMTP id bj8so1242395plb.4 for ; Wed, 21 Aug 2019 05:09:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel-dk.20150623.gappssmtp.com; s=20150623; h=subject:to:cc:references:from:message-id:date:user-agent :mime-version:in-reply-to:content-language:content-transfer-encoding; bh=UT6yE/roxwyyBSRfLOwrFlilraLjBXjoNWJQAsldDVo=; b=1mTbly5hNN6suDS+BwBXn5tZNQRoJv3U+6eGIZWkxOpX8gp4MfK0srbyshCamPl8cE oynbwAZaUVd3iYuDw/fFqllqnUyyMdhGmWDFTWD0+uRBHO1RABomqwNTPTloesNaBCP/ OF0wNlT1X2HUApuEYt9hqsB3ukfCOmKOxQ9VlFGyTVla9DArrhzV46cf0e1hqSL0Em1S kMKT+OUOB39Lc9u+MllIcA6W2VixaWAmIOOCqIPym//+KF+bJLzrXd5uXWfD6RF+tn8O fEItbmLNgpz+3xyfCw5xuoCb8BCqv/jPsevOVEPakCBbt5mOdjvlnK19JQHJXISJTFII +AuQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:subject:to:cc:references:from:message-id:date :user-agent:mime-version:in-reply-to:content-language :content-transfer-encoding; bh=UT6yE/roxwyyBSRfLOwrFlilraLjBXjoNWJQAsldDVo=; b=hbq8Lxo49KH25YIL+hlKu9hBBNUxCfxhdUPLmhyt7dXu5qxp6+8lQ95xpDkgZR6mSU mTDDbeePEv9Bs1UHRppj6t1kIdAmuK8wIqvk8gNulv0BGmQpk6PZ5Gg5cjQ6+5dCFFAu IhJ5eojQRQOmvfpTUojgvoFHDaLfF+ykca5QaZZhIgjrGKNKfF8z23eEX8v6GO4kd+/5 mHLBjbvnXPSFC2vg+8fpNvBf6+lu3fPOWRXvnURNIJwHMcPDovLTTYyoK1N6zKfvAZcx aXPrujsR0Auh0FEoL5Z8dqeLzIR5L065OnQyH0NPGb7VAekPDCzGt6inCCLd0ze8GVIU Y3Cg== X-Gm-Message-State: APjAAAXfNKnbW7IPA8yoB+3E9IE1gDo4HlWqoxlK+u7D8j5P+b1Se6ec I5VqSMEz9aMPg/LXwjcOdJ6+EQ== X-Google-Smtp-Source: APXvYqxsoe31YiWALXWqRLHXasZTZR3nM8GXNUHwTUUu4EkoxYDPJeCxhjU4HkYSZ/HpLNbIJ9AOOg== X-Received: by 2002:a17:902:a410:: with SMTP id p16mr17723995plq.150.1566389394293; Wed, 21 Aug 2019 05:09:54 -0700 (PDT) Received: from [192.168.1.188] (66.29.164.166.static.utbb.net. [66.29.164.166]) by smtp.gmail.com with ESMTPSA id z4sm22521476pfg.166.2019.08.21.05.09.51 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 21 Aug 2019 05:09:53 -0700 (PDT) Subject: Re: [PATCH 5/9] block: support diskcipher To: "boojin.kim" , linux-block@vger.kernel.org, linux-kernel@vger.kernel.org References: <004101d557eb$98b00060$ca100120$@samsung.com> From: Jens Axboe Message-ID: <6ea5e5db-4dd4-719f-3b3e-b89099636ea6@kernel.dk> Date: Wed, 21 Aug 2019 06:09:50 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <004101d557eb$98b00060$ca100120$@samsung.com> Content-Language: en-US X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190821_050956_811956_63423E5C X-CRM114-Status: GOOD ( 12.88 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: 'Ulf Hansson' , 'Mike Snitzer' , dm-devel@redhat.com, 'Andreas Dilger' , 'Alasdair Kergon' , 'Eric Biggers' , linux-samsung-soc@vger.kernel.org, 'Herbert Xu' , 'Krzysztof Kozlowski' , 'Jaehoon Chung' , 'Kukjin Kim' , linux-ext4@vger.kernel.org, 'Chao Yu' , linux-fscrypt@vger.kernel.org, 'Jaegeuk Kim' , linux-arm-kernel@lists.infradead.org, "'Theodore Y. Ts'o'" , linux-mmc@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, linux-crypto@vger.kernel.org, linux-fsdevel@vger.kernel.org, "'David S. Miller'" Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 8/21/19 12:42 AM, boojin.kim wrote: > This patch supports crypto information to be maintained via BIO > and passed to the storage driver. > > To do this, 'bi_aux_private', 'REQ_CYPTE' and 'bi_dun' are added > to the block layer. > > 'bi_aux_private' is added for loading additional private information into > BIO. > 'REQ_CRYPT' is added to distinguish that bi_aux_private is being used > for diskcipher. > F2FS among encryption users uses DUN(device unit number) as > the IV(initial vector) for cryptographic operations. > DUN is stored in 'bi_dun' of bi_iter as a specific value for each BIO. > > Before attempting to merge the two BIOs, the operation is also added to > verify that the crypto information contained in two BIOs is consistent. This isn't going to happen. With this, and the inline encryption proposed by Google, we'll bloat the bio even more. At least the Google approach didn't include bio iter changes as well. Please work it out between yourselves so we can have a single, clean abstraction that works for both. -- Jens Axboe _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel