diff options
author | Yann Gautier <yann.gautier@st.com> | 2019-01-17 11:17:05 +0100 |
---|---|---|
committer | Yann Gautier <yann.gautier@st.com> | 2019-01-17 11:17:05 +0100 |
commit | 5f9984ef5d51ed7db0209f4b0603e2182151392a (patch) | |
tree | cec168a4cea98da6e53e7ea233a6539c6fd5d78a /drivers/mmc | |
parent | cd1f39b48ab4a0596ace57cc920e4d4ba6e92784 (diff) |
mmc: correctly check ret in mmc_fill_device_info
In patch 93768644, ret will be MMC_STATE_TRAN (=4), which is a valid value.
We shouldn't exit the function in that case, but only if ret is < 0.
Change-Id: I776693fe847b6b45190af028f12d2e724ca46399
Signed-off-by: Yann Gautier <yann.gautier@st.com>
Diffstat (limited to 'drivers/mmc')
-rw-r--r-- | drivers/mmc/mmc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/mmc/mmc.c b/drivers/mmc/mmc.c index 450bd0b5..77d683c4 100644 --- a/drivers/mmc/mmc.c +++ b/drivers/mmc/mmc.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2018, ARM Limited and Contributors. All rights reserved. + * Copyright (c) 2018-2019, ARM Limited and Contributors. All rights reserved. * * SPDX-License-Identifier: BSD-3-Clause */ @@ -300,7 +300,7 @@ static int mmc_fill_device_info(void) break; } - if (ret != 0) { + if (ret < 0) { return ret; } |