From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lj1-f181.google.com (mail-lj1-f181.google.com [209.85.208.181]) by mx.groups.io with SMTP id smtpd.web11.39808.1658232639998351887 for ; Tue, 19 Jul 2022 05:10:40 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@gmail.com header.s=20210112 header.b=qXmT0aPc; spf=pass (domain: gmail.com, ip: 209.85.208.181, mailfrom: savvamtr@gmail.com) Received: by mail-lj1-f181.google.com with SMTP id v15so13383512ljc.1 for ; Tue, 19 Jul 2022 05:10:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=aVaO28+5jS5ptEo+RbON3NKGmEhGr806sVgbLl4BloI=; b=qXmT0aPcIfjmFFvDj5b8+bLDaS/MHleGIL3X7miFDYeRKm0XLNEwdLjz7vihwZrtg8 2hPllFzglmLy7PRCUqCkZRwZbJQ9py2hZo5ZxR9K3D+g9nk1JUt0fERqKXz+kOQmkKZN +SiWdbVLl3/e/UCl/GgEMqdPZQAV5SMDclRptzyN+o+13RVoqo3RMNFcbocdfIniaD2E kusBrjZa6qXhUfSnTWV8i8wKJEqS+U8MLMaIwnAACfnXCKzvg7pJ8rqvxbJFsber31EW M6lS95LxPBZAe9aYIYsBXZ68iG1YFv0a7DazU9XLLxAr6JhRkA3urIe+JzKEBxWGkr4k vjmw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=aVaO28+5jS5ptEo+RbON3NKGmEhGr806sVgbLl4BloI=; b=HSi3NpHcv7Y9UzMZnaBfmjmN/nkCH6XzaP2spjOOTC9Ju3m/ghc8M96UyurtZYKF5x ESVJJJuiwqgOv1WYZRZOoLXJMyeAxjzO0X4ZoxH/E6SqgXBEMzUqzZrUugu2TWpaZfmj rIvc+uzBy9gc1KEARbLfchSQo+wDpJJt4RP2YQcAeyu/2Lp5wIqAFRDRHrjHvTB9TwQx JSQEWPLR6k84Iw8lnGkS1sR3QDx3523ImLokdE1BxuLKBDMe1VuarzvuMT9O4EBGE15k 6r/fB2Zl+dl9KOkIPlZ3Ph6iIoBsSQZYTYuowqdk7B34Rj79OjxNSqns/UjLB9mJ7kmp 3vQg== X-Gm-Message-State: AJIora8B9VDF68AyLjVWrPsLz1qWY/2wvo5vFiwvQXlQHuc5B60aHrlV Adr2suv+LaWAITpJxqye8ceuIpP8ReCYlbroxLI= X-Google-Smtp-Source: AGRyM1u5H5yJ3nH9Ps5OU2gv65jtJnv3tIzFyQLkvuL4M5LQrVF6uJ4cDvATy5GJYF4bxScm03u+9w== X-Received: by 2002:a2e:9dd0:0:b0:25d:46d7:6bd with SMTP id x16-20020a2e9dd0000000b0025d46d706bdmr14464072ljj.502.1658232638067; Tue, 19 Jul 2022 05:10:38 -0700 (PDT) Return-Path: Received: from localhost.localdomain ([207.180.219.167]) by smtp.gmail.com with ESMTPSA id z20-20020a2eb534000000b0025d6ecbc897sm2668245ljm.46.2022.07.19.05.10.36 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Tue, 19 Jul 2022 05:10:37 -0700 (PDT) From: "Savva Mitrofanov" To: devel@edk2.groups.io Cc: =?UTF-8?q?Marvin=20H=C3=A4user?= , Pedro Falcato , Vitaly Cheptsov Subject: [edk2-platforms][PATCH 04/10] Ext4Pkg: Use assertion in Ext4CalculateChecksum Date: Tue, 19 Jul 2022 18:10:10 +0600 Message-Id: <20220719121016.29380-5-savvamtr@gmail.com> X-Mailer: git-send-email 2.37.0 In-Reply-To: <20220719121016.29380-1-savvamtr@gmail.com> References: <20220719121016.29380-1-savvamtr@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Replaced UNREACHABLE with ASSERT (FALSE) in case of new checksum algorithms, due to it is an invariant violation rather than unreachable path Cc: Marvin H=C3=A4user Cc: Pedro Falcato Cc: Vitaly Cheptsov Signed-off-by: Savva Mitrofanov --- Features/Ext4Pkg/Ext4Dxe/Superblock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Features/Ext4Pkg/Ext4Dxe/Superblock.c b/Features/Ext4Pkg/Ext4D= xe/Superblock.c index 47fc3a65507a..42762b6aa780 100644 --- a/Features/Ext4Pkg/Ext4Dxe/Superblock.c +++ b/Features/Ext4Pkg/Ext4Dxe/Superblock.c @@ -342,7 +342,7 @@ Ext4CalculateChecksum ( // For some reason, EXT4 really likes non-inverted CRC32C checksums,= so we stick to that here.=0D return ~CalculateCrc32c(Buffer, Length, ~InitialValue);=0D default:=0D - UNREACHABLE ();=0D + ASSERT (FALSE);=0D return 0;=0D }=0D }=0D --=20 2.37.0