From: Christoph Hellwig <hch@infradead.org>
To: Dennis Tighe <dennis.tighe@gmail.com>
Cc: Namjae Jeon <linkinjeon@kernel.org>,
Hyunchul Lee <hyc.lee@gmail.com>,
ntfs@lists.linux.dev, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] ntfs: mount read-only when mft records are smaller than the device block
Date: Mon, 24 Aug 2026 22:47:20 -0700 [thread overview]
Message-ID: <ao0saL_dQcM35LFU@infradead.org> (raw)
In-Reply-To: <6a8b31d3.6dfd78af.244576.33c7@mx.google.com>
On Sun, Aug 23, 2026 at 10:45:48AM -0700, Dennis Tighe wrote:
> An mft record is written with a single bio of exactly mft_record_size
> bytes. bio_unaligned() rejects a bio whose size is not a multiple of the
> device's logical block size, so on a volume whose mft records are smaller
> than that block no mft record can be written at all.
>
> On 512n and 512e drives this is a non-issue; however, on 4Kn drives when
> the mft record (1k) is smaller than the logical block size (4k) mft
> writes begin to fail. At the same time, other writes that use all 4k
> will succeed leading to a corruption situation.
>
> This is a stopgap change that mounts as read-only. The longer term fix is
> to perform 4k writes on 4Kn devices when writing the mft; however, that's
> more involved.
Between this and your previous patch it is pretty clear that a sector
size > 512 bytes is not supported. So instead of adding predicted
band aids, reject this entirely for now and let someone who has the time
actually understand this for real fix it with a real design test plan
and all the others bits needed.
next prev parent reply other threads:[~2026-08-25 5:47 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-08-23 17:45 Dennis Tighe
2026-08-24 9:37 ` Hyunchul Lee
2026-08-24 14:42 ` [PATCH v2] " Dennis Tighe
2026-08-25 1:30 ` Hyunchul Lee
2026-08-25 5:47 ` Christoph Hellwig [this message]
2026-08-25 7:28 ` [PATCH] " Namjae Jeon
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=ao0saL_dQcM35LFU@infradead.org \
--to=hch@infradead.org \
--cc=dennis.tighe@gmail.com \
--cc=hyc.lee@gmail.com \
--cc=linkinjeon@kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=ntfs@lists.linux.dev \
/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
all inboxes | Powered by JetHome®