From nobody Wed Nov 24 22:33:55 2021 X-Original-To: freebsd-usb@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 0AA6018AEC79 for ; Wed, 24 Nov 2021 22:34:04 +0000 (UTC) (envelope-from darius@dons.net.au) Received: from midget.dons.net.au (2403-5800-5200-4700-225-90ff-fe47-39b4.ip6.aussiebb.net [IPv6:2403:5800:5200:4700:225:90ff:fe47:39b4]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature ECDSA (P-384) client-digest SHA384) (Client CN "dons.net.au", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4Hzwlt694xz4rcd for ; Wed, 24 Nov 2021 22:34:02 +0000 (UTC) (envelope-from darius@dons.net.au) Received: from smtpclient.apple (2403-5800-5200-4700-c181-45e6-ef69-9817.ip6.aussiebb.net [IPv6:2403:5800:5200:4700:c181:45e6:ef69:9817]) (authenticated bits=0) by midget.dons.net.au (8.16.1/8.16.1) with ESMTPSA id 1AOMXulq049668 (version=TLSv1.2 cipher=ECDHE-ECDSA-AES256-GCM-SHA384 bits=256 verify=NO) for ; Thu, 25 Nov 2021 09:03:56 +1030 (ACDT) (envelope-from darius@dons.net.au) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=dons.net.au; s=default; t=1637793240; bh=c9lqpN+UXNBV4OJ+4dEiW/I/bEptqB8d0F0HspH448o=; h=From:Subject:Date:To; b=k8CFzyvzFynbuCOOAhZdvwypqiPU7fiM7KnJLhplQLsRuKEosK1bYbOT5p+4Gtn6y FVFI99kfpQPH2t5/L6i7ARsXa8nYlRTjjmX1PJu37egC1T7/jHSSP0pcV/LjwsENW2 8UEgkKdDRMqCbQ+9atyl9BibYjkwM76RWEG9eXkk= X-Authentication-Warning: midget.dons.net.au: Host 2403-5800-5200-4700-c181-45e6-ef69-9817.ip6.aussiebb.net [IPv6:2403:5800:5200:4700:c181:45e6:ef69:9817] claimed to be smtpclient.apple From: "Daniel O'Connor" Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable List-Id: FreeBSD List-Archive: https://lists.freebsd.org/archives/freebsd-usb List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-usb@freebsd.org X-BeenThere: freebsd-usb@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.120.0.1.13\)) Subject: Poor USB performance on ASUS 520 motherboard (no IRQ?) Message-Id: Date: Thu, 25 Nov 2021 09:03:55 +1030 To: freebsd-usb@freebsd.org X-Mailer: Apple Mail (2.3654.120.0.1.13) X-Spam-Score: 0 () No, score=-0.0 required=5.0 tests=NO_RECEIVED,NO_RELAYS autolearn=unavailable autolearn_force=no version=3.4.4 X-Scanned-By: MIMEDefang 2.83 X-Rspamd-Queue-Id: 4Hzwlt694xz4rcd X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=fail ("headers rsa verify failed") header.d=dons.net.au header.s=default header.b=k8CFzyvz; dmarc=pass (policy=quarantine) header.from=dons.net.au; spf=pass (mx1.freebsd.org: domain of darius@dons.net.au designates 2403:5800:5200:4700:225:90ff:fe47:39b4 as permitted sender) smtp.mailfrom=darius@dons.net.au X-Spamd-Result: default: False [-3.29 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; RCVD_TLS_ALL(0.00)[]; FROM_HAS_DN(0.00)[]; R_SPF_ALLOW(-0.20)[+mx:c]; R_DKIM_REJECT(0.00)[dons.net.au:s=default]; MIME_GOOD(-0.10)[text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-usb@freebsd.org]; HAS_XAW(0.00)[]; MV_CASE(0.50)[]; RCPT_COUNT_ONE(0.00)[1]; TO_DN_NONE(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DKIM_TRACE(0.00)[dons.net.au:-]; MID_RHS_MATCH_FROM(0.00)[]; DMARC_POLICY_ALLOW(0.00)[dons.net.au,quarantine]; NEURAL_HAM_SHORT(-0.99)[-0.990]; DMARC_POLICY_ALLOW_WITH_FAILURES(-0.50)[]; NEURAL_HAM_LONG(-1.00)[-1.000]; NEURAL_HAM_MEDIUM(-1.00)[-1.000]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:4764, ipnet:2403:5800:5000::/36, country:AU]; RCVD_COUNT_TWO(0.00)[2]; SUBJECT_HAS_QUESTION(0.00)[] X-ThisMailContainsUnwantedMimeParts: N [ Originally sent to freebsd-stable@ ] Hi, We bought a few low end motherboards to drive our hardware which is = controlled by a custom USB (Cypress FX2 interface) board. I found that the Gigabyte GA-A320M-H one works fine but the ASUS = A520M-A/CSM one is significantly slower for tests where there are many = back and forth messages (streaming data seems fine). I've tried updating the BIOS and tested FreeBSD 12 (same as the = Gigabyte) and FreeBSD 13 with no change. One thing I did notice is this dmesg output: xhci0: mem 0xfcfa0000-0xfcfa7fff at = device 0.0 on pci1 xhci0: 32 bytes context size, 64-bit DMAxhci1: mem 0xfcb00000-0xfcbfffff at = device 0.3 on pci7 xhci1: 64 bytes context size, 64-bit DMA .. xhci2: mem 0xfca00000-0xfcafffff at = device 0.4 on pci7 xhci2: 64 bytes context size, 64-bit DMA vs the working one: xhci0: mem 0xfcea0000-0xfcea7fff irq = 28 at device 0.0 on pci1 xhci0: 32 bytes context size, 64-bit DMA ... xhci1: mem 0xfca00000-0xfcafffff irq = 55 at device 0.3 on pci7 xhci1: 64 bytes context size, 64-bit DMA xhci1: Unable to map MSI-X table ... xhci2: mem 0xfc900000-0xfc9fffff irq = 52 at device 0.4 on pci7 xhci2: 64 bytes context size, 64-bit DMA xhci2: Unable to map MSI-X table I think the MSI-X warning is a difference between 12 & 13 but the lack = of IRQ appears to be common to the brokenness. I tried setting these with no change: hw.pci.honor_msi_blacklist=3D"0" hw.pci.msix_rewrite_table=3D"1" And also without success: hw.pci.enable_msix=3D"0" hw.pci.enable_msi=3D"0" pciconf -lcvb shows: xhci0@pci0:1:0:0: class=3D0x0c0330 card=3D0x11421b21 = chip=3D0x43ec1022 rev=3D0x00 hdr=3D0x00 vendor =3D 'Advanced Micro Devices, Inc. [AMD]' class =3D serial bus subclass =3D USB bar [10] =3D type Memory, range 64, base 0xfcfa0000, size 32768, = enabled cap 05[50] =3D MSI supports 8 messages, 64 bit cap 11[68] =3D MSI-X supports 8 messages Table in map 0x10[0x2000], PBA in map 0x10[0x2080] cap 01[78] =3D powerspec 3 supports D0 D3 current D0 cap 10[80] =3D PCI-Express 2 legacy endpoint max data 128(512) RO NS link x4(x4) speed 8.0(8.0) ASPM disabled(L0s/L1) ecap 0001[100] =3D AER 1 0 fatal 0 non-fatal 1 corrected ecap 0019[200] =3D PCIe Sec 1 lane errors 0 ecap 0018[300] =3D LTR 1 xhci1@pci0:7:0:3: class=3D0x0c0330 card=3D0x876b1043 = chip=3D0x15e01022 rev=3D0x00 hdr=3D0x00 vendor =3D 'Advanced Micro Devices, Inc. [AMD]' device =3D 'Raven USB 3.1' class =3D serial bus subclass =3D USB bar [10] =3D type Memory, range 64, base 0xfcb00000, size 1048576, = enabled cap 09[48] =3D vendor (length 8) cap 01[50] =3D powerspec 3 supports D0 D3 current D0 cap 10[64] =3D PCI-Express 2 endpoint max data 256(256) RO NS link x16(x16) speed 8.0(8.0) ASPM disabled(L0s/L1) cap 05[a0] =3D MSI supports 8 messages, 64 bit cap 11[c0] =3D MSI-X supports 8 messages Table in map 0x10[0xfe000], PBA in map 0x10[0xff000] ecap 000b[100] =3D Vendor 1 ID 1 xhci2@pci0:7:0:4: class=3D0x0c0330 card=3D0x876b1043 = chip=3D0x15e11022 rev=3D0x00 hdr=3D0x00 vendor =3D 'Advanced Micro Devices, Inc. [AMD]' device =3D 'Raven USB 3.1' class =3D serial bus subclass =3D USB bar [10] =3D type Memory, range 64, base 0xfca00000, size 1048576, = enabled cap 09[48] =3D vendor (length 8) cap 01[50] =3D powerspec 3 supports D0 D3 current D0 cap 10[64] =3D PCI-Express 2 endpoint max data 256(256) RO NS link x16(x16) speed 8.0(8.0) ASPM disabled(L0s/L1) cap 05[a0] =3D MSI supports 8 messages, 64 bit cap 11[c0] =3D MSI-X supports 8 messages Table in map 0x10[0xfe000], PBA in map 0x10[0xff000] ecap 000b[100] =3D Vendor 1 ID 1 I'm happy to try a newer kernel or patches if anyone has suggestions :) Thanks. -- Daniel O'Connor "The nice thing about standards is that there are so many of them to choose from." -- Andrew Tanenbaum