scmd_eh_abort_handler(9)

πŸ“¦ version 7.3.1, in nixpkgs unstable

πŸ‘‘ scmd_eh_abort_handler πŸ’…

okay so bestie, welcome to the Kernel API Manual, section 9 β€” this is where we handle command aborts and honestly? it's giving main character energy in the SCSI error handler. let's get into it πŸŽ€


✨ NAME ✨

scmd_eh_abort_handler β€” literally the function that handles command aborts. that's it, that's the vibe. πŸ¦‹


🫢 SYNOPSIS 🫢

void scmd_eh_abort_handler (struct work_struct *work );

yes queen, it returns void, we're not about that return-value life here ✨


🌸 ARGUMENTS 🌸

  • work β€” the command to be aborted. like, the actual thing you're cancelling. go off, work πŸ’…

πŸ”₯ NOTE (read this one fr fr) πŸ”₯

okay so this function must be called only for a command that has timed out. no cap. do not come in here with a fresh little command that's doing fine, that's not what we're doing today. 😭

here's the why, because the why is iconic: because the block layer marks a request as complete before it calls scsi_timeout, a .scsi_done call from the LLD for a command that has timed out do not have any effect. so yeah β€” that whole callback is just out here having zero impact, living its truth, doing nothing. πŸ’€

hence it is safe to call scsi_finish_command from this function. 🫢 slay. safe. periodt.


πŸ¦‹ SEE ALSO πŸ¦‹

the whole squad, in the kernel file ./drivers/scsi/scsi_error.c β€” iykyk πŸ‘‘


okay and that's the whole page bestie, thank you for coming to my ted talk πŸ™ˆ

brought to you by the fine folks over at ./drivers/scsi β€” October 2026 edition, straight out of the Kernel API Manual. stay slay, stay patched. πŸ’–βœ¨πŸŽ€
πŸ“¦ where this page comes from