From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from NAM10-MW2-obe.outbound.protection.outlook.com (NAM10-MW2-obe.outbound.protection.outlook.com [40.107.94.127]) by mx.groups.io with SMTP id smtpd.web12.10401.1609949371333346636 for ; Wed, 06 Jan 2021 08:09:31 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@os.amperecomputing.com header.s=selector2 header.b=CFOVhG4H; spf=pass (domain: os.amperecomputing.com, ip: 40.107.94.127, mailfrom: nhi@os.amperecomputing.com) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=edZ1Xpn+RWKKcmDiIjAeywfRnCe7g3eRP+3uIbVwxSpPb1pJcK+L5P7dVxroIp34tGUWtj9ceSzcet5BFlmCorFI7LhJRZYsVZn13tV4dnvICVIb+XBVmiQASV/Yf0dMEpEUxf39IVNqhRgbtDtJ1C5WgQ9MpzmmUKmgtKqg77vurRfnIw8qYZXzSG8V1MbVbswkQKn1bGIIX/wsA8AxSqju5fTXvtWf6p20ni6oVleNv6h8/17ZY3wzCN6/UYNLxBNkr0NnLJHYWoAQS10+J3GjcR7bFboqEOQkcIvdwtsl2QwpJuCRLuiIEGue/HgiZYYgDxQFEfnfBM3ALHj5wg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=qUNQQe6xp3qIuyCoPbP3ZsrsfOodJ+ucRw87X3qhwu4=; b=jyDWYJloEEitOOzlljYJz6izWJANGCSWwpq+RYJ9PMD2KWJDKDZ78Tw6I6WgG/gJiKs03NxDf3B+jIgaD3cPMWUUkGsX8v347f4WbboqMYVUTnbvJCAIrqRbtjamBAeSveXT4f88yaOGJqlD+JQ5c5UghKR19qfdTJEz7j7WElPTXqPTwPhR3UMBAIg50DEWPHcPoNC/6uM25w+BM+oBuz9dv62QeGRXOFPSvGjMkRvlFz6HlBkmoH35AjcCItHf35IrVQ3T10HvBr08RKpwHj5N3S/QGsiutMWtDYLOK6BMc837Cj18y5Qxk2ICfDhHGtdkme6r1GzoOyJeLDZOEg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=os.amperecomputing.com; dmarc=pass action=none header.from=os.amperecomputing.com; dkim=pass header.d=os.amperecomputing.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=os.amperecomputing.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=qUNQQe6xp3qIuyCoPbP3ZsrsfOodJ+ucRw87X3qhwu4=; b=CFOVhG4HndcB3OBp5lMeWw3IqjXEDZlWi/4KkwjRrh1+5IADVKRAndqVK+2d/B9p2Sz0pM/tgFWvYmvegD3TUq1w2R/zY0L1jkg0apz/dkA5/51IkpxfaxJX61Dzph1L/kWa7XLHEQq48w7a2JAx9ekvhd8Z25HSpHfKByjTJqs= Authentication-Results: edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=none action=none header.from=os.amperecomputing.com; Received: from DM6PR01MB5849.prod.exchangelabs.com (2603:10b6:5:205::20) by DM5PR01MB2538.prod.exchangelabs.com (2603:10b6:3:3e::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3742.6; Wed, 6 Jan 2021 16:09:30 +0000 Received: from DM6PR01MB5849.prod.exchangelabs.com ([fe80::c814:9a08:5c2e:4076]) by DM6PR01MB5849.prod.exchangelabs.com ([fe80::c814:9a08:5c2e:4076%5]) with mapi id 15.20.3721.024; Wed, 6 Jan 2021 16:09:30 +0000 From: "Nhi Pham" To: devel@edk2.groups.io Cc: Nhi Pham , Leif Lindholm , Ard Biesheuvel Subject: [PATCH v2 2/4] EmbeddedPkg/TimeBaseLib: Fix for minor code formatting Date: Wed, 6 Jan 2021 23:09:01 +0700 Message-Id: <20210106160903.27679-3-nhi@os.amperecomputing.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20210106160903.27679-1-nhi@os.amperecomputing.com> References: <20210106160903.27679-1-nhi@os.amperecomputing.com> X-Originating-IP: [118.69.219.201] X-ClientProxiedBy: HK2PR02CA0220.apcprd02.prod.outlook.com (2603:1096:201:20::32) To DM6PR01MB5849.prod.exchangelabs.com (2603:10b6:5:205::20) Return-Path: nhi@os.amperecomputing.com MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (118.69.219.201) by HK2PR02CA0220.apcprd02.prod.outlook.com (2603:1096:201:20::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3742.6 via Frontend Transport; Wed, 6 Jan 2021 16:09:28 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 00eb1170-588e-4767-bc52-08d8b25d7303 X-MS-TrafficTypeDiagnostic: DM5PR01MB2538: X-MS-Exchange-Transport-Forked: True X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3383; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 7oLY7rzrbYk/R63anR4BP5lwKpnSYzE4M3A4bz4uvHfqwK9xYczPBrM/jCZGHVmlhAHrviZjkQE7Au2aXSA/qqERZ+zfsMOKVoAqiWZxznOHVL4ng0gsb5EnGpCY48OIovyrbAorJ61UzPIwnSR6Objau0SnihJoUQggI+VSwo9/rlRaMtDZntdAckqsKUb5nlCrJG6PvPOpS6wSAoVa/1ljfCqV2zwQreCBCofhEMj/BEJXr9IVENu1YI/+TDIGGPrSp8/w0tBGIKBr24ecfBc0I0DKXUvrQ2MsvccBjGnz7QQ7kc3kNgTfbDVX1zAvm/ME2QThjOss9mq4X4mbjINm8mCa3jl3O+rXZkdKZ8nOO5or9raY4E/vFZM4DmOawJppgfUo9lbNfDR32GDTFvOoZf1h3WdhkKoSoY69bKuwhHAj8pDkk2rKltNvpyzBEff75Ulkh1vCjE1eI8iRww== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DM6PR01MB5849.prod.exchangelabs.com;PTR:;CAT:NONE;SFS:(4636009)(366004)(136003)(376002)(346002)(396003)(39850400004)(2616005)(6506007)(956004)(316002)(1076003)(6666004)(69590400011)(2906002)(8676002)(478600001)(6486002)(8936002)(54906003)(186003)(26005)(83380400001)(16526019)(6916009)(66556008)(6512007)(86362001)(4326008)(66476007)(52116002)(5660300002)(66946007);DIR:OUT;SFP:1102; X-MS-Exchange-AntiSpam-MessageData: =?us-ascii?Q?O4i+4uG+ehR7DweTm+6h5Otd+lEuRUUxWb2amvrWRzD/SEzvkcuSngeHENl2?= =?us-ascii?Q?7GS32rk2Rji1NFrjmwjiQd36gzXMIGL4gXOC/bb5e7E6DI/H5LfE/D6BWprE?= =?us-ascii?Q?sCa3PWD3VltGPfAWJsx+k1L9gC5kEBXmqXx0+YtrtarQxI9lzdyWwXMjJDAg?= =?us-ascii?Q?10aukC5YzE2eRMCWYCd75ppyPDq3AvwLaFMWtBTuHo7t0m76bK++baFZa8Ub?= =?us-ascii?Q?CDQ3VofG2yGkLJVldnwI7hs1JZkkE50O2Z7vdYY1lj6XrH33Grs2aBRXrthH?= =?us-ascii?Q?q+iH0kOhY2hlRfOHb0Ly91VbACJEmrgYVj4uhtbkUuP/X0drHRbf7SRyrUVI?= =?us-ascii?Q?438fNRU9d1BtMAcU2g1hLeC+Cl2jlqK64Bw3KwG15xF8saHSrE+Er7z8rjq+?= =?us-ascii?Q?WbFpbzsFfuklV5n84SIjEbBHhxw6ErHqkUlwquOiRZOyeI3LxpqR8elCjofN?= =?us-ascii?Q?DUSl8G78mUgVF4r8/zK4rV5DXoBGAtnxTTn2vvJBlNX5vhkWza57lp9Qqq3K?= =?us-ascii?Q?Fm5/eiTJFeqRG2wSmXmNYBW+3gtlRGJ4rucO8tBS4zdjsci1/X9KbzBKEowO?= =?us-ascii?Q?uF81E3gYYy7CWscRmIIVsSndzN21JMK8v8cXpQ7h7uGtrdXGTBhqUKKFSYA7?= =?us-ascii?Q?ff+/sn7KroP031QxMPS97oDvfdQ6hQ8g9jkWDrIOHiCu4aRaL1UI7vHVoeVJ?= =?us-ascii?Q?xi4KkgTL32yBOs2cYPRQ5zxrcTfahtHpzWFjBabsS2sr2ZOXA+xQFRYI6JMD?= =?us-ascii?Q?JzvrS2bb51xSW0a64QXtg9vXLfDDc/fJpIbQhkCPHNyHlU+NSSSTts584ByT?= =?us-ascii?Q?SLMsbn33CDDxYDuXR4Bws/0EiINST5nu6jF0pSWpM1jVVU5xQuoCqDNFDVRr?= =?us-ascii?Q?OrM9Qvd3+7KPgBxg4AZEz7/+71d2meNuinQrm6Dzr769VYXyn7yKUGP9USjZ?= =?us-ascii?Q?vjxRCIRd+1a0EZeXWEoVblNArVgr4ybNFbxtGNWKXDkwb5Q5K1v1FvvP4OpB?= =?us-ascii?Q?vO6F?= X-OriginatorOrg: os.amperecomputing.com X-MS-Exchange-CrossTenant-AuthSource: DM6PR01MB5849.prod.exchangelabs.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Jan 2021 16:09:30.3093 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3bc2b170-fd94-476d-b0ce-4229bdc904a7 X-MS-Exchange-CrossTenant-Network-Message-Id: 00eb1170-588e-4767-bc52-08d8b25d7303 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: D/fTBjVIBlT5oSwaa/7F3Pmje+viRATvSLN6mHDSBIh2ddmNXBkPn8jiLQASEVo0L7l9NKDcA/udEPZ2KFgFqgIb57n4iOBkxfkaLYfTZe0= X-MS-Exchange-Transport-CrossTenantHeadersStamped: DM5PR01MB2538 Content-Type: text/plain There is no functional modification in this change. Cc: Leif Lindholm Cc: Ard Biesheuvel Signed-off-by: Nhi Pham --- EmbeddedPkg/Library/TimeBaseLib/TimeBaseLib.c | 23 ++++++++++---------- 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/EmbeddedPkg/Library/TimeBaseLib/TimeBaseLib.c b/EmbeddedPkg/Library/TimeBaseLib/TimeBaseLib.c index c9048d765960..17466c1e6c67 100644 --- a/EmbeddedPkg/Library/TimeBaseLib/TimeBaseLib.c +++ b/EmbeddedPkg/Library/TimeBaseLib/TimeBaseLib.c @@ -221,23 +221,22 @@ IsDayValid ( **/ BOOLEAN EFIAPI -IsTimeValid( +IsTimeValid ( IN EFI_TIME *Time ) { // Check the input parameters are within the range specified by UEFI - if ((Time->Year < 2000) || - (Time->Year > 2099) || - (Time->Month < 1 ) || - (Time->Month > 12 ) || - (!IsDayValid (Time) ) || - (Time->Hour > 23 ) || - (Time->Minute > 59 ) || - (Time->Second > 59 ) || - (Time->Nanosecond > 999999999) || + if ((Time->Year < 2000) || + (Time->Year > 2099) || + (Time->Month < 1 ) || + (Time->Month > 12 ) || + (!IsDayValid (Time) ) || + (Time->Hour > 23 ) || + (Time->Minute > 59 ) || + (Time->Second > 59 ) || + (Time->Nanosecond > 999999999) || (!((Time->TimeZone == EFI_UNSPECIFIED_TIMEZONE) || ((Time->TimeZone >= -1440) && (Time->TimeZone <= 1440)))) || - (Time->Daylight & (~(EFI_TIME_ADJUST_DAYLIGHT | EFI_TIME_IN_DAYLIGHT))) - ) { + (Time->Daylight & (~(EFI_TIME_ADJUST_DAYLIGHT | EFI_TIME_IN_DAYLIGHT)))) { return FALSE; } -- 2.17.1