Re: [PATCH 0/3] Add UFS Host driver support for SpacemiT K3 SoC
Anirudh Srinivasan <[email protected]> Sun, 19 Jul 2026 18:20:08 -0500
| Newsgroups | dev.linux.lists.spacemit,org.infradead.lists.linux-riscv,org.kernel.vger.linux-devicetree,org.kernel.vger.linux-kernel,org.kernel.vger.linux-scsi |
|---|---|
| Message-ID | <CAEev2e_hmQBrk3Vfv4WmeH+ex_gMwW_9mgNKaUjFaiCScxAqTQ@mail.gmail.com> |
Hi Yixun, On Mon, Jul 13, 2026 at 6:57 PM Yixun Lan <[email protected]> wrote: > > Hi Anirudh, > > On 09:56 Mon 13 Jul , Anirudh Srinivasan wrote: > > Hi Yixun, > > > > On Mon, Jul 13, 2026 at 7:38 AM Yixun Lan <[email protected]> wrote: > > > > > > Hi Anirudh, > > > > > > On 22:40 Sun 12 Jul , Anirudh Srinivasan wrote: > > > > Hi Yixun, > > > > > > > > On Thu, Jul 02, 2026 at 02:31:34AM +0000, Yixun Lan wrote: > > > > > This series try to add UFS support for SpacemiT K3 SoC, the controller > > > > > components consists of System Bus Interface Unit, UFS Host Controller > > > > > Interface, UFS Transport Protocol Layer, UFS Host Registers, Device > > > > > Management Entity (DME), Transport Layer, Network Layer, Data Link > > > > > Layer, PHY Adapter Layer, and M-PHY Interface. A more detail functional > > > > > block diagram can be found in SpacemiT website, chapter 9.7.3 [1] > > > > > > > > > > Please note, in order to test this driver, the UFS clock driver[2] here > > > > > should be applied first as a prerequisite patch. > > > > > > > > > > One known issue is that the device will occasionally raise BKOPS interrupt > > > > > when doing some high load test, log from dmesg shows > > > > > > > > > > [ 806.710763] ufshcd-spacemit c0e00000.ufshc: ufshcd_bkops_exception_event_handler: device raised urgent BKOPS exception for bkops status 1 > > > > > > > > > > Link: https://spacemit.com/community/document/info?nodepath=hardware/key_stone/k3/k3_docs/k3_usermanual/09_memory_storage.md&lang=en [1] > > > > > Link: https://lore.kernel.org/all/[email protected]/ [2] > > > > > Signed-off-by: Yixun Lan <[email protected]> > > > > > > > > I see this during probe on a k3-pico-itx. Does the UFS chip on board > > > > have an RPMB block on it? Is this error of any concern. > > > > > > > It's probably true of having a RPMB block, but not used in K3 platform, so can ignore > > > > > > > [ 5.957864] ufshcd-spacemit c0e00000.ufshc: ufshcd_scsi_add_wlus: BOOT WLUN not found > .. > > > > [ 5.963319] bus_add_device: cannot add device 'ufs_rpmb0' to unregistered bus 'ufs_rpmb' > > Just checked code under drivers/ufs/, and couldn't find where ufs_rpmb bus is registered, > so this kind of warning/error message is expected, or could UFS maintainer confirm this? Seems like both of these are bugs with the existing UFS/RPMB code in the kernel. The dev_err("BOOT WLUN not found") print should probably be downgraded to a dev_warn. And like you mentiond above, the ufs_rpmb bus doesn't seem to be registered before the ufs device is probed. > > > > > [ 5.971155] ufshcd-spacemit c0e00000.ufshc: Failed to register UFS RPMB device 0 > > > > > > > Maybe disable CONFIG_RPMB to silent this? I've not tested this option locally > > > > I'm testing on a distro defconfig, so it has this option enabled. > > > > Is there anything we can do in the driver to have it ignore the RPMB? > > No, but why not disable CONFIG_RPMB in the first place > > > If the error is a red-herring, we shouldn't be displaying it at all in > > the first place. > > > > Either fix the code or just ignore it.. > > -- > Yixun Lan (dlan)