From: Vitaliy Ivanov <vitalivanov@gmail.com>
To: linux-kernel@vger.kernel.org, devzero@web.de, jsun@junsun.net,
dwmw2@infradead.org
Subject: [PATCH] Adding dummy release functions to avoid warnings.
Date: Wed, 16 Apr 2008 03:34:16 +0300 [thread overview]
Message-ID: <1208306056.15140.13.camel@pcvitaliy> (raw)
Subject: [PATCH] Adding dummy release functions to avoid warnings.
From: Vitaliy Ivanov <vitalivanov@gmail.com>
Trivial fix for #9690.
Added simple release functions that doing nothing.
Not sure whether we can leave it as is or to rework using platform_device helpers like platform_device_alloc.
This approach is used in many drivers.
Signed-off-by: Vitaliy Ivanov <vitalivanov@gmail.com>
--
drivers/mtd/maps/physmap.c | 6 ++++++
drivers/video/hgafb.c | 10 +++++++++-
2 files changed, 15 insertions(+), 1 deletions(-)
diff --git a/drivers/mtd/maps/physmap.c b/drivers/mtd/maps/physmap.c
index bc4649a..5bdbd04 100644
--- a/drivers/mtd/maps/physmap.c
+++ b/drivers/mtd/maps/physmap.c
@@ -264,11 +264,17 @@ static struct resource physmap_flash_resource = {
.flags = IORESOURCE_MEM,
};
+/* Fake release func.*/
+static void physmap_flash_release(struct device *dev)
+{
+}
+
static struct platform_device physmap_flash = {
.name = "physmap-flash",
.id = 0,
.dev = {
.platform_data = &physmap_flash_data,
+ .release = physmap_flash_release,
},
.num_resources = 1,
.resource = &physmap_flash_resource,
diff --git a/drivers/video/hgafb.c b/drivers/video/hgafb.c
index fb9e672..8707115 100644
--- a/drivers/video/hgafb.c
+++ b/drivers/video/hgafb.c
@@ -623,8 +623,16 @@ static struct device_driver hgafb_driver = {
.remove = hgafb_remove,
};
+/* Fake release func.*/
+static void hgafb_device_release(struct device *dev)
+{
+}
+
static struct platform_device hgafb_device = {
- .name = "hgafb",
+ .name = "hgafb",
+ .dev = {
+ .release = hgafb_device_release,
+ },
};
static int __init hgafb_init(void)
next reply other threads:[~2008-04-16 0:34 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-04-16 0:34 Vitaliy Ivanov [this message]
2008-06-05 9:39 ` [PATCH resend] " Vitaliy Ivanov
2008-06-05 16:07 ` Andrew Morton
2008-06-05 16:31 ` David Woodhouse
2008-06-05 16:32 ` Vitaliy Ivanov
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=1208306056.15140.13.camel@pcvitaliy \
--to=vitalivanov@gmail.com \
--cc=devzero@web.de \
--cc=dwmw2@infradead.org \
--cc=jsun@junsun.net \
--cc=linux-kernel@vger.kernel.org \
/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®