Skip to content

Commit

Permalink
mm, futex2: fix shared futex2 pgoff on shmem huge page
Browse files Browse the repository at this point in the history
Signed-off-by: Alexandre Frade <kernel@xanmod.org>
  • Loading branch information
xanmod committed Jun 30, 2021
1 parent 484fdcc commit aba4b73
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions kernel/futex2.c
Expand Up @@ -14,7 +14,6 @@
*/

#include <linux/freezer.h>
#include <linux/hugetlb.h>
#include <linux/jhash.h>
#include <linux/memblock.h>
#include <linux/pagemap.h>
Expand Down Expand Up @@ -310,7 +309,7 @@ static int futex_get_shared_key(uintptr_t address, struct mm_struct *mm,
}

key->pointer = futex_get_inode_uuid(inode);
key->index = (unsigned long)basepage_index(tail);
key->index = (unsigned long)page_to_pgoff(tail);
key->offset |= FUT_OFF_INODE;

rcu_read_unlock();
Expand Down

0 comments on commit aba4b73

Please sign in to comment.