Fixing checkpatch.pl warnings.
Most warnings are "Missing a blank line after declarations". I'm also
adding blank lines between multi-line comments and statements.
Ran with --ignore BRACES,SPDX_LICENSE_TAG,VOLATILE,SPLIT_STRING,
AVOID_EXTERNS,USE_SPINLOCK_T,NEW_TYPEDEFS,INITIALISED_STATIC,
FILE_PATH_CHANGES to reduce noise. Now there is only one type of
warning, with two instances:
WARNING: Prefer using '"%s...", __func__' to using 'dmb', this function's name, in a string
+ __asm__ volatile("dmb sy");
WARNING: Prefer using '"%s...", __func__' to using 'dsb', this function's name, in a string
+ __asm__ volatile("dsb sy");
Change-Id: Id837feef86dc81ba84de1809e76653ddce814422
diff --git a/src/mpool.c b/src/mpool.c
index 4cc1d40..6b5824e 100644
--- a/src/mpool.c
+++ b/src/mpool.c
@@ -123,6 +123,7 @@
entry = p->entry_list;
while (entry != NULL) {
void *ptr = entry;
+
entry = entry->next;
mpool_free(p->fallback, ptr);
}
@@ -132,6 +133,7 @@
while (chunk != NULL) {
void *ptr = chunk;
size_t size = (uintptr_t)chunk->limit - (uintptr_t)chunk;
+
chunk = chunk->next_chunk;
mpool_add_chunk(p->fallback, ptr, size);
}
@@ -193,6 +195,7 @@
mpool_lock(p);
if (p->entry_list != NULL) {
struct mpool_entry *entry = p->entry_list;
+
p->entry_list = entry->next;
ret = entry;
goto exit;