DPE: Refactor remove_linked_component

Removes a warning and simplifies the logic behind the utility
function that is used to remove items from the linked list.

Signed-off-by: Antonio de Angelis <antonio.deangelis@arm.com>
Change-Id: I02df7e710c8b1cfe6a639a20a56241048d573abf
1 file changed