Re: OpenBSD 6.6 snapshot #262 - no USB mouse

2019-09-07 Thread Mikal Villa


First, thanks for all good advices.

Ok I finally had time to sit down and figure it out, and my first guess
was wrong, it was a change in pms.c which made the touchpad stop
working. The patch that made it stop work was revision 1.89 committed
Mon Aug 19 21:08 UTC. Most of the patch is probably correct, I've not
worked with hardware drivers on this level before so someone that knows
what they are doing should probably look into this - but I also made a
patch to fix it, however I might have broken the support of other
touchpads or so with my suggested change. What I did was bringing back
the three lines deleted from elantech_get_hwinfo_v4 and re-added them to
the new if statement. I'm attaching a diff for this change.


On 30/08/2019, 17:16, Stuart Henderson wrote:

Mikal, as your problem started before the problematic snapshot, while
it may seem a similar issue, it definitely needs investigating differently.

On 2019/08/30 17:26, Mikal Villa wrote:

I tried that, booted with #248 but I'm sorry to say the issues are still
here. I wrote wrong in the last mail, wsmouse0 is the touchscreen which
as last time, is no responsive. wsmouse1, the trackpad is "sometimes"
acting on input but not nessesarry where you meant it to go, however
right clicking seem to work, and has in all tries of mine worked.

Is there a place I can read about whats already known about this issue?
I know you don't do bugtrackers, but maybe if I knew more I could make a
brave attempt to help fixing it myself. Unfamiliar with the openbsd
kernel, but has a little experience from xnu and linux. Dmesg has all
it's output from pms0, but I've read the pms driver code and I suspect
it's not the trouble maker but something else where it's just a
biproduct of it.


The best easy-ish thing you could do would be to try to identify a time
range (or even better the actual commit) when the problem started occurring.

The pms entries in dmesg seem to point at something kernel-side rather
than X so I would start by just trying different kernels. You could e.g.
fetch the src tree if you don't already have it, then do a date-based
update in /sys ("cvs up -Pd -D 2019/08/01"). Start with a date before
you think the problem started, to confirm that it was indeed working at
that point and to confirm that the process of just building kernels is
good enough for these tests. (If you go back too far you may run into
syscall or kernel structure incompatibilities, but I can't think of any
that will cause major problems in the suggested time window).
Build/install a kernel and test, if it works then do another cvs up
moving forward through time (forwards a week or so?) until it stops
working, then backwards again with smaller increments to narrow it down.




--
Best regards,
Mikal Villa

--- a/sys/dev/pckbc/pms.c
+++ b/sys/dev/pckbc/pms.c
@@ -1946,7 +1946,10 @@ elantech_get_hwinfo_v4(struct pms_softc *sc)
if (synaptics_query(sc, ELANTECH_QUE_FW_VER, _version))
return (-1);

-   if ((fw_version & 0x0f) >> 16 < 6)
+  if ((fw_version & 0x0f) >> 16 != 6
+  && (fw_version & 0x0f) >> 16 != 8
+  && (fw_version & 0x0f) >> 16 != 15
+   && (fw_version & 0x0f) >> 16 < 6)
return (-1);

elantech->fw_version = fw_version;


Re: OpenBSD 6.6 snapshot #262 - no USB mouse

2019-08-30 Thread Stuart Henderson
Mikal, as your problem started before the problematic snapshot, while
it may seem a similar issue, it definitely needs investigating differently.

On 2019/08/30 17:26, Mikal Villa wrote:
> I tried that, booted with #248 but I'm sorry to say the issues are still
> here. I wrote wrong in the last mail, wsmouse0 is the touchscreen which
> as last time, is no responsive. wsmouse1, the trackpad is "sometimes"
> acting on input but not nessesarry where you meant it to go, however
> right clicking seem to work, and has in all tries of mine worked.
> 
> Is there a place I can read about whats already known about this issue?
> I know you don't do bugtrackers, but maybe if I knew more I could make a
> brave attempt to help fixing it myself. Unfamiliar with the openbsd
> kernel, but has a little experience from xnu and linux. Dmesg has all
> it's output from pms0, but I've read the pms driver code and I suspect
> it's not the trouble maker but something else where it's just a
> biproduct of it.

