Author: hselasky
Date: Sun Feb 25 10:28:06 2018
New Revision: 329963
URL: https://svnweb.freebsd.org/changeset/base/329963

Log:
  MFC r329475:
  Implement get_task_pid() function macro in the LinuxKPI.
  
  Submitted by: Johannes Lundberg <johal...@gmail.com>
  Sponsored by: Mellanox Technologies

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

Modified: stable/11/sys/compat/linuxkpi/common/include/linux/pid.h
==============================================================================
--- stable/11/sys/compat/linuxkpi/common/include/linux/pid.h    Sun Feb 25 
10:26:44 2018        (r329962)
+++ stable/11/sys/compat/linuxkpi/common/include/linux/pid.h    Sun Feb 25 
10:28:06 2018        (r329963)
@@ -58,6 +58,11 @@ enum pid_type {
        __ts;                                   \
 })
 
+#define        get_task_pid(task, type) ({             \
+       CTASSERT((type) == PIDTYPE_PID);        \
+       (task)->task_thread->td_tid;            \
+})
+
 struct task_struct;
 extern struct task_struct *linux_pid_task(pid_t);
 extern struct task_struct *linux_get_pid_task(pid_t);
_______________________________________________
svn-src-all@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"

Reply via email to