From nobody Sun Mar 13 06:27:09 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 2A7CB1A247DE for ; Sun, 13 Mar 2022 06:27:20 +0000 (UTC) (envelope-from archimedes.gaviola@gmail.com) Received: from mail-ej1-x629.google.com (mail-ej1-x629.google.com [IPv6:2a00:1450:4864:20::629]) (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-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1D4" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4KGV872xRfz3HBS for ; Sun, 13 Mar 2022 06:27:19 +0000 (UTC) (envelope-from archimedes.gaviola@gmail.com) Received: by mail-ej1-x629.google.com with SMTP id a8so27530303ejc.8 for ; Sat, 12 Mar 2022 22:27:19 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=0zkD9gkxn1rftqnIvkhh6RrVAK8znRetFStSe55Tbyo=; b=ZXOX0eNZCZFygVeNi/5JLyKUV54G/Evpb+vjHpzYuuWxnhBtv5gt1iP+F/fUCjTP3C 8rqH9r2ImyM+rTQMRpaUj77fR8v9fEZbiLqted8wlvVIva6lVVae34A3+0kQeUtOOhN+ hMAIhekL/2O/2JsVlflHRSxxBTHXNvj8iprxKBnQWYssHimBQvmYt2tE2q6hTJE/kP9p 6Eag63r4x+zLK8vhc6PfrkplNkBBz1q8nWc8OjJ1aJt9IVilb99HD17dwxaf4vKnN2Ox SVyxcgDhMhhIpyHf5v2XiBTv9Q12O0rtGHTkqU8xkTKuStz/ILS+uiUUnJOJVgyTeWmk QyYg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=0zkD9gkxn1rftqnIvkhh6RrVAK8znRetFStSe55Tbyo=; b=OM5NWJjfPP36+PJZVtsWOO71f9TW3OTtCXfcaOK8eqoJrp42pR0gCZbahg3Y9VVAeQ tZwukEkIzpmErETmlpkzeSeAkq77Nk4pNDIB0ykRvpTNMdmMSKXBBu6BUnW3+h/0d8jK ie/r2cY3jI/iXI6+k7S7Z92eiEVDjU4ITT2MechJQfmm5h/g0WoOpl27YUoypMf4kE31 cFGEqPOCZhKDDmGdo3lshzJGIdek+XyNhRe8cCDiHRqcQ+v7e6bGMTYNg11jsAjnjxW3 hHnOLpgALorSJHymhO26IInEwBWFvbOl+nKvS9PP+unUaCwx/tFRfOOmQ/wqbVUg+zzt z4rQ== X-Gm-Message-State: AOAM531oAbWw/d1fDYR/2NKn0RPs9XqIPjiH4gynVx6DB/Zq9NnmusVe FOkUqMexvsilUP9He/+kriDG8K6dkH2n2RLbvFu4YwdrkMo= X-Google-Smtp-Source: ABdhPJw6fiYSbmO2t7D+1Z56DyyGY7rahkKZiDl4I8aCIoz93Mpc0grnel373x7YAc0PQ6QIH/FUkxxDCx0sxhiI2Bo= X-Received: by 2002:a17:907:a41f:b0:6d6:f925:1696 with SMTP id sg31-20020a170907a41f00b006d6f9251696mr14916188ejc.62.1647152838399; Sat, 12 Mar 2022 22:27:18 -0800 (PST) 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 References: <7c67118e-f6ec-c87d-9a81-3ee6a5952f49@selasky.org> <60f98b10-dcdc-cdf4-3d7a-fe9fd4dff223@selasky.org> <8226461b-5740-9c19-0575-2740bd952e16@selasky.org> In-Reply-To: From: Archimedes Gaviola Date: Sun, 13 Mar 2022 14:27:09 +0800 Message-ID: Subject: Re: Raspberry Pi 3B USB Printing Issue To: Hans Petter Selasky Cc: freebsd-arm@freebsd.org Content-Type: multipart/alternative; boundary="000000000000d2de2405da13a750" X-Rspamd-Queue-Id: 4KGV872xRfz3HBS X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org; dkim=pass header.d=gmail.com header.s=20210112 header.b=ZXOX0eNZ; dmarc=pass (policy=none) header.from=gmail.com; spf=pass (mx1.freebsd.org: domain of archimedesgaviola@gmail.com designates 2a00:1450:4864:20::629 as permitted sender) smtp.mailfrom=archimedesgaviola@gmail.com X-Spamd-Result: default: False [-2.73 / 15.00]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip6:2a00:1450:4000::/36:c]; FREEMAIL_FROM(0.00)[gmail.com]; MID_RHS_MATCH_FROMTLD(0.00)[]; DKIM_TRACE(0.00)[gmail.com:+]; RCPT_COUNT_TWO(0.00)[2]; DMARC_POLICY_ALLOW(-0.50)[gmail.com,none]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+,1:+,2:~]; FREEMAIL_ENVFROM(0.00)[gmail.com]; ASN(0.00)[asn:15169, ipnet:2a00:1450::/32, country:US]; TAGGED_FROM(0.00)[]; DWL_DNSWL_NONE(0.00)[gmail.com:dkim]; ARC_NA(0.00)[]; NEURAL_HAM_MEDIUM(-1.00)[-0.997]; R_DKIM_ALLOW(-0.20)[gmail.com:s=20210112]; FROM_HAS_DN(0.00)[]; NEURAL_SPAM_SHORT(0.27)[0.267]; NEURAL_HAM_LONG(-1.00)[-1.000]; MIME_GOOD(-0.10)[multipart/alternative,text/plain]; PREVIOUSLY_DELIVERED(0.00)[freebsd-arm@freebsd.org]; TO_MATCH_ENVRCPT_SOME(0.00)[]; RCVD_IN_DNSWL_NONE(0.00)[2a00:1450:4864:20::629:from]; MLMMJ_DEST(0.00)[freebsd-arm]; RCVD_COUNT_TWO(0.00)[2]; RCVD_TLS_ALL(0.00)[] X-ThisMailContainsUnwantedMimeParts: N Status: O Content-Length: 6404 Lines: 155 --000000000000d2de2405da13a750 Content-Type: text/plain; charset="UTF-8" On Sun, Mar 13, 2022 at 12:38 AM Hans Petter Selasky wrote: > On 3/12/22 16:31, Archimedes Gaviola wrote: > >> > >> IOERROR usually means an electrical error. The RPI3B will use a > >> transaction translator for the FULL speed traffic, which is driven by > >> software. > > > > Hi Archimedes, > > > Hi Hans, > > > > I'm curious about the transaction translator you've mentioned, any idea > why > > there's a need for translation and what is being translated? > > When the High Speed USB HUB was invented, there was a need to support > FULL and LOW speed USB transactions. Because FULL and LOW speed > transactions are slow and take up much bandwidth, a transactions > translator was invented which translates between High Speed USB and > FULL/LOW speed USB. That means the RPi 3B consists of a single USB HIGH > speed port, followed by a USB HUB. These transactions are not visible in > usbdump . > > >Does this only > > happen when RPi 3B (acting as host controller) is transmitting data to > the > > Epson printer? Are translation events visible in the usbdump? In this > case > > there's a way to possibly track what's going on and how to identify any > > info that is being translated? > > By turning on the HC debugging, you can possibly track via debug > messages what is going on. Maybe it is a timing issue, that the SW is > too slow serving the micro transactions. > > Any idea also if translation is being > > performed in RPi 4B? > > The later RPi's do the transaction translator bits in HW or via the XHCI > block. > > As I have conducted several printing cases with my > > Epson printer without any issues with either of the 4 ports. > > > > Sorry for these questions as I am catching-up to the USB technology > > internal workings under the hood. > > You are welcome! > Thank you so much Hans for answering my questions, really appreciate it! I have a much better understanding now. I came from testing with 13.0-RELEASE having the same RPi 3B hardware and setup and it's very stable. I haven't encountered any IOERROR and incomplete printed outputs that were encountered with 14.0-CURRENT (February 24, 2022). By the way, I found in the repository here https://download.freebsd.org/snapshots/arm64/aarch64/ISO-IMAGES/14.0/ that there were two latest snapshots released dated March 3 and March 10, respectively. I need to take printing tests first, especially the latest to check if it also manifests before I go back to the Feb. 24 snapshot and do a thorough test with debugging. I'll provide updates for any observations. Thanks, Archimedes --000000000000d2de2405da13a750 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable


=
On Sun, Mar 13, 2022 at 12:38 AM Hans= Petter Selasky <hps@selasky.org&= gt; wrote:
On 3/= 12/22 16:31, Archimedes Gaviola wrote:
>>
>> IOERROR usually means an electrical error. The RPI3B will use a >> transaction translator for the FULL speed traffic, which is driven= by
>> software.
>

Hi Archimedes,

> Hi Hans,
>
> I'm curious about the transaction translator you've mentioned,= any idea why
> there's a need for translation and what is being translated?

When the High Speed USB HUB was invented, there was a need to support
FULL and LOW speed USB transactions. Because FULL and LOW speed
transactions are slow and take up much bandwidth, a transactions
translator was invented which translates between High Speed USB and
FULL/LOW speed USB. That means the RPi 3B consists of a single USB HIGH speed port, followed by a USB HUB. These transactions are not visible in usbdump .

=C2=A0>Does this only
> happen when RPi 3B (acting as host controller) is transmitting data to= the
> Epson printer? Are translation events visible in the usbdump? In this = case
> there's a way to possibly track what's going on and how to ide= ntify any
> info that is being translated?

By turning on the HC debugging, you can possibly track via debug
messages what is going on. Maybe it is a timing issue, that the SW is
too slow serving the micro transactions.

Any idea also if translation is being
> performed in RPi 4B?

The later RPi's do the transaction translator bits in HW or via the XHC= I
block.

As I have conducted several printing cases with my
> Epson printer without any issues with either of the 4 ports.
>
> Sorry for these questions as I am catching-up to the USB technology > internal workings under the hood.

You are welcome!


Thank you so much Hans for answering my questions, really appreci= ate it! I have a much better understanding now.

I came from testing with 13.0= -RELEASE having the same RPi 3B hardware and setup and it's very stable= . I haven't encountered any IOERROR and incomplete printed outputs that= were encountered with 14.0-CURRENT (February 24, 2022). By the way, I foun= d in the repository here https://download.freebsd.org/snapshots/arm6= 4/aarch64/ISO-IMAGES/14.0/ that there were two latest snapshots release= d dated March 3 and March 10, respectively. I need to take printing tests f= irst, especially the latest to check if it also manifests before I go back = to the Feb. 24 snapshot and do a thorough test with debugging. I'll pro= vide updates for any observations.

=
Thanks,
Archimedes


--000000000000d2de2405da13a750--