Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 25 Feb 2018 10:24:59 +0000 (UTC)
From:      Hans Petter Selasky <hselasky@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   svn commit: r329960 - stable/11/sys/compat/linuxkpi/common/include/linux
Message-ID:  <201802251024.w1PAOxiO012914@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: hselasky
Date: Sun Feb 25 10:24:59 2018
New Revision: 329960
URL: https://svnweb.freebsd.org/changeset/base/329960

Log:
  MFC r329467:
  Add support for mmgrab() function in the LinuxKPI.
  
  Submitted by:	Johannes Lundberg <johalun0@gmail.com>
  Sponsored by:	Mellanox Technologies

Modified:
  stable/11/sys/compat/linuxkpi/common/include/linux/mm_types.h
Directory Properties:
  stable/11/   (props changed)

Modified: stable/11/sys/compat/linuxkpi/common/include/linux/mm_types.h
==============================================================================
--- stable/11/sys/compat/linuxkpi/common/include/linux/mm_types.h	Sun Feb 25 10:24:08 2018	(r329959)
+++ stable/11/sys/compat/linuxkpi/common/include/linux/mm_types.h	Sun Feb 25 10:24:59 2018	(r329960)
@@ -62,6 +62,12 @@ mmput(struct mm_struct *mm)
 		mmdrop(mm);
 }
 
+static inline void
+mmgrab(struct mm_struct *mm)
+{
+	atomic_inc(&mm->mm_count);
+}
+
 extern struct mm_struct *linux_get_task_mm(struct task_struct *);
 #define	get_task_mm(task) linux_get_task_mm(task)
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201802251024.w1PAOxiO012914>