LinuxQuestions.org
LinuxAnswers - the LQ Linux tutorial section.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
LinkBack Search this Thread
Old 11-02-2006, 08:51 AM   #1
asahlot
Member
 
Registered: Sep 2005
Location: india
Distribution: Fedora Core 2
Posts: 62

Rep: Reputation: 15
how can I put the CPU in sleep mode?


Hi all
I want to put CPU in sleep mode that is I want to execute only Idle process on CPU for continuous 5 Sec. So I think that if i use msleep (5000) in kernel version 2.6 then I can achieve my aim. ( I dont know if I am wrong). But as in kernel 2.4 we dont have msleep () function, how can we make CPU to execute Idle task for 5 secs.?

Do we have some way of scheduling IDLE task for some secs??
Please help me in this regard. its very very urgent for me.
Thanks in advance.
Arvind
 
Old 11-03-2006, 02:00 AM   #2
J.W.
LQ Veteran
 
Registered: Mar 2003
Location: Milwaukee, WI
Distribution: Mint
Posts: 6,642

Rep: Reputation: 69
Just use the sleep command in your script
Code:
man sleep
 
Old 11-03-2006, 10:23 AM   #3
asahlot
Member
 
Registered: Sep 2005
Location: india
Distribution: Fedora Core 2
Posts: 62

Original Poster
Rep: Reputation: 15
@J.W. Thanks for the reply.
You are right. But I need to do that in my module and not in script.
Can you please tell me in that case.
Thanks in advance.
Arvind
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
LXer: Put your laptop to sleep LXer Syndicated Linux News 0 08-02-2006 01:24 AM
how to use an IDE disk after put to sleep with hdparm -Y /dev/hdb qwijibow Linux - Hardware 0 08-24-2004 01:45 PM
CPU on 100% usage after sleep... Jestrik Linux - General 8 12-22-2003 09:18 AM
Put a hd to sleep dr_van_nostrand Linux - Hardware 1 09-12-2003 07:29 PM
Sleep mode mrsolo Linux - Hardware 4 11-26-2002 08:05 PM


All times are GMT -5. The time now is 05:17 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration