Hi Bart, On Fri, Nov 22, 2024 at 4:18 PM Bart Van Assche <bvanassche@xxxxxxx> wrote: > > On 11/22/24 1:55 PM, Sam Protsenko wrote: > > On Fri, Nov 22, 2024 at 6:04 AM Christoph Hellwig <hch@xxxxxx> wrote: > >> > >> On Thu, Nov 21, 2024 at 11:04:19PM -0600, Sam Protsenko wrote: > >>> Hi Christoph, > >>> > >>> This patch causes a regression on E850-96 board. Specifically, there are > >>> two noticeable time lags when booting Debian rootfs: > >> > >> What storage driver does this board use? Anything else interesting > >> about the setup? > >> > > > > It's an Exynos based board with eMMC, so it uses DW MMC driver, with > > Exynos glue layer on top of it, so: > > > > drivers/mmc/host/dw_mmc.c > > drivers/mmc/host/dw_mmc-exynos.c > > > > I'm using the regular ARM64 defconfig. Nothing fancy about this setup > > neither, the device tree with eMMC definition (mmc_0) is here: > > > > arch/arm64/boot/dts/exynos/exynos850-e850-96.dts > > > > FWIW, I was able to narrow down the issue to dd_insert_request() > > function. With this hack the freeze is gone: > > > > 8<-------------------------------------------------------------------->8 > > diff --git a/block/mq-deadline.c b/block/mq-deadline.c > > index acdc28756d9d..83d272b66e71 100644 > > --- a/block/mq-deadline.c > > +++ b/block/mq-deadline.c > > @@ -676,7 +676,7 @@ static void dd_insert_request(struct blk_mq_hw_ctx > > *hctx, struct request *rq, > > struct request_queue *q = hctx->queue; > > struct deadline_data *dd = q->elevator->elevator_data; > > const enum dd_data_dir data_dir = rq_data_dir(rq); > > - u16 ioprio = req_get_ioprio(rq); > > + u16 ioprio = 0; /* the same as old req->ioprio */ > > u8 ioprio_class = IOPRIO_PRIO_CLASS(ioprio); > > struct dd_per_prio *per_prio; > > enum dd_prio prio; > > 8<-------------------------------------------------------------------->8 > > > > Does it tell you anything about where the possible issue can be? > > It seems like eMMC devices do not tolerate I/O prioritization. How about > disabling I/O prioritization for eMMC setups? Is the ioprio cgroup > controller perhaps activated by the user space software that is running > on this setup? > Can you please elaborate on why eMMC devices might not play well with prios? Do they lack some particular hardware support, like required commands? Also, I've noticed (probably) the same issue reported recently [1] for USB SSD drives. so it'd nice to have some references showing it's actually the case specifically for eMMC. Do you know if we have any config options to disable I/O prioritization? Not sure how exactly we can do that specifically for eMMC devices too. I'm not an expert in block layer, would appreciate some help with this one. For ioprio cgroup: CONFIG_BLK_CGROUP_IOPRIO option is disabled in my case (ARM64 defconfig), so I don't think it has to do with ioprio cgroup? [1] https://lore.kernel.org/all/CAP-bSRbCo7=wfUBZ8H7c3Q-7XSG+SB=R4MHHNNGPvBoinsVSZg@xxxxxxxxxxxxxx/ Thanks! > Thanks, > > Bart.