- Remove some unused and deprecated macros from the network stack that did this.
- fastfat_new: Use FAT_FILE_SYSTEM instead of magic 0x23.
svn path=/trunk/; revision=43673
29 files changed:
{
/* FIXME: what to do if no more memory? */
DPRINT1("Unable to initialize FCB for filename '%wZ'\n", NameU);
{
/* FIXME: what to do if no more memory? */
DPRINT1("Unable to initialize FCB for filename '%wZ'\n", NameU);
- KeBugCheckEx(0, (ULONG_PTR)Fcb, (ULONG_PTR)NameU, 0, 0);
+ KeBugCheckEx(FAT_FILE_SYSTEM, (ULONG_PTR)Fcb, (ULONG_PTR)NameU, 0, 0);
}
Fcb->PathNameU.Length = 0;
}
Fcb->PathNameU.Length = 0;
#include <ntdddisk.h>
#include <debug.h>
#include <ntdddisk.h>
#include <debug.h>
else
{
/* Unexpected FCB type */
else
{
/* Unexpected FCB type */
- KeBugCheckEx(/*FAT_FILE_SYSTEM*/0x23, __LINE__, (ULONG_PTR)Fcb, 0, 0);
+ KeBugCheckEx(FAT_FILE_SYSTEM, __LINE__, (ULONG_PTR)Fcb, 0, 0);
#include <ntdddisk.h>
#include <debug.h>
#include <pseh/pseh2.h>
#include <ntdddisk.h>
#include <debug.h>
#include <pseh/pseh2.h>
else
{
/* We can't get here */
else
{
/* We can't get here */
- KeBugCheckEx(0x23, CreateDisposition, 0, 0, 0);
+ KeBugCheckEx(FAT_FILE_SYSTEM, CreateDisposition, 0, 0, 0);
#ifdef NASSERT
#define ASSERT(x)
#else /* NASSERT */
#ifdef NASSERT
#define ASSERT(x)
#else /* NASSERT */
-#define ASSERT(x) if (!(x)) { AFD_DbgPrint(MIN_TRACE, ("Assertion "#x" failed at %s:%d\n", __FILE__, __LINE__)); KeBugCheck(0); }
+#define ASSERT(x) if (!(x)) { AFD_DbgPrint(MIN_TRACE, ("Assertion "#x" failed at %s:%d\n", __FILE__, __LINE__)); DbgBreakPoint(); }
#endif /* NASSERT */
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
#endif /* NASSERT */
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
-/* Assert is defined in ndis.h */
-#if 0
-#ifdef ASSERT
-#undef ASSERT
-#endif
-
-#ifdef NASSERT
-#define ASSERT(x)
-#else /* NASSERT */
-#define ASSERT(x) if (!(x)) { NDIS_DbgPrint(MIN_TRACE, ("Assertion "#x" failed at %s:%d\n", __FILE__, __LINE__)); KeBugCheck(0); }
-#endif /* NASSERT */
-#endif
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
#define ASSERT_IRQL_EQUAL(x) ASSERT(KeGetCurrentIrql() == (x))
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
#define ASSERT_IRQL_EQUAL(x) ASSERT(KeGetCurrentIrql() == (x))
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to set DwordTest: 0x%x\n", Status);
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to set DwordTest: 0x%x\n", Status);
}
DbgPrint("ne2000!MiniportInitialize: DwordTest successfully set\n");
}
DbgPrint("ne2000!MiniportInitialize: DwordTest successfully set\n");
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to set StringTest: 0x%x\n", Status);
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to set StringTest: 0x%x\n", Status);
}
DbgPrint("ne2000!MiniportInitialize: StringTest successfully set\n");
}
DbgPrint("ne2000!MiniportInitialize: StringTest successfully set\n");
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to read DwordTest: 0x%x\n", Status);
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to read DwordTest: 0x%x\n", Status);
}
if(ParameterValue->ParameterData.IntegerData != 0x12345678)
{
DbgPrint("ne2000!MiniportInitialize: DwordTest value is wrong: 0x%x\n",
ParameterValue->ParameterData.IntegerData);
}
if(ParameterValue->ParameterData.IntegerData != 0x12345678)
{
DbgPrint("ne2000!MiniportInitialize: DwordTest value is wrong: 0x%x\n",
ParameterValue->ParameterData.IntegerData);
}
DbgPrint("ne2000!MiniportInitialize: DwordTest value was correctly read\n");
}
DbgPrint("ne2000!MiniportInitialize: DwordTest value was correctly read\n");
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to read StringTest: 0x%x\n", Status);
if(Status != NDIS_STATUS_SUCCESS)
{
DbgPrint("ne2000!MiniportInitialize: failed to read StringTest: 0x%x\n", Status);
}
if(wcsncmp(ParameterValue->ParameterData.StringData.Buffer, L"Testing123",
}
if(wcsncmp(ParameterValue->ParameterData.StringData.Buffer, L"Testing123",
{
DbgPrint("ne2000!MiniportInitialize: StringTest value is wrong: %wZ\n",
&ParameterValue->ParameterData.StringData);
{
DbgPrint("ne2000!MiniportInitialize: StringTest value is wrong: %wZ\n",
&ParameterValue->ParameterData.StringData);
}
DbgPrint("ne2000!MiniportInitialize: StringTest value was correctly read\n");
}
DbgPrint("ne2000!MiniportInitialize: StringTest value was correctly read\n");
-#if 0
-#ifdef ASSERT
-#undef ASSERT
-#endif
-
-#ifdef NASSERT
-#define ASSERT(x)
-#else /* NASSERT */
-#define ASSERT(x) if (!(x)) { LA_DbgPrint(MIN_TRACE, ("Assertion "#x" failed at %s:%d\n", __FILE__, __LINE__)); KeBugCheck(0); }
-#endif /* NASSERT */
-#endif
-
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
#else /* DBG */
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
#else /* DBG */
if (!DeviceExt)
{
// should not happen
if (!DeviceExt)
{
// should not happen
return STATUS_UNSUCCESSFUL;
}
return STATUS_UNSUCCESSFUL;
}
else
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
else
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
+ DbgBreakPoint();
+ while(TRUE);
}
Status = NewIrpQueue(&m_IrpQueue);
}
Status = NewIrpQueue(&m_IrpQueue);
else
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
else
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
+ DbgBreakPoint();
+ while(TRUE);
else
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
else
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
+ DbgBreakPoint();
+ while(TRUE);
}
Status = m_Miniport->NewStream(&m_Stream,
}
Status = m_Miniport->NewStream(&m_Stream,
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
KeBugCheck(0);
{
DPRINT("Unexpected Communication %u DataFlow %u\n", KsPinDescriptor->Communication, KsPinDescriptor->DataFlow);
KeBugCheck(0);
}
Status = m_Miniport->NewStream(&m_Stream, m_PortStream, ConnectDetails->PinId, Capture, m_Format);
}
Status = m_Miniport->NewStream(&m_Stream, m_PortStream, ConnectDetails->PinId, Capture, m_Format);
if (!NT_SUCCESS(Status))
{
DPRINT("Failed to obtain ISubdevice interface from port driver\n");
if (!NT_SUCCESS(Status))
{
DPRINT("Failed to obtain ISubdevice interface from port driver\n");
+ DbgBreakPoint();
+ while(TRUE);
}
// get current stack location
}
// get current stack location
{
// put error handling here
{
// put error handling here
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
else if (BusDataType == EisaConfiguration)
{
/* FIXME: TODO */
else if (BusDataType == EisaConfiguration)
{
/* FIXME: TODO */
}
else if ((BusDataType == PCIConfiguration) &&
(HalpPCIConfigInitialized) &&
}
else if ((BusDataType == PCIConfiguration) &&
(HalpPCIConfigInitialized) &&
{
DbgPrint ("(%s:%d) NewIrql %x CurrentIrql %x\n",
__FILE__, __LINE__, NewIrql, KeGetPcr()->Irql);
{
DbgPrint ("(%s:%d) NewIrql %x CurrentIrql %x\n",
__FILE__, __LINE__, NewIrql, KeGetPcr()->Irql);
+ KeBugCheck(IRQL_NOT_LESS_OR_EQUAL);
{
DbgPrint ("%s:%d CurrentIrql %x NewIrql %x\n",
__FILE__,__LINE__,KeGetPcr()->Irql,NewIrql);
{
DbgPrint ("%s:%d CurrentIrql %x NewIrql %x\n",
__FILE__,__LINE__,KeGetPcr()->Irql,NewIrql);
+ KeBugCheck (IRQL_NOT_GREATER_OR_EQUAL);
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
ULONG Handler;
PHARDWARE_PTE IdtPte;
ULONG Handler;
PHARDWARE_PTE IdtPte;
- /* On i586, the first 7 entries of IDT are write-protected, unprotect them. */
+ /* On i586, the first 7 entries of IDT are write-protected, unprotect them. */ // Nasty hto hack
if (KeGetCurrentPrcb()->CpuType == 5)
{
IdtPte = GetPteAddress(((PKIPCR)KeGetPcr())->IDT);
if (KeGetCurrentPrcb()->CpuType == 5)
{
IdtPte = GetPteAddress(((PKIPCR)KeGetPcr())->IDT);
Pte = GetPteAddress((PVOID)i);
Pte->Valid = 0;
Pte->Write = 0;
Pte = GetPteAddress((PVOID)i);
Pte->Valid = 0;
Pte->Write = 0;
+ //Pte->Owner = 0; // Missing this?
Pte->PageFrameNumber = 0;
}
Pte->PageFrameNumber = 0;
}
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStopProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalStartProfileInterrupt(IN KPROFILE_SOURCE ProfileSource)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
NTAPI
HalSetProfileInterval(IN ULONG_PTR Interval)
{
DPRINT1("Bad MP configuration block signature: %c%c%c%c\n",
pc[0], pc[1], pc[2], pc[3]);
DPRINT1("Bad MP configuration block signature: %c%c%c%c\n",
pc[0], pc[1], pc[2], pc[3]);
- KeBugCheckEx(0, pc[0], pc[1], pc[2], pc[3]);
+ KeBugCheckEx(HAL_INITIALIZATION_FAILED, pc[0], pc[1], pc[2], pc[3]);
break;
default:
TI_DbgPrint(DEBUG_ARP,("Bad Address Type %x\n", Address->Type));
break;
default:
TI_DbgPrint(DEBUG_ARP,("Bad Address Type %x\n", Address->Type));
/* Should not happen */
return FALSE;
}
/* Should not happen */
return FALSE;
}
-#if 0
-#ifdef ASSERT
-#undef ASSERT
-#endif
-
-#ifdef NASSERT
-#define ASSERT(x)
-#else /* NASSERT */
-#define ASSERT(x) if (!(x)) { OS_DbgPrint(MIN_TRACE, ("Assertion "#x" failed at %s:%d\n", __FILE__, __LINE__)); KeBugCheck(0); }
-#endif /* NASSERT */
-#endif
-
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
#else /* DBG */
#define ASSERT_IRQL(x) ASSERT(KeGetCurrentIrql() <= (x))
#else /* DBG */
DbgPrint("EXCEPTION! Record %08x Frame %08x\n",
ExceptionRecord, ExceptionFrame);
MmuDumpMap();
DbgPrint("EXCEPTION! Record %08x Frame %08x\n",
ExceptionRecord, ExceptionFrame);
MmuDumpMap();
+ KeBugCheck(KMODE_EXCEPTION_NOT_HANDLED);
+ KeBugCheck(KMODE_EXCEPTION_NOT_HANDLED);
-#define ASSERT(x) if (!(x)) {DbgPrint("Assertion "#x" failed at %s:%d\n", __FILE__,__LINE__); KeBugCheck(0); }
+#define ASSERT(x) if (!(x)) {DbgPrint("Assertion "#x" failed at %s:%d\n", __FILE__,__LINE__); DbgBreakPoint(); }
// enable "magic"
//#define R_MAGIC
// enable "magic"
//#define R_MAGIC
#define R_ACQUIRE_MUTEX(pool) /*DPRINT1("Acquiring PPool Mutex\n");*/ ExAcquireFastMutex(&pool->Mutex)
#define R_RELEASE_MUTEX(pool) /*DPRINT1("Releasing PPool Mutex\n");*/ ExReleaseFastMutex(&pool->Mutex)
#define R_PRINT_ADDRESS(addr) KeRosPrintAddress(addr)
#define R_ACQUIRE_MUTEX(pool) /*DPRINT1("Acquiring PPool Mutex\n");*/ ExAcquireFastMutex(&pool->Mutex)
#define R_RELEASE_MUTEX(pool) /*DPRINT1("Releasing PPool Mutex\n");*/ ExReleaseFastMutex(&pool->Mutex)
#define R_PRINT_ADDRESS(addr) KeRosPrintAddress(addr)
-#define R_PANIC() KeBugCheck(0)
+#define R_PANIC() KeBugCheck(MEMORY_MANAGEMENT)
#define R_DEBUG DbgPrint
#ifdef _ARM_
#define R_DEBUG DbgPrint
#ifdef _ARM_