{
  "slug": "command-duration-limit",
  "term": "Command duration limit",
  "aliases": [
    "Command Duration Limits",
    "CDL",
    "Device duration limit"
  ],
  "definition": "A command duration limit is a device-side policy selected by a descriptor index for supported storage commands.",
  "note": "Linux v6.12 I/O-priority hints 1 through 7 select duration-limit descriptors on supporting ATA/SCSI devices when CDL is enabled. The hint is an index, not seconds, and is separate from scheduling class and priority level. [c1]\n\nThe cdl_supported attribute reports capability; cdl_enable controls activation and is documented as off by default. In the v6.12 SCSI disk driver, sd_cdl_dld() selects zero unless support, activation and a valid request hint are all present. Enabling CDL alone does not assign every request a nonzero descriptor. [c2] [c3]\n\nThe descriptor and device contract determine the applicable policy. Its index alone does not specify the duration or establish a host deadline, final write outcome or durable completion. [c4]\n\nIn Linux v6.12, ABORTED_COMMAND with ASC/ASCQ 2E/01-03 and COMPLETED with 55/0A both receive SCSIML_STAT_DL_TIMEOUT. SCSI suppresses retries for this classification; the internal SUCCESS return is not I/O success. [c5]\n\nThe completion path maps that classification to BLK_STS_DURATION_LIMIT and then -ETIME, distinct from BLK_STS_TIMEOUT's -ETIMEDOUT. This source-level mapping does not promise unchanged errors at the application or rule out retries above SCSI. [c6] [c7]",
  "related": [
    "error-recovery-control",
    "io-timeout",
    "scsi",
    "sata"
  ],
  "citations": [
    {
      "id": "c1",
      "title": "Linux v6.12: include/uapi/linux/ioprio.h, device duration-limit hints.",
      "url": "https://raw.githubusercontent.com/torvalds/linux/v6.12/include/uapi/linux/ioprio.h",
      "accessed": "2026-10-16"
    },
    {
      "id": "c2",
      "title": "Linux v6.12: sysfs-block-device ABI, cdl_supported and cdl_enable.",
      "url": "https://raw.githubusercontent.com/torvalds/linux/v6.12/Documentation/ABI/testing/sysfs-block-device",
      "accessed": "2026-10-16"
    },
    {
      "id": "c3",
      "title": "Linux v6.12: drivers/scsi/sd.c, sd_cdl_dld().",
      "url": "https://raw.githubusercontent.com/torvalds/linux/v6.12/drivers/scsi/sd.c",
      "accessed": "2026-10-16"
    },
    {
      "id": "c4",
      "title": "Hesela: Storage timeouts and uncertain completion",
      "url": "https://hesela.com/analyses/storage-timeouts-uncertain-completion/",
      "accessed": "2026-10-16"
    },
    {
      "id": "c5",
      "title": "Linux v6.12: scsi_check_sense() and scsi_noretry_cmd().",
      "url": "https://raw.githubusercontent.com/torvalds/linux/v6.12/drivers/scsi/scsi_error.c",
      "accessed": "2026-10-16"
    },
    {
      "id": "c6",
      "title": "Linux v6.12: scsi_result_to_blk_status().",
      "url": "https://raw.githubusercontent.com/torvalds/linux/v6.12/drivers/scsi/scsi_lib.c",
      "accessed": "2026-10-16"
    },
    {
      "id": "c7",
      "title": "Linux v6.12: blk_errors[] and blk_status_to_errno().",
      "url": "https://raw.githubusercontent.com/torvalds/linux/v6.12/block/blk-core.c",
      "accessed": "2026-10-16"
    }
  ],
  "provenance": [
    "Linux behavior is scoped to v6.12 source and ABI documentation, not every deployed kernel or storage transport.",
    "Source review only; no device CDL configuration or fault-injection test was performed."
  ],
  "status": "shipping",
  "advantages": [],
  "limitations": [],
  "supersedes": [],
  "supersededBy": [],
  "firstSeen": null,
  "lastSeen": null,
  "updated": "2026-10-16"
}
