2001-10-16 17:41:21

by Marcelo Borges Ribeiro

[permalink] [raw]
Subject: joypad bug

I'm using 2.4.12 and since 2.4.10 my 8-button joypad (via gameport) stoped
working.
The first 4 buttons work but directions and other 4 buttons doesn?t. I did
not notice nothing
about it in changelog so I?m reporting it.

Marcelo Ribeiro




2001-10-17 19:23:36

by Vojtech Pavlik

[permalink] [raw]
Subject: Re: joypad bug

On Tue, Oct 16, 2001 at 03:30:40PM -0300, Marcelo Borges Ribeiro wrote:
> I'm using 2.4.12 and since 2.4.10 my 8-button joypad (via gameport) stoped
> working.
> The first 4 buttons work but directions and other 4 buttons doesn?t. I did
> not notice nothing
> about it in changelog so I?m reporting it.

I know about the problem in 2.4.10. But in 2.4.12 that should be fixed ...

--
Vojtech Pavlik
SuSE Labs

2001-10-17 19:32:06

by James D Strandboge

[permalink] [raw]
Subject: Re: joypad bug

On Wed, Oct 17, 2001 at 09:23:42PM +0200 or thereabouts, Vojtech Pavlik wrote:
> On Tue, Oct 16, 2001 at 03:30:40PM -0300, Marcelo Borges Ribeiro wrote:
> > I'm using 2.4.12 and since 2.4.10 my 8-button joypad (via gameport) stoped
> > working.
> > The first 4 buttons work but directions and other 4 buttons doesn?t. I did
> > not notice nothing
> > about it in changelog so I?m reporting it.
>
> I know about the problem in 2.4.10. But in 2.4.12 that should be fixed ...
>
I am using kernel 2.4.12 now, and my Logitech WIngman Attack (analog driver)
has the same symptions. Buttons work, directions don't.

James Strandboge

--
GPG/PGP Info
Email: [email protected]
ID: 26384A3A
Fingerprint: D9FF DF4A 2D46 A353 A289 E8F5 AA75 DCBE 2638 4A3A
--

2001-10-17 20:43:25

by Vojtech Pavlik

[permalink] [raw]
Subject: Re: joypad bug

On Wed, Oct 17, 2001 at 03:32:14PM -0400, James D Strandboge wrote:
> On Wed, Oct 17, 2001 at 09:23:42PM +0200 or thereabouts, Vojtech Pavlik wrote:
> > On Tue, Oct 16, 2001 at 03:30:40PM -0300, Marcelo Borges Ribeiro wrote:
> > > I'm using 2.4.12 and since 2.4.10 my 8-button joypad (via gameport) stoped
> > > working.
> > > The first 4 buttons work but directions and other 4 buttons doesn?t. I did
> > > not notice nothing
> > > about it in changelog so I?m reporting it.
> >
> > I know about the problem in 2.4.10. But in 2.4.12 that should be fixed ...
> >
> I am using kernel 2.4.12 now, and my Logitech WIngman Attack (analog driver)
> has the same symptions. Buttons work, directions don't.

Uh-uh. Gotta get me an analog joystick fast and test this.

--
Vojtech Pavlik
SuSE Labs

2001-10-18 07:09:28

by john slee

[permalink] [raw]
Subject: Re: joypad bug

On Wed, Oct 17, 2001 at 10:43:37PM +0200, Vojtech Pavlik wrote:
> On Wed, Oct 17, 2001 at 03:32:14PM -0400, James D Strandboge wrote:
> > On Wed, Oct 17, 2001 at 09:23:42PM +0200 or thereabouts, Vojtech Pavlik wrote:
> > > On Tue, Oct 16, 2001 at 03:30:40PM -0300, Marcelo Borges Ribeiro wrote:
> > > > I'm using 2.4.12 and since 2.4.10 my 8-button joypad (via gameport) stoped
> > > > working.
> > > > The first 4 buttons work but directions and other 4 buttons doesn?t. I did
> > > > not notice nothing
> > > > about it in changelog so I?m reporting it.
> > >
> > > I know about the problem in 2.4.10. But in 2.4.12 that should be fixed ...
> > >
> > I am using kernel 2.4.12 now, and my Logitech WIngman Attack (analog driver)
> > has the same symptions. Buttons work, directions don't.
>
> Uh-uh. Gotta get me an analog joystick fast and test this.

