* [9front] nusb/kb: add support for my mouse
@ 2020-04-12 5:02 petermikkelsen10
2020-04-12 5:14 ` ori
0 siblings, 1 reply; 3+ messages in thread
From: petermikkelsen10 @ 2020-04-12 5:02 UTC (permalink / raw)
To: 9front
[-- Attachment #1: Type: text/plain, Size: 630 bytes --]
Hello,
I have recently installed 9front on my laptop and only some USB mice seems to work. After a bit of investigation it
turned out that my issues were with the kind of mice that presented part of them as a pointing device, and part of them
as a keyboard. I had a look at the USB Hid spec, and it seems like some of the things that nusb/kb does
(like setting the idle time) is not always supported by all types of devices, so this patch changes those things.
It fixes the problems for me so now I can use my mouse. A sysinfo is attached.
(Sorry if I am spamming the list, it doesn't seem like my mails are getting through..)
[-- Attachment #2: sysinfo --]
[-- Type: text/plain, Size: 18319 bytes --]
% cd '#ec'; for(i in *){echo $i '=' `{cat $i}}
*acpi = 0xbddfd014
*bootscreen = 1920x1080x32 x8r8g8b8 0xc0000000
*e820 = 1 0000000000000000 0000000000008000 1 0000000000008000 000000000000c000 1 000000000000c000 000000000009f000 2 000000000009f000 00000000000a0000 2 00000000000e0000 0000000000100000 1 0000000000100000 0000000009c00000 1 0000000009d81000 0000000009f00000 4 0000000009f00000 0000000009f0b000 1 0000000009f0b000 00000000b26c7000 1 00000000b26c7000 00000000b2747000 1 00000000b2747000 00000000b6d1a000 1 00000000b6d1a000 00000000b6dab000 1 00000000b6dab000 00000000b6e6c000 1 00000000b6e6c000 00000000b7045000 1 00000000b7045000 00000000b7080000 1 00000000b7080000 00000000b80a6000 1 00000000b80a6000 00000000b80ad000 1 00000000b80ad000 00000000b814b000 1 00000000b814b000 00000000b816b000 1 00000000b816b000 00000000b9d25000 1 00000000b9d25000 00000000ba29f000 1 00000000ba29f000 00000000ba3ac000 1 00000000ba3ac000 00000000ba3c3000 1 00000000ba3c3000 00000000ba463000 1 00000000ba463000 00000000ba464000 1 00000000ba464000 00000000ba827000 1 00000000ba827000 00000000ba904000 1 00000000ba904000 00000000bc71f000 2 00000000bc71f000 00000000bdc63000 4 00000000bdc63000 00000000bddfa000 3 00000000bddfa000 00000000bddfe000 1 00000000bddfe000 00000000be400000 1 00000000be400000 00000000be562000 1 00000000be562000 00000000be582000 1 00000000be582000 00000000be5db000 1 00000000be5db000 00000000beff3000 1 00000000beff3000 00000000bf000000 1 0000000100000000 00000003ff000000 2 0000000009c00000 0000000009d81000 2 00000000bf000000 00000000c0000000 2 00000000fd200000 00000000fd300000 2 00000000fed80000 00000000fed81000
bootargs = local!/dev/sdN0/fscache
bootfile = 9pc64
mouseport = ps2intellimouse
nobootprompt = local!/dev/sdN0/fscache
nora6 =
user = glenda
% cat '#'P/archctl
cpu unknown 2297 pge
pge on
coherence mfence
cmpswap cmpswap486
arch ACPI
cache default uc
cache 0x0 2147483648 wb
cache 0x80000000 1073741824 wb
cache 0xff000000 16777216 wp
cache 0xc0000000 67108864 wc
% cat '#'P/irqalloc
1 0 debugexc
3 0 debugpt
7 0 mathemu
8 0 doublefault
9 0 mathover
14 0 faultamd64
15 0 unexpected
16 0 matherror
19 0 simderror
50 18 clock
51 19 lapicerror
63 31 lapicspurious
65 -1 ether0
73 1 kbd
81 -1 hda
89 -1 xhci
97 -1 xhci
105 -1 sdE (ahci)
113 -1 sdN (nvme)
121 12 kbdaux
% cat '#'P/ioalloc
20 21 i8259.0
40 43 i8253
60 60 i8042.data
61 61 i8253.cntr2c
62 62 ec.data
64 64 i8042.cs
66 66 ec.sc
70 71 rtc/nvr
a0 a1 i8259.1
2b0 2df vga
3c0 3da vga
fff fff dummy
3000 30ff rtl8169
% cat '#'c/config
# pc64 - amd64 pc terminal with local disk
dev
root
cons
swap
arch
pnp pci
env
pipe
proc
mnt
srv
shr
dup
rtc
ssl
tls
cap
kprof
fs
ether netif
bridge netif log
ip arp chandial ip ipv6 ipaux iproute netlog ethermedium nullmedium pktmedium inferno
draw screen vga vgax vgasoft
mouse mouse
kbd
vga
sd
# floppy dma
aoe
# lpt
audio dma
# pccard
# i82365 cis
uart
usb
segment
vmx
dtracy
link
# devpccard
# devi82365
cputemp
# ether2000 ether8390
# ether2114x pci
# ether589 etherelnk3
ether79c970 pci
# ether8003 ether8390
ether8139 pci
ether8169 pci ethermii
# should be obsoleted by igbe
# ether82543gc pci
# ether82557 pci
ether82563 pci
ether82598 pci
etherx550 pci
# ether83815 pci
etherbcm pci
# etherdp83820 pci ethermii
# etherec2t ether8390
# etherelnk3 pci
# etherga620 pci
etherigbe pci ethermii
# ethervgbe pci ethermii
# ethervt6102 pci ethermii
# ethervt6105m pci ethermii
ethersink
# ethersmc devi82365 cis
etheryuk pci
# etherwavelan wavelan devi82365 cis pci
etheriwl pci wifi
etherwpi pci wifi
etherrt2860 pci wifi
ethervirtio pci
ethermedium
# pcmciamodem
netdevmedium
loopbackmedium
usbuhci
usbohci
usbehci usbehcipc
usbxhci pci
# audiosb16 dma
# audioac97 audioac97mix
audiohda
misc
archacpi mp apic squidboy ec
archmp mp apic squidboy
mtrr
sdaoe
sdide pci sdscsi
sd53c8xx pci sdscsi
# sdmylex pci sdscsi
sdiahci pci sdscsi led
# sdodin pci sdscsi led
sdvirtio pci sdscsi
sdmmc pci pmmc
sdnvme pci
sdloop
sdram
uarti8250
uartisa
uartpci pci
vgasoft =cur swcursor
# vga3dfx +cur
# vgaark2000pv +cur
# vgabt485 =cur
# vgaclgd542x +cur
# vgaclgd546x +cur
# vgact65545 +cur
# vgacyber938x +cur
# vgaet4000 +cur
# vgageode +cur
# vgahiqvideo +cur
# vgai81x +cur
vgaigfx +cur
# vgamach64xx +cur
# vgamga2164w +cur
# vgamga4xx +cur
# vganeomagic +cur
# vganvidia +cur
vgaradeon +cur
# vgargb524 =cur
# vgas3 +cur vgasavage
# vgat2r4 +cur
# vgatvp3020 =cur
# vgatvp3026 =cur
vgavesa
# vgavmware +cur
dtracysys
dtracytimer
ip
tcp
udp
rudp
ipifc
icmp
icmp6
gre
ipmux
esp
il
port
int cpuserver = 0;
bootdir
/$objtype/bin/paqfs
/$objtype/bin/auth/factotum
bootfs.paq
boot
% cat '#'c/sysstat
0 70778 331337 83126 13914 0 0 17 100 0
1 87250 231691 86034 16441 0 0 0 100 0
2 241201 259804 334629 12558 0 0 0 99 0
3 176973 350639 205734 14285 0 0 0 99 0
4 175115 291931 173059 16596 0 0 0 99 0
5 179056 296742 167995 15342 0 0 0 100 0
6 141181 261097 152399 16459 0 0 0 99 0
7 148902 262831 153966 28443 0 0 0 100 0
% cat '#'¶/swap
16042115072 memory
4096 pagesize
524288 kernel
14594/3280640 user
0/160000 swap
2362/3280640 reclaim
4962408/5244160/2139377280 kernel malloc
28693688/32798464/1925439552 kernel draw
768/65568/16777216 kernel secret
% awk /^Plan 9/{p=1} /^init: starting/{exit} {if(p)print} '#'c/kmesg
Plan 9
123 holes free
0x0002a000 0x0009f000 479232
0x00100000 0x00110000 65536
0x00505000 0x09c00000 158314496
0x09d81000 0x09f00000 1568768
0x09f0b000 0x7ffff000 1980710912
2141138944 bytes free
cpu0: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
amlmapio: [0xffffff18-0x100000018) overlaps usable memory
amlmapio: mapping \_SB.FRTP failed
LAPIC: fee00000 0xffffff00fee00000
ec: cmd 66, data 62
ELCR: 0000
cpu0: lapic clock at 25MHz
cpu1: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
cpu2: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
cpu3: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
cpu4: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
cpu5: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
cpu6: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
cpu7: 2297MHz AuthenticAMD unknown (AX 00810F81 CX 76D8320B DX 178BFBFF)
pcienable PCI.0.1.2: pcr 3->7
rtl8169: oui 0x732 phyno 1, macv = 0x50800000 phyv = 0x0000
#l0: rtl8169: 100Mbps port 0x3000 irq 255 ea 98fa9b69b552
#S/sdE: ahci: sata-II with 1 ports
pcienable PCI.5.0.6: pcr 0->2
#A0: hda mem ffffff00d06c0000 irq 255
#A0: codec #0, vendor 14f11f86, rev 00100100
usbxhci: 0x1022 0x15e0: port 0xd0300000 size 0x100000 irq 255
usbxhci: 0x1022 0x15e1: port 0xd0400000 size 0x100000 irq 255
15303M memory: 2488M kernel data, 12815M user, 13440M swap
pcienable PCI.5.0.4: pcr 0->2
sdE0: LLBA 488,397,168 sectors
Samsung SSD 840 EVO 250GB EXT0BB6Q S1DBNSBF928022M [newdrive]
current fs is "main"
10 uids read, 3 groups used
63-bit cwfs as of Mon Apr 6 03:51:46 2020
last boot Sun Apr 12 07:51:43 2020
% pci -v
0.0.0: brg 06.00.00 1022/15d0 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Root Complex
0.0.2: base 08.06.00 1022/15d1 255
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 IOMMU
0.1.0: brg 06.00.00 1022/1452 0
Advanced Micro Devices, Inc. [AMD] Family 17h (Models 00h-1fh) PCIe Dummy Host Bridge
0.1.1: brg 06.04.00 1022/15d3 255
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 PCIe GPP Bridge [6:0]
0.1.2: brg 06.04.00 1022/15d3 255
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 PCIe GPP Bridge [6:0]
0.1.3: brg 06.04.00 1022/15d3 255
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 PCIe GPP Bridge [6:0]
0.1.6: brg 06.04.00 1022/15d3 255
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 PCIe GPP Bridge [6:0]
0.8.0: brg 06.00.00 1022/1452 0
Advanced Micro Devices, Inc. [AMD] Family 17h (Models 00h-1fh) PCIe Dummy Host Bridge
0.8.1: brg 06.04.00 1022/15db 255
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Internal PCIe GPP Bridge 0 to Bus A
0.8.2: brg 06.04.00 1022/15dc 255
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Internal PCIe GPP Bridge 0 to Bus B
0.20.0: smb 0c.05.00 1022/790b 0
Advanced Micro Devices, Inc. [AMD] FCH SMBus Controller
0.20.3: brg 06.01.00 1022/790e 0
Advanced Micro Devices, Inc. [AMD] FCH LPC Bridge
0.24.0: brg 06.00.00 1022/15e8 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 0
0.24.1: brg 06.00.00 1022/15e9 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 1
0.24.2: brg 06.00.00 1022/15ea 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 2
0.24.3: brg 06.00.00 1022/15eb 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 3
0.24.4: brg 06.00.00 1022/15ec 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 4
0.24.5: brg 06.00.00 1022/15ed 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 5
0.24.6: brg 06.00.00 1022/15ee 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 6
0.24.7: brg 06.00.00 1022/15ef 0
Advanced Micro Devices, Inc. [AMD] Raven/Raven2 Device 24: Function 7
1.0.0: disk 01.08.02 1c5c/1327 255 0:d0a00004 16384
SK hynix
2.0.0: net 02.00.00 10ec/8168 255 0:00003001 256 2:d0904004 4096 4:d0900004 16384
Realtek Semiconductor Co., Ltd. RTL8111/8168/8411 PCI Express Gigabit Ethernet Controller
3.0.0: --- ff.00.00 10ec/522a 255
Realtek Semiconductor Co., Ltd. RTS522A PCI Express Card Reader
4.0.0: --- ff.00.00 10ec/b822 255
Realtek Semiconductor Co., Ltd. RTL8822BE 802.11a/b/g/n/ac WiFi adapter
5.0.0: vid 03.00.00 1002/15d8 255 0:c000000c 268435456 2:d000000c 2097152 4:00001001 256 5:d0600000 524288
Advanced Micro Devices, Inc. [AMD/ATI] Picasso
5.0.1: aud 04.03.00 1002/15de 255 0:d06c8000 16384
Advanced Micro Devices, Inc. [AMD/ATI] Raven/Raven2/Fenghuang HDMI/DP Audio Controller
5.0.2: cryp 10.80.00 1022/15df 255 2:d0500000 1048576 5:d06cc000 8192
Advanced Micro Devices, Inc. [AMD] Family 17h (Models 10h-1fh) Platform Security Processor
5.0.3: usb 0c.03.30 1022/15e0 255 0:d0300004 1048576
Advanced Micro Devices, Inc. [AMD] Raven USB 3.1
5.0.4: usb 0c.03.30 1022/15e1 255 0:d0400004 1048576
Advanced Micro Devices, Inc. [AMD] Raven USB 3.1
5.0.5: aud 04.80.00 1022/15e2 255 0:d0680000 262144
Advanced Micro Devices, Inc. [AMD] Raven/Raven2/FireFlight/Renoir Audio Processor
5.0.6: aud 04.03.00 1022/15e3 255 0:d06c0000 32768
Advanced Micro Devices, Inc. [AMD] Family 17h (Models 10h-1fh) HD Audio Controller
6.0.0: disk 01.06.01 1022/7901 255 5:d0200000 2048
Advanced Micro Devices, Inc. [AMD] FCH SATA Controller [AHCI mode]
% aux/cpuid
vendor AuthenticAMD
procmodel 00810f81 / 05080800
typefammod 0 17 00f 1
features fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat
features pse36 clflush mmx fxsr sse sse2 ht
features pni pclmulqdq monitor ssse3 fma cx16 sse4_1 sse4_2 movbe popcnt aes xsave avx f16c rdrnd
features xsaveopt
extmodel 00810f81 / 00000000
extfeatures fpu vme de pse tsc msr pae mce cx8 apic syscall mtrr pge mca cmov pat
extfeatures pse36 nx mmx+ mmx fxsr ffxsr pg1g tscp lm
extfeatures ahf64 cmp svm eas cr8d lzcnt sse4a msse 3dnow!p osvw skinit wdt tce topx pcx_core pcx_nb procname AMD Ryzen 7 3700U with Radeon Vega Mobile Gfx
physbits 48
virtbits 48
% aux/icanhasmsi
0.0.2
0.1.1
0.1.2
0.1.3
0.1.6
0.8.1
0.8.2
1.0.0
2.0.0
3.0.0
4.0.0
5.0.0
5.0.1
5.0.2
5.0.3
5.0.4
5.0.5
5.0.6
6.0.0
% aux/icanhasvmx -v
% aux/pcmcia
% cat '#'u/usb/ctl
ep1.0 enabled control rw speed high maxpkt 64 ntds 1 pollival 0 samplesz 0 hz 0 uframes 0 hub 0 port 0 rootport 0 addr 0 busy
roothub csp 0x000009 ports 4 xhci
ep2.0 enabled control rw speed super maxpkt 512 ntds 1 pollival 0 samplesz 0 hz 0 uframes 0 hub 0 port 0 rootport 0 addr 0 busy
roothub csp 0x000009 ports 4 xhci
ep3.0 enabled control rw speed high maxpkt 64 ntds 1 pollival 0 samplesz 0 hz 0 uframes 0 hub 0 port 0 rootport 0 addr 0 busy
roothub csp 0x000009 ports 2 xhci
ep4.0 enabled control rw speed super maxpkt 512 ntds 1 pollival 0 samplesz 0 hz 0 uframes 0 hub 0 port 0 rootport 0 addr 0 busy
roothub csp 0x000009 ports 1 xhci
ep5.0 enabled control rw speed high maxpkt 64 ntds 1 pollival 0 samplesz 0 hz 0 uframes 0 hub 0 port 2 rootport 2 addr 1 idle
239 csp 0x0102ef vid 0x5986 did 0x2113 'SunplusIT Inc' 'Integrated Camera' 36e4c xhci
ep5.1 enabled iso r speed high maxpkt 1020 ntds 3 pollival 10 samplesz 4 hz 44100 uframes 0 hub 0 port 2 rootport 2 addr 1 idle
ep5.7 enabled interrupt r speed high maxpkt 16 ntds 1 pollival 128 samplesz 0 hz 0 uframes 0 hub 0 port 2 rootport 2 addr 1 idle
ep6.0 enabled control rw speed full maxpkt 8 ntds 1 pollival 0 samplesz 0 hz 0 uframes 0 hub 0 port 4 rootport 4 addr 1 busy
hid csp 0x010103 vid 0x046d did 0xc52b Logitech 'USB Receiver' 3d436 xhci
ep6.1 enabled interrupt r speed full maxpkt 8 ntds 1 pollival 8 samplesz 0 hz 0 uframes 0 hub 0 port 4 rootport 4 addr 1 busy
ep6.2 enabled interrupt r speed full maxpkt 8 ntds 1 pollival 2 samplesz 0 hz 0 uframes 0 hub 0 port 4 rootport 4 addr 1 busy
ep6.3 enabled interrupt r speed full maxpkt 32 ntds 1 pollival 2 samplesz 0 hz 0 uframes 0 hub 0 port 4 rootport 4 addr 1 busy
% cat '#'S/sdctl
sdE ahci ahci port 0xffffff00d0200000: 64a ncq ntf mps alp led clo am pm fbs pmb slum pslum iss 3 ncs 31 np 1 ghc 80000002 isr 0 pi 1 0 ver 10301
sdN nvme 1024 units
sdZ ram 4 units
% cat '#'S/sdE0/ctl
inquiry Samsung SSD 840 EVO 250GB
model Samsung SSD 840 EVO 250GB
serial S1DBNSBF928022M
firm EXT0BB6Q
wwn 50025388a070be63
flag lba llba smart nop ata8 sct
udma 6
reg task 50 cmd 404017 serr 0 ci 0 is 0 sig 101 sstatus 133
cmd fbsc fr pod sud st
mode auto sataiii
geometry 488397168 512
alignment 512 0
missirq 0
part data 0 488397168
part esp 64 1024
part openbsd 1024 488397105
% cat '#'S/sdN0/ctl
inquiry HFM512GDHTNG-8710B
model HFM512GDHTNG-8710B
serial NI93T01301
firm 80010C
geometry 1000215216 512
part data 0 1000215216
part esp 2048 534528
part msr 534528 567296
part dos 567296 214454272
part linuxdata 214454272 218648576
part plan9 218648576 419254272
part linuxdata1 419254272 421351424
part linuxswap 421351424 435822592
part linuxdata2 435822592 998166528
part recovery 998166528 1000214528
part 9fat 218648576 218853376
part nvram 218853376 218853377
part other 218853377 247482076
part fscache 247482076 276110775
part fsworm 276110775 419254272
% cat '#'l0/ether0/addr
98fa9b69b552
% cat '#'l0/ether0/stats
in: 3535
link: 1
out: 896
crc errs: 0
overflows: 0
soft overflows: 0
framing errs: 0
buffer errs: 0
output errs: 0
prom: 0
mbps: 100
addr: 98fa9b69b552
% cat '#'l0/ether0/ifstats
TxOk: 896
RxOk: 3535
TxEr: 0
RxEr: 0
MissPkt: 0
FAE: 0
Tx1Col: 0
TxMCol: 0
RxOkPh: 3215
RxOkBrd: 312
RxOkMu: 8
TxAbt: 0
TxUndrn: 0
serr: 0
fovw: 0
txdu: 0
tcpf: 1176
udpf: 2074
ipf: 0
fovf: 0
rer: 0
rdu: 0
punlc: 1
tcr: 0x53900f00
rcr: 0x0000870e
multicast: 8
phy: 1040 79ed 001c c800 01e1 45e1 0065 2801
0000 0200 0000 0000 0000 0000 0000 2000
0000 0000 0000 0000 0000 0000 0000 0000
319a 0043 301c 80d9 7078 0000 0000 0000
% cat '#'v/vgactl
type cga
size 1920x1080x32 x8r8g8b8
hwgc soft
hwaccel off
hwblank off
panning off
addr p 0xc0000000 v 0xffffff00c0000000 size 0x4000000
softscreen on
@{rfork n; aux/realemu; aux/vga -p}
% xd -x1 '#'r/nvram
0000000 07 56 24 26 06 10 01 12 04 20 26 02 50 80 00 00
0000010 00 00 00 00 0a 80 02 00 3c 00 00 00 00 00 00 00
0000020 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 c8
0000030 00 3c 20 00 00 9b 00 00 00 00 00 00 00 00 00 00
0000040 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0000050 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0000060 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0000070 00 00 30 00 00 00 00 00 00 5a 00 00 49 53 b2 00
0000080 07 56 24 26 06 10 01 12 04 20 26 02 40 80 00 00
0000090 00 00 00 00 0a 80 02 00 3c 00 00 00 00 00 00 00
00000a0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 c8
00000b0 00 3c 20 00 00 9b 00 00 00 00 00 00 00 00 00 00
00000c0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00000d0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00000e0 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00000f0 00 00 30 00 00 00 00 00 00 5a 00 00 49 53 b2 00
0000100
0000100
% cat '#'A/audiostat
bufsize 1024 buffered 0
codec 0 pin 23 inpin 26
aout 16 c1d
aout 17 c1d
beep 18 70000c
ain 19 100d1b ← pin 24, pin 25, pin 26, beep 21
ain 20 100d1b ← pin 26, beep 21
beep 21 f0050b ← aout 16, aout 17
pin 22 out jack ext left hpout black eapd ← aout 16, aout 17
pin 23 out fix int rear speaker ? eapd ← aout 16, aout 17
pin 24 in nothing ext N/A other ?
pin 25 in jack ext left micin black
pin 26 in fix int top micin ?
beep 27 f00000
beep 28 f00000
beep 29 f0058b
beep 30 f0058b
beep 31 f0058b
aout 32 611
pin 33 out nothing ext N/A other ? ← aout 32
outpath aout 16 → pin 23
outamp aout 16
inpath pin 26 → ain 19
inamp ain 19
% cat '#'A/volume
master 100 100
recgain 0 0
speed 44100
delay 1764
% cat /mnt/apm/ctl
[-- Attachment #3.1: Type: text/plain, Size: 325 bytes --]
from postmaster@plan9:
The following attachment had content that we can't
prove to be harmless. To avoid possible automatic
execution, we changed the content headers.
The original header was:
Content-Disposition: attachment; filename=usb.patch
Content-Type: text/plain; charset="US-ASCII"
Content-Transfer-Encoding: 7bit
[-- Attachment #3.2: usb.patch.suspect --]
[-- Type: application/octet-stream, Size: 1221 bytes --]
diff -r 22dd54063d2c sys/src/cmd/nusb/kb/kb.c
--- a/sys/src/cmd/nusb/kb/kb.c Sat Apr 11 18:09:48 2020 +0200
+++ b/sys/src/cmd/nusb/kb/kb.c Sun Apr 12 04:35:20 2020 +0200
@@ -330,12 +330,21 @@
iface = f->dev->usb->ep[eid]->iface;
- /*
- * DWC OTG controller misses some split transaction inputs.
- * Set nonzero idle time to return more frequent reports
- * of keyboard state, to avoid losing key up/down events.
+ /* Appendix G of the USB Hid spec says that only boot mouse and boot keyboards
+ * are required to support setting the protocol, so only try it for those.
*/
- usbcmd(f->dev, Rh2d|Rclass|Riface, Setidle, 8<<8, iface->id, nil, 0);
+ if (iface->csp != KbdCSP && iface->csp != PtrCSP)
+ return 0;
+
+ /* Only set the idle time keyboards since only those are required to support it */
+ if (iface->csp == KbdCSP) {
+ /*
+ * DWC OTG controller misses some split transaction inputs.
+ * Set nonzero idle time to return more frequent reports
+ * of keyboard state, to avoid losing key up/down events.
+ */
+ usbcmd(f->dev, Rh2d|Rclass|Riface, Setidle, 8<<8, iface->id, nil, 0);
+ }
f->nrep = usbcmd(f->dev, Rd2h|Rstd|Riface, Rgetdesc, Dreport<<8, iface->id,
f->rep, sizeof(f->rep));
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [9front] nusb/kb: add support for my mouse
2020-04-12 5:02 [9front] nusb/kb: add support for my mouse petermikkelsen10
@ 2020-04-12 5:14 ` ori
2020-04-12 6:03 ` Stanley Lieber
0 siblings, 1 reply; 3+ messages in thread
From: ori @ 2020-04-12 5:14 UTC (permalink / raw)
To: petermikkelsen10, 9front
> Hello,
>
> I have recently installed 9front on my laptop and only some USB mice seems to work. After a bit of investigation it
> turned out that my issues were with the kind of mice that presented part of them as a pointing device, and part of them
> as a keyboard. I had a look at the USB Hid spec, and it seems like some of the things that nusb/kb does
> (like setting the idle time) is not always supported by all types of devices, so this patch changes those things.
>
> It fixes the problems for me so now I can use my mouse. A sysinfo is attached.
>
> (Sorry if I am spamming the list, it doesn't seem like my mails are getting through..)
They're getting through for me.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [9front] nusb/kb: add support for my mouse
2020-04-12 5:14 ` ori
@ 2020-04-12 6:03 ` Stanley Lieber
0 siblings, 0 replies; 3+ messages in thread
From: Stanley Lieber @ 2020-04-12 6:03 UTC (permalink / raw)
To: 9front
On April 12, 2020 1:14:26 AM EDT, ori@eigenstate.org wrote:
>> Hello,
>>
>> I have recently installed 9front on my laptop and only some USB mice
>seems to work. After a bit of investigation it
>> turned out that my issues were with the kind of mice that presented
>part of them as a pointing device, and part of them
>> as a keyboard. I had a look at the USB Hid spec, and it seems like
>some of the things that nusb/kb does
>> (like setting the idle time) is not always supported by all types of
>devices, so this patch changes those things.
>>
>> It fixes the problems for me so now I can use my mouse. A sysinfo is
>attached.
>>
>> (Sorry if I am spamming the list, it doesn't seem like my mails are
>getting through..)
>
>They're getting through for me.
lately some subscribers report not receiving copies of their own messages to the list. cause currently unlnown. i dont find any errors related to the addresses in the logs. note: all reported problems are for gmail addresses.
sl
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-04-12 6:03 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-12 5:02 [9front] nusb/kb: add support for my mouse petermikkelsen10
2020-04-12 5:14 ` ori
2020-04-12 6:03 ` Stanley Lieber
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).