From nobody Wed May 8 21:13:49 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) client-ip=66.175.222.108; envelope-from=bounce+27952+93737+1787277+3901457@groups.io; helo=mail02.groups.io; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+93737+1787277+3901457@groups.io; dmarc=fail(p=none dis=none) header.from=kunluntech.com.cn ARC-Seal: i=1; a=rsa-sha256; t=1663140706; cv=none; d=zohomail.com; s=zohoarc; b=Ct1BG1LkfYFPpOwOuzgs2ZYYXsI4LAWh/UKMJ3trvic/qL+8GugEnIFCFPH46GjznPWTDiMoHzh9U4ub8n3qDf0NTIssIZCL5lBlY9AS0aIdC7o3oDDXWq+BFugzXh280D+dzmAR/sG4DnqsrbV6Nsj21qfsHWIWBEa4L17F4/8= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1663140706; h=Content-Type:Date:From:List-Subscribe:List-Id:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Reply-To:Sender:Subject:To; bh=vy6pl6lYIXSEE38n2FUxfAFOnA9zbbJelwdJOkhGXUc=; b=A34PSy3QfZ21IgLvOXaNzfaomFxN+JO5fxQeTGo/cv9jBbeWKlAIS/lXJuaHLC7KMa54Sy6hAxpwgQm7vRgf+i+cdnYfDv7/M1tEXLTkb9J7YInlFZP81SCqZw8wZCYLFLdjzJbzWG12u/lLGvbmhjrYKfpaeCgRIQsgN6yxVVc= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of groups.io designates 66.175.222.108 as permitted sender) smtp.mailfrom=bounce+27952+93737+1787277+3901457@groups.io; dmarc=fail header.from= (p=none dis=none) Received: from mail02.groups.io (mail02.groups.io [66.175.222.108]) by mx.zohomail.com with SMTPS id 1663140706073225.09806757369654; Wed, 14 Sep 2022 00:31:46 -0700 (PDT) Return-Path: X-Received: by 127.0.0.2 with SMTP id Otl3YY1788612xeqhsfJjIKF; Wed, 14 Sep 2022 00:31:44 -0700 Subject: [edk2-devel] [PATCH] MdeModulePkg/Bus/Pci/XhciDxe: Fix the Bug of clean InputContext in XhcEvaluateContext64(); To: devel@edk2.groups.io From: "Jiading Zhang" X-Originating-Location: Tokyo, JP (192.109.233.224) X-Originating-Platform: Windows Chrome 105 User-Agent: GROUPS.IO Web Poster MIME-Version: 1.0 Date: Wed, 14 Sep 2022 00:14:47 -0700 Message-ID: Precedence: Bulk List-Unsubscribe: List-Subscribe: List-Help: Sender: devel@edk2.groups.io List-Id: Mailing-List: list devel@edk2.groups.io; contact devel+owner@edk2.groups.io Reply-To: devel@edk2.groups.io,jdzhang@kunluntech.com.cn X-Gm-Message-State: 435Uw6GdlKvc19dmYglgvhPDx1787277AA= Content-Type: multipart/alternative; boundary="CF0Yl0GJK7twPxC1sCK5" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=groups.io; q=dns/txt; s=20140610; t=1663140704; bh=GmWIPz6N7yqzkgcGf8HBsJGQ/ThkUi1qRKyF0EwQ6FQ=; h=Content-Type:Date:From:Reply-To:Subject:To; b=KVHFw8MmkDkMbaiAKpVRuFWo1QZ6XZdi54wUp00XjvDnSYiOFjo7+/h+pRvUlb5jASX XkNhKVdZp+pRiTZ0cM1JXWkXJBIQEuX3Z7lWibU6iXhA5MSfoYWu78RSaYFtUzm0ue9D0 vpHDNERdPQoRMUMZ0Ps0CiVfDmGtqgzAoEM= X-ZohoMail-DKIM: pass (identity @groups.io) X-ZM-MESSAGEID: 1663140707575100007 --CF0Yl0GJK7twPxC1sCK5 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 The value of InputContext structure is initialized in XhcInitializeDeviceSl= ot/XhcInitializeDeviceSlot64, it shouldn't be cleared when used in XhcEvalu= ateContext64(). Signed-off-by: jdzhang --- MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c | 1 - 1 file changed, 1 deletion(-) diff --git a/MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c b/MdeModulePkg/Bus/Pc= i/XhciDxe/XhciSched.c index c2906e06fd..efbbe247c1 100644 --- a/MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c +++ b/MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c @@ -4021,7 +4021,6 @@ XhcEvaluateContext64 ( // 4.6.7 Evaluate Context // InputContext =3D Xhc->UsbDevContext[SlotId].InputContext; -=C2=A0 ZeroMem (InputContext, sizeof (INPUT_CONTEXT_64)); InputContext->InputControlContext.Dword2 |=3D BIT1; InputContext->EP[0].MaxPacketSize=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0=3D MaxP= acketSize; -- 2.20.1.windows.1 -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#93737): https://edk2.groups.io/g/devel/message/93737 Mute This Topic: https://groups.io/mt/93673303/1787277 Group Owner: devel+owner@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [importer@patchew.org] -=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D-=3D- --CF0Yl0GJK7twPxC1sCK5 Content-Type: text/html; charset="utf-8" Content-Transfer-Encoding: quoted-printable
The value of InputContext structure is initialized in XhcInitializeDev= iceSlot/XhcInitializeDeviceSlot64, it shouldn't be cleared when used in Xhc= EvaluateContext64().
 
Signed-off-by: jdzhang <jdzhang@kunluntech.com.cn>
---
 MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c | 1 -
 1 file changed, 1 deletion(-)
 
diff --git a/MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c b/MdeModulePkg/B= us/Pci/XhciDxe/XhciSched.c
index c2906e06fd..efbbe247c1 100644
--- a/MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c
+++ b/MdeModulePkg/Bus/Pci/XhciDxe/XhciSched.c
@@ -4021,7 +4021,6 @@ XhcEvaluateContext64 (
   // 4.6.7 Evaluate Context
   //
   InputContext =3D Xhc->UsbDevContext[SlotId].InputConte= xt;
-  ZeroMem (InputContext, sizeof (INPUT_CONTEXT_64));
 
   InputContext->InputControlContext.Dword2 |=3D BIT1;
   InputContext->EP[0].MaxPacketSize      =    =3D MaxPacketSize;
-- 
2.20.1.windows.1
 
_._,_._,_

G= roups.io Links:

You receive all messages sent to this group.

Vi= ew/Reply Online (#93737) | | Mute This Topic | New Topic
Your Subscription | Contact Group Owner | Unsubscribe [importer@patchew.org]
_._,_._,_

=20 --CF0Yl0GJK7twPxC1sCK5--