[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-07-24 Thread Brad Figg
** Tags added: cscc -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with dax To manage notifications about this bug go to:

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-03-05 Thread Launchpad Bug Tracker
This bug was fixed in the package linux - 4.15.0-46.49 --- linux (4.15.0-46.49) bionic; urgency=medium * linux: 4.15.0-46.49 -proposed tracker (LP: #1814726) * mprotect fails on ext4 with dax (LP: #1799237) - x86/speculation/l1tf: Exempt zeroed PTEs from inversion *

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-02-17 Thread Christian Priebe
I have not had a chance to try and reproduce the issue with the example mentioned in this bug report but I have been able to verify that the kernel in bionic-proposed fixes the problem I have reported in the following bug report that has been rightfully marked as a duplicate:

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-02-15 Thread Brad Figg
This bug is awaiting verification that the kernel in -proposed solves the problem. Please test the kernel and update this bug with the results. If the problem is solved, change the tag 'verification-needed- bionic' to 'verification-done-bionic'. If the problem still exists, change the tag

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-02-05 Thread Kleber Sacilotto de Souza
Hi, I have followed the steps from comment #27 and I was able to reproduce the issue with bionic kernel 4.15.0-44-generic. I applied the suggested fix (f19f5c49bbc3 x86/speculation/l1tf: Exempt zeroed PTEs from inversion) and confirmed that it fixes the issue. An SRU request has been sent with

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-02-05 Thread Kleber Sacilotto de Souza
** Changed in: linux (Ubuntu) Status: Confirmed => Invalid -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with dax To manage notifications about this

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-01-25 Thread Christian Priebe
I missed this report when I submitted my own report yesterday (https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1813179). In my case there is no workaround, so I am hoping this can be backported. It is a one-line fix. -- You received this bug notification because you are a member of Ubuntu

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-01-21 Thread Joseph Salisbury via ubuntu-bugs
** Changed in: linux (Ubuntu) Assignee: Joseph Salisbury (jsalisbury) => (unassigned) ** Changed in: linux (Ubuntu Bionic) Assignee: Joseph Salisbury (jsalisbury) => (unassigned) -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to

[Bug 1799237] Re: mprotect fails on ext4 with dax

2019-01-21 Thread Igor Chorazewicz
The problem is still present on kernel 4.15.0-43. Do you have any plans to fix that? -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with dax To manage

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-12-12 Thread Igor Chorazewicz
I performed bisect on my own and it seems that following commit causes the problem: 1920d4a1d4ff27ebfd34a99eca67c3c470c8c524 (x86/speculation/l1tf: Invert all not present mappings). In upstream kernel there is a commit fixing this: f19f5c49bbc3ffcc9126cc245fc1b24cc29f4a37 The mprotect issue is

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-12-03 Thread Joseph Salisbury
I started a kernel bisect between Ubuntu 4.15.0-20 and Ubuntu 4.15.0-34. The kernel bisect will require testing of about 7-10 test kernels. I built the first test kernel, up to the following commit: 9dcfef9fe59a2b4931f58b18fba731d00a4531bd The test kernel can be downloaded from:

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-11-30 Thread Marcin Ślusarz
To summarize: 4.15.0-20 is the last kernel where mprotect works, all kernels between 4.15.0-20 and 4.15.0-34 are not testable, 4.15.0-34 is the first kernel that boots correctly and mprotect fails. You have a test program, instructions how to run it and here's a guide how to set up pmem

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-11-19 Thread Igor Chorazewicz
When I install kernel from package I have some problems with pmem emulation and I can't really test this. Here is a simple script which can be used to reproduce the problem (assuming you have pmem emulation, e.g. using memmap and ndctl installed): sudo umount /dev/pmem0 sudo ndctl

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-11-14 Thread Joseph Salisbury
We can perform a kernel bisect, once we narrow down that last good version and first bad one. Can you test 4.15.0-25? It can be downloaded from: https://launchpad.net/~canonical-kernel- team/+archive/ubuntu/ppa/+build/15074499 -- You received this bug notification because you are a member of

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-11-02 Thread Igor Chorazewicz
Eerything I described in previous comment was observed on Ubuntu kernel (4.15.0-34). It worked fine on upstream and on ubuntu 4.15.0-20 so we can still consider this a regression. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu.

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-11-01 Thread Joseph Salisbury
Is this the case with all kernel versions, or can we still consider this a regression in the kernel? -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with dax To

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-30 Thread Igor Chorazewicz
It turns out that this issue is only present for certain mapping lengths. If I run the program, which I attached to the bug report, with size>=2M, mprotect succeeds. I have also tested this on device dax, and the results depend on alignment. For 2M alignment, everything works fine, for 4k

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-30 Thread Igor Chorazewicz
I have tested the following upstream kernels and mprotect works fine on all of them: 4.15.17-041517-generic 4.15.18-041518-generic 4.19.0-041900-generic -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu.

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-25 Thread Joseph Salisbury
I'd like to perform a bisect to figure out what commit caused this regression. We need to identify the earliest kernel where the issue started happening as well as the last kernel that did not have this issue. Can you test the following kernels and report back? Ubuntu 4.15.0-20 was based on the

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-25 Thread Igor Chorazewicz
This bug was not present in the following kernel: 4.15.0-20-generic -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with dax To manage notifications about this

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-25 Thread Joseph Salisbury
Did this issue start happening after an update/upgrade? Was there a prior kernel version where you were not having this particular problem? If it is a regression, we can perform a kernel bisect to narrow down which commit introduced it. Also, it might be good to test the latest mainline kernel

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-25 Thread Joseph Salisbury
The latest mainline kernel is available from: http://kernel.ubuntu.com/~kernel-ppa/mainline/v4.19 Some documentation on it is here: https://wiki.ubuntu.com/KernelMainlineBuilds -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu.

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-25 Thread Robie Basak
Thanks. If the conclusion is that there's no action needed for pmdk, I think the appropriate status for the pmdk task is Invalid - even though pmdk use is affected. We wouldn't for example add a task for every package if a kernel bug were to cause boot to fail, even though all packages would be

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-24 Thread Marcin Ślusarz
This is purely kernel issue. It can be worked around in PMDK by code change, as those mprotects are only safety precautions, but I really wouldn't want to do this upstream. -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu.

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-24 Thread Andreas Hasenack
Is there something to be done in the user space pmdk component for this bug, or is it purely a kernel issue? -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-24 Thread Launchpad Bug Tracker
Status changed to 'Confirmed' because the bug affects multiple users. ** Changed in: pmdk (Ubuntu) Status: New => Confirmed -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title:

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-24 Thread dawid
** Description changed: I have a file located on ext4 mounted with "dax". When I call mmap on that file with protection flag different than PROT_NONE and pass the returned address to mprotect(..., PROT_NONE) it fails with: mprotect: Permission denied This bug affects PMDK

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-24 Thread Marcin Ślusarz
** Also affects: pmdk (Ubuntu) Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with dax To manage notifications

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-24 Thread Launchpad Bug Tracker
Status changed to 'Confirmed' because the bug affects multiple users. ** Changed in: ubuntu Status: New => Confirmed -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-23 Thread Igor Chorazewicz
apport information ** Tags added: apport-collected ** Description changed: I have a file located on ext4 mounted with "dax". When I call mmap on that file with protection flag different than PROT_NONE and pass the returned address to mprotect(..., PROT_NONE) it fails with: mprotect:

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-22 Thread Andreas Hasenack
** Also affects: linux (Ubuntu) Importance: Undecided Status: New -- You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. https://bugs.launchpad.net/bugs/1799237 Title: mprotect fails on ext4 with dax To manage notifications

[Bug 1799237] Re: mprotect fails on ext4 with dax

2018-10-22 Thread Igor
** Description changed: - I have a file located on ext4 mounted with "dax". When I call mmap on that file with protection flag different than PROT_NONE - and pass the returned address to mprotect(..., PROT_NONE) it fails with: + I have a file located on ext4 mounted with "dax". When I call mmap