Opened 16 years ago

Closed 16 years ago

Last modified 16 years ago

#2973 closed bug (invalid)

ps2 driver recognizes 4 mices on laptop

Reported by: jackburton Owned by: marcusoverhagen
Priority: normal Milestone: R1
Component: Drivers/Mouse/PS2 Version: R1/pre-alpha1
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description (last modified by jackburton)

The ps2 driver publishes 4 mices on my laptop, with no external mouse connected: Ps/2 mouse 1, 2, 3 and 4.

here's the output of the "iroster" command:

~> iroster
        name              type             state
----------------------------------------------------
       AT Keyboard     B_KEYMAP_DEVICE     running
        PS/2 Mouse 4   B_POINTING_DEVICE   running
        PS/2 Mouse 3   B_POINTING_DEVICE   running
        PS/2 Mouse 2   B_POINTING_DEVICE   running
        PS/2 Mouse 1   B_POINTING_DEVICE   running
       Wacom Tablets   B_POINTING_DEVICE   running
          Usb Mouse 1  B_POINTING_DEVICE   running

Moreover, why is the Wacom Tablets device up and running, without one ? Should I open a different bug for this ?

Change History (8)

comment:1 by jackburton, 16 years ago

Component: Drivers/MouseDrivers/Mouse/PS2
Description: modified (diff)

comment:2 by marcusoverhagen, 16 years ago

And what is the problem? Please also remember to attach a syslog.

comment:3 by jackburton, 16 years ago

Description: modified (diff)

...that it allocates 4 BInputDevice addons for nothing, maybe ?

comment:4 by jackburton, 16 years ago

Description: modified (diff)

comment:5 by stippi, 16 years ago

The Wacom device running is my fault... seems I misunderstood RegisterDevices() at the time I wrote the add-on. The Wacom add-on registers one device type and is "running", even though there are no child devices. The mouse and keyboard add-ons do this differently and register each individual child device. Which brings me to the next point: These child devices will actually report a failure from Start(), because opening the devfs device will fail. Then their threads are not running and the latest revision (hrev28352) should also not report them running anymore. I could maybe change this to UnregisterDevices() for devices that failed to start. Of course, the driver could also be changed not to publish devices that are not there. This currently causes quite a bit of unnecessary things being performed in the input_server at the moment.

comment:6 by marcusoverhagen, 16 years ago

Why does iroster display those mice? They should vanish when they are not present, after the input server initially tried to open them. Whats happening???

still no sylog file :-(

still no sylog file :-(

still no sylog file :-(

still no sylog file :-(

The ps2 driver publishes 4 mice when it is able to enable active multiplexing. The mouse needs to be reset initially. This is done when the device is opened. When no mouse is detected, an error is returned from open. You could first try to reset all mice ports from the ps2 driver, and then only publish those that are detected. However, because of hot plugin possibility, you still would have to reset the mouse when the individual device is opened. Two resets take longer than one reset, and timeouts are in the range of seconds.

comment:7 by marcusoverhagen, 16 years ago

Resolution: invalid
Status: newclosed

comment:8 by stippi, 16 years ago

I'm about to commit a patch that will eliminate the problems that are caused by this, ie no more non-running devices in the input_server.

Note: See TracTickets for help on using tickets.