Notatka
Dostęp do tej strony wymaga autoryzacji. Może spróbować zalogować się lub zmienić katalogi.
Dostęp do tej strony wymaga autoryzacji. Możesz spróbować zmienić katalogi.
The PcwUnregister function closes the specified counterset registration. Most developers will use a CTRPP-generated UnregisterXxx function instead of calling this function directly.
Syntax
VOID PcwUnregister(
PPCW_REGISTRATION Registration
);
Parameters
Registration
[in A pointer to the registration being closed.
Return value
None
Remarks
The PcwUnregister function closes the specified counterset registration. Instances owned by the counterset registration are automatically closed. These instances should not be accessed by the provider while the counterset is being unregistered or after the counterset is unregistered.
Before the provider uses this function, the provider must call the PcwRegister function to create a registration.
CTRPP-generated UnregisterXxx function
Most developers do not need to call PcwUnregister directly. Instead, they will compile a manifest with the CTRPP tool and use the UnregisterXxx function from the CTRPP-generated header. The generated function will look like this:
EXTERN_C FORCEINLINE VOID
UnregisterMyCounterset(
VOID
)
{
PAGED_CODE();
PcwUnregister(MyCounterset);
}
The CTRPP-generated Unregister function will be named PrefixUnregisterCounterSet. Prefix is usually blank, but may be present if the -prefix parameter was used on the CTRPP command-line. CounterSet is the name of the counterset, as specified in the manifest. Note that the function references a Counterset variable (MyCounterset in the example), which is a global variable that holds the counterset registration handle initialized by the CTRPP-generated RegisterXxx function.
Requirements
| Requirement | Value |
|---|---|
| Minimum supported client | Available in Windows 7 and later versions of Windows. |
| Target Platform | Universal |
| Header | wdm.h (include Wdm.h, Ntddk.h) |
| Library | NtosKrnl.lib |
| DLL | NtosKrnl.exe |
| IRQL | IRQL <= APC_LEVEL |