unless it specifically has to be gameport, probably the easiest, best,
and cheapest way is to buy a playstation => usb adapter (~20AUD from
http://www.lik-sang.com) and a playstation controller or two. psx
dualshock controller costs ~50AUD and gives you 12 buttons, two analog
sticks, and a dpad... (in an imho very comfortable-to-use package)

you could then also use the dualshock to test bugs in the parallel port
psx driver, i believe the adapters are quite cheap to make and have the
added benefit of having the vibration feature supported (whereas it
doesnt seem to work with the usb adapter)

j.

--
R N G G "Well, there it goes again... And we just sit
I G G G here without opposable thumbs." -- gary larson

2001-10-18 12:46:12

by James D Strandboge

[permalink] [raw]
Subject: Re: joypad bug

On Wed, Oct 17, 2001 at 10:43:37PM +0200 or thereabouts, Vojtech Pavlik wrote:
> On Wed, Oct 17, 2001 at 03:32:14PM -0400, James D Strandboge wrote:
> > On Wed, Oct 17, 2001 at 09:23:42PM +0200 or thereabouts, Vojtech Pavlik wrote:
> > > On Tue, Oct 16, 2001 at 03:30:40PM -0300, Marcelo Borges Ribeiro wrote:
> > > > I'm using 2.4.12 and since 2.4.10 my 8-button joypad (via gameport) stoped
> > > > working.
> > > > The first 4 buttons work but directions and other 4 buttons doesn?t. I did
> > > > not notice nothing
> > > > about it in changelog so I?m reporting it.
> > >
> > > I know about the problem in 2.4.10. But in 2.4.12 that should be fixed ...
> > >
> > I am using kernel 2.4.12 now, and my Logitech WIngman Attack (analog driver)
> > has the same symptions. Buttons work, directions don't.
>
> Uh-uh. Gotta get me an analog joystick fast and test this.
>
I just confirmed that joystick works properly in 2.4.9.

Jamie

--
GPG/PGP Info
Email: [email protected]
ID: 26384A3A
Fingerprint: D9FF DF4A 2D46 A353 A289 E8F5 AA75 DCBE 2638 4A3A
--

2001-10-18 16:01:28

by Vojtech Pavlik

[permalink] [raw]
Subject: [patch] Re: joypad bug

On Thu, Oct 18, 2001 at 08:53:29AM -0400, James D Strandboge wrote:

> On Wed, Oct 17, 2001 at 11:51:12PM +0200 or thereabouts, Vojtech Pavlik wrote:
> > But if you could provide some more detail about when it stopped to work
> > exactly (did it work with 2.4.9?) that might help.
>
> I posted a message to the kernel mailing list and you a few minutes ago
> regarding the driver working in 2.4.9. It did, however, when I made the
> original post, I was using vanilla 2.4.10 and 2.4.12. However, I just
> tried 2.4.12-ac3 and it is in fact working. Hope this helps.

It's because a fix didn't make it into Linus's tree. Fix is attached.
Linus: Please apply it. Thanks.

--
Vojtech Pavlik
SuSE Labs


--- linux/drivers/char/joystick/analog.c Fri Sep 14 23:40:00 2001
+++ linux-fixed/drivers/char/joystick/analog.c Thu Oct 18 17:57:06 2001
@@ -138,7 +138,7 @@

#ifdef __i386__
#define TSC_PRESENT (test_bit(X86_FEATURE_TSC, &boot_cpu_data.x86_capability))
-#define GET_TIME(x) do { if (TSC_PRESENT) rdtscl(x); else outb(0, 0x43); x = inb(0x40); x |= inb(0x40) << 8; } while (0)
+#define GET_TIME(x) do { if (TSC_PRESENT) rdtscl(x); else { outb(0, 0x43); x = inb(0x40); x |= inb(0x40) << 8; } } while (0)
#define DELTA(x,y) (TSC_PRESENT?((y)-(x)):((x)-(y)+((x)<(y)?1193180L/HZ:0)))
#define TIME_NAME (TSC_PRESENT?"TSC":"PIT")
#elif __x86_64__
@@ -499,7 +499,9 @@
else
printk(" [%s timer, %d %sHz clock, %d ns res]\n", TIME_NAME,
port->speed > 10000 ? (port->speed + 800) / 1000 : port->speed,
- port->speed > 10000 ? "M" : "k", (port->loop * 1000000) / port->speed);
+ port->speed > 10000 ? "M" : "k",
+ port->speed > 10000 ? (port->loop * 1000) / (port->speed / 1000)
+ : (port->loop * 1000000) / port->speed);
}

/*