當前位置: 首頁>>代碼示例>>C++>>正文


C++ DPF_ENTER函數代碼示例

本文整理匯總了C++中DPF_ENTER函數的典型用法代碼示例。如果您正苦於以下問題:C++ DPF_ENTER函數的具體用法?C++ DPF_ENTER怎麽用?C++ DPF_ENTER使用的例子?那麽, 這裏精選的函數代碼示例或許可以為您提供幫助。


在下文中一共展示了DPF_ENTER函數的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C++代碼示例。

示例1: PAGED_CODE

NTSTATUS CMiniportWaveRT::GetDeviceChannelCount
(
        _In_  ULONG					_ulNodeId,
        _In_  eChannelTargetType	_targetType,
		_Out_  UINT32				*_pulChannelCount
)
{
    NTSTATUS ntStatus = STATUS_INVALID_DEVICE_REQUEST;

    PAGED_CODE ();
    ASSERT(_pulChannelCount);

    DPF_ENTER(("[CMiniportWaveRT::GetChannelCount]"));

    IF_TRUE_ACTION_JUMP(_ulNodeId != KSNODE_WAVE_AUDIO_ENGINE, ntStatus = STATUS_INVALID_DEVICE_REQUEST, Exit);

    switch (_targetType)
    {
        case eVolumeAttribute:
             ntStatus = GetVolumeChannelCount(_pulChannelCount);
             break;
        case eMuteAttribute:
             ntStatus = GetMuteChannelCount(_pulChannelCount);
             break;
        case ePeakMeterAttribute:
             ntStatus = GetPeakMeterChannelCount(_pulChannelCount);
             break;
        default:
            ntStatus = STATUS_INVALID_DEVICE_REQUEST;
            break;
    }
Exit:
    return ntStatus;
}
開發者ID:0xhack,項目名稱:Windows-driver-samples,代碼行數:34,代碼來源:MiniportAudioEngineNode.cpp

示例2: STDMETHODIMP_

/*-----------------------------------------------------------------------------
IMiniportAudioEngineNode::GetSupportedDeviceFormats 
 
Decscription:

    GetSupportedDeviceFormats get the complete format list supported by the hw Audio Engine

Parameters:

        _In_ _ulNodeId: node id for the target audio engine node
        _Out_ pFormat: a buffer pointer for receiving the supported device formats
		_In_ ulBufferSize: a pointer to a ULONG variable that has the size of the buffer pointed by pFormat

Return Value:

   Appropriate NTSTATUS code

Called at PASSIVE_LEVEL

Remarks

-------------------------------------------------------------------------------------------------------------------------*/
STDMETHODIMP_(NTSTATUS) CMiniportWaveRT::GetSupportedDeviceFormats(_In_  ULONG _ulNodeId, _Out_ KSMULTIPLE_ITEM* _pFormat, _In_ ULONG _ulBufferSize)
{
    PKSDATAFORMAT_WAVEFORMATEXTENSIBLE pDeviceFormats;
    ULONG cDeviceFormats;
    NTSTATUS ntStatus = STATUS_INVALID_DEVICE_REQUEST;
    PAGED_CODE ();

    ASSERT(_pFormat);

    DPF_ENTER(("[CMiniportWaveRT::GetSupportedDeviceFormats]"));
    IF_TRUE_ACTION_JUMP(_ulNodeId != KSNODE_WAVE_AUDIO_ENGINE, ntStatus = STATUS_INVALID_DEVICE_REQUEST, Exit);

    cDeviceFormats = GetAudioEngineSupportedDeviceFormats(&pDeviceFormats);

    KSMULTIPLE_ITEM *pKsMulti = static_cast<KSMULTIPLE_ITEM*>(_pFormat);
    pKsMulti->Size = sizeof(KSMULTIPLE_ITEM) + sizeof(KSDATAFORMAT_WAVEFORMATEXTENSIBLE) * cDeviceFormats;
    pKsMulti->Count = cDeviceFormats;

    IF_TRUE_ACTION_JUMP(_ulBufferSize < pKsMulti->Size, ntStatus = STATUS_BUFFER_TOO_SMALL, Exit);

    RtlCopyMemory((PVOID)(pKsMulti + 1), pDeviceFormats,
        sizeof(KSDATAFORMAT_WAVEFORMATEXTENSIBLE) * cDeviceFormats);

    ntStatus = STATUS_SUCCESS;

Exit:    
    return ntStatus;
}
開發者ID:0xhack,項目名稱:Windows-driver-samples,代碼行數:50,代碼來源:MiniportAudioEngineNode.cpp

