Uploaded image for project: 'Lustre'
  1. Lustre
  2. LU-19825

use io_schedule() instead of schedule when waiting for IO

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Unresolved
    • Medium
    • None
    • None
    • 3
    • 9223372036854775807

    Description

      In upstream kernel code, it is common to use io_schedule() (and related family of functions) to sleep when processes are waiting for IO completion, rather than schedule() when they are just idle or waiting to on other processes, memory, CPU, etc. This allows the kernel to account sleeping processes waiting for IO rather than waiting for the task to be runnable. That helps with vmstat, top and other commands that distinguish how processes are sleeping.

      There are a number of places that Lustre waits for completion that should be updated:

      • schedule() -> io_schedule() - with review to ensure it is actually waiting on IO
      • schedule_timeout() -> io_schedule_timeout() - with review
      • wait_event() -> io_wait_event() - with review
      • l_wait_abortable*() - should be unrolled to use __wait_event() and calls io_schedule() at the bottom level, until such a time that [__]io_wait_event_interruptible*() is available in the kernel, possibly renamed to io_wait_event_abortable() to better match other functions

      Attachments

        Issue Links

          Activity

            People

              npapakonstantinou Nikos Papakonstantinou
              adilger Andreas Dilger
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated: