mirror of https://github.com/acidanthera/audk.git
Add volatile keyword to NvmExpressPei's Passthru CQ
This applies the volatile keyword and appropriate casts to the NvmExpressPei's Passthru CQ. Cc: Hao A Wu <hao.a.wu@intel.com> Cc: Ray Ni <ray.ni@intel.com> Cc: Jian J Wang <jian.j.wang@intel.com> Cc: Liming Gao <gaoliming@byosoft.com.cn> Cc: Michael Kubacki <mikuback@linux.microsoft.com> Cc: Sean Brogan <sean.brogan@microsoft.com> Signed-off-by: Oliver Smith-Denny <osde@linux.microsoft.com> Reviewed-by: Hao A Wu <hao.a.wu@intel.com> Acked-by: Michael Kubacki <michael.kubacki@microsoft.com>
This commit is contained in:
parent
293b97d0c4
commit
8dbf868e02
|
@ -115,7 +115,7 @@ NvmeCreatePrpList (
|
||||||
**/
|
**/
|
||||||
EFI_STATUS
|
EFI_STATUS
|
||||||
NvmeCheckCqStatus (
|
NvmeCheckCqStatus (
|
||||||
IN NVME_CQ *Cq
|
IN volatile NVME_CQ *Cq
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
if ((Cq->Sct == 0x0) && (Cq->Sc == 0x0)) {
|
if ((Cq->Sct == 0x0) && (Cq->Sc == 0x0)) {
|
||||||
|
@ -344,7 +344,7 @@ NvmePassThruExecute (
|
||||||
{
|
{
|
||||||
EFI_STATUS Status;
|
EFI_STATUS Status;
|
||||||
NVME_SQ *Sq;
|
NVME_SQ *Sq;
|
||||||
NVME_CQ *Cq;
|
volatile NVME_CQ *Cq;
|
||||||
UINT8 QueueId;
|
UINT8 QueueId;
|
||||||
UINTN SqSize;
|
UINTN SqSize;
|
||||||
UINTN CqSize;
|
UINTN CqSize;
|
||||||
|
@ -617,7 +617,7 @@ NvmePassThruExecute (
|
||||||
//
|
//
|
||||||
// Copy the Respose Queue entry for this command to the callers response buffer
|
// Copy the Respose Queue entry for this command to the callers response buffer
|
||||||
//
|
//
|
||||||
CopyMem (Packet->NvmeCompletion, Cq, sizeof (EFI_NVM_EXPRESS_COMPLETION));
|
CopyMem (Packet->NvmeCompletion, (VOID *)Cq, sizeof (EFI_NVM_EXPRESS_COMPLETION));
|
||||||
|
|
||||||
//
|
//
|
||||||
// Check the NVMe cmd execution result
|
// Check the NVMe cmd execution result
|
||||||
|
|
Loading…
Reference in New Issue