All of lore.kernel.org
 help / color / mirror / Atom feed
From: Heikki Krogerus <heikki.krogerus@linux.intel.com>
To: "Shevchenko, Andriy" <andriy.shevchenko@intel.com>
Cc: "rjw@rjwysocki.net" <rjw@rjwysocki.net>,
	"mika.westerberg@linux.intel.com"
	<mika.westerberg@linux.intel.com>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"John.Youn@synopsys.com" <John.Youn@synopsys.com>
Subject: Re: [PATCH 2/2] device property: fix for a case of use-after-free
Date: Fri, 26 Feb 2016 10:04:34 +0200	[thread overview]
Message-ID: <20160226080434.GD29434@kuha.fi.intel.com> (raw)
In-Reply-To: <1456160688.13244.30.camel@intel.com>

On Mon, Feb 22, 2016 at 05:04:04PM +0000, Shevchenko, Andriy wrote:
> Considering this, perhaps better solution is to convert last lines to
> 
> if (!IS_ERR(fwnode) && is_pset_node(fwnode)) {
>   set_secondary_fwnode(dev, NULL);
>   pset_free_set(to_pset_node(fwnode));
> }

After some testing, this seems to work. I'll prepare v2 and use it.

Thanks Andy,

-- 
heikki

  parent reply	other threads:[~2016-02-26  8:04 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-22 14:50 [PATCH 0/2] device property: fix for couple of bugs Heikki Krogerus
2016-02-22 14:50 ` [PATCH 1/2] device property: fwnode->secondary may contain ERR_PTR(-ENODEV) Heikki Krogerus
2016-02-22 14:50 ` [PATCH 2/2] device property: fix for a case of use-after-free Heikki Krogerus
2016-02-22 15:40   ` Andy Shevchenko
2016-02-22 17:04     ` Shevchenko, Andriy
2016-02-23 23:37       ` Rafael J. Wysocki
2016-02-26  8:04       ` Heikki Krogerus [this message]
2016-02-26 10:36         ` Heikki Krogerus
2016-02-23 23:37 ` [PATCH 0/2] device property: fix for couple of bugs Rafael J. Wysocki
2016-02-26  8:02   ` Heikki Krogerus

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=20160226080434.GD29434@kuha.fi.intel.com \
    --to=heikki.krogerus@linux.intel.com \
    --cc=John.Youn@synopsys.com \
    --cc=andriy.shevchenko@intel.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mika.westerberg@linux.intel.com \
    --cc=rjw@rjwysocki.net \
    /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.