diff options
Diffstat (limited to 'litmus/sched_gsn_edf.c')
-rw-r--r-- | litmus/sched_gsn_edf.c | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/litmus/sched_gsn_edf.c b/litmus/sched_gsn_edf.c index 4c8a21705810..6b4e4d9aa099 100644 --- a/litmus/sched_gsn_edf.c +++ b/litmus/sched_gsn_edf.c | |||
@@ -775,9 +775,34 @@ static long gsnedf_fmlp_return_priority(struct pi_semaphore *_sem) | |||
775 | 775 | ||
776 | return ret; | 776 | return ret; |
777 | } | 777 | } |
778 | #endif | ||
779 | |||
780 | |||
781 | #ifdef CONFIG_OMLP | ||
782 | /* Reuse FMLP hooks since OMLP implements the G-EDF stuff | ||
783 | * already. May have to do G-EDF specific work here in the | ||
784 | * future. Will probably need additional callback to move | ||
785 | * items from PQ to FIFO. | ||
786 | */ | ||
787 | static long gsnedf_omlp_pi_block(struct pi_semaphore *_sem, | ||
788 | struct task_struct *new_waiter) | ||
789 | { | ||
790 | return gsnedf_fmlp_pi_block(_sem, new_waiter); | ||
791 | } | ||
778 | 792 | ||
793 | static long gsnedf_omlp_inherit_priority(struct pi_semaphore *_sem, | ||
794 | struct task_struct *new_owner) | ||
795 | { | ||
796 | return gsnedf_fmlp_inherit_priority(_sem, new_owner); | ||
797 | } | ||
798 | |||
799 | static long gsnedf_omlp_return_priority(struct pi_semaphore *_sem) | ||
800 | { | ||
801 | return gsnedf_fmlp_return_priority(_sem); | ||
802 | } | ||
779 | #endif | 803 | #endif |
780 | 804 | ||
805 | |||
781 | static long gsnedf_admit_task(struct task_struct* tsk) | 806 | static long gsnedf_admit_task(struct task_struct* tsk) |
782 | { | 807 | { |
783 | return 0; | 808 | return 0; |
@@ -830,6 +855,12 @@ static struct sched_plugin gsn_edf_plugin __cacheline_aligned_in_smp = { | |||
830 | .fmlp_inherit_priority = gsnedf_fmlp_inherit_priority, | 855 | .fmlp_inherit_priority = gsnedf_fmlp_inherit_priority, |
831 | .fmlp_return_priority = gsnedf_fmlp_return_priority, | 856 | .fmlp_return_priority = gsnedf_fmlp_return_priority, |
832 | #endif | 857 | #endif |
858 | #ifdef CONFIG_OMLP | ||
859 | .omlp_active = 1, | ||
860 | .omlp_pi_block = gsnedf_omlp_pi_block, | ||
861 | .omlp_inherit_priority = gsnedf_omlp_inherit_priority, | ||
862 | .omlp_return_priority = gsnedf_omlp_return_priority, | ||
863 | #endif | ||
833 | .admit_task = gsnedf_admit_task, | 864 | .admit_task = gsnedf_admit_task, |
834 | .activate_plugin = gsnedf_activate_plugin, | 865 | .activate_plugin = gsnedf_activate_plugin, |
835 | }; | 866 | }; |