示例3: PAGED_CODE

CMiniportTopologySYSVAD::~CMiniportTopologySYSVAD
(
    void
)
/*++

Routine Description:

  Topology miniport destructor

Arguments:

Return Value:

  void

--*/
{
    PAGED_CODE();

    DPF_ENTER(("[%s]",__FUNCTION__));

    SAFE_RELEASE(m_AdapterCommon);
    SAFE_RELEASE(m_PortEvents);
} // ~CMiniportTopologySYSVAD
開發者ID:0xhack,項目名稱:Windows-driver-samples,代碼行數:25,代碼來源:basetopo.cpp

示例4: PAGED_CODE

//=============================================================================
CMiniportWaveCyclicStream::~CMiniportWaveCyclicStream
( 
    void 
)
/*++

Routine Description:

  Destructor for wavecyclicstream 

Arguments:

Return Value:

  NT status code.

--*/
{
    PAGED_CODE();

    DPF_ENTER(("[CMiniportWaveCyclicStream::~CMiniportWaveCyclicStream]"));

    if (NULL != m_pMiniportLocal)
    {
        m_pMiniportLocal->m_arInstanceCounts[m_ulPin] = 0;
    }
} // ~CMiniportWaveCyclicStream
開發者ID:kcrazy,項目名稱:winekit,代碼行數:28,代碼來源:minwave.cpp

示例5: target

/*-----------------------------------------------------------------------------
IMiniportAudioEngineNode::GetDeviceAttributeSteppings 
 
Decscription:

    When handling volume, mute, and meter related KS properties, Portcls calls 
    this method, inside its property handlers, to know the property stepping information for the 
    corresponding KS property.

Parameters:

        _In_ _ulNodeId: node id for the target audio engine node
        _In_ _targetType:  the query target (volume. mute, or peak meter)
		_Out_ _pKsPropMembHead: a pointer to a PKSPROPERTY_STEPPING_LONG variable for receiving returned channel count information
        _In_ ulBufferSize: a pointer to a ULONG variable that has the size of the buffer pointed by _pKsPropMembHead

Return Value:

   Appropriate NTSTATUS code

Called at PASSIVE_LEVEL

Remarks

-------------------------------------------------------------------------------------------------------------------------*/
NTSTATUS CMiniportWaveRT::GetDeviceAttributeSteppings(_In_  ULONG _ulNodeId, _In_  eChannelTargetType _targetType, _Out_ PKSPROPERTY_STEPPING_LONG _pKsPropMembHead, _In_  UINT32 _ui32DataSize)
{
    NTSTATUS ntStatus = STATUS_INVALID_DEVICE_REQUEST;

    PAGED_CODE ();

    DPF_ENTER(("[CMiniportWaveRT::GetDeviceAttributeSteppings]"));
    IF_TRUE_ACTION_JUMP(_ulNodeId != KSNODE_WAVE_AUDIO_ENGINE, ntStatus = STATUS_INVALID_DEVICE_REQUEST, Exit);

    switch (_targetType)
    {
        case eVolumeAttribute:
             ntStatus = GetVolumeSteppings(_pKsPropMembHead, _ui32DataSize);;
             break;
        case eMuteAttribute:
             ntStatus = GetMuteSteppings(_pKsPropMembHead, _ui32DataSize);;
             break;
        case ePeakMeterAttribute:
             ntStatus = GetPeakMeterSteppings(_pKsPropMembHead, _ui32DataSize);;
             break;
        default:
            ntStatus = STATUS_INVALID_DEVICE_REQUEST;
            break;
    }
Exit:
     return ntStatus;
}
開發者ID:0xhack,項目名稱:Windows-driver-samples,代碼行數:52,代碼來源:MiniportAudioEngineNode.cpp

