Re: How differentiate between kernel threads and Per-CPU thresds

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On 6/25/07, Mulyadi Santosa <mulyadi.santosa@xxxxxxxxx> wrote:
Hi...


>  I have task_struct of one process and I need to find out whether that
> process is a kernel thread(like pdflush etc) or Per-CPU kernel thread
> like(like migration/0 or migration/1). Is there any way to do that??

I think you can check the atrributes in task_struct that leads to
affinity setting. Another way is by parsing "comm" attribute and see
if it contains numbers (0,1, and so on) :)



I thought of differentiating using affinity setting,but one can set the affinity for kerel threads too(right??), then how can I differentiate b/w kernel threads and per-cpu threads.
 

regards,

Mulyadi



--
============================
Thanks
  Srinivas DS
===========================

[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux