Add test_runner service
This is a new service with client and provider that can be
used for running tests in a secure processing environment
and retrieving the results. The test_runner provider allows
for arbitrary test farmework backends. The goal is to
have a cpputest backend. In this commit, a mock backend
is included for testing the service itself. The service
has its own access protocol defined under the protocols
top-level directory.
Signed-off-by: Julian Hall <julian.hall@arm.com>
Change-Id: If4e965c110763bd805abbdcb87e7e03cd76248b2
diff --git a/components/common/tlv/tlv.c b/components/common/tlv/tlv.c
index 1308832..80c1edb 100644
--- a/components/common/tlv/tlv.c
+++ b/components/common/tlv/tlv.c
@@ -82,10 +82,13 @@
bool tlv_find_decode(struct tlv_const_iterator *iter, uint16_t tag, struct tlv_record *output)
{
- while (tlv_decode(iter, output)) {
+ struct tlv_const_iterator temp_iter = *iter;
+
+ while (tlv_decode(&temp_iter, output)) {
if (output->tag == tag) {
- /* Found a record */
+ /* Found a record - update input iterator to next record */
+ *iter = temp_iter;
return true;
}
else if (output->tag > tag) {