Skip to contentSkip to conversation

xen/sched: remove pointless BUG_ON() in credit2

PATCH In review Juergen Gross 2 participants 2 messages Feb 11, 2020

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 xen/sched: remove pointless BUG_ON() in credit2

The BUG_ON() at the top of csched2_context_saved() is completely pointless, as the ASSERT() just following it catches the same problem already.

---
 xen/common/sched/credit2.c | 2 --
 1 file changed, 2 deletions(-)
xen/common/sched/credit2.c +0 -2
index b965cd1c7b..7d104f15d0 100644
@@ -2167,8 +2167,6 @@ csched2_context_saved(const struct scheduler *ops, struct sched_unit *unit)
     s_time_t now = NOW();
     LIST_HEAD(were_parked);
 
-    BUG_ON( !is_idle_unit(unit) &&
-            svc->rqd != c2rqd(ops, sched_unit_master(unit)));
     ASSERT(is_idle_unit(unit) ||
            svc->rqd == c2rqd(ops, sched_unit_master(unit)));
 
Signature · 7 lines
2.16.4


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
Reviewed-by on v2 1/1
#1 lore raw
Quoted 6 lines · Juergen Gross

The BUG_ON() at the top of csched2_context_saved() is completely pointless, as the ASSERT() just following it catches the same problem already.

Thanks and Regards

Signature · 6 lines
Dario Faggioli, Ph.D
http://about.me/dario.faggioli
Virtualization Software Engineer
SUSE Labs, SUSE https://www.suse.com/
-------------------------------------------------------------------
<<This happens because _I_ choose it to happen!>> (Raistlin Majere)

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel