Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 13 Nov 2020 13:38:08 +0000 (UTC)
From:      Mateusz Guzik <mjg@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-12@freebsd.org
Subject:   svn commit: r367638 - stable/12/sys/kern
Message-ID:  <202011131338.0ADDc82O034257@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: mjg
Date: Fri Nov 13 13:38:08 2020
New Revision: 367638
URL: https://svnweb.freebsd.org/changeset/base/367638

Log:
  MFC r367572:
  
      Allow rtprio_thread to operate on threads of any process

Modified:
  stable/12/sys/kern/kern_resource.c
Directory Properties:
  stable/12/   (props changed)

Modified: stable/12/sys/kern/kern_resource.c
==============================================================================
--- stable/12/sys/kern/kern_resource.c	Fri Nov 13 13:36:46 2020	(r367637)
+++ stable/12/sys/kern/kern_resource.c	Fri Nov 13 13:38:08 2020	(r367638)
@@ -303,8 +303,7 @@ sys_rtprio_thread(struct thread *td, struct rtprio_thr
 		td1 = td;
 		PROC_LOCK(p);
 	} else {
-		/* Only look up thread in current process */
-		td1 = tdfind(uap->lwpid, curproc->p_pid);
+		td1 = tdfind(uap->lwpid, -1);
 		if (td1 == NULL)
 			return (ESRCH);
 		p = td1->td_proc;



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