X86 platform drivers
 help / color / mirror / Atom feed
From: Matthew Garrett <mjg59@srcf.ucam.org>
To: Robert Gerlach <khnz@gmx.de>
Cc: "Ryan H. Lewis" <me@ryanlewis.net>,
	platform-driver-x86@vger.kernel.org, dmitry.torokhov@gmail.com
Subject: Re: [RESEND PATCH] Fujitsu tablet pc extras driver
Date: Tue, 29 Mar 2011 11:33:22 +0100	[thread overview]
Message-ID: <20110329103321.GA8969@srcf.ucam.org> (raw)
In-Reply-To: <20110329100322.GA7099@fais.local>

On Tue, Mar 29, 2011 at 12:03:22PM +0200, Robert Gerlach wrote:

> +#define INTERRUPT 5
> +#define IO_BASE 0xfd70

You're binding to an ACPI device here - does it have a _CRS method? If 
so, you should retrieve the resource information from acpipnp rather 
than hardcoding it. That'll involve reworking it as an acpi driver 
rather than a platform one, but that should be easy enough.

> +/*** HELPER *******************************************************************/

Does checkpatch really not complain about that? I don't think it's a 
terribly helpful comment in any case :)

> +static int fujitsu_busywait(void)

You're sleeping, so it's not really a busywait...

> +static void fujitsu_reset(void)
> +{
> +	fujitsu_ack();
> +	if (fujitsu_busywait())
> +		printk(KERN_WARNING MODULENAME ": timeout, real reset needed!\n");
> +}

We have no idea how to do a "real" reset, I guess?

> +	error = request_irq(INTERRUPT, fujitsu_isr,
> +			IRQF_SHARED, MODULENAME, fujitsu_isr);

Any risk of the irq firing between you doing setup and requesting the 
IRQ?

Other than the above, this looks fine from the driver point of view - 
Cc:ing Dmitry so he can have a quick look at the input side of things.

-- 
Matthew Garrett | mjg59@srcf.ucam.org

  reply	other threads:[~2011-03-29 10:33 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-03-29 10:03 [RESEND PATCH] Fujitsu tablet pc extras driver Robert Gerlach
2011-03-29 10:33 ` Matthew Garrett [this message]
2011-03-29 12:11   ` Robert Gerlach
2011-03-29 12:13     ` Matthew Garrett
2011-03-31  5:50 ` Dmitry Torokhov

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=20110329103321.GA8969@srcf.ucam.org \
    --to=mjg59@srcf.ucam.org \
    --cc=dmitry.torokhov@gmail.com \
    --cc=khnz@gmx.de \
    --cc=me@ryanlewis.net \
    --cc=platform-driver-x86@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