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

use schedule_timeout_{un,}interruptible where possible.

    XMLWordPrintable

Details

    • Improvement
    • Resolution: Fixed
    • Minor
    • Lustre 2.14.0
    • None
    • None
    • 9223372036854775807

    Description

      The construct:

        

      set_current_state(TASK_UNINTERRUPTIABLE);
      schedule_timeout(time);

      Is more clearly expressed as

      schedule_timeout_uninterruptible(time);

      And similarly with TASK_INTERRUPTIBLE / schedule_timeout_interruptible()

      Establishing this practice makes it harder to forget to call set_current_state() as has happened a couple of times - in lnet_peer_discovery and mdd_changelog_fini().

      Also, there is no need to set_current_state(TASK_RUNNABLE) after calling schedule*().  That state is guaranteed to have been set.

       

      Attachments

        Issue Links

          Activity

            People

              neilb Neil Brown
              neilb Neil Brown
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: