All of lore.kernel.org
 help / color / mirror / Atom feed
From: Mehmet Fide <mehmet.fide@gmail.com>
To: Marek Vasut <marek.vasut+usb@mailbox.org>,
	Simon Glass <sjg@chromium.org>
Cc: Tom Rini <trini@konsulko.com>,
	u-boot@lists.u-boot-project.org,
	Mehmet Fide <mehmet.fide@screeningeagle.com>
Subject: [PATCH v2 0/4] usb: ehci-vf: take the register bases from the device tree
Date: Thu, 20 Aug 2026 09:15:07 +0200	[thread overview]
Message-ID: <20260820071511.1036506-1-mehmet.fide@gmail.com> (raw)

From: Mehmet Fide <mehmet.fide@screeningeagle.com>

Review of v1 asked for three things and they are all here.

Marek asked whether the code path removed in patch 1 is used in SPL
without DM_USB. The question is a fair one, because the select of DM_USB
that USB_EHCI_HCD does only covers U-Boot proper: in an SPL build
CONFIG_IS_ENABLED(DM_USB) reads CONFIG_SPL_DM_USB, so a board could take
that path there. No build can, though. The driver depends on ARCH_VF610,
five boards select it, drivers/Makefile builds usb/host/ for SPL only
when SPL_USB_HOST is set, and none of the five sets it or CONFIG_SPL at
all. The path also does not compile, which is how it stayed unnoticed.

Patch 2 carries the two Fixes tags Marek pointed at.

Patch 4 no longer uses fdtdec. v1 did, because that is what ehci-mx6
does in mx6_parse_dt_addrs(), but the livetree calls are what review
asked for and the driver now has none of the flat tree API left, not
even the include.

One piece was missing for that. The alias of a node reached through a
phandle could not be read with the livetree API at all: dev_read_alias_seq()
wants a device, of_alias_get_id() wants a live tree and these boards run
a flat one, and ofnode_get_aliases_node() answers the other direction.
Only fdtdec could do it. That gap has stood because the need is rare -
ehci-mx6 is the only driver in the tree that ever asked for the alias of
a node it does not own, and it reached for fdtdec. Patch 3 moves the body
of dev_read_alias_seq() down to the ofnode level and lets both of its
variants call it, so patch 4 has a livetree call to use. It is a pure
move, no functional change.

Testing. test/py on sandbox, before and after patch 3: 11 failed, 414
passed, 210 skipped, 1 xfailed, 20 errors, the same failures both times,
all of them from tools and images missing in my environment.

On a Colibri VF50 V1.2A on an Iris carrier, U-Boot 2026.07 from NAND:
"usb start" brings the host controller up and enumerates the root hub,
and Linux still boots with Ethernet, SD card and USB working.

v1: https://lore.kernel.org/u-boot/20260819093705.4143509-1-mehmet.fide@gmail.com/

Mehmet Fide (4):
  usb: ehci-vf: remove the code path for a build without DM_USB
  usb: ehci-vf: drop the empty bind hook
  dm: core: add ofnode_get_alias_seq()
  usb: ehci-vf: take the register bases from the device tree

 drivers/core/ofnode.c      |  20 +++++
 drivers/core/read.c        |  20 +----
 drivers/usb/host/ehci-vf.c | 178 +++++++++++++------------------------
 include/dm/ofnode.h        |  14 +++
 include/dm/read.h          |   8 +-
 5 files changed, 102 insertions(+), 138 deletions(-)

-- 
2.54.0


             reply	other threads:[~2026-08-20  7:15 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-08-20  7:15 Mehmet Fide [this message]
2026-08-20  7:15 ` [PATCH v2 1/4] usb: ehci-vf: remove the code path for a build without DM_USB Mehmet Fide
2026-08-20  7:15 ` [PATCH v2 2/4] usb: ehci-vf: drop the empty bind hook Mehmet Fide
2026-08-20  7:15 ` [PATCH v2 3/4] dm: core: add ofnode_get_alias_seq() Mehmet Fide
2026-08-20  7:15 ` [PATCH v2 4/4] usb: ehci-vf: take the register bases from the device tree Mehmet Fide
2026-08-21  0:29 ` [PATCH v2 0/4] " Marek Vasut
2026-08-21  5:56   ` Mehmet Fide

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20260820071511.1036506-1-mehmet.fide@gmail.com \
    --to=mehmet.fide@gmail.com \
    --cc=marek.vasut+usb@mailbox.org \
    --cc=mehmet.fide@screeningeagle.com \
    --cc=sjg@chromium.org \
    --cc=trini@konsulko.com \
    --cc=u-boot@lists.u-boot-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.