From: Mikulas Patocka <mpatocka@redhat.com>
To: Christoph Hellwig <hch@infradead.org>
Cc: James Bottomley <James.Bottomley@HansenPartnership.com>,
Jens Axboe <axboe@kernel.dk>,
"Alasdair G. Kergon" <agk@redhat.com>,
Mike Snitzer <msnitzer@redhat.com>,
dm-devel@redhat.com, "David S. Miller" <davem@davemloft.net>,
linux-ide@vger.kernel.org, linux-scsi@vger.kernel.org,
linux-kernel@vger.kernel.org, Neil Brown <neilb@suse.de>,
linux-raid@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH] block devices: validate block device capacity
Date: Mon, 3 Feb 2014 15:22:01 -0500 (EST) [thread overview]
Message-ID: <alpine.LRH.2.02.1402031513070.18926@file01.intranet.prod.int.rdu2.redhat.com> (raw)
In-Reply-To: <20140203081506.GA10961@infradead.org>
On Mon, 3 Feb 2014, Christoph Hellwig wrote:
> On Fri, Jan 31, 2014 at 03:20:17AM -0500, Mikulas Patocka wrote:
> > So if you think you can support 16TiB devices and leave pgoff_t 32-bit,
> > send a patch that does it.
> >
> > Until you make it, you should apply the patch that I sent, that prevents
> > kernel lockups or data corruption when the user uses 16TiB device on
> > 32-bit kernel.
>
> Exactly. I had actually looked into support for > 16TiB devices for
> a NAS use case a while ago, but when explaining the effort involves
> the idea was dropped quickly. The Linux block device is too deeply
> tied to the pagecache to make it easily feasible.
The memory management routines use pgoff_t, so we could define pgoff_t to
be 64-bit type. But there is lib/radix_tree.c that uses unsigned long as
an index into the radix tree - and pgoff_t is cast to unsigned long when
calling the radix_tree routines - so we'd need to change lib/radix_tree to
use pgoff_t.
Then, there may be other places where pgoff_t is cast to unsigned long and
they are not trivial to find (one could enable some extra compiler
warnings about truncating values when casting them, but I suppose, this
would trigger a lot of false positives). This needs some deep review by
people who designed the memory management code.
Mikulas
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
prev parent reply other threads:[~2014-02-03 20:22 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <alpine.LRH.2.02.1401301531040.29912@file01.intranet.prod.int.rdu2.redhat.com>
[not found] ` <1391122163.2181.103.camel@dabdike.int.hansenpartnership.com>
[not found] ` <alpine.LRH.2.02.1401301805590.19506@file01.intranet.prod.int.rdu2.redhat.com>
[not found] ` <1391125027.2181.114.camel@dabdike.int.hansenpartnership.com>
2014-01-31 0:20 ` Mikulas Patocka
2014-01-31 1:43 ` James Bottomley
2014-01-31 2:43 ` Mikulas Patocka
2014-01-31 5:45 ` James Bottomley
2014-01-31 8:20 ` Mikulas Patocka
2014-02-03 8:15 ` Christoph Hellwig
2014-02-03 20:22 ` Mikulas Patocka [this message]
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=alpine.LRH.2.02.1402031513070.18926@file01.intranet.prod.int.rdu2.redhat.com \
--to=mpatocka@redhat.com \
--cc=James.Bottomley@HansenPartnership.com \
--cc=agk@redhat.com \
--cc=axboe@kernel.dk \
--cc=davem@davemloft.net \
--cc=dm-devel@redhat.com \
--cc=hch@infradead.org \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-raid@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=msnitzer@redhat.com \
--cc=neilb@suse.de \
/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