nand: stm32_fmc_nand: remove dead code

The FMC driver in TF-A only supports NAND Mode 0 timings.
The timings are then hard-coded as macros, leading to some parts of code
unreachable.
This issue was found by Coverity scan: CID 366361.

Change-Id: I864c51ce11b9ef74ad82b3301f56f46a2e0f70ca
Signed-off-by: Yann Gautier <yann.gautier@foss.st.com>
This commit is contained in:
Yann Gautier 2021-02-08 10:44:55 +01:00
parent 94b0c3341e
commit 3ed016571a
1 changed files with 1 additions and 10 deletions

View File

@ -1,5 +1,5 @@
/*
* Copyright (c) 2019-2020, STMicroelectronics - All Rights Reserved
* Copyright (c) 2019-2021, STMicroelectronics - All Rights Reserved
*
* SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause
*/
@ -200,9 +200,6 @@ static void stm32_fmc2_nand_setup_timing(void)
if ((twait < NAND_TCS_MIN) && (tset_mem < (NAND_TCS_MIN - twait))) {
tset_mem = NAND_TCS_MIN - twait;
}
if ((twait < NAND_TALS_MIN) && (tset_mem < (NAND_TALS_MIN - twait))) {
tset_mem = NAND_TALS_MIN - twait;
}
if ((twait > thiz) && ((twait - thiz) < NAND_TDS_MIN) &&
(tset_mem < (NAND_TDS_MIN - (twait - thiz)))) {
tset_mem = NAND_TDS_MIN - (twait - thiz);
@ -244,12 +241,6 @@ static void stm32_fmc2_nand_setup_timing(void)
if ((twait < NAND_TCS_MIN) && (tset_att < (NAND_TCS_MIN - twait))) {
tset_att = NAND_TCS_MIN - twait;
}
if ((twait < NAND_TCLS_MIN) && (tset_att < (NAND_TCLS_MIN - twait))) {
tset_att = NAND_TCLS_MIN - twait;
}
if ((twait < NAND_TALS_MIN) && (tset_att < (NAND_TALS_MIN - twait))) {
tset_att = NAND_TALS_MIN - twait;
}
if ((thold_mem < NAND_TRHW_MIN) &&
(tset_att < (NAND_TRHW_MIN - thold_mem))) {
tset_att = NAND_TRHW_MIN - thold_mem;