From nobody Sat Sep 17 16:09:10 2022 X-Original-To: freebsd-arm@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 4MVG8q2w2dz2kwBQ for ; Sat, 17 Sep 2022 16:09:15 +0000 (UTC) (envelope-from marklmi@yahoo.com) Received: from sonic305-20.consmr.mail.gq1.yahoo.com (sonic305-20.consmr.mail.gq1.yahoo.com [98.137.64.83]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4MVG8p1K1pz3Scp for ; Sat, 17 Sep 2022 16:09:14 +0000 (UTC) (envelope-from marklmi@yahoo.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1663430951; bh=HU28ZmlrtanvBHv1X+dhwZ+Uhc4+ac1tJZP7eR+vaes=; h=From:Subject:Date:To:References:From:Subject:Reply-To; b=l+WBSe7Lw18VqXoz65b5/CxsAvyNlpnge+Ihmy+9CYZvCQ43dOES4Fc6DvcG/Up+5BZv+YQVUqFpXiXNExoIzHJ4fiAUedIoz00rONCYF7+ObJLV/CySM64IKNLN6ClyFUbsiEEjRe4jA6KXi+0XF92OOv+Zw1uS6TF13foL+FR8MVzJULNF+jV8FuNljqMj3gP0oUtKihiVxNX91I+oP9bCfXe5wojNDUjmWsVw6ptk9KoN7PNoYIYgZJn7D8xit1rpGC9s/b7xSRkgr5NsdP8HLNjr0A8kA5CrfCKPFCIdEeWbSGEOKTUUu0qDUOunU/APpEhJW8Nplhk6yX27Aw== X-SONIC-DKIM-SIGN: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s2048; t=1663430951; bh=Fe0mCX4OZ61iSgg8G8WzTxu9Cns9mtVdNhV1tIRFW7o=; h=X-Sonic-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GdiIUNz8Njo9Ydy.pm6HlwRpXXEEk rRM9rUQIUbxy0Oa1m_dHCwg_P1QsIPU._468GxscAQVAzfFr_pG_x1TQxhLaFwINkAOMJ7im4E8q KP8G8FN5fhMEUYzo2bwxUviDHaIgdo8xp9gRVif1P7LYoBMRQaO.aYjjoYCqIbZE56W6eOCEmGvs 1yalKax84vHOEjF5pqONvykN5TKcR2PwSSKvUJF2WMe5JLPUY1gxxcpg7uBhYymuVPBtinwQmbIo wuPQVHO1IOU9fXI0i4I_328uDFITSEhByJbOgPUIVRtJfY3Mha.BNhLnZcpKzjtmUK8Ko4Ep2BrX 1majkWOSpEgo8LSx1WI3pq8rGCZnvV.xMCAaFgp2S6.LZDQkD5yLuDPl8pVixuDIEkkufowH_7V0 sZs7uyRvHeUZvUZNOn88dhZC6i0WM_u_8p4BugVDav1ENS0o6KxsuD3uj8va0Gscxzt_.hCt1GOO ruMJ_e2Bg5.b_qmLXcqTxXeZJ9LmPJRepKJUpZUHhFEIBcuyoTcWsvkSq0lbzqqw- X-Sonic-MF: Received: from sonic.gate.mail.ne1.yahoo.com by sonic305.consmr.mail.gq1.yahoo.com with HTTP; Sat, 17 Sep 2022 16:09:11 +0000 Received: by hermes--production-gq1-5499fdd576-49dgt (Yahoo Inc. Hermes SMTP Server) with ESMTPA ID 0c963d3e107db8075da25b378210d9d1; Sat, 17 Sep 2022 16:09:10 +0000 (UTC) From: Mark Millard Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable List-Id: Porting FreeBSD to ARM processors List-Archive: https://lists.freebsd.org/archives/freebsd-arm List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-arm@freebsd.org Mime-Version: 1.0 (Mac OS X Mail 14.0 \(3654.120.0.1.13\)) Subject: FYI: RPi4B's and such: VLI_SS_BULK_OUT_BUG quirk handling vs. VL805 (linux example) Message-Id: <34A55B2A-1351-4D9A-B5E1-536F32F5F559@yahoo.com> Date: Sat, 17 Sep 2022 09:09:10 -0700 To: freebsd-arm X-Mailer: Apple Mail (2.3654.120.0.1.13) References: <34A55B2A-1351-4D9A-B5E1-536F32F5F559.ref@yahoo.com> X-Rspamd-Queue-Id: 4MVG8p1K1pz3Scp X-Spamd-Bar: --- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=yahoo.com header.s=s2048 header.b=l+WBSe7L; dmarc=pass (policy=reject) header.from=yahoo.com; spf=pass (mx1.freebsd.org: domain of marklmi@yahoo.com designates 98.137.64.83 as permitted sender) smtp.mailfrom=marklmi@yahoo.com X-Spamd-Result: default: False [-3.28 / 15.00]; NEURAL_HAM_LONG(-0.97)[-0.971]; NEURAL_HAM_MEDIUM(-0.94)[-0.942]; NEURAL_HAM_SHORT(-0.87)[-0.870]; DMARC_POLICY_ALLOW(-0.50)[yahoo.com,reject]; MV_CASE(0.50)[]; R_DKIM_ALLOW(-0.20)[yahoo.com:s=s2048]; R_SPF_ALLOW(-0.20)[+ptr:yahoo.com]; MIME_GOOD(-0.10)[text/plain]; ARC_NA(0.00)[]; FROM_HAS_DN(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; TO_MATCH_ENVRCPT_ALL(0.00)[]; DWL_DNSWL_NONE(0.00)[yahoo.com:dkim]; RCPT_COUNT_ONE(0.00)[1]; MID_RHS_MATCH_FROM(0.00)[]; ASN(0.00)[asn:36647, ipnet:98.137.64.0/20, country:US]; RCVD_IN_DNSWL_NONE(0.00)[98.137.64.83:from]; TO_DN_ALL(0.00)[]; RCVD_COUNT_THREE(0.00)[3]; FREEMAIL_FROM(0.00)[yahoo.com]; RCVD_TLS_LAST(0.00)[]; DKIM_TRACE(0.00)[yahoo.com:+]; MIME_TRACE(0.00)[0:+]; FROM_EQ_ENVFROM(0.00)[]; FREEMAIL_ENVFROM(0.00)[yahoo.com]; MLMMJ_DEST(0.00)[freebsd-arm@freebsd.org] X-ThisMailContainsUnwantedMimeParts: N https://github.com/raspberrypi/linux/pull/5173 reports: QUOTE After several months back-and-forth with VIA, we have a candidate = root-cause for #4844 and a suggested fix. My known-bad pendrive now gets = written to endlessly without suffering data corruption. END QUOTE and: QUOTE usb: xhci: expand mitigations for VLI_SS_BULK_OUT_BUG quirk =E2=80=A6 = c9e051a The VL805 can cause data corruption if a SS Bulk OUT endpoint enters a flow-control condition and there are TRBs in the transfer ring that are not an integral size of wMaxPacket and the endpoint is behind one or = more hubs. This is frequently the case encountered when FAT32 filesystems are present on mass-storage devices with cluster sizes of 1 sector, and the filesystem is being written to with an aggregate of small files. The initial implementation of this quirk separated TRBs that didn't adhere to this limitation into two - the first a multiple of wMaxPacket and the second the 512-byte remainder - in an attempt to force TD fragments to align with packet boundaries. This reduced the incidence rate of data corruption but did not resolve it. The fix as recommended by VIA is to disable bursts if this sequence of TRBs can occur. Limit turning off bursts to just USB mass-storage devices by searching the device's configuration for an interface with a class type of USB_CLASS_MASS_STORAGE. Signed-off-by: Jonathan Bell END QUOTE and the drivers/usb/host/xhci-mem.c change has the comments: /* * VL805 errata - Bulk OUT bursts to superspeed mass-storage * devices behind hub ports can cause data corruption with * non-wMaxPacket-multiple transfers. */ . . . /* * Slight hack - look at interface altsetting 0, which * should be the UMS bulk-only interface. If the class * matches, then we disable out bursts for all OUT * endpoints because endpoint assignments may change * between alternate settings. */ =3D=3D=3D Mark Millard marklmi at yahoo.com