Re: Non Preemptive Kernel.

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

 



On Fri, Jun 25, 2004 at 21:31:39 +0530, Dhiman, Gaurav wrote:
> Thanks for the code snippet.
> It really helped in understanding what exactly happens.
> Can you please explain what we are doing in following code:
> 
> void update_process_times(int user_tick)
> {
> ............
> ........
> .......
> 
>   if (p->nice > 0)
>    kstat.per_cpu_nice[cpu] += user_tick;
>   else
>    kstat.per_cpu_user[cpu] += user_tick;
>   kstat.per_cpu_system[cpu] += system;
>  } else if (local_bh_count(cpu) || local_irq_count(cpu) > 1)
>   kstat.per_cpu_system[cpu] += system;
> 
> .......
> .....
> .......
> }
> 
> I think this code is something related to SMP

It's not directly related to SMP. It is written so that it works on both
SMP and UP. And it really is gathering data for ulimit and for
getrusage. It is especialy NOT related to scheduling.

-------------------------------------------------------------------------------
						 Jan 'Bulb' Hudec <bulb@ucw.cz>

Attachment: signature.asc
Description: Digital signature


[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