From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.115; helo=mga14.intel.com; envelope-from=star.zeng@intel.com; receiver=edk2-devel@lists.01.org Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 13D6C211211F8 for ; Mon, 4 Jun 2018 19:29:38 -0700 (PDT) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 04 Jun 2018 19:29:37 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.49,477,1520924400"; d="scan'208";a="46775944" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by orsmga008.jf.intel.com with ESMTP; 04 Jun 2018 19:29:37 -0700 Received: from fmsmsx115.amr.corp.intel.com (10.18.116.19) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 4 Jun 2018 19:29:36 -0700 Received: from shsmsx101.ccr.corp.intel.com (10.239.4.153) by fmsmsx115.amr.corp.intel.com (10.18.116.19) with Microsoft SMTP Server (TLS) id 14.3.319.2; Mon, 4 Jun 2018 19:29:36 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.223]) by SHSMSX101.ccr.corp.intel.com ([169.254.1.82]) with mapi id 14.03.0319.002; Tue, 5 Jun 2018 10:29:34 +0800 From: "Zeng, Star" To: "Ni, Ruiyu" , "edk2-devel@lists.01.org" CC: "Zeng, Star" Thread-Topic: [PATCH v2 2/4] MdeModulePkg: Add AtaAtapiPolicy protocol definition Thread-Index: AQHT+9IyNlD6eWzsAkOmzizs2sojPqRQ8ehg Date: Tue, 5 Jun 2018 02:29:33 +0000 Message-ID: <0C09AFA07DD0434D9E2A0C6AEB0483103BB53315@shsmsx102.ccr.corp.intel.com> References: <20180604070337.164836-1-ruiyu.ni@intel.com> <20180604070337.164836-3-ruiyu.ni@intel.com> In-Reply-To: <20180604070337.164836-3-ruiyu.ni@intel.com> Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: [PATCH v2 2/4] MdeModulePkg: Add AtaAtapiPolicy protocol definition X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.26 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 05 Jun 2018 02:29:38 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Ray, I could not find code to compare DeviceSleepEnable/AggressiveDeviceSleepEna= ble with value 0, is that expected? Thanks, Star -----Original Message----- From: Ni, Ruiyu=20 Sent: Monday, June 4, 2018 3:04 PM To: edk2-devel@lists.01.org Cc: Zeng, Star Subject: [PATCH v2 2/4] MdeModulePkg: Add AtaAtapiPolicy protocol definitio= n The patch adds AtaAtapiPolicy protocol which is produced by platform and consumed by AtaAtapiPassThruDxe driver. Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Ruiyu Ni Cc: Star Zeng --- MdeModulePkg/Include/Protocol/AtaAtapiPolicy.h | 59 ++++++++++++++++++++++= ++++ MdeModulePkg/MdeModulePkg.dec | 2 + 2 files changed, 61 insertions(+) create mode 100644 MdeModulePkg/Include/Protocol/AtaAtapiPolicy.h diff --git a/MdeModulePkg/Include/Protocol/AtaAtapiPolicy.h b/MdeModulePkg/= Include/Protocol/AtaAtapiPolicy.h new file mode 100644 index 0000000000..12657d749e --- /dev/null +++ b/MdeModulePkg/Include/Protocol/AtaAtapiPolicy.h @@ -0,0 +1,59 @@ +/** @file + ATA ATAPI Policy protocol is produced by platform and consumed by AtaAta= piPassThruDxe + driver. + + Copyright (c) 2018, Intel Corporation. All rights reserved.
+ This program and the accompanying materials + are licensed and made available under the terms and conditions of the BS= D License + which accompanies this distribution. The full text of the license may b= e 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 IMP= LIED. + +**/ +#ifndef __ATA_ATAPI_POLICY_H__ +#define __ATA_ATAPI_POLICY_H__ + +#define EDKII_ATA_ATAPI_POLICY_PROTOCOL_GUID \ + { \ + 0xe59cd769, 0x5083, 0x4f26,{ 0x90, 0x94, 0x6c, 0x91, 0x9f, 0x91, 0x6c,= 0x4e } \ + } + +typedef struct { + /// + /// Protocol version. + /// + UINT32 Version; + + /// + /// 0: Disable Power-up in Standby; + /// 1: Enable Power-up in Standby; + /// others: Since PUIS setting is non-volatile, platform can use other v= alue than 0/1 to keep hardware PUIS setting. + /// + UINT8 PuisEnable; + + /// + /// 0: Disable Device Sleep; + /// 1: Enable Device Sleep; + /// others: Ignored. + /// + UINT8 DeviceSleepEnable; + + /// + /// 0: Disable Aggressive Device Sleep; + /// 1: Enable Aggressive Device Sleep; + /// others: Ignored. + /// + UINT8 AggressiveDeviceSleepEnable; + + UINT8 Reserved; +} EDKII_ATA_ATAPI_POLICY_PROTOCOL; + +#define EDKII_ATA_ATAPI_POLICY_VERSION 0x00010000 + + +extern EFI_GUID gEdkiiAtaAtapiPolicyProtocolGuid; + +#endif + diff --git a/MdeModulePkg/MdeModulePkg.dec b/MdeModulePkg/MdeModulePkg.dec index 97ec87e1cf..3802b6e0b8 100644 --- a/MdeModulePkg/MdeModulePkg.dec +++ b/MdeModulePkg/MdeModulePkg.dec @@ -606,6 +606,8 @@ [Protocols] ## Include/Protocol/FirmwareManagementProgress.h gEdkiiFirmwareManagementProgressProtocolGuid =3D { 0x1849bda2, 0x6952, 0= x4e86, { 0xa1, 0xdb, 0x55, 0x9a, 0x3c, 0x47, 0x9d, 0xf1 } } =20 + ## Include/Protocol/AtaAtapiPolicy.h + gEdkiiAtaAtapiPolicyProtocolGuid =3D { 0xe59cd769, 0x5083, 0x4f26,{ 0x90= , 0x94, 0x6c, 0x91, 0x9f, 0x91, 0x6c, 0x4e } } # # [Error.gEfiMdeModulePkgTokenSpaceGuid] # 0x80000001 | Invalid value provided. --=20 2.16.1.windows.1