Re: nanosleep

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

 



On 06/07/07, Bhanu Kalyan Chetlapalli <chbhanukalyan@xxxxxxxxx> wrote:
On 7/6/07, hari krishna angadi <reachtohari@xxxxxxxxx> wrote:
> hi all,
>          I am porting  from 2.4 to 2.6, There is a  problem,  a user space
> code which should be pushed to kernel space(driver module). In the user
> program there is a  nanosleep()  function i need to know the respective
> kernel routine for nanosleep.

kernel does not have something like sleep, it just schedules a new
process in that time.

Not true, you have udelay(), ndelay(), mdelay(), msleep(), ssleep()
and the *_interruptible() versions...

So you do have functions to delay or sleep in the kernel.

And if you don't want the kernel to preempt you you can disable
preemption while doing your sleeping...  not very well behaved kernel
code, but you can do it...

--
Jesper Juhl <jesper.juhl@xxxxxxxxx>
Don't top-post  http://www.catb.org/~esr/jargon/html/T/top-post.html
Plain text mails only, please      http://www.expita.com/nomime.html

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[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