diff options
Diffstat (limited to 'storage/class/classpnp/src')
| -rw-r--r-- | storage/class/classpnp/src/class.c | 6 | ||||
| -rw-r--r-- | storage/class/classpnp/src/classpnp.vcxproj | 46 | ||||
| -rw-r--r-- | storage/class/classpnp/src/obsolete.c | 6 |
3 files changed, 29 insertions, 29 deletions
diff --git a/storage/class/classpnp/src/class.c b/storage/class/classpnp/src/class.c index 58d1835a..6da2b146 100644 --- a/storage/class/classpnp/src/class.c +++ b/storage/class/classpnp/src/class.c @@ -3740,7 +3740,7 @@ ClassIoComplete( PSCSI_REQUEST_BLOCK srb = Context; PFUNCTIONAL_DEVICE_EXTENSION fdoExtension = Fdo->DeviceExtension; PCLASS_PRIVATE_FDO_DATA fdoData = fdoExtension->PrivateFdoData; - NTSTATUS status; + NTSTATUS status = STATUS_SUCCESS; BOOLEAN retry; BOOLEAN callStartNextPacket; ULONG srbFlags; @@ -6055,7 +6055,7 @@ __ClassInterpretSenseInfo_ProcessingInvalidSenseBuffer: logErrorInternal = FALSE; logError = FALSE; } else if (cdbOpcode == SCSIOP_MODE_SENSE10) { - USHORT allocationLength; + USHORT allocationLength = 0; REVERSE_BYTES_SHORT(&(cdb->MODE_SENSE10.AllocationLength), &allocationLength); if (SrbGetDataTransferLength(Srb) <= allocationLength) { *Status = STATUS_SUCCESS; @@ -6063,7 +6063,7 @@ __ClassInterpretSenseInfo_ProcessingInvalidSenseBuffer: logError = FALSE; } } else if (ClasspIsReceiveTokenInformation(cdb)) { - ULONG allocationLength; + ULONG allocationLength = 0; REVERSE_BYTES(&(cdb->RECEIVE_TOKEN_INFORMATION.AllocationLength), &allocationLength); if (SrbGetDataTransferLength(Srb) <= allocationLength) { *Status = STATUS_SUCCESS; diff --git a/storage/class/classpnp/src/classpnp.vcxproj b/storage/class/classpnp/src/classpnp.vcxproj index 4b092509..2fc75493 100644 --- a/storage/class/classpnp/src/classpnp.vcxproj +++ b/storage/class/classpnp/src/classpnp.vcxproj @@ -1,13 +1,13 @@ <?xml version="1.0" encoding="utf-8"?> <Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <ItemGroup Label="ProjectConfigurations"> - <ProjectConfiguration Include="Debug|Win32"> + <ProjectConfiguration Include="Debug|ARM64"> <Configuration>Debug</Configuration> - <Platform>Win32</Platform> + <Platform>ARM64</Platform> </ProjectConfiguration> - <ProjectConfiguration Include="Release|Win32"> + <ProjectConfiguration Include="Release|ARM64"> <Configuration>Release</Configuration> - <Platform>Win32</Platform> + <Platform>ARM64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Debug|x64"> <Configuration>Debug</Configuration> @@ -23,7 +23,7 @@ <RootNamespace>$(MSBuildProjectName)</RootNamespace> <SupportsPackaging>false</SupportsPackaging> <Configuration Condition="'$(Configuration)' == ''">Debug</Configuration> - <Platform Condition="'$(Platform)' == ''">Win32</Platform> + <Platform Condition="'$(Platform)' == ''">x64</Platform> <SampleGuid>{58F97C0C-9D73-4882-B4FA-BBEAE3EA4E10}</SampleGuid> </PropertyGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> @@ -35,23 +35,23 @@ <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset> <ConfigurationType>Driver</ConfigurationType> </PropertyGroup> - <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> + <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'"> <TargetVersion>Windows10</TargetVersion> - <UseDebugLibraries>True</UseDebugLibraries> + <UseDebugLibraries>False</UseDebugLibraries> <DriverTargetPlatform>Windows Driver</DriverTargetPlatform> <DriverType>ExportDriver</DriverType> <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset> <ConfigurationType>Driver</ConfigurationType> </PropertyGroup> - <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <TargetVersion>Windows10</TargetVersion> - <UseDebugLibraries>False</UseDebugLibraries> + <UseDebugLibraries>True</UseDebugLibraries> <DriverTargetPlatform>Windows Driver</DriverTargetPlatform> <DriverType>ExportDriver</DriverType> <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset> <ConfigurationType>Driver</ConfigurationType> </PropertyGroup> - <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'"> <TargetVersion>Windows10</TargetVersion> <UseDebugLibraries>True</UseDebugLibraries> <DriverTargetPlatform>Windows Driver</DriverTargetPlatform> @@ -66,13 +66,13 @@ <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" /> </ImportGroup> - <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> + <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" /> </ImportGroup> - <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" /> </ImportGroup> - <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" /> </ImportGroup> <ItemGroup Label="WrappedTaskItems"> @@ -95,13 +95,13 @@ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> <TargetName>classpnp</TargetName> </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'"> <TargetName>classpnp</TargetName> </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <TargetName>classpnp</TargetName> </PropertyGroup> - <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'"> <TargetName>classpnp</TargetName> </PropertyGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> @@ -135,7 +135,7 @@ <PreprocessorDefinitions>%(PreprocessorDefinitions);CLASS_GLOBAL_BUFFERED_DEBUG_PRINT_BUFFERS=512</PreprocessorDefinitions> </Midl> </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'"> <ClCompile> <TreatWarningAsError>true</TreatWarningAsError> <WarningLevel>Level4</WarningLevel> @@ -166,7 +166,7 @@ <PreprocessorDefinitions>%(PreprocessorDefinitions);CLASS_GLOBAL_BUFFERED_DEBUG_PRINT_BUFFERS=512</PreprocessorDefinitions> </Midl> </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <ClCompile> <TreatWarningAsError>true</TreatWarningAsError> <WarningLevel>Level4</WarningLevel> @@ -197,7 +197,7 @@ <PreprocessorDefinitions>%(PreprocessorDefinitions);CLASS_GLOBAL_BUFFERED_DEBUG_PRINT_BUFFERS=512</PreprocessorDefinitions> </Midl> </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'"> <ClCompile> <TreatWarningAsError>true</TreatWarningAsError> <WarningLevel>Level4</WarningLevel> @@ -247,7 +247,7 @@ <FileDigestAlgorithm>sha256</FileDigestAlgorithm> </DriverSign> </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'"> <ClCompile> <PreprocessorDefinitions Condition="!('$(UseDebugLibraries)'=='false')">%(PreprocessorDefinitions);DEBUG_USE_KDPRINT</PreprocessorDefinitions> <ExceptionHandling> @@ -266,7 +266,7 @@ <FileDigestAlgorithm>sha256</FileDigestAlgorithm> </DriverSign> </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <ClCompile> <PreprocessorDefinitions Condition="!('$(UseDebugLibraries)'=='false')">%(PreprocessorDefinitions);DEBUG_USE_KDPRINT</PreprocessorDefinitions> <ExceptionHandling> @@ -285,7 +285,7 @@ <FileDigestAlgorithm>sha256</FileDigestAlgorithm> </DriverSign> </ItemDefinitionGroup> - <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> + <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'"> <ClCompile> <PreprocessorDefinitions Condition="!('$(UseDebugLibraries)'=='false')">%(PreprocessorDefinitions);DEBUG_USE_KDPRINT</PreprocessorDefinitions> <ExceptionHandling> @@ -314,7 +314,7 @@ </ItemGroup> <Exec Command="if not exist "%(CustomBuildTarget0Input.Identity)" copy ".\%(CustomBuildTarget0Input.Filename)%(CustomBuildTarget0Input.Extension)" "%(CustomBuildTarget0Input.Identity)"" WorkingDirectory="$(MSBuildProjectDirectory)" /> <Exec Command="mofcomp -Amendment:ms_409 -MFL:$(IntDir)\MFL.MFL -MOF:$(IntDir)\MOF.MOF "%(CustomBuildTarget0Input.Identity)"" WorkingDirectory="$(MSBuildProjectDirectory)" /> - <Exec Command="wmimofck -y$(IntDir)\MOF.MOF -z$(IntDir)\MFL.MFL $(IntDir)\MOFMFL.MOF" WorkingDirectory="$(MSBuildProjectDirectory)" /> + <Exec Command=""$(WmimofckToolPath)\wmimofck.exe" -y$(IntDir)\MOF.MOF -z$(IntDir)\MFL.MFL $(IntDir)\MOFMFL.MOF" WorkingDirectory="$(MSBuildProjectDirectory)" /> <Exec Command="mofcomp -B:".\$(IntDir)\classlog.bmf" $(IntDir)\MOFMFL.MOF" WorkingDirectory="$(MSBuildProjectDirectory)" /> </Target> <ItemGroup> diff --git a/storage/class/classpnp/src/obsolete.c b/storage/class/classpnp/src/obsolete.c index aeeef81d..e0fe3d13 100644 --- a/storage/class/classpnp/src/obsolete.c +++ b/storage/class/classpnp/src/obsolete.c @@ -119,7 +119,7 @@ ClassIoCompleteAssociated( PIRP originalIrp = Irp->AssociatedIrp.MasterIrp; LONG irpCount; - NTSTATUS status; + NTSTATUS status = STATUS_SUCCESS; BOOLEAN retry; TracePrint((TRACE_LEVEL_WARNING, TRACE_FLAG_GENERAL, "ClassIoCompleteAssociated is OBSOLETE !")); @@ -390,8 +390,8 @@ RetryRequest( // NT_ASSERT(SrbGetDataBuffer(srbHeader) == MmGetMdlVirtualAddress(Irp->MdlAddress)); - _Analysis_assume_(Irp->MdlAddress->ByteCount <= dataTransferLength); - transferByteCount = Irp->MdlAddress->ByteCount; + _Analysis_assume_(MmGetMdlByteCount(Irp->MdlAddress) <= dataTransferLength); + transferByteCount = MmGetMdlByteCount(Irp->MdlAddress); } else { |
