All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jean Pihet <jean.pihet@newoldbits.com>
To: Todd Poynor <toddpoynor@google.com>
Cc: "Rafael J. Wysocki" <rjw@sisk.pl>, Paul Walmsley <paul@pwsan.com>,
	Kevin Hilman <khilman@ti.com>,
	Magnus Damm <magnus.damm@gmail.com>,
	Linux PM mailing list <linux-pm@lists.linux-foundation.org>,
	linux-omap@vger.kernel.org, markgross@thegnar.org,
	broonie@opensource.wolfsonmicro.com, Jean Pihet <j-pihet@ti.com>
Subject: Re: [PATCH 08/13] OMAP2+: powerdomain: control power domains next state
Date: Thu, 11 Aug 2011 17:09:59 +0200	[thread overview]
Message-ID: <CAORVsuWHc=ybjTAXe7=Dqj4Pnme6q29eqN0t3AHVkZE5CL+RpA@mail.gmail.com> (raw)
In-Reply-To: <20110729180047.GA14228@google.com>

Hi Todd,

On Fri, Jul 29, 2011 at 8:00 PM, Todd Poynor <toddpoynor@google.com> wrote:
> On Fri, Jul 29, 2011 at 10:47:43AM +0200, Jean Pihet wrote:
>> On Fri, Jul 29, 2011 at 9:59 AM, Todd Poynor <toddpoynor@google.com> wrote:
> ...
>> > All min_latency != PM_QOS_DEV_LAT_DEFAULT_VALUE paths need
>> > free_new_user = 1.
>> free_new_user = 1 is only needed if no existing constraint has been
>> found, i.e. user stays at NULL. This is implemented in the check for
>> an existing constraint (plist_for_each_entry(...)).
>
> Oops, I meant to say it applies in all cases where min_latency ==
> PM_QOS_DEV_LAT_DEFAULT_VALUE, since the new node is only used for
> adding a constraint (and no existing constraint found).  I'd suggest
> something like:
>
>        if (min_latency != PM_QOS_DEV_LAT_DEFAULT_VALUE) {
>                new_user = kzalloc(sizeof(struct pwrdm_wkup_constraints_entry),
>                        GFP_KERNEL);
>                <check NULL return>
>                free_new_user = 1;
>        }
>
> and then set free_new_user = 0 only if no existing constraint is found
> for the add case.  Because it's easy to miss cases where the
> allocated memory needs to be freed when that's not the default, and you
> might as well skip the allocate on a constraint removal.  Pretty minor
> point, though.

This has been addressed in the latest patch set (v4).

Regards,
Jean

>
>
> Todd
>
--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

  reply	other threads:[~2011-08-11 15:10 UTC|newest]

