Home | Info | Community | Development | myReactOS | Contact Us
[private]
Definition at line 295 of file minwave.cpp.
Referenced by ~CMiniportWaveCMI().
{ //PAGED_CODE(); PREGISTRYKEY DriverKey; PREGISTRYKEY SettingsKey; UNICODE_STRING KeyName; DWORD Value; DBGPRINT(("CMiniportWaveCMI::storeChannelConfigToRegistry()")); if ((!CMIAdapter) || (!(CMIAdapter->getDeviceObject()))) { return STATUS_UNSUCCESSFUL; } NTSTATUS ntStatus = PcNewRegistryKey(&DriverKey, NULL, DriverRegistryKey, KEY_ALL_ACCESS, CMIAdapter->getDeviceObject(), NULL, NULL, 0, NULL); if(!NT_SUCCESS(ntStatus)) { DBGPRINT(("PcNewRegistryKey() failed")); return STATUS_UNSUCCESSFUL; } RtlInitUnicodeString(&KeyName, L"Settings"); ntStatus = DriverKey->NewSubKey(&SettingsKey, NULL, KEY_ALL_ACCESS, &KeyName, REG_OPTION_NON_VOLATILE, NULL); if(!NT_SUCCESS(ntStatus)) { DBGPRINT(("DriverKey->NewSubKey() failed")); return STATUS_UNSUCCESSFUL; } Value = requestedChannelCount; RtlInitUnicodeString(&KeyName, L"ChannelCount"); ntStatus = SettingsKey->SetValueKey(&KeyName, REG_DWORD, PVOID(&Value), sizeof(DWORD)); if (!NT_SUCCESS(ntStatus)) { DBGPRINT(("SetValueKey() failed")); } Value = requestedChannelMask; RtlInitUnicodeString(&KeyName, L"ChannelMask"); ntStatus = SettingsKey->SetValueKey(&KeyName, REG_DWORD, PVOID(&Value), sizeof(DWORD)); if (!NT_SUCCESS(ntStatus)) { DBGPRINT(("SetValueKey() failed")); } SettingsKey->Release(); DriverKey->Release(); return STATUS_SUCCESS; }