From: Dave Jiang <dave.jiang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
To: "Theodore Y. Ts'o" <tytso-3s7WtUTddSA@public.gmane.org>
Cc: linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
Matthew Wilcox <mawilcox-0li6OtcxBFHby3iVrkZq2A@public.gmane.org>,
linux-nvdimm-hn68Rpc1hR1g9hUCZPvPmw@public.gmane.org
Subject: Re: Help trying to use /dev/pmem for dax debugging?
Date: Fri, 10 Aug 2018 09:18:11 -0700 [thread overview]
Message-ID: <4222843a-13ea-e88f-ca74-4e3fe53b4105@intel.com> (raw)
In-Reply-To: <20180810025339.GB21087-AKGzg7BKzIDYtjvyW6yDsg@public.gmane.org>
On 08/09/2018 07:53 PM, Theodore Y. Ts'o wrote:
> On Tue, Jul 31, 2018 at 01:27:15PM -0700, Dave Jiang wrote:
>>
>> On 7/31/2018 12:36 PM, Ross Zwisler wrote:
>>> On Mon, Jul 30, 2018 at 07:53:12PM -0400, Theodore Y. Ts'o wrote:
>>>> In newer kernels, it looks like you can't use /dev/pmem0 for DAX
>>>> unless it's marked as being DAX capable. This appears to require
>>>> CONFIG_NVDIMM_PFN. But when I tried to build a kernel with that
>>>> configured, I get the following BUG:
>>>
>>> You're using the memmap kernel command line parameter to reserve normal
>>> memory to be treated as normal memory, but you've also got kernel address
>>> randomization turned on in your kernel config:
>>>
>>> CONFIG_RANDOMIZE_BASE=y
>>> CONFIG_RANDOMIZE_MEMORY=y
>>>
>>> You need to turn these off for the memmap kernel command line parameter, else
>>> the memory we're using could overlap with addresses used for other things.
>>
>> I believe this issue was fixed a while back. Although we probably can see if
>> that is the issue or something else.
>
> I turned off RANDOMIZE_BASE and RANDOMIZE_MEMORY, but that didn't fix
> my problem.
>
> It turns out the problem was KASAN. It looks like using memmap to
> create test /dev/pmemX devices is not compatible with CONFIG_KASAN
> being enabled.
>
> So I have a workaround for now, but it seems this to be a bug in
> KASAN, or at least an unfortunate interaction between KASAN and
> NVDIMM_PFN.
Thanks Ted. I have updated the wiki Ross mentioned to reflect that.
WARNING: multiple messages have this Message-ID (diff)
From: Dave Jiang <dave.jiang@intel.com>
To: "Theodore Y. Ts'o" <tytso@mit.edu>
Cc: linux-ext4@vger.kernel.org,
Matthew Wilcox <mawilcox@microsoft.com>,
linux-nvdimm@lists.01.org
Subject: Re: Help trying to use /dev/pmem for dax debugging?
Date: Fri, 10 Aug 2018 09:18:11 -0700 [thread overview]
Message-ID: <4222843a-13ea-e88f-ca74-4e3fe53b4105@intel.com> (raw)
In-Reply-To: <20180810025339.GB21087@thunk.org>
On 08/09/2018 07:53 PM, Theodore Y. Ts'o wrote:
> On Tue, Jul 31, 2018 at 01:27:15PM -0700, Dave Jiang wrote:
>>
>> On 7/31/2018 12:36 PM, Ross Zwisler wrote:
>>> On Mon, Jul 30, 2018 at 07:53:12PM -0400, Theodore Y. Ts'o wrote:
>>>> In newer kernels, it looks like you can't use /dev/pmem0 for DAX
>>>> unless it's marked as being DAX capable. This appears to require
>>>> CONFIG_NVDIMM_PFN. But when I tried to build a kernel with that
>>>> configured, I get the following BUG:
>>>
>>> You're using the memmap kernel command line parameter to reserve normal
>>> memory to be treated as normal memory, but you've also got kernel address
>>> randomization turned on in your kernel config:
>>>
>>> CONFIG_RANDOMIZE_BASE=y
>>> CONFIG_RANDOMIZE_MEMORY=y
>>>
>>> You need to turn these off for the memmap kernel command line parameter, else
>>> the memory we're using could overlap with addresses used for other things.
>>
>> I believe this issue was fixed a while back. Although we probably can see if
>> that is the issue or something else.
>
> I turned off RANDOMIZE_BASE and RANDOMIZE_MEMORY, but that didn't fix
> my problem.
>
> It turns out the problem was KASAN. It looks like using memmap to
> create test /dev/pmemX devices is not compatible with CONFIG_KASAN
> being enabled.
>
> So I have a workaround for now, but it seems this to be a bug in
> KASAN, or at least an unfortunate interaction between KASAN and
> NVDIMM_PFN.
Thanks Ted. I have updated the wiki Ross mentioned to reflect that.
_______________________________________________
Linux-nvdimm mailing list
Linux-nvdimm@lists.01.org
https://lists.01.org/mailman/listinfo/linux-nvdimm
next prev parent reply other threads:[~2018-08-10 16:18 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-30 23:53 Help trying to use /dev/pmem for dax debugging? Theodore Y. Ts'o
2018-07-30 23:53 ` Theodore Y. Ts'o
[not found] ` <20180730235312.GA5089-AKGzg7BKzIDYtjvyW6yDsg@public.gmane.org>
2018-07-31 19:36 ` Ross Zwisler
2018-07-31 19:36 ` Ross Zwisler
[not found] ` <20180731193642.GA3473-VuQAYsv1563Yd54FQh9/CA@public.gmane.org>
2018-07-31 20:27 ` Dave Jiang
2018-07-31 20:27 ` Dave Jiang
[not found] ` <30247efc-88f8-3e0b-fcd8-83801be5f041-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2018-08-10 2:53 ` Theodore Y. Ts'o
2018-08-10 2:53 ` Theodore Y. Ts'o
[not found] ` <20180810025339.GB21087-AKGzg7BKzIDYtjvyW6yDsg@public.gmane.org>
2018-08-10 16:18 ` Dave Jiang [this message]
2018-08-10 16:18 ` Dave Jiang
[not found] ` <4222843a-13ea-e88f-ca74-4e3fe53b4105-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2018-08-10 17:28 ` Dan Williams
2018-08-10 17:28 ` Dan Williams
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=4222843a-13ea-e88f-ca74-4e3fe53b4105@intel.com \
--to=dave.jiang-ral2jqcrhueavxtiumwx3w@public.gmane.org \
--cc=linux-ext4-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-nvdimm-hn68Rpc1hR1g9hUCZPvPmw@public.gmane.org \
--cc=mawilcox-0li6OtcxBFHby3iVrkZq2A@public.gmane.org \
--cc=tytso-3s7WtUTddSA@public.gmane.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.