Patent ID: 7082494

Claim:
A disk drive comprising: (a) a disk; (b) a head actuated radially over the disk; (c) a read/write channel for interfacing with the disk through the head; and (d) a microprocessor for executing a preemptive multitasking operating system, the preemptive multitasking operating system comprising a plurality of preemptive tasks, each preemptive task comprising a different priority level, the plurality of preemptive tasks comprising: a disk task for processing disk commands by initiating seek operations and configuring parameters of the read/write channel; a host task for initiating disk commands in response to host commands received from a host computer; a background task for initiating disk commands to perform background operations including a defect scan of the disk; and an execution task for arbitrating the disk commands generated by the host task and the background task and for transmitting the arbitrated disk commands to the disk task.