The best easy-ish thing you could do would be to try to identify a time
range (or even better the actual commit) when the problem started occurring.

The pms entries in dmesg seem to point at something kernel-side rather
than X so I would start by just trying different kernels. You could e.g.
fetch the src tree if you don't already have it, then do a date-based
update in /sys ("cvs up -Pd -D 2019/08/01"). Start with a date before
you think the problem started, to confirm that it was indeed working at
that point and to confirm that the process of just building kernels is
good enough for these tests. (If you go back too far you may run into
syscall or kernel structure incompatibilities, but I can't think of any
that will cause major problems in the suggested time window).
Build/install a kernel and test, if it works then do another cvs up
moving forward through time (forwards a week or so?) until it stops
working, then backwards again with smaller increments to narrow it down.



Re: OpenBSD 6.6 snapshot #262 - no USB mouse

2019-08-30 Thread Mikal Villa

I tried that, booted with #248 but I'm sorry to say the issues are still
here. I wrote wrong in the last mail, wsmouse0 is the touchscreen which
as last time, is no responsive. wsmouse1, the trackpad is "sometimes"
acting on input but not nessesarry where you meant it to go, however
right clicking seem to work, and has in all tries of mine worked.

Is there a place I can read about whats already known about this issue?
I know you don't do bugtrackers, but maybe if I knew more I could make a
brave attempt to help fixing it myself. Unfamiliar with the openbsd
kernel, but has a little experience from xnu and linux. Dmesg has all
it's output from pms0, but I've read the pms driver code and I suspect
it's not the trouble maker but something else where it's just a
biproduct of it.

As always, attached xorg log, dmesg for boot and after xorg.


On 30/08/2019, 08:05, Cleber A. Nascimento wrote:

What if do you make just a "sysupgrade -s", and lets the system download
the next snapshot?



Em qui, 29 de ago de 2019 às 23:34, Mikal Villa 
escreveu:



I tried it now. Booted with "OpenBSD 6.6-beta (GENERIC.MP) #2: Fri Aug
30 03:36:27 CEST 2019". Unfortunately I experience the same issues now,
so if it where an attempt already on fixed it, I'm sorry to say it
didn't work.

The only difference is that this time wsmouse0 (the trackpad) seem to
not respond at all, while the trackpad behaves quite uncontrollable
and where I wouldn't say the debug output of it reflect anything near
what I actually did on the trackpad.. I'll attach the dmesg.boot,
dmesg after xorg, and the Xorg.0.log for this test.


On 29/08/2019, 14:16, Stefan Sperling wrote:
>Kernel #262 is known to be broken.
>Compile your own from -current sources or wait for the next snapshot.
>

--
Best regards,
Mikal Villa




--

Cleber Alves

.ılı..ılı.
"Observe as estrelas e aprenda com elas." Albert Einstein


--
Best regards,
Mikal Villa