示例6: STDMETHODIMP_

/*-----------------------------------------------------------------------------
IMiniportStreamAudioEngineNode::SetStreamChannelVolume 
 
Decscription:

    When handling SET volume KS property for the device, Portcls calls 
    this method, inside its property handlers, to set the current setting on the specific channel.

Parameters:

        _In_ Channel:  the target channel for this GET volume operation
        _In_ TargetVolume: volume value to set 
        _In_ CurveType: type of curve to apply to the ramp
        _In_ CurveDuration: amount of time in hns over which to ramp the volume

Return Value:

   Appropriate NTSTATUS code

Called at PASSIVE_LEVEL

Remarks

-------------------------------------------------------------------------------------------------------------------------*/
STDMETHODIMP_(NTSTATUS) CMiniportWaveRTStream::SetStreamChannelVolume
(
    _In_ UINT32             Channel,
    _In_ LONG	            TargetVolume,
    _In_ AUDIO_CURVE_TYPE   CurveType,
    _In_ ULONGLONG          CurveDuration
)
{
    UNREFERENCED_PARAMETER(CurveType);
    UNREFERENCED_PARAMETER(CurveDuration);
    NTSTATUS ntStatus = STATUS_INVALID_DEVICE_REQUEST;

    PAGED_CODE ();

    DPF_ENTER(("[CMiniportWaveRTStream::SetStreamChannelVolume]"));

    // Snap the volume level to our range of steppings.
    LONG lVolume = VOLUME_NORMALIZE_IN_RANGE(TargetVolume); 

    // If Channel is ALL_CHANNELS_ID, then set the level on all channels
    if ( ALL_CHANNELS_ID == Channel )
    {
        for (UINT32 i = 0; i < m_pWfExt->Format.nChannels; i++)
        {
            ntStatus = SetChannelVolume(i, lVolume);
        }
    }
    else
    {
        ntStatus = SetChannelVolume(Channel, lVolume);
    }

    return ntStatus;
}
開發者ID:0xhack,項目名稱:Windows-driver-samples,代碼行數:58,代碼來源:MiniportStreamAudioEngineNode.cpp

示例7: DPF_ENTER

CMiniportWaveCyclicStreamMSVAD::TransferCount
(
    void
)
/*++

Routine Description:

  The TransferCount function returns the size in bytes of the buffer currently
  being transferred by a DMA object. Callers of TransferCount can run
  at any IRQL.

Arguments:

Return Value:

  ULONG - The return value is the size in bytes of the buffer currently
          being transferred.

--*/
{
	DPF_ENTER(("[CMiniportWaveCyclicStreamMSVAD::TransferCount]"));

    return m_ulDmaBufferSize;
}
開發者ID:wifigeek,項目名稱:ohNet,代碼行數:25,代碼來源:basedma.cpp

示例8: PAGED_CODE

CMiniportTopologyMSVAD::~CMiniportTopologyMSVAD
(
    void
)
/*++

Routine Description:

  Topology miniport destructor

Arguments:

Return Value:

  void

--*/
{
    PAGED_CODE();

    DPF_ENTER(("[%s]",__FUNCTION__));

    if (m_AdapterCommon)
    {
        m_AdapterCommon->Release();
    }
} // ~CMiniportTopologyMSVAD
開發者ID:kcrazy,項目名稱:winekit,代碼行數:27,代碼來源:basetopo.cpp

示例9: target

