Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Oct 2007 13:37:53 -0700
From:      Julian Elischer <julian@elischer.org>
To:        =?UTF-8?B?RGFnLUVybGluZyBTbcO4cmdyYXY=?= <des@des.no>
Cc:        freebsd-hackers@freebsd.org, Sergey Matveychuk <sem@FreeBSD.org>
Subject:   Re: How to get a kthread ID?
Message-ID:  <4720FEA1.2040505@elischer.org>
In-Reply-To: <867ilbtsrc.fsf@ds4.des.no>
References:  <47205B91.80408@FreeBSD.org> <867ilbtsrc.fsf@ds4.des.no>

next in thread | previous in thread | raw e-mail | index | archive | help
Dag-Erling Smørgrav wrote:
> Sergey Matveychuk <sem@FreeBSD.org> writes:
>> Is there a possibility to get a kthread ID inside a kthread?
>> Just like pthread_self(3).
> 
> curthread?

well that's a thread pointer, but you are I guess correct because from there
you can get to curthread->td_tid which is the thread ID.

> 
> DES




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