From: Heinrich Schuchardt Date: Wed, 11 Dec 2019 12:51:38 +0000 (+0100) Subject: mkimage: simplify fit_check_params() X-Git-Url: http://git.dujemihanovic.xyz/img/static/gitweb.css?a=commitdiff_plain;h=5819466dc1d2856afa84188745eaa5f415ee08cb;p=u-boot.git mkimage: simplify fit_check_params() fit_check_params() wants at least two of dflag, fflag, and lflag set. Simplify the logical constraint checking this. Signed-off-by: Heinrich Schuchardt --- diff --git a/tools/fit_image.c b/tools/fit_image.c index 114df5af30..6aa4b1c733 100644 --- a/tools/fit_image.c +++ b/tools/fit_image.c @@ -825,9 +825,9 @@ static int fit_check_params(struct image_tool_params *params) { if (params->auto_its) return 0; - return ((params->dflag && (params->fflag || params->lflag)) || - (params->fflag && (params->dflag || params->lflag)) || - (params->lflag && (params->dflag || params->fflag))); + return ((params->dflag && params->fflag) || + (params->fflag && params->lflag) || + (params->lflag && params->dflag)); } U_BOOT_IMAGE_TYPE(