From: Pantelis Antoniou <panto@antoniou-consulting.com>
To: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: linux-kernel@vger.kernel.org, Matt Porter <mporter@ti.com>,
Russ Dill <Russ.Dill@ti.com>,
Koen Kooi <koen@dominion.thruhere.net>
Subject: [PATCH] Link platform device resources properly.
Date: Thu, 17 Jan 2013 19:26:36 +0200 [thread overview]
Message-ID: <1358443596-30631-1-git-send-email-panto@antoniou-consulting.com> (raw)
The resources of the platform devices created by the OF core were
not properly linked. Make sure that they are, so that we don't get
any crashes when trying to remove the device.
Signed-off-by: Pantelis Antoniou <panto@antoniou-consulting.com>
---
drivers/of/device.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/of/device.c b/drivers/of/device.c
index 4c74e4f..d75fcaf 100644
--- a/drivers/of/device.c
+++ b/drivers/of/device.c
@@ -62,6 +62,9 @@ int of_device_add(struct platform_device *ofdev)
if (!ofdev->dev.parent)
set_dev_node(&ofdev->dev, of_node_to_nid(ofdev->dev.of_node));
+ /* make sure we add the resources to the appropriate lists */
+ platform_device_link_resources(ofdev);
+
return device_add(&ofdev->dev);
}
--
1.7.12
next reply other threads:[~2013-01-17 17:26 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-17 17:26 Pantelis Antoniou [this message]
2013-02-08 22:03 ` Grant Likely
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=1358443596-30631-1-git-send-email-panto@antoniou-consulting.com \
--to=panto@antoniou-consulting.com \
--cc=Russ.Dill@ti.com \
--cc=gregkh@linuxfoundation.org \
--cc=koen@dominion.thruhere.net \
--cc=linux-kernel@vger.kernel.org \
--cc=mporter@ti.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
all inboxes | Powered by JetHome®