lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Message-Id: <20171011200603.27442-6-jack@suse.cz> Date: Wed, 11 Oct 2017 22:05:49 +0200 From: Jan Kara <jack@...e.cz> To: <linux-fsdevel@...r.kernel.org> Cc: <linux-ext4@...r.kernel.org>, <linux-xfs@...r.kernel.org>, Christoph Hellwig <hch@...radead.org>, Dan Williams <dan.j.williams@...el.com>, Ross Zwisler <ross.zwisler@...ux.intel.com>, Ted Tso <tytso@....edu>, "Darrick J. Wong" <darrick.wong@...cle.com>, Jan Kara <jack@...e.cz> Subject: [PATCH 05/19] dax: Create local variable for VMA in dax_iomap_pte_fault() There are already two users and more are coming. Reviewed-by: Christoph Hellwig <hch@....de> Reviewed-by: Ross Zwisler <ross.zwisler@...ux.intel.com> Signed-off-by: Jan Kara <jack@...e.cz> --- fs/dax.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fs/dax.c b/fs/dax.c index 116eef8d6c69..c09465884bbe 100644 --- a/fs/dax.c +++ b/fs/dax.c @@ -1108,7 +1108,8 @@ static int dax_fault_return(int error) static int dax_iomap_pte_fault(struct vm_fault *vmf, const struct iomap_ops *ops) { - struct address_space *mapping = vmf->vma->vm_file->f_mapping; + struct vm_area_struct *vma = vmf->vma; + struct address_space *mapping = vma->vm_file->f_mapping; struct inode *inode = mapping->host; unsigned long vaddr = vmf->address; loff_t pos = (loff_t)vmf->pgoff << PAGE_SHIFT; @@ -1196,7 +1197,7 @@ static int dax_iomap_pte_fault(struct vm_fault *vmf, case IOMAP_MAPPED: if (iomap.flags & IOMAP_F_NEW) { count_vm_event(PGMAJFAULT); - count_memcg_event_mm(vmf->vma->vm_mm, PGMAJFAULT); + count_memcg_event_mm(vma->vm_mm, PGMAJFAULT); major = VM_FAULT_MAJOR; } error = dax_insert_mapping(vmf, &iomap, pos, entry); -- 2.12.3
Powered by blists - more mailing lists