RE: preemptive kernels and the use of smp_processor_id()

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

 



Hi,

>> So it seems the kernel module I am porting assumed to always run on 
>> the same CPU core once entered kernelspace, but on a preemptive system 
>> you cannot guarantee that.

> Correct.  You probably want to fix the assumption(s) in the kernel module,
> that's in the long term probably easier than trying to make it work otherwise

Uh, are we saying that once a process (say running on core-0) has entered preemptible kernel , there is a chance that suddenly the scheduler might decide it to move to core-1? I though preemptible only means that a process can only be preempted (not moved to another core) under following situations:

1) An interrupt happens (In case of timer, it could put the process back in queue if its time slice expired).
2) The process goes to sleep (can be a result of a call that can sleep).

Can some one shed light on what conditions would a running process be moved to another core?

Thanks,

rajat



_______________________________________________
Kernelnewbies mailing list
Kernelnewbies@xxxxxxxxxxxxxxxxx
http://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies




[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