public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Alan Cox <alan@lxorguk.ukuu.org.uk>
To: Arjan van de Ven <arjan@infradead.org>
Cc: Matti Linnanvuori <mattilinnanvuori@yahoo.com>,
	linux-kernel@vger.kernel.org
Subject: Re: Do not deprecate binary semaphore or do allow mutex in software interrupt contexts
Date: Tue, 11 Sep 2007 14:56:22 +0100	[thread overview]
Message-ID: <20070911145622.0a37bbda@the-village.bc.nu> (raw)
In-Reply-To: <20070911153628.26ca02bc@laptopd505.fenrus.org>

> to be honest, the scenario describe really smells of broken locking, in
> fact it really sounds like it wants to use spinlocks instead 

For polling and timer based code its often simpler to do

	del_timer_sync(&my_timer);
	FrobStuff
	add_timer(&my_timer);

especially if "FrobStuff" is likely to change when you next need to poll.

And don't forget regular polling is a good way to really annoy laptop
users as it burns power

Alan


  reply	other threads:[~2007-09-11 13:48 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-11 13:20 Do not deprecate binary semaphore or do allow mutex in software interrupt contexts Matti Linnanvuori
2007-09-11 14:36 ` Arjan van de Ven
2007-09-11 13:56   ` Alan Cox [this message]
  -- strict thread matches above, loose matches on Subject: below --
2007-09-11 16:20 Matti Linnanvuori
2007-09-11 16:50 ` Peter Zijlstra
2007-09-11 18:22 ` Arjan van de Ven
2007-09-11 17:29 Matti Linnanvuori
2007-09-11 19:22 ` Arjan van de Ven
2007-09-12  5:39 Matti Linnanvuori

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=20070911145622.0a37bbda@the-village.bc.nu \
    --to=alan@lxorguk.ukuu.org.uk \
    --cc=arjan@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mattilinnanvuori@yahoo.com \
    /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