From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-eopbgr20087.outbound.protection.outlook.com [40.107.2.87]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id BBB2921C9127B for ; Tue, 29 Aug 2017 01:17:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=a5fGogRxDkAC+8SwgMmYOzk356frqymq8MpLbiK2cIU=; b=IzYX5wLsZs56ugdtK2Ma6QF9nhJXDx6tkhXz9Cqt2FF7lqhWq/mxFPMepmH5oTmIDfY4EyTy68M3po6sn0n74XLphdij5gMb7NQ4SwoiqAtqGXH8XcxtoAXWhbK9G/uDg18qpsYjsUtO8NAUVXupsLy4xWfLPETF6kMs9tmpSrc= Received: from DBXPR04MB144.eurprd04.prod.outlook.com (10.242.140.16) by DBXPR04MB144.eurprd04.prod.outlook.com (10.242.140.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.1385.9; Tue, 29 Aug 2017 08:19:50 +0000 Received: from DBXPR04MB144.eurprd04.prod.outlook.com ([fe80::7ccb:8c87:fdd5:bbfd]) by DBXPR04MB144.eurprd04.prod.outlook.com ([fe80::7ccb:8c87:fdd5:bbfd%15]) with mapi id 15.01.1385.014; Tue, 29 Aug 2017 08:19:49 +0000 From: Pankaj Bansal To: "edk2-devel@lists.01.org" Thread-Topic: UART Baud rate change code flow Thread-Index: AdMgnZA6KZ1lmP0uQG6ZqWwIglwyHQ== Date: Tue, 29 Aug 2017 08:19:49 +0000 Message-ID: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=pankaj.bansal@nxp.com; x-originating-ip: [192.88.169.1] x-ms-publictraffictype: Email x-microsoft-exchange-diagnostics: 1; DBXPR04MB144; 6:3b4STq48txO6z1gRE0+OkyweYK3x98JAl/fZ+QOZvThJtbTjM48+EseMIEBhjCZe1nUYGMxOBbVs6x1EEhaDAlW+FuC3ydgejo3DNr8y1gHPMfAVE5Fai+pWROU3gcHQJ4FovYtiwCprR8Thq259aeuxao59M+STF8YGVSfE2mHc3sF18pYI36oPiPqvHr/DraZWGkkbdzUDS0JMKpjoSPG4xa8JeLnuafu8tw4Cd4wYXU00k33VP1+8nKS2GW4S7o+m+FNGfneVWSj+M+Ex/n9PWFsGT5p3kN+EHDnAkAR/ffgoBxcSw+NypK3jyYQjIiZ8qIP1BJm4G7+vhpZgxA==; 5:txV0qzqh6d74t01k88g2isOSH80urjexpCcvy8S5uOrAP4UxJhewG2Pz0NpBaa47RbqNJQsaxfyTZh978XfmjeXx1lGq7UfTP0SXSnmx5VWM89xRYbjLrrWantjwkXWsD5zvQU4YqeVkwJ/G4w342w==; 24:T8+3PO60F4DQxEGhJTixUuKGTaDbs1MVeiOiGfRoG4EYBYnhuOVKPDv9jZ16QaEFgPsM6g3L4DyFuFCewzGYq7mPj8OPjNouAdZRa9jjIOA=; 7:ObBvejnnWzzIGxLEbzUwzdtV1M9WHDTM3ZvDZEd0/WbL6INdvxO0Tg1TAcr3zz7rJJw4YUSPOLVuJ5PWPIby5UV6epheRNqz/E9xqn2NsBhlzQOc0Bp7RoZeWG+7rprmtqcOTBSYCRsX14PkddtQnI07W8O+oq0zbeq0Cdr979DXioGeATEzrpWD2aR5W+UpKsd8aQbk2Or4E2sKZSkHWS6oWlQLSeiISjux+nmsuV0= x-ms-exchange-antispam-srfa-diagnostics: SSOS;SSOR; x-forefront-antispam-report: SFV:SKI; SCL:-1; SFV:NSPM; SFS:(10009020)(6009001)(199003)(189002)(50986999)(101416001)(6916009)(66066001)(33656002)(99286003)(5640700003)(2351001)(9686003)(53936002)(4326008)(110136004)(55016002)(189998001)(97736004)(106356001)(14454004)(86362001)(478600001)(5660300001)(2900100001)(25786009)(54356999)(105586002)(7696004)(7736002)(305945005)(6506006)(74316002)(3660700001)(2906002)(6116002)(102836003)(8936002)(81156014)(8676002)(81166006)(2501003)(3280700002)(3846002)(5250100002)(6436002)(68736007)(20673002); DIR:OUT; SFP:1101; SCL:1; SRVR:DBXPR04MB144; H:DBXPR04MB144.eurprd04.prod.outlook.com; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; x-ms-office365-filtering-correlation-id: 3eb091df-1849-4b23-cf64-08d4eeb6b7b5 x-ms-office365-filtering-ht: Tenant x-microsoft-antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(2017030254152)(300000503095)(300135400095)(48565401081)(2017052603199)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:DBXPR04MB144; x-ms-traffictypediagnostic: DBXPR04MB144: x-exchange-antispam-report-test: UriScan:; x-microsoft-antispam-prvs: x-exchange-antispam-report-cfa-test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(8121501046)(5005006)(3002001)(10201501046)(93006095)(93001095)(100000703101)(100105400095)(6055026)(6041248)(20161123564025)(20161123555025)(20161123560025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(201703061406153)(20161123558100)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:DBXPR04MB144; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:DBXPR04MB144; x-forefront-prvs: 0414DF926F received-spf: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) spamdiagnosticoutput: 1:99 spamdiagnosticmetadata: NSPM MIME-Version: 1.0 X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-originalarrivaltime: 29 Aug 2017 08:19:49.8592 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DBXPR04MB144 Subject: UART Baud rate change code flow X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 29 Aug 2017 08:17:13 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hello Edk2 team, We are trying to change the UART Baud rate dynamically from UEFI shell usin= g "sermode" command in our ARM64 based platform. I see the code flow of sermode call as below : ShellCommandRunSerMode() -> SerialSetAttributes() -> SerialPortSetAttribu= tes() SerialSetAttribu= tes() <- TerminalDriverBindingStart() -> SerialSetAttributes() -> SerialPort= SetAttributes()=20 TerminalDriverBindingStart() <- SerialSetAttributes() <-=20 TerminalConInReset() -> SerialReset () -> SerialPortInitialize() TerminalConInReset() <- SerialReset() <-=20 TerminalConInTimerHandler() -> SerialSetAttributes() -> SerialPortSe= tAttributes()=20 TerminalConInTimerHandler() <- SerialSetAttributes() ShellCommandRunSerMode() <- I am not able to understand why SerialSetAttributes and SerialReset are bei= ng called, while the first call to SerialSetAttributes has not yet complete= d. Is this code flow right ? am I missing something ? Thanks & Regards, Pankaj Bansal