mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: manomugdha biswas <manomugdhab@yahoo.co.in>
To: gaurav4lkg@gmail.com
Cc: linux-kernel@vger.kernel.org
Subject: Re: how to use wait_event_interruptible_timeout
Date: Tue, 13 Sep 2005 10:44:37 +0100 (BST)	[thread overview]
Message-ID: <20050913094437.3252.qmail@web8501.mail.in.yahoo.com> (raw)
In-Reply-To: <1e33f571050913023042b4c109@mail.gmail.com>

Hi, 
I am using the this function in the following way:

wait_queue_head_t     VNICClientWQHead;

/* Initialise the wait q head */
init_waitqueue_head(&VNICClientWQHead);

init_waitqueue_entry(&waitQ, current);
add_wait_queue(sock->sk->sk_sleep, waitQ));

/*
 my code, it reads data from socket
*/

wait_event_interruptible_timeout(VNICClientWQHead, 0,
HZ * 100000);

if no activity is to be done then this process sleeps.
When some data comes in socket i.e socket becomes
readable this process should wake up. In kernel 2.4 it
was working fine using interruptible_sleep_on_time().
But it is not working in kernel 2.6 even if data
arrives in socket! The sleeping process never wake up.
Could you please tell me what is the problem?

Regards,
Mano


--- Gaurav Dhiman <gaurav4lkg@gmail.com> wrote:

> On 9/13/05, manomugdha biswas
> <manomugdhab@yahoo.co.in> wrote:
> > Hi,
> > I was using interruptible_sleep_on_timeout() in
> kernel
> > 2.4. In kernel 2.6 I have use
> > wait_event_interruptible_timeout. But it is now
> > working!!. interruptible_sleep_on_timeout() was
> > working fine. Could anyone please help me in this
> > regard.
> 
> What problem are you facing with
> wait_event_interruptible_timeout() in 2.6
> Elaborate more on it.
> 
> -Gaurav
> 
> > Regards,
> > Mano
> > 
> > Manomugdha Biswas
> > 
> > 
> > 
> >
>
__________________________________________________________
> > Yahoo! India Matrimony: Find your partner now. Go
> to http://yahoo.shaadi.com
> > -
> > To unsubscribe from this list: send the line
> "unsubscribe linux-kernel" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at 
> http://vger.kernel.org/majordomo-info.html
> > Please read the FAQ at  http://www.tux.org/lkml/
> > 
> 
> 
> -- 
> - Gaurav
> my blog: http://lkdp.blogspot.com/
> --
> -
> To unsubscribe from this list: send the line
> "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at 
> http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/
> 


Manomugdha Biswas


		
__________________________________________________________ 
Yahoo! India Matrimony: Find your partner now. Go to http://yahoo.shaadi.com

  reply	other threads:[~2005-09-13  9:44 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-09-13  9:20 manomugdha biswas
2005-09-13  9:30 ` Gaurav Dhiman
2005-09-13  9:44   ` manomugdha biswas [this message]
2005-09-13 11:11     ` Gaurav Dhiman
2005-09-13 13:49       ` manomugdha biswas

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050913094437.3252.qmail@web8501.mail.in.yahoo.com \
    --to=manomugdhab@yahoo.co.in \
    --cc=gaurav4lkg@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®