Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1323157 > unrolled thread

Re: [PATCH v1 1/1] PM: Avoid false-positive warnings in dev_pm_domain_set()

Started byAndy Shevchenko <andriy.shevchenko@linux.intel.com>
First post2016-02-01 15:20 +0100
Last post2016-02-01 15:20 +0100
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH v1 1/1] PM: Avoid false-positive warnings in  dev_pm_domain_set() Andy Shevchenko <andriy.shevchenko@linux.intel.com> - 2016-02-01 15:20 +0100

#1323157 — Re: [PATCH v1 1/1] PM: Avoid false-positive warnings in dev_pm_domain_set()

FromAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Date2016-02-01 15:20 +0100
SubjectRe: [PATCH v1 1/1] PM: Avoid false-positive warnings in dev_pm_domain_set()
Message-ID<qXnuG-40K-11@gated-at.bofh.it>
On Mon, 2016-02-01 at 16:12 +0200, Andy Shevchenko wrote:
> From: "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
> 
> There is a WARN_ON() in dev_pm_domain_set() that triggers on attempts
> to set the pm_domain pointer for devices with a driver bound.
> 
> However, that WARN_ON() triggers on attempts to clear the pointer
> too and the test it uses is based on checking the device's
> p->knode_driver pointer which still is set when the device bus
> type's/driver's ->remove callback has been executed.  This
> leads to false-positive warnings when bus type code calls
> dev_pm_domain_set() to clear the pm_domain pointer after
> invoking the driver's ->remove() callback.
> 
> To avoid those false-positives, make dev_pm_domain_set() check
> if the pointer passed to it is NULL and skip the warning in
> that case.
> 
> Fixes: 989561de9b51 (PM / Domains: add setter for dev.pm_domain)
> Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>

Oops, it is a wrong one, should be previous.

Btw, this one has been tested and went fine!

-- 
Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Intel Finland Oy

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web