/*-----------------------------------------------------------------------------
IMiniportStreamAudioEngineNode::GetStreamChannelCount 
 
Decscription:

    When handling volume, mute, and meter related KS properties, Portcls calls 
    this method, inside its property handlers, to know the number of channels for the 
    corresponding KS property.

Parameters:

        _In_ _targetType:  the query target (volume, mute, or peak meter)
		_Out_ _pulChannelCount: a pointer to a UINT32 variable for receiving returned channel count information

Return Value:

   Appropriate NTSTATUS code

Called at PASSIVE_LEVEL

Remarks

-------------------------------------------------------------------------------------------------------------------------*/
NTSTATUS CMiniportWaveRTStream::GetStreamChannelCount(_In_  eChannelTargetType	_targetType,_Out_  UINT32 *_pulChannelCount)
{
    NTSTATUS ntStatus = STATUS_INVALID_DEVICE_REQUEST;

    PAGED_CODE ();

    DPF_ENTER(("[CMiniportWaveRTStream::GetStreamChannelCount]"));

    switch (_targetType)
    {
        case eVolumeAttribute:
             ntStatus = GetVolumeChannelCount(_pulChannelCount);
             break;
        case eMuteAttribute:
             ntStatus = GetMuteChannelCount(_pulChannelCount);
             break;
        case ePeakMeterAttribute:
             ntStatus = GetPeakMeterChannelCount(_pulChannelCount);
             break;
        default:
            ntStatus = STATUS_INVALID_DEVICE_REQUEST;
            break;
    }

    return ntStatus;
}
開發者ID:0xhack,項目名稱:Windows-driver-samples,代碼行數:49,代碼來源:MiniportStreamAudioEngineNode.cpp

示例10: DPF_ENTER

NTSTATUS 
CMiniportWaveRTStream::GetScoStreamNtStatus()
/*++

Routine Description:

  Checks if the Bluetooth SCO HFP connection is up, if not, an error is returned.

Return Value:

  NT status code.

--*/
{
    DPF_ENTER(("[CMiniportWaveRTStream::GetScoStreamNtStatus]"));

    NTSTATUS  ntStatus  = STATUS_INVALID_DEVICE_STATE;
        
    if (m_ScoOpen)
    {
        PBTHHFPDEVICECOMMON bthHfpDevice;
        
        ASSERT(m_pMiniport->IsBthHfpDevice());
        bthHfpDevice = m_pMiniport->GetBthHfpDevice(); // weak ref.
        ASSERT(bthHfpDevice != NULL);

        if (bthHfpDevice->GetStreamStatus())
        {
            ntStatus = STATUS_SUCCESS;
        }
    }

    return ntStatus;        
}
開發者ID:Realhram,項目名稱:wdk81,代碼行數:34,代碼來源:minwavertstream.cpp

示例11: STDMETHODIMP_

//=============================================================================
STDMETHODIMP_(ULONG) CMiniportWaveCyclicStream::SetNotificationFreq(
    IN  ULONG                   Interval,
    OUT PULONG                  FramingSize
)
/*++
Routine Description:
  The SetNotificationFrequency function sets the frequency at which
  notification interrupts are generated. Callers of SetNotificationFrequency
  should run at IRQL PASSIVE_LEVEL.

Arguments:
  Interval - Value indicating the interval between interrupts,
             expressed in milliseconds
  FramingSize - Pointer to a ULONG value where the number of bytes equivalent
                to Interval milliseconds is returned

Return Value:
  NT status code.
--*/
{
    PAGED_CODE();

    ASSERT(FramingSize);

    DPF_ENTER(("[CMiniportWaveCyclicStream::SetNotificationFreq]"));

    m_pMiniport->m_NotificationInterval = Interval;

    *FramingSize = m_usBlockAlign * m_pMiniport->m_SamplingFrequency * Interval / 1000;

    return m_pMiniport->m_NotificationInterval;
} // SetNotificationFreq
開發者ID:duncanthrax,項目名稱:scream,代碼行數:33,代碼來源:minstream.cpp

示例12: PropertyHandler_TopoFilter

