From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Alex Hudson <home@alexhudson.com>
Cc: Linux Input <linux-input@vger.kernel.org>
Subject: Re: Driver problems: t213 on i8042 port
Date: Mon, 13 Dec 2010 01:10:27 -0800 [thread overview]
Message-ID: <20101213091027.GI21401@core.coreip.homeip.net> (raw)
In-Reply-To: <1292057765.2844.9.camel@lapland.localdomain>
On Sat, Dec 11, 2010 at 08:56:05AM +0000, Alex Hudson wrote:
> Hi Dmitry,
>
> Thanks for responding, much appreciated ;)
>
> On Fri, 2010-12-10 at 23:15 -0800, Dmitry Torokhov wrote:
> > > I'm having some trouble with the serio support for a touchit213 device,
> > > and I'm hoping by describing what's going on someone can offer some
> > > clues.
> >
> > I guess I'd start by making sure that you are indeed dealing with
> > touchit123 and not some other device.
>
> Indeed, I'm pretty sure this is the right device. The xf86 driver I
> mentioned comes as a source module, and accesses the device via
> serio_raw. I've compared the code and the protocol is identical: and
> indeed, the xf86 module makes clear some things the serio driver implies
> (e.g., the xf86 driver treats the data definitively as 11-bit).
Any chance you could post a link to the sources?
>
> The problem with the xf86 driver is many-fold; it was written pre-Xorg
> and it's taken me a fair bit of hacking just to even get it to work on
> Fedora 14 without segfaulting. It's also a lot more complex than the
> serio equivalent.
Right, it is most likely does hardware probing and initialization
whereas touchkit213 expects input_attach to do this for it.
>
> > > Now, there is a serio driver for the touchit213 series, but the obvious:
> > >
> > > echo -n "touchit213" > /sys/bus/serio/devices/serio4/drvctl
> > >
> > > .. doesn't work. I don't see anything in the logs; whereas if I use
> > > inputattach to connect the driver to ttyS0 (which doesn't have the
> > > device, obviously) I can see that the driver is enabled
> > > in /var/log/messages and a touch /dev/input/event device is created.
> >
> > Right, the current touchit123 driver only binds to serio that has
> > appropriate type. Basically this means that the driver only works with
> > serial ports (ttySx) and not PS/2 ports.
>
> I think you've nailed the problem, then - is this to do with the
> structure in touchit213_serio_ids[]? I had only really been looking at
> the connect() function.
>
> Is it possible it's as simple as adding another stanza accepting
> SERIO_8042 or is there a more fundamental reason why ttySx is only
> allowed?
You can't simply allowing binding to SERIO_8042 as it will cause
touchkit213 to fight with the standard psmouse driver. What needs to be
done is to write a sub-driver (or protocol driver) for psmouse module
which would probe the devices and automatically select proper protocol.
Please take a look at drivers/input/mouse/psmouse-base.c and friends
there.
Also, please use 'reply-all' on kernel lists - this way you have much
better chance to receive prompt replies ;)
--
Dmitry
next prev parent reply other threads:[~2010-12-13 9:10 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-08 10:33 Driver problems: t213 on i8042 port Alex Hudson
2010-12-11 7:15 ` Dmitry Torokhov
2010-12-11 8:56 ` Alex Hudson
2010-12-13 9:10 ` Dmitry Torokhov [this message]
2010-12-13 10:12 ` Alex Hudson
2010-12-15 8:03 ` 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=20101213091027.GI21401@core.coreip.homeip.net \
--to=dmitry.torokhov@gmail.com \
--cc=home@alexhudson.com \
--cc=linux-input@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;
as well as URLs for NNTP newsgroup(s).