linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Axel Lin <axel.lin@gmail.com>
Cc: linux-kernel@vger.kernel.org, Pau Oliva Fora <pof@eslack.org>,
	linux-input@vger.kernel.org
Subject: Re: [PATCH] Input: htcpen - add #ifdef CONFIG_PNP guard for pnp_ids
Date: Wed, 9 Nov 2011 21:18:46 -0800	[thread overview]
Message-ID: <20111110051846.GA3079@core.coreip.homeip.net> (raw)
In-Reply-To: <1320899091.6118.0.camel@phoenix>

On Thu, Nov 10, 2011 at 12:24:51PM +0800, Axel Lin wrote:
> Fix below build warning if CONFIG_PNP is disabled.
> 
>   CC      drivers/input/touchscreen/htcpen.o
> drivers/input/touchscreen/htcpen.c:50: warning: 'pnp_ids' defined but not used
> 

Does not seem to help, How about below instead?

Thanks.

-- 
Dmitry


Input: htcpen - switch to DMI-based autoloading

From: Dmitry Torokhov <dmitry.torokhov@gmail.com>

Having module device table based on PNP id produces the following warning:

  CC      drivers/input/touchscreen/htcpen.o
drivers/input/touchscreen/htcpen.c:50: warning: 'pnp_ids' defined but not used

This happens because it is not a PNP driver, bit rather ISA driver and
pnp_ids table is not used anywhere. To fix this issue let's switch to
DMI-based module table instead,

Reported-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
---

 drivers/input/touchscreen/htcpen.c |    7 +------
 1 files changed, 1 insertions(+), 6 deletions(-)


diff --git a/drivers/input/touchscreen/htcpen.c b/drivers/input/touchscreen/htcpen.c
index 62811de..81e3386 100644
--- a/drivers/input/touchscreen/htcpen.c
+++ b/drivers/input/touchscreen/htcpen.c
@@ -47,12 +47,6 @@ static int invert_y;
 module_param(invert_y, bool, 0644);
 MODULE_PARM_DESC(invert_y, "If set, Y axis is inverted");
 
-static struct pnp_device_id pnp_ids[] = {
-	{ .id = "PNP0cc0" },
-	{ .id = "" }
-};
-MODULE_DEVICE_TABLE(pnp, pnp_ids);
-
 static irqreturn_t htcpen_interrupt(int irq, void *handle)
 {
 	struct input_dev *htcpen_dev = handle;
@@ -237,6 +231,7 @@ static struct dmi_system_id __initdata htcshift_dmi_table[] = {
 	},
 	{ }
 };
+MODULE_DEVICE_TABLE(dmi, htcshift_dmi_table);
 
 static int __init htcpen_isa_init(void)
 {

      reply	other threads:[~2011-11-10  5:18 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-11-10  4:24 [PATCH] Input: htcpen - add #ifdef CONFIG_PNP guard for pnp_ids Axel Lin
2011-11-10  5:18 ` Dmitry Torokhov [this message]

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=20111110051846.GA3079@core.coreip.homeip.net \
    --to=dmitry.torokhov@gmail.com \
    --cc=axel.lin@gmail.com \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=pof@eslack.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;
as well as URLs for NNTP newsgroup(s).