Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 25f3ff2c authored by Mike Frysinger's avatar Mike Frysinger
Browse files

Blackfin: sram_free_with_lsl: do not ignore return value of sram_free



If there was an error in the lower free functions, we need to pass that
back up so the calling process is able to check things.

Signed-off-by: default avatarMike Frysinger <vapier@gentoo.org>
parent a8b19886
Loading
Loading
Loading
Loading
+9 −9
Original line number Diff line number Diff line
@@ -704,18 +704,18 @@ int sram_free_with_lsl(const void *addr)
{
	struct sram_list_struct *lsl, **tmp;
	struct mm_struct *mm = current->mm;
	int ret = -1;

	for (tmp = &mm->context.sram_list; *tmp; tmp = &(*tmp)->next)
		if ((*tmp)->addr == addr)
			goto found;
	return -1;
found:
		if ((*tmp)->addr == addr) {
			lsl = *tmp;
	sram_free(addr);
			ret = sram_free(addr);
			*tmp = lsl->next;
			kfree(lsl);
			break;
		}

	return 0;
	return ret;
}
EXPORT_SYMBOL(sram_free_with_lsl);