From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from EUR04-DB3-obe.outbound.protection.outlook.com (EUR04-DB3-obe.outbound.protection.outlook.com [40.107.6.54]) by mx.groups.io with SMTP id smtpd.web11.5442.1609922723292520625 for ; Wed, 06 Jan 2021 00:45:24 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@armh.onmicrosoft.com header.s=selector2-armh-onmicrosoft-com header.b=crqwcYZA; spf=pass (domain: arm.com, ip: 40.107.6.54, mailfrom: sami.mujawar@arm.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2EUYhdAoFZDbwKvn7LhSWplRKAkxeWGyJZBzO1/+DbA=; b=crqwcYZAdqRR0DL/e3sFkGXpMlYEZsX6NluvZaovlxSQ3kR1nojraUhWBdLHUew3Ic6dzAsnmgMxzEVCqpO286n50V3G88pcxwEd/7Zz7si1a7I42CcmuywkWV3fftH0hT+32zI4SPrQLE+WI5+96KbulxJ2oON8dWUHeykWfjo= Received: from AM6P192CA0031.EURP192.PROD.OUTLOOK.COM (2603:10a6:209:83::44) by AM6PR08MB4835.eurprd08.prod.outlook.com (2603:10a6:20b:c3::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3721.23; Wed, 6 Jan 2021 08:45:20 +0000 Received: from VE1EUR03FT062.eop-EUR03.prod.protection.outlook.com (2603:10a6:209:83:cafe::af) by AM6P192CA0031.outlook.office365.com (2603:10a6:209:83::44) 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 08:45:20 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 63.35.35.123) smtp.mailfrom=arm.com; edk2.groups.io; dkim=pass (signature was verified) header.d=armh.onmicrosoft.com;edk2.groups.io; dmarc=pass action=none header.from=arm.com; Received-SPF: Pass (protection.outlook.com: domain of arm.com designates 63.35.35.123 as permitted sender) receiver=protection.outlook.com; client-ip=63.35.35.123; helo=64aa7808-outbound-1.mta.getcheckrecipient.com; Received: from 64aa7808-outbound-1.mta.getcheckrecipient.com (63.35.35.123) by VE1EUR03FT062.mail.protection.outlook.com (10.152.18.252) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.3721.21 via Frontend Transport; Wed, 6 Jan 2021 08:45:18 +0000 Received: ("Tessian outbound fc5cc0046d61:v71"); Wed, 06 Jan 2021 08:45:18 +0000 X-CR-MTA-TID: 64aa7808 Received: from 7e251374690a.2 by 64aa7808-outbound-1.mta.getcheckrecipient.com id 024F681E-F655-411C-8CC4-CF6BE205B303.1; Wed, 06 Jan 2021 08:45:13 +0000 Received: from EUR02-VE1-obe.outbound.protection.outlook.com by 64aa7808-outbound-1.mta.getcheckrecipient.com with ESMTPS id 7e251374690a.2 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384); Wed, 06 Jan 2021 08:45:13 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=W3K5eAIXA2vC9QJ2VyXCYuBEIHuIm51CNiVu17MGgsBzdVXbY+uA7RPGq/9U4aRzJpA6YmMvmQTtObBWxlA+v3Dm4/lq0T3+8kdX80QeoCWoKH5lap3iKqJq7QRRUrFo/mqKCp1sJ8SBDlTKVttbFtpG0uonPAc/Sz3I33v6wVHaZh2qozXLBrfvJ3yW9clGY2m1zvys8+FktObfXO941Sa71R0RIPIdkPyWobU5JHJOnK40s2pNp2wpoQaCgLwywA5mVy4MpCMiY8niGqcTKNy2FGLQeDOKO8omLVx4ApqTWlytEBxcATnzNYRqn5v8HR7wyxfwsmNiNmVwJqlYqA== 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=2EUYhdAoFZDbwKvn7LhSWplRKAkxeWGyJZBzO1/+DbA=; b=JjphTeCvTHl/Gl0EJsEPExxTNGr5c+OQCdiLFFqZOuR3O60clEuiUIpb6CP7H6Tx5E0n71dsjjP2QRP+ehSBYdmhJe1YkP3O8rJborj8SXaGHSdnBdiakd+tv1blRepsEDd2IqbEetg+b/hhioJBEqMNmOUqDq75f7BO2kvRLgvJ1jBuHkl8sXTpOi5ZaAuFKZ891hHQsjj6W/1GG0l7ug/h67b+0jx2CFa1UJoU1boWHEjaV3HL8kFziolc9pofHvFK4zOmTZ07rcWP7txjSe+GWIA70IjUfre8LEe7LyIP5NJ94fg3ysIFjSYddwThA9B43iTR28Hxkz/RB8e4+g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=arm.com; dmarc=pass action=none header.from=arm.com; dkim=pass header.d=arm.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=armh.onmicrosoft.com; s=selector2-armh-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=2EUYhdAoFZDbwKvn7LhSWplRKAkxeWGyJZBzO1/+DbA=; b=crqwcYZAdqRR0DL/e3sFkGXpMlYEZsX6NluvZaovlxSQ3kR1nojraUhWBdLHUew3Ic6dzAsnmgMxzEVCqpO286n50V3G88pcxwEd/7Zz7si1a7I42CcmuywkWV3fftH0hT+32zI4SPrQLE+WI5+96KbulxJ2oON8dWUHeykWfjo= Received: from DB7PR08MB3097.eurprd08.prod.outlook.com (2603:10a6:5:1d::27) by DB9PR08MB6553.eurprd08.prod.outlook.com (2603:10a6:10:25b::15) 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 08:45:11 +0000 Received: from DB7PR08MB3097.eurprd08.prod.outlook.com ([fe80::315c:f6c3:2600:bd39]) by DB7PR08MB3097.eurprd08.prod.outlook.com ([fe80::315c:f6c3:2600:bd39%6]) with mapi id 15.20.3721.024; Wed, 6 Jan 2021 08:45:11 +0000 From: "Sami Mujawar" To: "devel@edk2.groups.io" , Samer El-Haj-Mahmoud CC: Leif Lindholm , Ard Biesheuvel , nd Subject: Re: [edk2-devel] [edk2-platform][PATCH v1 1/1] ArmPlatformPkg/PL011UartLib : Fix SetControl() SCT conformance Thread-Topic: [edk2-devel] [edk2-platform][PATCH v1 1/1] ArmPlatformPkg/PL011UartLib : Fix SetControl() SCT conformance Thread-Index: AQHW1wWU7m4ElyTAzk6c5rARRoeIO6oZmaFAgADGuAA= Date: Wed, 6 Jan 2021 08:45:11 +0000 Message-ID: References: <16528319E8EDB840.11931@groups.io> In-Reply-To: Accept-Language: en-GB, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ts-tracking-id: 3C742B8AA4615D41B47080E536F2B649.0 x-checkrecipientchecked: true Authentication-Results-Original: edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=none action=none header.from=arm.com; x-originating-ip: [2a00:23c6:548a:4800:e57f:6514:b3ee:55b5] x-ms-publictraffictype: Email X-MS-Office365-Filtering-HT: Tenant X-MS-Office365-Filtering-Correlation-Id: 6effa6ba-46d9-47ae-663a-08d8b21f660c x-ms-traffictypediagnostic: DB9PR08MB6553:|AM6PR08MB4835: x-ms-exchange-transport-forked: True X-Microsoft-Antispam-PRVS: x-checkrecipientrouted: true nodisclaimer: true x-ms-oob-tlc-oobclassifiers: OLM:8882;OLM:8882; X-MS-Exchange-SenderADCheck: 1 X-Microsoft-Antispam-Untrusted: BCL:0; X-Microsoft-Antispam-Message-Info-Original: UjkizeopcgaNreeFdsgp299PfPv12mEtBcrigKTBhmdJfvzb6sd/9u+45cgXuRybDBlR32Ch6SCZHAxFbsjXw5kImDeSSl625jW7DehSwP3NAt8KnrmA5zZx3rbaF3glBJiQ94uwb5D7UtyKFQKf0BujhrHHoX1mJPDxtma7TFvX1xL6V6wRoYOjGnN6PBlNuVskEzUTqYwu22/JU6yP5LT+NSR6mVeqmwGuoyRWWTyhUaMNl7ep42lwjd5Z2E3bzbbQzBsPeulj+3otkzFa0ReIXZsej8JuABuVeuSL2NCUBuZzzsms6K8cO7Jy3V+SjIzfUJCjagI9rwChAYmaKOvdr/FGX9QIkIQf9Ayus/j3Qt2/MzDtEINN0r5r1itqVr3k41RfLRIYfiYvdjLtZK5Txky8hzXZ4NJWJ+1Y2OuU1Ud/HKWcbWkYPWEH8fArFk8mFe3VHBS/fnSg0hPjoQ== X-Forefront-Antispam-Report-Untrusted: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:DB7PR08MB3097.eurprd08.prod.outlook.com;PTR:;CAT:NONE;SFS:(4636009)(39860400002)(346002)(396003)(376002)(136003)(366004)(66476007)(64756008)(66446008)(66946007)(66556008)(86362001)(76116006)(55016002)(6636002)(19627235002)(5660300002)(71200400001)(9686003)(33656002)(8676002)(8936002)(2906002)(186003)(6506007)(966005)(7696005)(52536014)(478600001)(53546011)(83380400001)(4326008)(54906003)(110136005)(316002);DIR:OUT;SFP:1101; x-ms-exchange-antispam-messagedata: =?us-ascii?Q?c3WFb+CdVOHjM0u+5Qdt4fq5vj3YV5AvBy/q4KnscVyeaUvnVnxIxRJtAWvw?= =?us-ascii?Q?rAeooOL/EWchiPxGnx1zp227Mg1Pfk/gq5FkaGZC/JXSrJew8WkO6SCh6F/2?= =?us-ascii?Q?kMNMkzDggxR6iGWfsvdSn2f2V9R4c2tDmVkfoi187lrntqOXnXKd9UmU28ZH?= =?us-ascii?Q?Oi1liAOlfrMurksJNlL1Iy6D/ly2YQsilZ2wdklDuBCOnaS1WE5lz2ID6wkC?= =?us-ascii?Q?t1Z2HeMAQGnv6GGHehvR+FVNfeaug2+Kf5zGExQ+/xP6fgmfq/aK4ttIEvcf?= =?us-ascii?Q?rBbWKQ8Q8WoslZ7hL5D7AEg7a+lU+LgxFIpRpG533bkawiI32FUex1uwVClv?= =?us-ascii?Q?SyM7y+ng9yGuZXwaB8ln7+uXnQ0PQQTzOOqnr/SbOSasRNT4fdwrd/vgqc7K?= =?us-ascii?Q?+8j/S2QSOigoDzv6sfMonbQ+lY7uHKB+aHQSXK6b7CefsUBKnb31PYFpIQdv?= =?us-ascii?Q?hYm89Gsh5FTPlscBlf2cS2emF4rjZjE+/0qbmTsmxI5E/U/8CmOCrEBDyLtU?= =?us-ascii?Q?bqN1Ulbnm4T9fi/cbbbTvfc4WgRjFOXHT6ci2nQIGCuymhzgWg6IH4efs19K?= =?us-ascii?Q?pC7h/f/LMAM4ExRqySIOFVWw24Z6OdlPwbUy6hqGCWcQX9xkkZdzTGSSOV7H?= =?us-ascii?Q?rP+/ldrtX8yMUgM8y32+oCX1CmDgnMugi43Zq5me/eZf36khp6YV9XmUForm?= =?us-ascii?Q?vGp1FgjafyFPtjyScx1icSqjtuiND6i6CcELbxOG6VTh5BJ1b9zMJSkmbM8b?= =?us-ascii?Q?lL1RvmSieZtBzMoFIsh30g9E5D8bFo0kCq9auMSidXeMbXjqQ/00ahW5i58d?= =?us-ascii?Q?x7OlG3Q9oW1XOm+FCQnoDrZ5MQmv5MBFU1vGycaUgj7uRI0yXShnIaAoU8Jx?= =?us-ascii?Q?E5TPLnofPzM//pvpa6yTI3Rv6IIgWWQPLIU7h/QYDO/aQnFMEwqNpzexOcmW?= =?us-ascii?Q?dvq4efblrqZ+H9fm6ExrGHDNdp8WmemA18Kg7a2vID3PXvoBhcGhrxuL5JOk?= =?us-ascii?Q?DWp02rhxiL/D2C/VHPgbxjcqMhjrlwpd5frPVee0KTU+8b8=3D?= MIME-Version: 1.0 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB9PR08MB6553 Original-Authentication-Results: edk2.groups.io; dkim=none (message not signed) header.d=none;edk2.groups.io; dmarc=none action=none header.from=arm.com; Return-Path: Sami.Mujawar@arm.com X-EOPAttributedMessage: 0 X-MS-Exchange-Transport-CrossTenantHeadersStripped: VE1EUR03FT062.eop-EUR03.prod.protection.outlook.com X-MS-Office365-Filtering-Correlation-Id-Prvs: 37aa5ef7-44b5-4522-8ff2-08d8b21f6145 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: uRf5dIpVDnz9EbgDDMwpLzdlibPJVXq84Ay3u372mrfWMym4jKAa4ycbCdBdpDL8GSepYiBqhQE2YaYxNm8WGUL7klhoT/THgNMDSquvMLQK9wjqKsw7rPHQM1WxxNd+dOyJil57juHtZ6O0HULK+AL6bqGuBCbspWXQpRCnJFK1WWOBvX1cb3fVIy84v6rK+Tumo+eKnvst+653p7qEbjlUlODSbB2X0T49Le8MdRz5iUAub6lq+mzu4PfXE8L+jznE1mFWzyvYasNkwc6cHi81Yu4x+jqLazFG2L4F+HN0vMKdXtEFDRIn5dFe22P3XDR1WRb0V8Ib2VXWF2o3DkfaFKaDyUAtejU9tM5OjUrg1j3qNG2wP7qokkhZr7s/4BAGq3txn6nXx769BTQdLP7kDSWrrQdD5eVww/taKiQ4fWp7pMnTXLoCXJSEAlb8pbz3EB+EnU5P56iUao1can3dARHFvOzaDwMtXY+vIdiT+tcxQxu5Utg9xltM9Qc8wiB+QLr/8/qvBjOeyIlP05UopXFsVPGmXiGh3vxDJcyKXU9P7iLBpQOHKNHHArZ9 X-Forefront-Antispam-Report: CIP:63.35.35.123;CTRY:IE;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:64aa7808-outbound-1.mta.getcheckrecipient.com;PTR:ec2-63-35-35-123.eu-west-1.compute.amazonaws.com;CAT:NONE;SFS:(4636009)(396003)(346002)(136003)(376002)(39860400002)(46966006)(7696005)(966005)(53546011)(81166007)(478600001)(19627235002)(6636002)(9686003)(82740400003)(5660300002)(316002)(356005)(86362001)(82310400003)(70586007)(55016002)(70206006)(336012)(47076005)(2906002)(110136005)(6506007)(8936002)(26005)(34070700002)(33656002)(54906003)(186003)(8676002)(4326008)(52536014)(83380400001);DIR:OUT;SFP:1101; X-OriginatorOrg: arm.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Jan 2021 08:45:18.5740 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6effa6ba-46d9-47ae-663a-08d8b21f660c X-MS-Exchange-CrossTenant-Id: f34e5979-57d9-4aaa-ad4d-b122a662184d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=f34e5979-57d9-4aaa-ad4d-b122a662184d;Ip=[63.35.35.123];Helo=[64aa7808-outbound-1.mta.getcheckrecipient.com] X-MS-Exchange-CrossTenant-AuthSource: VE1EUR03FT062.eop-EUR03.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM6PR08MB4835 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi Samer, Please find my response marked [SAMI]. Regards, Sami Mujawar -----Original Message----- From: devel@edk2.groups.io On Behalf Of Samer El-Ha= j-Mahmoud via groups.io Sent: 05 January 2021 08:47 PM To: devel@edk2.groups.io; Samer El-Haj-Mahmoud Cc: Leif Lindholm ; Ard Biesheuvel Subject: Re: [edk2-devel] [edk2-platform][PATCH v1 1/1] ArmPlatformPkg/PL0= 11UartLib : Fix SetControl() SCT conformance Gentle reminder > -----Original Message----- > From: devel@edk2.groups.io On Behalf Of Samer > El-Haj-Mahmoud via groups.io > Sent: Sunday, December 20, 2020 2:23 PM > To: devel@edk2.groups.io > Cc: Leif Lindholm ; Ard Biesheuvel > > Subject: [edk2-devel] [edk2-platform][PATCH v1 1/1] > ArmPlatformPkg/PL011UartLib : Fix SetControl() SCT conformance > > REF: https://github.com/pftf/RPi4/issues/87 > > The PL011UartLib SetControl() is failing the SCT test for > SerialIoBBTestConformance (00605CBC-3965-4B61-A254-2B2B723172EA), > which is trying to set bits that are not supported per UEFI spec. > > Add proper argument check for valid bits, and confirm that test passes. > > Cc: Leif Lindholm > Cc: Ard Biesheuvel > Signed-off-by: Samer El-Haj-Mahmoud > --- > ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.c | 15 > +++++++++++++++ > 1 file changed, 15 insertions(+) > > diff --git a/ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.c > b/ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.c > index 3c58a0f39acb..ec6056f5fdfd 100644 > --- a/ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.c > +++ b/ArmPlatformPkg/Library/PL011UartLib/PL011UartLib.c > @@ -269,6 +269,21 @@ PL011UartSetControl ( > { > > UINT32 Bits; > > > > + > > + // > > + // Per UEFI spec, the control bits that can be set are : > > + // EFI_SERIAL_DATA_TERMINAL_READY > > + // EFI_SERIAL_REQUEST_TO_SEND > > + // EFI_SERIAL_HARDWARE_LOOPBACK_ENABLE > > + // EFI_SERIAL_SOFTWARE_LOOPBACK_ENABLE > > + // EFI_SERIAL_HARDWARE_FLOW_CONTROL_ENABLE > > + // > > + if ((Control & (~(EFI_SERIAL_REQUEST_TO_SEND | > EFI_SERIAL_DATA_TERMINAL_READY | > > + EFI_SERIAL_HARDWARE_LOOPBACK_ENABLE | > EFI_SERIAL_SOFTWARE_LOOPBACK_ENABLE | > > + EFI_SERIAL_HARDWARE_FLOW_CONTROL_ENABLE))) !=3D 0) = { > > + return EFI_UNSUPPORTED; > > + } > > + [SAMI] mInvalidControlBits appears to be filtering the software loopback e= nable control as it is not supported. Would it be possible to initialise mInvalidControlBits with the control bi= ts above instead, please? [/SAMI] > > if ((Control & mInvalidControlBits) !=3D 0) { > > return RETURN_UNSUPPORTED; > > } > > -- > 2.25.1 > > > > -=3D-=3D-=3D-=3D-=3D-=3D > Groups.io Links: You receive all messages sent to this group. > View/Reply Online (#69271): https://edk2.groups.io/g/devel/message/69271 > Mute This Topic: https://groups.io/mt/79110273/1945644 > Group Owner: devel+owner@edk2.groups.io > Unsubscribe: https://edk2.groups.io/g/devel/unsub [samer.el-haj- > mahmoud@arm.com] > -=3D-=3D-=3D-=3D-=3D-=3D > IMPORTANT NOTICE: The contents of this email and any attachments are confi= dential and may also be privileged. If you are not the intended recipient, = please notify the sender immediately and do not disclose the contents to an= y other person, use it for any purpose, or store or copy the information in= any medium. Thank you.