[19.503] (WW) checkDevMem: failed to open /dev/xf86 and /dev/mem
(Operation not permitted)
Check that you have set 'machdep.allowaperture=1'
in /etc/sysctl.conf and reboot your machine
refer to xf86(4) for details
[19.503]linear framebuffer access unavailable
[19.530] (--) Using wscons driver on /dev/ttyC4
[19.550] 
X.Org X Server 1.20.5
X Protocol Version 11, Revision 0
[19.550] Build Operating System: OpenBSD 6.6 amd64 
[19.550] Current Operating System: OpenBSD openbsd.meeh.no 6.6 
GENERIC.MP#266 amd64
[19.551] Build Date: 29 August 2019  05:54:46PM
[19.551]  
[19.551] Current version of pixman: 0.38.4
[19.551]Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
[19.551] Markers: (--) probed, (**) from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[19.551] (==) Log file: "/var/log/Xorg.0.log", Time: Fri Aug 30 15:21:44 
2019
[19.553] (==) Using config file: "/etc/X11/xorg.conf"
[19.553] (==) Using config directory: "/etc/X11/xorg.conf.d"
[19.553] (==) Using system config directory 
"/usr/X11R6/share/X11/xorg.conf.d"
[19.558] (==) ServerLayout "Lenovo Yoga"
[19.558] (**) |-->Screen "Screen0" (0)
[19.558] (**) |   |-->Monitor "LCD Panel"
[19.560] (==) No device specified for screen "Screen0".
Using the first device section listed.
[19.560] (**) |   |-->Device "drm"
[19.560] (**) |   |-->GPUDevice "drm"
[19.561] (**) |-->Input Device "Trackpoint"
[19.561] (**) |-->Input Device "Touchscreen"
[19.561] (**) |-->Input Device "Generic Keyboard"
[19.561] (**) Option "AutoAddDevices" "no"
[19.561] (**) Option "DRI2" "True"
[19.561] (**) Not automatically adding devices
[19.561] (==) Automatically enabling devices
[19.561] (==) Not automatically adding GPU devices
[19.561] (==) Max clients allowed: 256, resource mask: 0x1f
[19.562] (**) FontPath set to:
/usr/X11R6/lib/X11/fonts/misc/,
/usr/X11R6/lib/X11/fonts/TTF/,
/usr/X11R6/lib/X11/fonts/OTF/,
/usr/X11R6/lib/X11/fonts/Type1/,
/usr/X11R6/lib/X11/fonts/100dpi/,
/usr/X11R6/lib/X11/fonts/75dpi/,
/usr/X11R6/lib/X11/fonts/misc/,
/usr/X11R6/lib/X11/fonts/TTF/,
/usr/X11R6/lib/X11/fonts/OTF/,
/usr/X11R6/lib/X11/fonts/Type1/,
/usr/X11R6/lib/X11/fonts/100dpi/,
/usr/X11R6/lib/X11/fonts/75dpi/
[19.562] (**) ModulePath set to "/usr/X11R6/lib/modules"
[19.562] (II) Loader magic: 0xa28cc00f000
[19.562] (II) Module ABI versions:
[19.562]X.Org ANSI C Emulation: 0.4
[19.562]X.Org Video Driver: 24.0
[19.562]X.Org XInput driver : 24.1
[19.562]X.Org Server Extension : 10.0
[19.563] (--) PCI:*(0@0:2:0) 8086:5916:17aa:39f4 rev 2, Mem @ 
0xa200/16777216, 0xb000/268435456, I/O @ 0x4000/64
[19.563] (--) 

Re: OpenBSD 6.6 snapshot #262 - no USB mouse

2019-08-30 Thread Cleber A. Nascimento
What if do you make just a "sysupgrade -s", and lets the system download
the next snapshot?



Em qui, 29 de ago de 2019 às 23:34, Mikal Villa 
escreveu:

>
> I tried it now. Booted with "OpenBSD 6.6-beta (GENERIC.MP) #2: Fri Aug
> 30 03:36:27 CEST 2019". Unfortunately I experience the same issues now,
> so if it where an attempt already on fixed it, I'm sorry to say it
> didn't work.
>
> The only difference is that this time wsmouse0 (the trackpad) seem to
> not respond at all, while the trackpad behaves quite uncontrollable
> and where I wouldn't say the debug output of it reflect anything near
> what I actually did on the trackpad.. I'll attach the dmesg.boot,
> dmesg after xorg, and the Xorg.0.log for this test.
>
>
> On 29/08/2019, 14:16, Stefan Sperling wrote:
> >Kernel #262 is known to be broken.
> >Compile your own from -current sources or wait for the next snapshot.
> >
>
> --
> Best regards,
> Mikal Villa
>
>

-- 

Cleber Alves

.ılı..ılı.
"Observe as estrelas e aprenda com elas." Albert Einstein


Re: OpenBSD 6.6 snapshot #262 - no USB mouse

2019-08-29 Thread Stefan Sperling
Kernel #262 is known to be broken.
Compile your own from -current sources or wait for the next snapshot.