//=============================================================================
NTSTATUS PropertyHandler_TopoFilter(IN PPCPROPERTY_REQUEST PropertyRequest)
/*++
Routine Description:
  Redirects property request to miniport object

Arguments:
  PropertyRequest - 

Return Value:
  NT status code.
--*/
{
    PAGED_CODE();

    ASSERT(PropertyRequest);

    DPF_ENTER(("[PropertyHandler_TopoFilter]"));

    // PropertryRequest structure is filled by portcls. 
    // MajorTarget is a pointer to miniport object for miniports.
    //
    NTSTATUS            ntStatus = STATUS_INVALID_DEVICE_REQUEST;
    PCMiniportTopology  pMiniport = (PCMiniportTopology)PropertyRequest->MajorTarget;

    if (IsEqualGUIDAligned(*PropertyRequest->PropertyItem->Set, KSPROPSETID_Jack) && (PropertyRequest->PropertyItem->Id == KSPROPERTY_JACK_DESCRIPTION)) {
        ntStatus = pMiniport->PropertyHandlerJackDescription(PropertyRequest);
    }

    return ntStatus;
} // PropertyHandler_TopoFilter
開發者ID:duncanthrax,項目名稱:scream,代碼行數:31,代碼來源:mintopo.cpp

示例13: PAGED_CODE

CMiniportWaveCyclicStreamMSVAD::FreeBuffer
(
    void
)
/*++

Routine Description:

  The FreeBuffer function frees the buffer allocated by AllocateBuffer. Because
  the buffer is automatically freed when the DMA object is deleted, this
  function is not normally used. Callers of FreeBuffer should run at
  IRQL PASSIVE_LEVEL.

Arguments:

Return Value:

  void

--*/
{
	PAGED_CODE();

	DPF_ENTER(("[CMiniportWaveCyclicStreamMSVAD::FreeBuffer]"));

    if ( m_pvDmaBuffer )
    {
        ExFreePoolWithTag( m_pvDmaBuffer, SNEAKY_POOLTAG );
        m_ulDmaBufferSize = 0;
    }
} // FreeBuffer
開發者ID:wifigeek,項目名稱:ohNet,代碼行數:31,代碼來源:basedma.cpp

示例14: PAGED_CODE

//=============================================================================
STDMETHODIMP CMiniportTopology::GetDescription(OUT PPCFILTER_DESCRIPTOR * OutFilterDescriptor)
/*++
Routine Description:
  The GetDescription function gets a pointer to a filter description. 
  It provides a location to deposit a pointer in miniport's description 
  structure. This is the placeholder for the FromNode or ToNode fields in 
  connections which describe connections to the filter's pins. 

Arguments:
  OutFilterDescriptor - Pointer to the filter description. 

Return Value:
  NT status code.
--*/
{
    PAGED_CODE();

    ASSERT(OutFilterDescriptor);

    DPF_ENTER(("[%s]",__FUNCTION__));

    *OutFilterDescriptor = m_FilterDescriptor;

    return (STATUS_SUCCESS);
} // GetDescription
開發者ID:duncanthrax,項目名稱:scream,代碼行數:26,代碼來源:mintopo.cpp

示例15: PAGED_CODE

//=============================================================================
NTSTATUS
PropertyHandler_Topology
( 
    IN PPCPROPERTY_REQUEST      PropertyRequest 
)
/*++

Routine Description:

  Redirects property request to miniport object

Arguments:

  PropertyRequest - 

Return Value:

  NT status code.

--*/
{
    PAGED_CODE();

    ASSERT(PropertyRequest);

    DPF_ENTER(("[PropertyHandler_Topology]"));

    return ((PCMiniportTopology)
        (PropertyRequest->MajorTarget))->PropertyHandlerGeneric
        (
            PropertyRequest
        );
} // PropertyHandler_Topology
開發者ID:kcrazy,項目名稱:winekit,代碼行數:34,代碼來源:mintopo.cpp


注:本文中的DPF_ENTER函數示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。