289{
291
293
294 DPRINT(
"ArbInitializeArbiterInstance: '%S'\n", ArbiterName);
295
303
305 Arbiter->BusDeviceObject = BusDeviceObject;
306
308 if (!Arbiter->MutexEvent)
309 {
310 DPRINT1(
"ArbInitializeArbiterInstance: STATUS_INSUFFICIENT_RESOURCES\n");
312 }
313
315
317 if (!Arbiter->AllocationStack)
318 {
319 DPRINT1(
"ArbInitializeArbiterInstance: STATUS_INSUFFICIENT_RESOURCES\n");
322 }
323
324 Arbiter->AllocationStackMaxSize =
PAGE_SIZE;
325
327 if (!Arbiter->Allocation)
328 {
329 DPRINT1(
"ArbInitializeArbiterInstance: STATUS_INSUFFICIENT_RESOURCES\n");
333 }
334
336 if (!Arbiter->PossibleAllocation)
337 {
338 DPRINT1(
"ArbInitializeArbiterInstance: STATUS_INSUFFICIENT_RESOURCES\n");
343 }
344
347
348 Arbiter->Name = ArbiterName;
349 Arbiter->ResourceType = ResourceType;
350 Arbiter->TransactionInProgress =
FALSE;
351
352 if (!Arbiter->TestAllocation)
354
355 if (!Arbiter->RetestAllocation)
357
358 if (!Arbiter->CommitAllocation)
360
361 if (!Arbiter->RollbackAllocation)
363
364 if (!Arbiter->AddReserved)
366
367 if (!Arbiter->PreprocessEntry)
369
370 if (!Arbiter->AllocateEntry)
372
373 if (!Arbiter->GetNextAllocationRange)
375
376 if (!Arbiter->FindSuitableRange)
378
379 if (!Arbiter->AddAllocation)
381
382 if (!Arbiter->BacktrackAllocation)
384
385 if (!Arbiter->OverrideConflict)
387
388 if (!Arbiter->BootAllocation)
390
391 if (!Arbiter->QueryConflict)
393
394 if (!Arbiter->StartArbiter)
396
399 {
401 }
402
403 DPRINT1(
"ArbInitializeArbiterInstance: Status %X\n",
Status);
404
406}
NTSTATUS NTAPI ArbOverrideConflict(_In_ PARBITER_INSTANCE Arbiter)
BOOLEAN NTAPI ArbGetNextAllocationRange(_In_ PARBITER_INSTANCE Arbiter, _Inout_ PARBITER_ALLOCATION_STATE ArbState)
VOID NTAPI ArbAddAllocation(_In_ PARBITER_INSTANCE Arbiter, _Inout_ PARBITER_ALLOCATION_STATE ArbState)
NTSTATUS NTAPI ArbRetestAllocation(_In_ PARBITER_INSTANCE Arbiter, _In_ PLIST_ENTRY ArbitrationList)
NTSTATUS NTAPI ArbAddReserved(_In_ PARBITER_INSTANCE Arbiter)
NTSTATUS NTAPI ArbStartArbiter(_In_ PARBITER_INSTANCE Arbiter)
BOOLEAN NTAPI ArbFindSuitableRange(_In_ PARBITER_INSTANCE Arbiter, _Inout_ PARBITER_ALLOCATION_STATE ArbState)
NTSTATUS NTAPI ArbCommitAllocation(_In_ PARBITER_INSTANCE Arbiter)
NTSTATUS NTAPI ArbPreprocessEntry(_In_ PARBITER_INSTANCE Arbiter, _Inout_ PARBITER_ALLOCATION_STATE ArbState)
VOID NTAPI ArbBacktrackAllocation(_In_ PARBITER_INSTANCE Arbiter, _Inout_ PARBITER_ALLOCATION_STATE ArbState)
NTSTATUS NTAPI ArbQueryConflict(_In_ PARBITER_INSTANCE Arbiter)
NTSTATUS NTAPI ArbAllocateEntry(_In_ PARBITER_INSTANCE Arbiter, _Inout_ PARBITER_ALLOCATION_STATE ArbState)
NTSTATUS NTAPI ArbBuildAssignmentOrdering(_Inout_ PARBITER_INSTANCE ArbInstance, _In_ PCWSTR OrderName, _In_ PCWSTR ReservedOrderName, _In_ PARB_TRANSLATE_ORDERING TranslateOrderingFunction)
NTSTATUS NTAPI ArbBootAllocation(_In_ PARBITER_INSTANCE Arbiter, _In_ PLIST_ENTRY ArbitrationList)
NTSTATUS NTAPI ArbTestAllocation(_In_ PARBITER_INSTANCE Arbiter, _In_ PLIST_ENTRY ArbitrationList)
NTSTATUS NTAPI ArbRollbackAllocation(_In_ PARBITER_INSTANCE Arbiter)
#define TAG_ARB_ALLOCATION
#define ARBITER_SIGNATURE
#define NT_SUCCESS(StatCode)
#define ExAllocatePoolWithTag(hernya, size, tag)
#define KeInitializeEvent(pEvt, foo, foo2)
#define ExFreePoolWithTag(_P, _T)
NTSYSAPI VOID NTAPI RtlInitializeRangeList(_Out_ PRTL_RANGE_LIST RangeList)
#define STATUS_INSUFFICIENT_RESOURCES