From: Kevin Hilman <khilman@deeprootsystems.com>
To: Nishanth Menon <nm@ti.com>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>,
lkml <linux-kernel@vger.kernel.org>,
linux-pm <linux-pm@lists.linux-foundation.org>,
l-o <linux-omap@vger.kernel.org>,
l-a <linux-arm-kernel@lists.infradead.org>,
linux-doc <linux-doc@vger.kernel.org>
Subject: Re: [PATCH v3] power: introduce library for device-specific OPPs
Date: Thu, 23 Sep 2010 07:39:33 -0700 [thread overview]
Message-ID: <871v8k7cd6.fsf@deeprootsystems.com> (raw)
In-Reply-To: <4C9A9F84.7000104@ti.com> (Nishanth Menon's message of "Wed, 22 Sep 2010 19:29:56 -0500")
Nishanth Menon <nm@ti.com> writes:
> Rafael J. Wysocki had written, on 09/22/2010 07:03 PM, the following:
>> [Trimming the CC list slightly.]
> [...]
>
>> ...
>>
>> First, thanks for addressing the previous comments, things look much better
>> now. In particular the documentation has been improved a lot in my view.
> Thanks for the excellent reviews :)
>
> [...]
>
>>> +
>>> +WARNING on OPP List Modification Vs Query operations:
>>> +----------------------------------------------------
>>> +The OPP layer's query functions are expected to be used in multiple contexts
>>> +(including calls from interrupt locked context) based on SoC framework
>>> +implementation. Only OPP modification functions are guaranteed exclusivity by
>>> +the OPP library. Exclusivity between query functions and modification functions
>>> +should be handled by the users such as the SoC framework appropriately; else,
>>> +there is a risk for the query functions to retrieve stale data.
>>
>> Well, this sounds like a good use case for RCU.
> Kevin did point out rwlock but am I confusing with
> http://lwn.net/Articles/364583/
> If I get the message right, rwlock is more or less on it's way out?
RCU is different from the reader-writer locks that are on their way out.
Let's think about RCU a little more and see if it might be worth using.
As these APIs are infrequencly accessed, I'm thinking a single spinlock
to protect the whole list from concurrent access/modification is
sufficient.
Kevin
next prev parent reply other threads:[~2010-09-23 14:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <[PATCH] opp: introduce library for device-specific OPPs>
2010-09-22 21:47 ` [PATCH v3] power: introduce library for device-specific OPPs Nishanth Menon
2010-09-23 0:03 ` Rafael J. Wysocki
2010-09-23 0:29 ` Nishanth Menon
2010-09-23 14:39 ` Kevin Hilman [this message]
2010-09-23 11:30 ` Linus Walleij
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=871v8k7cd6.fsf@deeprootsystems.com \
--to=khilman@deeprootsystems.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-doc@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-omap@vger.kernel.org \
--cc=linux-pm@lists.linux-foundation.org \
--cc=nm@ti.com \
--cc=rjw@sisk.pl \
/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