linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Chandan Rajendra <chandan@linux.vnet.ibm.com>
To: linux-ext4@vger.kernel.org
Cc: "Theodore Ts'o" <tytso@mit.edu>,
	Michael Halcrow <mhalcrow@google.com>,
	linux-fsdevel@vger.kernel.org
Subject: Bio: Determining encrypted vs plain content
Date: Wed, 13 Sep 2017 15:33:33 +0530	[thread overview]
Message-ID: <2507710.a1WupZru2S@localhost.localdomain> (raw)

Hi,

I am trying to get encryption to work on block size < page size scenario
(e.g. 4k block size on ppc64's 64k page size).

One of the last scenarios that I am working on is to decrypt a page whose
blocks are not contiguously stored on the underlying disk. 

The code assumes that bio's pages are supposed to be decrypted if 
bio-b_private has a non-zero value (See the definition of 
ext4_bio_encrypted()).

Instead of that, why can't the code extract the first page from the first bio
vector of the bio and then use ext4_encrypted_inode(page->mapping->host) to
determine if bio's pages are supposed to contain encrypted data? Was there a
specific reason to not use ext4_encrypted_inode()?

-- 
chandan

                 reply	other threads:[~2017-09-13 10:02 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=2507710.a1WupZru2S@localhost.localdomain \
    --to=chandan@linux.vnet.ibm.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=mhalcrow@google.com \
    --cc=tytso@mit.edu \
    /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).