Skip to content

Commit

Permalink
Merge pull request #1196 from taj0207/main
Browse files Browse the repository at this point in the history
update with codel fix
  • Loading branch information
taj0207 authored Jul 8, 2024
2 parents b4cb654 + 6f1d71f commit 6dbda1f
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
4 changes: 3 additions & 1 deletion network/wwan/cxwmbclass/datapipe.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -428,6 +428,7 @@ MbbBusWriteData(__in MBB_BUS_HANDLE BusHandle, __in MBB_REQUEST_HANDLE RequestHa
WDFMEMORY BufferMemoryObject = NULL;
WDFREQUEST WriteRequestZLP = NULL;
PUSB_WRITE_REQ_CONTEXT writeContextZLP = NULL;
NTSTATUS ZlpStatus;

usbDeviceContext = GetUsbDeviceContext(BusObject->WdfUsbDevice);

Expand Down Expand Up @@ -641,7 +642,7 @@ MbbBusWriteData(__in MBB_BUS_HANDLE BusHandle, __in MBB_REQUEST_HANDLE RequestHa
if (WriteRequestZLP != NULL)
{

NTSTATUS ZlpStatus;


Status = WdfUsbTargetPipeFormatRequestForWrite(usbDeviceContext->BulkOutputPipe, WriteRequestZLP, NULL, NULL);
if (!NT_SUCCESS(Status))
Expand Down Expand Up @@ -696,6 +697,7 @@ MbbBusWriteData(__in MBB_BUS_HANDLE BusHandle, __in MBB_REQUEST_HANDLE RequestHa

if (WriteRequestZLP != NULL)
{
Status = ZlpStatus;
FreeWriteRequest(BusObject->WdfUsbDevice, WriteRequestZLP);
WriteRequestZLP = NULL;
}
Expand Down
14 changes: 6 additions & 8 deletions network/wwan/cxwmbclass/inc/util.h
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,12 @@
// Copyright (C) Microsoft. All rights reserved.
//
#pragma once
typedef enum
{
MbbPoolTagDefault = '0CBM',
MbbPoolTagNtbSend = '1CBM',
MbbPoolTagNblSend = '2CBM',
MbbPoolTagNbSend = '3CBM',
MbbPoolTagMdlReceive = '6CBM'
} MBB_POOL_TAG;

#define MbbPoolTagDefault '0CBM'
#define MbbPoolTagNtbSend '1CBM'
#define MbbPoolTagNblSend '2CBM'
#define MbbPoolTagNbSend '3CBM'
#define MbbPoolTagMdlReceive '6CBM'

#define ALLOCATE_PAGED_POOL(_y) ExAllocatePool2(POOL_FLAG_PAGED, _y, MbbPoolTagDefault)
#define ALLOCATE_NONPAGED_POOL(_y) ExAllocatePool2(POOL_FLAG_NON_PAGED, _y, MbbPoolTagDefault)
Expand Down
2 changes: 1 addition & 1 deletion network/wwan/cxwmbclass/utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -248,7 +248,7 @@ MbbBusGetStat(__in MBB_BUS_HANDLE BusHandle, __in USHORT StatIndex, __out ULONGL

if (NT_SUCCESS(Status))
{
if (BytesTransfered < sizeof(Value))
if (BytesTransfered < sizeof(*Value))
{
Status = STATUS_INFO_LENGTH_MISMATCH;
}
Expand Down

0 comments on commit 6dbda1f

Please sign in to comment.