#1122340 I/O scheduler shows "[mq-deadline] none" on AHCI SATA drives

Package:
linux
Source:
linux
Submitter:
iprodha_gab
Date:
2025-12-11 09:19:10 UTC
Severity:
normal
Tags:
#1122340#5
Date:
2025-12-10 10:28:32 UTC
From:
To:
Problem:
On AMD A320 chipset systems with AHCI SATA controller, the block I/O layer
incorrectly displays multiple schedulers as active simultaneously:
"[mq-deadline] [bfq] none". This causes severe system slowdown and desktop
unresponsiveness during disk I/O operations.

How to reproduce:
1. Boot Debian 11 (bullseye) on AMD A320 chipset motherboard (ASRock
A320M-HDV)
2. Connect SATA HDD (TOSHIBA DT01ACA0 7200 RPM)
3. Check current scheduler: cat /sys/block/sda/queue/scheduler
4. Observe output: mq-deadline [bfq] none  (note two active schedulers in
brackets)
5. Perform large file copy or disk-intensive operation
6. Desktop environment (MATE) becomes unresponsive, system stalls

Diagnosis:
- System: Debian GNU/Linux 11 (bullseye), Kernel: 5.10.0-36-amd64, x86_64
- Motherboard: ASRock A320M-HDV (AMD Promontory A320 chipset)
- Disk: TOSHIBA DT01ACA0 (HDD, rotational=1, 7200 RPM SATA)
- Driver: ahci (multiple AHCI hosts detected: 9 instances)
- Scheduler state: mq-deadline [bfq] none  (bfq active but mq-deadline also
shown as active)
- Expected: Single scheduler in brackets indicating active one
- Current bug: Two schedulers shown with brackets [mq-deadline] [bfq]
- Physical system (not virtual machine)

Workaround:
Temporary fix:
# echo "bfq" > /sys/block/sda/queue/scheduler

Permanent fix via udev rule:
ACTION=="add|change", SUBSYSTEM=="block", ATTR{queue/rotational}=="1",
ATTR{queue/scheduler}="bfq"

Expected behavior:
According to kernel documentation and block layer design:
1. Only ONE scheduler should be active at a time
2. The active scheduler should be shown in brackets: [bfq]
3. Available schedulers should be listed after: [bfq] mq-deadline none
4. Current display "mq-dedeadline [bfq] none" is inconsistent

Impact:
- Severe desktop usability regression (MATE environment freezes during I/O)
- System becomes unresponsive for tens of seconds during file operations
- Affects user experience significantly on HDD-based systems
- Problem appears to be in scheduler initialization/display logic

Additional notes:
- Problem persists across reboots
- Not VM-related (bare metal installation)
- Multiple AHCI hosts detected (9), may be related to initialization order
- Manual scheduler selection works correctly once set

Suggested fix locations:
1. block/elevator.c - scheduler selection/display logic
2. drivers/ata/libata-core.c - ATA device initialization
3. /lib/udev/rules.d/60-block-scheduler.rules - default scheduler assignment

System info for reference:
- Debian: 11 (bullseye)
- Kernel: 5.10.0-36-amd64
- Architecture: x86_64
- Disk: TOSHIBA DT01ACA0 (rotational=1)
- Driver: ahci (9 instances)
- Desktop: MATE
- Motherboard: ASRock A320M-HDV (AMD A320 chipset)

#1122340#10
Date:
2025-12-10 15:15:12 UTC
From:
To:
Hello,

5.10.0-36-amd64 is not a kernel version, I guess you meant 5.10.244-1
(i.e. the most recent bullseye kernel) and fixed the bug metadata
accordingly.

This is strange.

Huh, if you repeat the problem description, please make sure the stuff
is consistent.

Another repetition, so you reported a state that looks perfectly fine
twice :-D

Can you please try if the problem also exists with newer kernels, e.g.
by updating your system to Debian 12 and then Debian 13. Alternatively
at least try a backports kernel.

Best regards
Uwe

#1122340#15
Date:
2025-12-10 15:15:12 UTC
From:
To:
Hello,

5.10.0-36-amd64 is not a kernel version, I guess you meant 5.10.244-1
(i.e. the most recent bullseye kernel) and fixed the bug metadata
accordingly.

This is strange.

Huh, if you repeat the problem description, please make sure the stuff
is consistent.

Another repetition, so you reported a state that looks perfectly fine
twice :-D

Can you please try if the problem also exists with newer kernels, e.g.
by updating your system to Debian 12 and then Debian 13. Alternatively
at least try a backports kernel.

Best regards
Uwe