From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=148.163.129.52; helo=dispatch1-us1.ppe-hosted.com; envelope-from=tpilar@solarflare.com; receiver=edk2-devel@lists.01.org Received: from dispatch1-us1.ppe-hosted.com (dispatch1-us1.ppe-hosted.com [148.163.129.52]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 04602211616B3 for ; Tue, 2 Oct 2018 07:46:31 -0700 (PDT) X-Virus-Scanned: Proofpoint Essentials engine Received: from webmail.solarflare.com (webmail.solarflare.com [12.187.104.26]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-SHA384 (256/256 bits)) (No client certificate requested) by mx1-us3.ppe-hosted.com (Proofpoint Essentials ESMTP Server) with ESMTPS id 6868AB4005A for ; Tue, 2 Oct 2018 14:46:30 +0000 (UTC) Received: from tp-desktop.uk.solarflarecom.com (10.17.20.51) by ocex03.SolarFlarecom.com (10.20.40.36) with Microsoft SMTP Server (TLS) id 15.0.1395.4; Tue, 2 Oct 2018 07:46:27 -0700 From: "Tomas Pilar (tpilar)" To: "edk2-devel@lists.01.org" Message-ID: <436c51f1-3ca0-9efa-c79d-b12f46be10ff@solarflare.com> Date: Tue, 2 Oct 2018 15:46:25 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 X-Originating-IP: [10.17.20.51] X-TM-AS-Product-Ver: SMEX-12.5.0.1300-8.5.1010-24130.005 X-TM-AS-Result: No-3.027000-4.000000-10 X-TMASE-MatchedRID: AoIuaCp/2W8vebl6MJ1oUQPZZctd3P4Bm/y00tE9StZ+YesuCgkiXKOY kPCgi2F6zmy+RYEtL0lFGoS2VdsTIBgHZ8655DOPOX/V8P8ail2S8v5OLj2NysRB0bsfrpPInxM yeYT53RkKNGgFPO+loZ1gbiYXDXo/WN6idUWhFlsEn5h/8ADH66Ctw+E2+GQhtVjwEeshRoUJrl VTaE9w9OvLjrN/xU9vGlK0ux8jVwrW7TWbOh+TWJGYTqi6gneM3ZcrA+o+FYYFWG1G7q8GC1Zca 9RSYo/b X-TM-AS-User-Approved-Sender: No X-TM-AS-User-Blocked-Sender: No X-TMASE-Result: 10--3.027000-4.000000 X-TMASE-Version: SMEX-12.5.0.1300-8.5.1010-24130.005 X-MDID: 1538491591-ufApISlzX7jc Subject: [PATCH] BaseTools: Allow multiple PciDeviceId in Fdf OptionROM override X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Oct 2018 14:46:32 -0000 Content-Type: text/plain; charset="windows-1252" Content-Language: en-US Content-Transfer-Encoding: 7bit Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Tomas Pilar --- BaseTools/Source/Python/GenFds/FdfParser.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/BaseTools/Source/Python/GenFds/FdfParser.py b/BaseTools/Source/Python/GenFds/FdfParser.py index 63687e98bb..a65f2cfd2d 100644 --- a/BaseTools/Source/Python/GenFds/FdfParser.py +++ b/BaseTools/Source/Python/GenFds/FdfParser.py @@ -4469,10 +4469,15 @@ class FdfParser: if self.__IsKeyword( "PCI_DEVICE_ID"): if not self.__IsToken( "="): raise Warning("expected '='", self.FileName, self.CurrentLineNumber) - if not self.__GetNextHexNumber(): - raise Warning("expected Hex device id", self.FileName, self.CurrentLineNumber) - Overrides.PciDeviceId = self.__Token + # Get a list of PCI IDs + Overrides.PciDeviceId = "" + + while self.__GetNextHexNumber(): + Overrides.PciDeviceId += " " + self.__Token + + if not Overrides.PciDeviceId: + raise Warning("expected one or more Hex device ids", self.FileName, self.CurrentLineNumber) continue if self.__IsKeyword( "PCI_REVISION"): -- 2.17.1