forked from auracaster/openocd
flash: nand: prepare for aligning switch and case statements
To prepare for aligning switch and case statements, fix in advance some checkpatch error due to existing code: - remove useless parenthesis; - don't end line with an open parenthesis; - expand multiple assignments. While there, put the 'default' case as last in the list. Change-Id: I17bf5e88b145ef9b5b188424182f4e54b818eeae Signed-off-by: Antonio Borneo <borneo.antonio@gmail.com> Reviewed-on: https://review.openocd.org/c/openocd/+/9011 Tested-by: jenkins
This commit is contained in:
@@ -314,8 +314,7 @@ int nand_probe(struct nand_device *nand)
|
||||
LOG_DEBUG("controller initialization failed");
|
||||
return ERROR_NAND_OPERATION_FAILED;
|
||||
case ERROR_NAND_OPERATION_NOT_SUPPORTED:
|
||||
LOG_ERROR(
|
||||
"BUG: controller reported that it doesn't support default parameters");
|
||||
LOG_ERROR("BUG: controller reported that it doesn't support default parameters");
|
||||
return ERROR_NAND_OPERATION_FAILED;
|
||||
default:
|
||||
LOG_ERROR("BUG: unknown controller initialization failure");
|
||||
@@ -474,11 +473,10 @@ int nand_probe(struct nand_device *nand)
|
||||
LOG_DEBUG("controller initialization failed");
|
||||
return ERROR_NAND_OPERATION_FAILED;
|
||||
case ERROR_NAND_OPERATION_NOT_SUPPORTED:
|
||||
LOG_ERROR(
|
||||
"controller doesn't support requested parameters (buswidth: %i, address cycles: %i, page size: %i)",
|
||||
nand->bus_width,
|
||||
nand->address_cycles,
|
||||
nand->page_size);
|
||||
LOG_ERROR("controller doesn't support requested parameters (buswidth: %i, address cycles: %i, page size: %i)",
|
||||
nand->bus_width,
|
||||
nand->address_cycles,
|
||||
nand->page_size);
|
||||
return ERROR_NAND_OPERATION_FAILED;
|
||||
default:
|
||||
LOG_ERROR("BUG: unknown controller initialization failure");
|
||||
|
||||
Reference in New Issue
Block a user