From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-BN3-obe.outbound.protection.outlook.com (mail-bn3nam01on0613.outbound.protection.outlook.com [IPv6:2a01:111:f400:fe41::613]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 68AC58193F for ; Wed, 4 Jan 2017 15:08:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amdcloud.onmicrosoft.com; s=selector1-amd-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=o1tjH6hXKILr8GBotSIpsRC3MYvOL6yNtuvN/BhMBQs=; b=aNYDvefjkKRJenaobcxSQOaOpp25EyAdhdbOXyLBBT06R1eHUGbUF5lws9cgY3pVoqU9TjmUN/7PaRdHs4hdhgPB2m5ww83e7kLLiOnnjEYYw68V7FhQyjdY7OkDgpgXVBLRTTMs83DxWD4fKe0r0UnnCuNn/biw/4Gt1FQhhgA= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=leo.duran@amd.com; Received: from leduran-Precision-WorkStation-T5400.amd.com (165.204.77.1) by CY4PR12MB1237.namprd12.prod.outlook.com (10.168.167.12) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.817.10; Wed, 4 Jan 2017 23:08:08 +0000 From: Leo Duran To: CC: , , , , , Leo Duran Date: Wed, 4 Jan 2017 17:07:53 -0600 Message-ID: <1483571273-11187-5-git-send-email-leo.duran@amd.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1483571273-11187-1-git-send-email-leo.duran@amd.com> References: <1483571273-11187-1-git-send-email-leo.duran@amd.com> MIME-Version: 1.0 X-Originating-IP: [165.204.77.1] X-ClientProxiedBy: CY1PR08CA0011.namprd08.prod.outlook.com (10.163.94.149) To CY4PR12MB1237.namprd12.prod.outlook.com (10.168.167.12) X-MS-Office365-Filtering-Correlation-Id: 5672b5dc-3a5f-44b1-30ab-08d434f68c8f X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:(22001);SRVR:CY4PR12MB1237; X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1237; 3:6ueQHn9ukkid4pp1XUSMp78EHHh563VwxZka08nluDURgTSli4Mk8eMqV2QNTr4d/+vjPm9eQ/349I+chgDOzgAFXkkv4mb6iAZwP764154FowAXJKPi4pMBo4rwNLsYOxWh1A7B/0bEqAmWcAfTCSzv30xc+p7ayuviWpwpZT0NlThpKy5YSnRH8bvY/lNmmp6s4MgMVyafuFyfusK2Pzy0a2kwD9WPrYZ6+HyuKFqyU8xo5SZeJo4sYgNSgkLTWO/jdsB5ja2lkb7cUOxxvQ==; 25:M/DtHHZDLvIghWxqmvSHikqKOeJH6qB2hWq/KGM3U5oN2Oq5+fpJ12xycKP2XimmccA38i/hLoE0RNSCt3GMD+xp2PjqfuvTVqx4aYvqJDJaoGrrZt2Wplx4kiberEfIiH3f4oB2wAWslz7sbs/j7C04XTItcKjYrq628KpS4wsnBd+QB3pEg5Ctya4F5tOqvmnM4kxk7zwbBard3kg/IdeD2Do1NLI5rG//6CRh5oA6YrzKeL8rpb6427JyZfq974vdmsAIqF++HSFkR4uBjtK0YDsFcYImXHVxH/8hY4ihngGrhEs5DD7TRsi/sijA3Ak/mf5mqAhyONc6dJPCzQl0lKp2d4NMUClI+jNDFpZCoa++K4ne+vdZnjAF/XUrYG78DdGeAQla00fBUChFqO5ZZOI7wNxfyJstZ6psaHj2mrr4YqkOCtwVFyCu/V3jGcC5IrEkZAZ5zzZwIegd9g== X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1237; 31:XUiQDvkfhq8jQWB8h09bgvI+k/LPTOhovJumDrN5gSoRUw6MOWZwrGpf5hsIB4P4c4F8ftmi9+CEawSfer8DgByPfdSUIMSf844uUAtwA8WIUkqraV+NHwfhBc79f7o2+MES/7zbxU5fMuBAeniUxf0BT+9c/f2imfw3gbkjw4bUV4zIvi4Rv/Y4gEAo7JVzVkp30VOUyjTCXHDht7Sh11CJYsCLyyP2Yd4fFVJMr/9nuYTshs7D1tTNQJBZlsOkd28hCEsn/yPp5EY1oQnk/Q==; 20:7iEbckSjgqQhW6V/ZjoV59WLMGyRtlOGdoJ/Vg/nSL1tYe76VRYfgLwZ0seADNev/Ut+oTuIxUjF3Pd6knZMDJy+thvJ+n8DaC7Xbqr50N4gcCfj4VsgFQGbBS68v/z4J8eh4T9nqcgi1axNDPwH8pD9WpTgqk9yU8qa4aKd0yKDBApWFila9iItn/lxu3LblAcD7+PLzw2Uyqyc7hfIBhib6PoIkjjP++ySmbiTUoZmhhpM9nY45aQffA8YqkYVdeA7BrdxoyhSoBzM6JGVXBUJRlZs9AnbuLMYge/4/yE5yT7dxIyn8JXIyEw4YlERry8maW1RdWbHFYo6kuSanZeCLBg64zcligZZIubOhX0vun4DblzSaObwYcWNsbn1XH5usPZcDoxlCvTV9/Gil7GyGToUZ4W1FXJmncUa9ZOqEGXy4449MeVX62+toFbj82LFrLUfN8Qd6YoYVh7afvMxeivxfgZNKJ/fYqrt/WdgNq0G0pHNB79+chxiD1IV X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(767451399110); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040375)(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046)(6055026)(6041248)(20161123560025)(20161123555025)(20161123564025)(20161123562025)(20161123558021)(6072148); SRVR:CY4PR12MB1237; BCL:0; PCL:0; RULEID:; SRVR:CY4PR12MB1237; X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1237; 4:djM/o+HDDYo8KgLUMLVVRhSwkB5aRqmTT3UMqaFZbI91363cYhYdaugRfvQnA2l5VKqU2gCvdNxOyKfcL4Zmcps9lt/YK8HsuixqzNj1kL7Q7WEzk1+5FSD0VsqIFZtEgQNjXJwnAyDJVjyT7OFnX3CVJk/jASRCxK6UBraQPLwhXxp8tQXF8+Db/1y2K5+gI2Ru0hrSSVHWNq4MaNwflCORi2+UFsuPZgjNs3tWUrrOrq74+u3NQJ2l+4tRj5jlSlwY/fBitZOO3vw3sxeXF//lCprnUcG+/vBtEsufl9EpIuPtvYAg52bKOYldvws/xfLkixHvaqOqyrKx2tsieb5h4RPkxWLEsOm4+zmGxBRH0TyYoPhHSP6kiV/xhvPX5sELNxdol8t9DdXr3Mykh3waxhbyN2SzExXLaBXZoc1HQesRAFyUxxhKEom+sq31gR9A4zDxavq++arWOeACnSKBYv9Ax/0VznObwvpBeXPV54RsFx7kV5z38C0xpd1BwRJcUZNGAW68pQG16V+hvEV7b/ILfBZ9QcWVIQnViGbJxzf8dFDZq+65m8ZxAhH0ztPBd9oghQJ6wxvL66ZW0GV6Fbqufz6XBzbhSNWGq9PhKvBj37XYHxoImy54R/p6owlbp1YcwIAERE2nlyEmRj8U29AdsVnVpeG8uePlM5E= X-Forefront-PRVS: 0177904E6B X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6009001)(6029001)(7916002)(39860400002)(39840400002)(39410400002)(39450400003)(39850400002)(189002)(199003)(6666003)(66066001)(48376002)(2351001)(5003940100001)(105586002)(189998001)(92566002)(50226002)(5660300001)(50466002)(54906002)(53416004)(97736004)(42186005)(25786008)(6486002)(6116002)(8676002)(47776003)(106356001)(38730400001)(101416001)(4326007)(2906002)(15395725005)(50986999)(81156014)(76176999)(2950100002)(81166006)(110136003)(68736007)(305945005)(86362001)(3846002)(7736002)(36756003)(33646002)(6916009)(6306002)(19627235001); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR12MB1237; H:leduran-Precision-WorkStation-T5400.amd.com; FPR:; SPF:None; PTR:InfoNoRecords; MX:1; A:1; LANG:en; Received-SPF: None (protection.outlook.com: amd.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY4PR12MB1237; 23:VvX7Y2rBTxCVOhDPpEf/eiHbVeas1+qRxi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fVnqZrWFa9KT+K9J/3eXPfHLv6UXbod0MH?= =?us-ascii?Q?Ltv2ageQTiWRtWzarT9Ispe3tH+N9BlpzRDOG9L2kbAzkDXUDG0GvGPjFxgi?= =?us-ascii?Q?Pw2f7dxr4rNyz3GAmkq37QpxqEoy1eY0aN1mstcD9xg1m1qw2ingR1ZxgWCm?= =?us-ascii?Q?Wk+/ExgVHly+saVGYUNoPa1PhHxFrh0vNGFxlwN+8cbFJmE/USe9GBqODu0y?= =?us-ascii?Q?DJA+BcttL5vO52yTZXae3UeBirmLpcSIhYT86o80/SayViExhfIf0v3MsyVG?= =?us-ascii?Q?py3i5irlrvdXzAHwP8rAnDkSDSv5GdtqwbW8EzQ/czV4gBw0lng+sa0ZPgGK?= =?us-ascii?Q?upVfW1Olx3VFQnFlbpN1AwWu90d5gUrSw35S4a/aMya3SFPwUU8yK23qu2Xg?= =?us-ascii?B?dz09?= X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1237; 6:bhAItHuN+/erk55LiAKR12emxf12Xo2d1szy5moTGPJJUHcqbyhOBV6crf1iQozDioqA0rAbVkqiYoF96fNlC9uw+6QJDH151vP/Y/FACVYv71ItuXm1zW1p4h+U3QAjJtryeNyeHRpBiUd59WRNAbsKHzZYyBvHcGm+rJmn3uxSZ95tHVaNipDOYZSE8zJvBKFlO/sugKDLwTu7spzlhLxQo7zUzN+duV8g3AAOM7FWmX9gewgZjpmjDrZevCgdi4xNR3Ogx57QL1iZjtMW8+w95vBpMDZJjVIBeYoWf9CqKTjLA5tsWQM71PzmAyYwtGEX8dSjZ59PXkUoZNOw86BeK0u7XypTSnJUbeDnE1FruYYTnnmTj8bu6Ku86KQ72VbwgQYJ1mQPGAjBFE79NwJCVssw/58AutF5SZ5pAndJicypekm29UikDdpMKsiq1ff/0z0KYlmuQ6+wuM70dg==; 5:WZX/bKSAyjuf0wnJzELFA1clgQJ0jwUAKz42mTCllOOXcftoB9sGoeqXQQQk2iHnZVBwq8v47qxWX64nYPkeDs2vd1ZvVwxzxV5SFFFCr20N72fqAcCl+keT9duO4MoA7HtFGMFwakxj82lHKdvvQS/v1pVDecpqvQpihnG02CY=; 24:A/8crK91sS2ShtHQNquf8HAFsmKAE9YyAq7fQyAmKKC+zaDTmSEuBhhOQxA2sut5Qw2ebMGF+ks8zWRLLrT1gp9GOGOKklQty2y8WV4gTZ4= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY4PR12MB1237; 7:jpnma6NIG5ViGxOe/asRf1e9dLBBQsH1ZLdRxU1WHWh5CpjZ/XBanBr3WLTPGhlFtmRxiPKnRWO0P9uVmrIFw3BLtccda3aCPPwEyXrOYLBG8zCGS5hLGmNXiSfc34ho0ccyRzGtr1aYMeg6jDt3RM1YPwyo0hDKfyr68wHH90iCzB3RSJJHCGbTofOy5P2bcQ26KhB0iEdA793L6UdOxQH5b6eA6Jh7Px1Ubf99ciI/4FNHFTPBRGUSdN9MgomX8QegaZuEwJ4fu0LFWYGKamS4ZNvB+vPGQeHxsgdYIAiWZ8llrYZZcO1tFRPbRjripTZJlt8cLXkTmfm9BK6QtSu7dUAMYmBx/5QDZlPn3IibXlNA6GyEXEXHI/G5BEanfkxgGlQt3by8mobvO7KUGk0LsxdUEam8DseIB+hzHHM5NPRvs6AGuW1xTdLKOSqkmxw8YPJFkULqtoEIGNrF8Q==; 20:VBqpRp+DOgE83vPmg8u52ZXNHzBYtXpL9J+fkEuuKKzCN61PWumpUQfFKx+bKKmV37gKXKK6xmOCYH/4JObNmQIfurRvz4rXRLLHa34T1DEvh1z3kPGC0BjvdYx3z1PcautelPZCMN6do+n8+SUeOTnUTRSMG95uHsEUmL4cJfcSPRNskQnPOMyL8bG8YaNqv6Si3qi5vqsZ+RAu22XnJPMweIz5buACerHI9y+YYMqFCEFB3BrfL/qQLCKMmxdO X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Jan 2017 23:08:08.8163 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR12MB1237 Subject: [PATCH 4/4] Modify QemuFwCfgLib to use new BaseIoFifoLib library. X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 04 Jan 2017 23:08:10 -0000 Content-Type: text/plain Contributed-under: TianoCore Contribution Agreement 1.0 Signed-off-by: Brijesh Singh Reviewed-by: Leo Duran --- OvmfPkg/Library/QemuFwCfgLib/Ia32/IoLibExAsm.nasm | 55 ----------------------- OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.c | 1 + OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.inf | 7 +-- OvmfPkg/Library/QemuFwCfgLib/X64/IoLibExAsm.nasm | 52 --------------------- 4 files changed, 2 insertions(+), 113 deletions(-) delete mode 100644 OvmfPkg/Library/QemuFwCfgLib/Ia32/IoLibExAsm.nasm delete mode 100644 OvmfPkg/Library/QemuFwCfgLib/X64/IoLibExAsm.nasm diff --git a/OvmfPkg/Library/QemuFwCfgLib/Ia32/IoLibExAsm.nasm b/OvmfPkg/Library/QemuFwCfgLib/Ia32/IoLibExAsm.nasm deleted file mode 100644 index faa22e9..0000000 --- a/OvmfPkg/Library/QemuFwCfgLib/Ia32/IoLibExAsm.nasm +++ /dev/null @@ -1,55 +0,0 @@ -;------------------------------------------------------------------------------ -; -; Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.
-; This program and the accompanying materials -; are licensed and made available under the terms and conditions of the BSD License -; which accompanies this distribution. The full text of the license may be found at -; http://opensource.org/licenses/bsd-license.php. -; -; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, -; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. -; -;------------------------------------------------------------------------------ - - SECTION .text - -;------------------------------------------------------------------------------ -; VOID -; EFIAPI -; IoReadFifo8 ( -; IN UINTN Port, -; IN UINTN Size, -; IN VOID *Buffer -; ); -;------------------------------------------------------------------------------ -global ASM_PFX(IoReadFifo8) -ASM_PFX(IoReadFifo8): - - mov dx, [esp + 4] - mov ecx, [esp + 8] - push edi - mov edi, [esp + 16] -rep insb - pop edi - ret - -;------------------------------------------------------------------------------ -; VOID -; EFIAPI -; IoWriteFifo8 ( -; IN UINTN Port, -; IN UINTN Size, -; IN VOID *Buffer -; ); -;------------------------------------------------------------------------------ -global ASM_PFX(IoWriteFifo8) -ASM_PFX(IoWriteFifo8): - - mov dx, [esp + 4] - mov ecx, [esp + 8] - push esi - mov esi, [esp + 16] -rep outsb - pop esi - ret - diff --git a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.c b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.c index 0bbf121..ea59bc5 100644 --- a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.c +++ b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.c @@ -18,6 +18,7 @@ #include #include #include +#include #include #include #include diff --git a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.inf b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.inf index 66ac778..6fbb702 100644 --- a/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.inf +++ b/OvmfPkg/Library/QemuFwCfgLib/QemuFwCfgLib.inf @@ -36,12 +36,6 @@ QemuFwCfgLib.c QemuFwCfgPeiDxe.c -[Sources.IA32] - Ia32/IoLibExAsm.nasm - -[Sources.X64] - X64/IoLibExAsm.nasm - [Packages] MdePkg/MdePkg.dec OvmfPkg/OvmfPkg.dec @@ -51,5 +45,6 @@ BaseMemoryLib DebugLib IoLib + IoFifoLib MemoryAllocationLib diff --git a/OvmfPkg/Library/QemuFwCfgLib/X64/IoLibExAsm.nasm b/OvmfPkg/Library/QemuFwCfgLib/X64/IoLibExAsm.nasm deleted file mode 100644 index f1078f2..0000000 --- a/OvmfPkg/Library/QemuFwCfgLib/X64/IoLibExAsm.nasm +++ /dev/null @@ -1,52 +0,0 @@ -;------------------------------------------------------------------------------ -; -; Copyright (c) 2006 - 2013, Intel Corporation. All rights reserved.
-; This program and the accompanying materials -; are licensed and made available under the terms and conditions of the BSD License -; which accompanies this distribution. The full text of the license may be found at -; http://opensource.org/licenses/bsd-license.php. -; -; THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS, -; WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED. -; -;------------------------------------------------------------------------------ - - DEFAULT REL - SECTION .text - -;------------------------------------------------------------------------------ -; VOID -; EFIAPI -; IoReadFifo8 ( -; IN UINTN Port, // rcx -; IN UINTN Size, // rdx -; IN VOID *Buffer // r8 -; ); -;------------------------------------------------------------------------------ -global ASM_PFX(IoReadFifo8) -ASM_PFX(IoReadFifo8): - - xchg rcx, rdx - xchg rdi, r8 ; rdi: buffer address; r8: save rdi -rep insb - mov rdi, r8 ; restore rdi - ret - -;------------------------------------------------------------------------------ -; VOID -; EFIAPI -; IoWriteFifo8 ( -; IN UINTN Port, // rcx -; IN UINTN Size, // rdx -; IN VOID *Buffer // r8 -; ); -;------------------------------------------------------------------------------ -global ASM_PFX(IoWriteFifo8) -ASM_PFX(IoWriteFifo8): - - xchg rcx, rdx - xchg rsi, r8 ; rdi: buffer address; r8: save rdi -rep outsb - mov rsi, r8 ; restore rdi - ret - -- 1.9.1