Author: tkreuzer
Date: Tue Dec 21 23:48:15 2010
New Revision: 50089
URL:
http://svn.reactos.org/svn/reactos?rev=50089&view=rev
Log:
[SCSIPORT]
ScsiPortConvertPhysicalAddressToUlong takes an ULONG_PTR as input, fix function
accordingly and do the "calculation" directly instead of calling
RtlConvertUlongToLargeInteger
Spotted by Samuel.
Modified:
trunk/reactos/boot/freeldr/freeldr/disk/scsiport.c
trunk/reactos/drivers/storage/ide/uniata/srb.h
trunk/reactos/drivers/storage/scsiport/stubs.c
trunk/reactos/include/ddk/srb.h
Modified: trunk/reactos/boot/freeldr/freeldr/disk/scsiport.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/boot/freeldr/freeldr/disk/…
==============================================================================
--- trunk/reactos/boot/freeldr/freeldr/disk/scsiport.c [iso-8859-1] (original)
+++ trunk/reactos/boot/freeldr/freeldr/disk/scsiport.c [iso-8859-1] Tue Dec 21 23:48:15
2010
@@ -445,9 +445,12 @@
SCSI_PHYSICAL_ADDRESS
NTAPI
ScsiPortConvertUlongToPhysicalAddress(
- IN ULONG UlongAddress)
-{
- return RtlConvertUlongToLargeInteger(UlongAddress);
+ IN ULONG_PTR UlongAddress)
+{
+ SCSI_PHYSICAL_ADDRESS Address;
+
+ Address.QuadPart = UlongAddress;
+ return Address;
}
VOID
@@ -1540,7 +1543,7 @@
{
CHAR* Name;
PVOID Function;
- } ExportTable[] =
+ } ExportTable[] =
{
{ "ScsiDebugPrint", ScsiDebugPrint },
{ "ScsiPortCompleteRequest", ScsiPortCompleteRequest },
@@ -1618,7 +1621,7 @@
ImageDosHeader.e_lfanew = SWAPD((ULONG_PTR)&ImageNtHeaders -
(ULONG_PTR)&ImageDosHeader);
ImageNtHeaders.Signature = IMAGE_NT_SIGNATURE;
ImageNtHeaders.OptionalHeader.NumberOfRvaAndSizes =
SWAPD(IMAGE_DIRECTORY_ENTRY_EXPORT + 1);
-
ImageNtHeaders.OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_EXPORT].VirtualAddress =
+
ImageNtHeaders.OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_EXPORT].VirtualAddress
=
SWAPW((ULONG_PTR)&ImageExportDirectory - (ULONG_PTR)&ImageDosHeader);
ImageNtHeaders.OptionalHeader.DataDirectory[IMAGE_DIRECTORY_ENTRY_EXPORT].Size = 1;
ImageExportDirectory.NumberOfNames = sizeof(ExportTable) / sizeof(ExportTable[0]);
Modified: trunk/reactos/drivers/storage/ide/uniata/srb.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/ide/uniata…
==============================================================================
--- trunk/reactos/drivers/storage/ide/uniata/srb.h [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/ide/uniata/srb.h [iso-8859-1] Tue Dec 21 23:48:15 2010
@@ -935,7 +935,7 @@
SCSIPORT_API
SCSI_PHYSICAL_ADDRESS NTAPI
ScsiPortConvertUlongToPhysicalAddress(
- ULONG UlongAddress
+ ULONG_PTR UlongAddress
);
SCSIPORT_API
Modified: trunk/reactos/drivers/storage/scsiport/stubs.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/scsiport/s…
==============================================================================
--- trunk/reactos/drivers/storage/scsiport/stubs.c [iso-8859-1] (original)
+++ trunk/reactos/drivers/storage/scsiport/stubs.c [iso-8859-1] Tue Dec 21 23:48:15 2010
@@ -42,9 +42,12 @@
SCSI_PHYSICAL_ADDRESS
NTAPI
ScsiPortConvertUlongToPhysicalAddress(
- IN ULONG UlongAddress)
-{
- return RtlConvertUlongToLargeInteger(UlongAddress);
+ IN ULONG_PTR UlongAddress)
+{
+ SCSI_PHYSICAL_ADDRESS Address;
+
+ Address.QuadPart = UlongAddress;
+ return Address;
}
VOID
Modified: trunk/reactos/include/ddk/srb.h
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/srb.h?rev=5008…
==============================================================================
--- trunk/reactos/include/ddk/srb.h [iso-8859-1] (original)
+++ trunk/reactos/include/ddk/srb.h [iso-8859-1] Tue Dec 21 23:48:15 2010
@@ -550,7 +550,7 @@
SCSI_PHYSICAL_ADDRESS
NTAPI
ScsiPortConvertUlongToPhysicalAddress(
- IN ULONG UlongAddress);
+ IN ULONG_PTR UlongAddress);
SCSIPORTAPI
VOID