mem: Fix assertions in LRG Q policy

Fix assertions in LRG Queue Policy to correctly assert requestor and
list validity

Change-Id: I84e3f5b8936b74e7ac675faf7a3e6b9999026781
This commit is contained in:
Hristo Belchev
2024-02-12 11:54:33 +00:00
parent 0f79b15b2f
commit f20ac07dde

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2018 ARM Limited
* Copyright (c) 2018,2024 ARM Limited
* All rights reserved
*
* The license below extends only to copyright in the software and shall
@@ -91,10 +91,10 @@ LrgQueuePolicy::selectPacket(PacketQueue* q)
"from queue with id %d\n", requestor_id);
// Check if this is a known requestor.
panic_if(memCtrl->hasRequestor(requestor_id),
panic_if(!memCtrl->hasRequestor(requestor_id),
"%s: Unrecognized Requestor\n", __func__);
panic_if(toServe.size() > 0,
panic_if(toServe.size() <= 0,
"%s: toServe list is empty\n", __func__);
if (toServe.front() == requestor_id) {