diff options
author | Jim Quigley <jim.quigley@arm.com> | 2020-03-05 18:25:27 +0000 |
---|---|---|
committer | nicola-mazzucato-arm <42373140+nicola-mazzucato-arm@users.noreply.github.com> | 2020-03-12 17:23:30 +0000 |
commit | a366c5c6da1a93a9f374784fb9a6af0edb4027fd (patch) | |
tree | 270d41194774a04112a9be40863fabc1b9199a9f /module/css_clock/src | |
parent | c24d8666b033d87e02d2cec5b3fb031d6aa63a8d (diff) |
fwk/fwk_mm_alloc: panic if memory allocation failed
Currently the framework will return NULL if the memory allocation
fails. As the system will ultimately fail on receiving the error
we could just panic instead, saving the memory used for the NULL
checks.
Change-Id: I731b87b7acb19d30df84936b07c76cbfe0d0726e
Signed-off-by: Jim Quigley <jim.quigley@arm.com>
Diffstat (limited to 'module/css_clock/src')
-rw-r--r-- | module/css_clock/src/mod_css_clock.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/module/css_clock/src/mod_css_clock.c b/module/css_clock/src/mod_css_clock.c index 06b5accf..39945dc4 100644 --- a/module/css_clock/src/mod_css_clock.c +++ b/module/css_clock/src/mod_css_clock.c @@ -338,9 +338,6 @@ static int css_clock_init(fwk_id_t module_id, unsigned int element_count, module_ctx.dev_ctx_table = fwk_mm_calloc(element_count, sizeof(struct css_clock_dev_ctx)); - if (module_ctx.dev_ctx_table == NULL) - return FWK_E_NOMEM; - return FWK_SUCCESS; } |