Thread overview: 78+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-28  8:30 [RFC/PATCH v3 00/13] PM QoS: add a per-device latency constraints class jean.pihet
2011-07-28  8:30 ` [PATCH 01/13] PM: QoS: rename pm_qos_params files to pm_qos jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-29 21:57   ` Rafael J. Wysocki
2011-08-02  9:31     ` Jean Pihet
2011-08-02  9:47       ` Rafael J. Wysocki
2011-08-02  9:47       ` Rafael J. Wysocki
2011-07-28  8:30 ` [PATCH 02/13] PM: add a per-device wake-up latency constraints plist jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-29 21:58   ` Rafael J. Wysocki
2011-07-29 21:58   ` Rafael J. Wysocki
2011-07-28  8:30 ` [PATCH 03/13] PM: QoS: extend the in-kernel API with per-device latency constraints jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-29 22:55   ` Rafael J. Wysocki
2011-07-29 22:55   ` Rafael J. Wysocki
2011-08-02  9:41     ` Jean Pihet
2011-08-02 21:02       ` Rafael J. Wysocki
2011-08-02 21:02       ` Rafael J. Wysocki
2011-08-02  9:41     ` Jean Pihet
2011-08-02 18:01   ` Kevin Hilman
2011-08-02 18:01   ` Kevin Hilman
2011-07-28  8:30 ` [PATCH 04/13] PM: QoS: implement the " jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-30 22:30   ` Rafael J. Wysocki
2011-08-02 10:05     ` Jean Pihet
2011-08-02 21:13       ` Rafael J. Wysocki
2011-08-02 21:13       ` Rafael J. Wysocki
2011-08-02 10:05     ` Jean Pihet
2011-07-30 22:30   ` Rafael J. Wysocki
2011-07-28  8:30 ` [PATCH 05/13] PM: QoS: support the dynamic insertion and removal of devices jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-30 22:38   ` Rafael J. Wysocki
2011-07-30 22:38   ` Rafael J. Wysocki
2011-08-02 10:07     ` Jean Pihet
2011-08-02 10:07     ` Jean Pihet
2011-07-28  8:30 ` [PATCH 06/13] OMAP PM: create a PM layer plugin for per-device constraints jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-28  8:30 ` [PATCH 07/13] OMAP PM: early init of the pwrdms states jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-29  8:08   ` Todd Poynor
2011-07-29  8:50     ` Jean Pihet
2011-07-29  8:50     ` Jean Pihet
2011-08-02  8:57       ` Jean Pihet
2011-08-02  8:57       ` Jean Pihet
2011-08-11 15:12         ` Jean Pihet
2011-08-11 15:12         ` Jean Pihet
2011-07-29  8:08   ` Todd Poynor
2011-07-28  8:30 ` [PATCH 08/13] OMAP2+: powerdomain: control power domains next state jean.pihet
2011-07-29  7:59   ` Todd Poynor
2011-07-29  7:59   ` Todd Poynor
2011-07-29  8:47     ` Jean Pihet
2011-07-29  8:47     ` Jean Pihet
2011-07-29 18:00       ` Todd Poynor
2011-07-29 18:00       ` Todd Poynor
2011-08-11 15:09         ` Jean Pihet [this message]
2011-08-11 15:09         ` Jean Pihet
2011-07-28  8:30 ` jean.pihet
2011-07-28  8:30 ` [PATCH 09/13] OMAP3: powerdomain data: add wake-up latency figures jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-28  8:30 ` [PATCH 10/13] OMAP4: " jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-28  8:30 ` [PATCH 11/13] OMAP2+: omap_hwmod: manage the wake-up latency constraints jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-28  8:30 ` [PATCH 12/13] OMAP: PM CONSTRAINTS: implement the devices " jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-28  8:30 ` [PATCH 13/13] OMAP2+: cpuidle only influences the MPU state jean.pihet
2011-07-28  8:30 ` jean.pihet
2011-07-28 13:14 ` [RFC/PATCH v3 00/13] PM QoS: add a per-device latency constraints class mark gross
2011-07-29  8:37   ` Jean Pihet
2011-07-29  8:37   ` Jean Pihet
2011-07-29 14:24     ` mark gross
2011-07-29 14:24     ` mark gross
2011-07-29 21:46       ` Rafael J. Wysocki
2011-07-31 17:38         ` mark gross
2011-07-31 17:38         ` [linux-pm] " mark gross
2011-07-29 21:46       ` Rafael J. Wysocki
2011-07-29 21:25 ` Rafael J. Wysocki
2011-07-29 21:25 ` Rafael J. Wysocki

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='CAORVsuWHc=ybjTAXe7=Dqj4Pnme6q29eqN0t3AHVkZE5CL+RpA@mail.gmail.com' \
    --to=jean.pihet@newoldbits.com \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=j-pihet@ti.com \
    --cc=khilman@ti.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=linux-pm@lists.linux-foundation.org \
    --cc=magnus.damm@gmail.com \
    --cc=markgross@thegnar.org \
    --cc=paul@pwsan.com \
    --cc=rjw@sisk.pl \
    --cc=toddpoynor@google.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.