summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorya-solnyshko <[email protected]>2024-12-29 18:38:40 +0100
committerGitHub <[email protected]>2024-12-29 18:38:40 +0100
commit3dbe73da0848fce170ff4f59459bc597f0d0cd34 (patch)
tree878510e10356226b2b529cac769be4c3573f5ef9
parentd0b2ae23542a22bdddcb30c9d82d89c614027faa (diff)
parent57ecdd5d16347ef3bc1348a164ce90288c44c243 (diff)
Merge branch 'main' into fix-transaction-processing
-rw-r--r--.gitattributes5
-rw-r--r--.github/scripts/Build-ChangedSamples.ps12
-rw-r--r--.github/workflows/Code-Scanning.yml54
-rw-r--r--.github/workflows/ci-pr.yml18
-rw-r--r--.github/workflows/ci.yml21
-rw-r--r--Build-SampleSet.ps158
-rw-r--r--Building-Locally.md66
-rw-r--r--Directory.Build.props10
-rw-r--r--audio/Acx/Samples/AudioCodec/Driver/AudioCodec.infbin8526 -> 4123 bytes
-rw-r--r--audio/simpleaudiosample/Source/Filters/speakertoptable.h2
-rw-r--r--audio/simpleaudiosample/Source/Main/SimpleAudioSample.inxbin15004 -> 7299 bytes
-rw-r--r--audio/simpleaudiosample/Source/Main/common.cpp6
-rw-r--r--audio/simpleaudiosample/Source/Main/minwavert.h52
-rw-r--r--audio/simpleaudiosample/Source/Main/minwavertstream.h52
-rw-r--r--audio/sysvad/APO/AecApo/AecApo.vcxproj4
-rw-r--r--audio/sysvad/APO/DelayAPO/DelayAPO.vcxproj4
-rw-r--r--audio/sysvad/APO/KWSApo/KWSApo.vcxproj4
-rw-r--r--audio/sysvad/APO/SwapAPO/SwapAPO.vcxproj4
-rw-r--r--audio/sysvad/TabletAudioSample/ComponentizedApoSample.inxbin22624 -> 11119 bytes
-rw-r--r--audio/sysvad/TabletAudioSample/ComponentizedAudioSample.inxbin52952 -> 25853 bytes
-rw-r--r--audio/sysvad/TabletAudioSample/ComponentizedAudioSampleExtension.inxbin13660 -> 6686 bytes
-rw-r--r--avstream/avscamera/sys/avscamera.inxbin25172 -> 12364 bytes
-rw-r--r--avstream/avshws/avshws.inxbin6028 -> 2905 bytes
-rw-r--r--avstream/avssamp/avssamp.inxbin3278 -> 1567 bytes
-rw-r--r--bluetooth/bthecho/bthcli/sys/BthEchoSampleCli.inxbin4570 -> 2206 bytes
-rw-r--r--bluetooth/bthecho/bthsrv/sys/BthEchoSampleSrv.inxbin4578 -> 2210 bytes
-rw-r--r--bluetooth/serialhcibus/WDK/SerialBusWdk.inxbin4732 -> 2277 bytes
-rw-r--r--configuration.dsc.yaml19
-rw-r--r--configuration_vsonly.dsc.yaml3
-rw-r--r--filesys/miniFilter/MetadataManager/fmm.infbin8292 -> 4012 bytes
-rw-r--r--filesys/miniFilter/NameChanger/NameChanger.infbin9004 -> 4361 bytes
-rw-r--r--filesys/miniFilter/avscan/avscan.infbin8858 -> 4274 bytes
-rw-r--r--filesys/miniFilter/cancelSafe/cancelSafe.infbin8792 -> 4262 bytes
-rw-r--r--filesys/miniFilter/cdo/cdo.infbin8270 -> 4004 bytes
-rw-r--r--filesys/miniFilter/change/change.infbin7816 -> 3782 bytes
-rw-r--r--filesys/miniFilter/ctx/ctx.infbin8252 -> 3993 bytes
-rw-r--r--filesys/miniFilter/delete/delete.infbin8084 -> 3913 bytes
-rw-r--r--filesys/miniFilter/minispy/minispy.infbin9920 -> 4817 bytes
-rw-r--r--filesys/miniFilter/nullFilter/nullFilter.infbin7928 -> 3836 bytes
-rw-r--r--filesys/miniFilter/passThrough/passThrough.infbin8116 -> 3930 bytes
-rw-r--r--filesys/miniFilter/scanner/scanner.infbin8340 -> 4035 bytes
-rw-r--r--filesys/miniFilter/scanner/user/scanUser.c52
-rw-r--r--filesys/miniFilter/simrep/simrep.infbin9280 -> 4496 bytes
-rw-r--r--filesys/miniFilter/swapBuffers/swapBuffers.infbin8270 -> 4005 bytes
-rw-r--r--general/DCHU/osrfx2_DCHU_base/osrfx2_DCHU_base/osrfx2_DCHU_base.inxbin7898 -> 3827 bytes
-rw-r--r--general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_component/osrfx2_DCHU_component.inxbin3386 -> 1628 bytes
-rw-r--r--general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inxbin3020 -> 1455 bytes
-rw-r--r--general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_component/osrfx2_DCHU_component.inxbin3386 -> 1628 bytes
-rw-r--r--general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inxbin2994 -> 1442 bytes
-rw-r--r--general/PLX9x5x/sys/pci9x5x.inxbin5334 -> 2574 bytes
-rw-r--r--general/SimpleMediaSource/SimpleMediaSourceDriver/SimpleMediaSourceDriver.infbin6768 -> 3283 bytes
-rw-r--r--general/echo/kmdf/driver/AutoSync/echo.inxbin4138 -> 1981 bytes
-rw-r--r--general/echo/kmdf/driver/DriverSync/echo_2.inxbin4272 -> 2047 bytes
-rw-r--r--general/echo/umdf2/driver/AutoSync/echoum.inxbin4596 -> 2198 bytes
-rw-r--r--general/ioctl/kmdf/exe/install.c432
-rw-r--r--general/ioctl/kmdf/exe/nonpnp.inf8
-rw-r--r--general/ioctl/kmdf/exe/testapp.c120
-rw-r--r--general/pcidrv/kmdf/genpci.inxbin6258 -> 3028 bytes
-rw-r--r--general/toaster/toastDrv/kmdf/bus/dynamic/dynambus.inxbin4794 -> 2309 bytes
-rw-r--r--general/toaster/toastDrv/kmdf/bus/static/statbus.inxbin4696 -> 2260 bytes
-rw-r--r--general/toaster/toastDrv/kmdf/filter/filter.inxbin6262 -> 3016 bytes
-rw-r--r--general/toaster/toastDrv/kmdf/func/featured/wdffeatured.inxbin5076 -> 2442 bytes
-rw-r--r--general/toaster/toastDrv/kmdf/func/simple/wdfsimple.inxbin6070 -> 2935 bytes
-rw-r--r--general/toaster/toastDrv/kmdf/toastmon/wdftoastmon.inxbin3964 -> 1898 bytes
-rw-r--r--general/toaster/umdf2/filter/generic/filterum.inxbin4586 -> 2197 bytes
-rw-r--r--general/toaster/umdf2/func/featured/wdffeaturedum.inxbin4730 -> 2267 bytes
-rw-r--r--general/toaster/umdf2/func/simple/wdfsimpleum.inxbin4606 -> 2206 bytes
-rw-r--r--gnss/gnssUmdf/gnssUmdf.infbin2672 -> 1275 bytes
-rw-r--r--gpio/samples/simdevice/kmdf/simdevice.inxbin3068 -> 1462 bytes
-rw-r--r--gpio/samples/simdevice/umdf/simdeviceumdf.inxbin3444 -> 1652 bytes
-rw-r--r--gpio/samples/simgpio/simgpio.inxbin3714 -> 1776 bytes
-rw-r--r--gpio/samples/simgpio_i2c/simgpio_i2c.inxbin3786 -> 1812 bytes
-rw-r--r--hid/firefly/driver/firefly.inxbin6552 -> 3155 bytes
-rw-r--r--hid/hidusbfx2/sys/hidusbfx2.inxbin7642 -> 3686 bytes
-rw-r--r--hid/vhidmini2/driver/kmdf/vhidmini.inxbin4072 -> 1945 bytes
-rw-r--r--hid/vhidmini2/driver/umdf2/VhidminiUm.inxbin4588 -> 2200 bytes
-rw-r--r--input/kbfiltr/sys/kbfiltr.inxbin4976 -> 2362 bytes
-rw-r--r--input/moufiltr/moufiltr.inxbin4952 -> 2350 bytes
-rw-r--r--network/modem/fakemodem/mdmfake.inxbin24280 -> 11875 bytes
-rw-r--r--network/ndis/extension/samples/forward/msforwardext.infbin5048 -> 2442 bytes
-rw-r--r--network/ndis/extension/samples/passthrough/mspassthroughext.infbin5218 -> 2529 bytes
-rw-r--r--network/ndis/filter/netlwf.infbin19952 -> 9749 bytes
-rw-r--r--network/ndis/mux/driver/60/mux_mp.infbin7718 -> 3736 bytes
-rw-r--r--network/ndis/mux/driver/60/muxp.infbin7380 -> 3564 bytes
-rw-r--r--network/ndis/ndisprot/6x/sys/60/ndisprot60.infbin7168 -> 3475 bytes
-rw-r--r--network/ndis/ndisprot/6x/sys/630/ndisprot630.infbin8974 -> 4363 bytes
-rw-r--r--network/ndis/ndisprot_kmdf/60/ndisprot.inxbin13478 -> 6557 bytes
-rw-r--r--network/ndis/netvmini/6x/60/netvmini60.infbin6470 -> 3138 bytes
-rw-r--r--network/ndis/netvmini/6x/620/netvmini620.infbin11196 -> 5460 bytes
-rw-r--r--network/ndis/netvmini/6x/630/netvmini630.infbin12318 -> 6011 bytes
-rw-r--r--network/ndis/netvmini/6x/680/netvmini680.infbin12314 -> 6010 bytes
-rw-r--r--network/trans/inspect/sys/inspect.infbin3944 -> 1919 bytes
-rw-r--r--network/trans/msnmntr/sys/msnmntr.infbin3172 -> 1538 bytes
-rw-r--r--network/wlan/WDI/PLATFORM/WinInf/SDIO/x64/netrtwlans.infbin74380 -> 36123 bytes
-rw-r--r--network/wwan/cxwmbclass/cxwmbclass/cxwmbclass.infbin8266 -> 4013 bytes
-rw-r--r--network/wwan/cxwmbclass/datapipe.cpp4
-rw-r--r--network/wwan/cxwmbclass/inc/util.h14
-rw-r--r--network/wwan/cxwmbclass/utils.cpp2
-rw-r--r--nfc/NfcCxSample/windows-drivertemplate-nfc/windows-drivertemplate-nfc.infbin3316 -> 1595 bytes
-rw-r--r--packages.config10
-rw-r--r--pofx/PEP/acpi/sampleacpipep.inxbin4270 -> 2053 bytes
-rw-r--r--pofx/UMDF2/Driver/SingleComp/SingleComponentSingleStateUm.inxbin4262 -> 2040 bytes
-rw-r--r--pofx/WDF/Driver/MultiComp/driver/WdfMultiComp.inxbin3608 -> 1726 bytes
-rw-r--r--pofx/WDF/Driver/SingleComp/SingleComponentFStateSample.inxbin5090 -> 2456 bytes
-rw-r--r--pos/drivers/MagneticStripeReader/SampleMagneticStripeReaderDrv.infbin3040 -> 1458 bytes
-rw-r--r--pos/drivers/barcodescanner/SampleBarcodeScannerDrv.infbin2912 -> 1394 bytes
-rw-r--r--prm/PrmFunc/prmfuncsample.infbin2780 -> 1334 bytes
-rw-r--r--sd/miniport/sdhc/sdhc.inxbin7856 -> 3822 bytes
-rw-r--r--sensors/ADXL345Acc/ADXL345Acc.inxbin4398 -> 2114 bytes
-rw-r--r--sensors/Activity/Activity.inxbin4250 -> 2038 bytes
-rw-r--r--sensors/CustomSensors/CustomSensors.inxbin4524 -> 2175 bytes
-rw-r--r--sensors/Fusion/FusionSensor.inxbin4458 -> 2142 bytes
-rw-r--r--sensors/Pedometer/Pedometer.inxbin4302 -> 2064 bytes
-rw-r--r--sensors/SensorsComboDriver/SensorsComboDriver.inxbin4746 -> 2289 bytes
-rw-r--r--sensors/SimpleDeviceOrientationSensor/SimpleDeviceOrientationSensor.inxbin5444 -> 2635 bytes
-rw-r--r--serial/VirtualSerial2/ComPort/virtualserial2um.inxbin6316 -> 3053 bytes
-rw-r--r--serial/VirtualSerial2/FakeModem/fakemodem2um.inxbin16818 -> 8209 bytes
-rw-r--r--serial/VirtualSerial2/queue.c1
-rw-r--r--serial/serial/serial.inxbin5586 -> 2696 bytes
-rw-r--r--simbatt/func/miniclass.c2
-rw-r--r--simbatt/func/simbatt.inxbin3946 -> 1891 bytes
-rw-r--r--smartcrd/pscr/pscr.inxbin6898 -> 3322 bytes
-rw-r--r--spb/SkeletonI2C/skeletoni2c.inxbin3914 -> 1883 bytes
-rw-r--r--spb/SpbTestTool/sys/spbtesttool.inxbin4846 -> 2334 bytes
-rw-r--r--storage/msdsm/src/SampleDSM.infbin4388 -> 2108 bytes
-rw-r--r--thermal/simsensor/simsensor.infbin5570 -> 2689 bytes
-rw-r--r--thermal/thermalclient/simtc.infbin3860 -> 1852 bytes
-rw-r--r--tools/dv/samples/DV-FailDriver-WDM/driver/defect_toastmon.infbin3674 -> 1765 bytes
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/KasanDemo.sln46
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/README.md25
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.c157
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj184
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj.Filters22
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.c303
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.h30
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.rc10
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj155
-rw-r--r--tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj.Filters36
-rw-r--r--usb/UcmCxUcsi/UcmCxUcsi.infbin3940 -> 1896 bytes
-rw-r--r--usb/UcmTcpciCxClientSample/UcmTcpciCxClientSample.infbin3352 -> 1616 bytes
-rw-r--r--usb/UcmUcsiAcpiSample/UcmUcsiAcpiSample/UcmUcsiAcpiSample.infbin3250 -> 1563 bytes
-rw-r--r--usb/kmdf_enumswitches/sys/kmdf_enumswitches.inxbin5330 -> 2567 bytes
-rw-r--r--usb/kmdf_fx2/driver/osrusbfx2.inxbin7006 -> 3386 bytes
-rw-r--r--usb/ufxclientsample/UfxClientSample.inxbin4470 -> 2156 bytes
-rw-r--r--usb/umdf2_fx2/driver/osrusbfx2um.inxbin6012 -> 2903 bytes
-rw-r--r--usb/usbsamp/sys/driver/usbsamp.inxbin5820 -> 2812 bytes
-rw-r--r--usb/wdf_osrfx2_lab/kmdf/step1/osrusbfx2.inxbin5046 -> 2423 bytes
-rw-r--r--usb/wdf_osrfx2_lab/kmdf/step2/osrusbfx2.inxbin5042 -> 2422 bytes
-rw-r--r--usb/wdf_osrfx2_lab/kmdf/step3/osrusbfx2.inxbin5042 -> 2422 bytes
-rw-r--r--usb/wdf_osrfx2_lab/kmdf/step4/osrusbfx2.inxbin5042 -> 2422 bytes
-rw-r--r--usb/wdf_osrfx2_lab/kmdf/step5/osrusbfx2.inxbin5042 -> 2422 bytes
-rw-r--r--video/IndirectDisplay/IddSampleDriver/IddSampleDriver.infbin4198 -> 2026 bytes
-rw-r--r--wia/ProdScan/ProdScan.inxbin3786 -> 1825 bytes
-rw-r--r--wia/microdrv/testmcro.inxbin3292 -> 1580 bytes
-rw-r--r--wia/wiadriverex/usd/WiaDriver.inxbin7566 -> 3682 bytes
-rw-r--r--wmi/wmisamp/wmisamp.inxbin5212 -> 2501 bytes
156 files changed, 1247 insertions, 750 deletions
diff --git a/.gitattributes b/.gitattributes
index 84b1bf11..a59c7386 100644
--- a/.gitattributes
+++ b/.gitattributes
@@ -24,6 +24,10 @@
*.vcxproj text eol=crlf
*.xaml text eol=crlf
+# Declare files that are encoded in UTF-16
+*.inf text diff working-tree-encoding=UTF-16LE-BOM eol=crlf
+*.inx text diff working-tree-encoding=UTF-16LE-BOM eol=crlf
+
###############################################################################
# Set default behavior for command prompt diff.
#
@@ -32,4 +36,3 @@
# Note: This is only used by command line
###############################################################################
*.cs diff=csharp
-
diff --git a/.github/scripts/Build-ChangedSamples.ps1 b/.github/scripts/Build-ChangedSamples.ps1
index f7dc95f5..bdaee943 100644
--- a/.github/scripts/Build-ChangedSamples.ps1
+++ b/.github/scripts/Build-ChangedSamples.ps1
@@ -22,7 +22,7 @@ foreach ($file in $ChangedFiles) {
$filename = Split-Path $file -Leaf
# Files that can affect how every sample is built should trigger a full build
- if ($filename -eq "Build-AllSamples.ps1" -or $filename -eq "Build-Sample.ps1" -or $filename -eq "Build-SampleSet.ps1" -or $filename -eq "exclusions.csv") {
+ if ($filename -eq "Build-AllSamples.ps1" -or $filename -eq "Build-Sample.ps1" -or $filename -eq "Build-SampleSet.ps1" -or $filename -eq "exclusions.csv" -or $filename -eq "Directory.Build.props" -or $filename -eq "packages.config") {
$buildAll = $true
}
if ($dir -like "$root\.github\scripts" -or $dir -like "$root\.github\scripts\*") {
diff --git a/.github/workflows/Code-Scanning.yml b/.github/workflows/Code-Scanning.yml
index a18bcf95..72e9c32c 100644
--- a/.github/workflows/Code-Scanning.yml
+++ b/.github/workflows/Code-Scanning.yml
@@ -8,11 +8,17 @@ on:
branches:
- main
- develop
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
pull_request:
# The branches below must be a subset of the branches above
branches:
- main
- develop
+ paths-ignore:
+ - '**.md'
+ - 'LICENSE'
# Allow manual scheduling
workflow_dispatch:
@@ -32,31 +38,27 @@ jobs:
language: [ 'cpp' ]
steps:
- - name: Checkout repository
- uses: actions/checkout@v4
- with:
- submodules: 'recursive'
+ - name: Checkout repository
+ uses: actions/checkout@v4
+ with:
+ submodules: 'recursive'
+ - name: Install Nuget Packages
+ run: nuget restore .\packages.config -PackagesDirectory .\packages\
- - name: Initialize CodeQL
- uses: github/codeql-action/init@v3
- with:
- languages: ${{ matrix.language }}
- packs: microsoft/windows-drivers
- - name: Add MSBuild to PATH
- uses: microsoft/setup-msbuild@v2
+ - name: Initialize CodeQL
+ uses: github/codeql-action/init@v3
+ with:
+ languages: ${{ matrix.language }}
+ config-file: microsoft/Windows-Driver-Developer-Supplemental-Tools/config/codeql-config.yml@development
+ packs: +microsoft/[email protected]
+ - name: Retrieve and build all available solutions
+ run: .\Build-AllSamples.ps1 -Verbose -ThrottleLimit 1
+ env:
+ WDS_Configuration: Debug
+ WDS_Platform: x64
+ WDS_WipeOutputs: ${{ true }}
- - name: Retrieve and build all available solutions
- run: |
- .\Build-AllSamples.ps1 -Verbose -ThrottleLimit 1
- env:
- WDS_Configuration: Debug
- WDS_Platform: x64
- WDS_WipeOutputs: ${{ true }}
-
- - name: Perform CodeQL analysis
- uses: github/codeql-action/analyze@v3
- with:
- category: "/language:${{matrix.language}}"
-
-
-
+ - name: Perform CodeQL analysis
+ uses: github/codeql-action/analyze@v3
+ with:
+ category: "/language:${{matrix.language}}"
diff --git a/.github/workflows/ci-pr.yml b/.github/workflows/ci-pr.yml
index 7640b966..9c1202b2 100644
--- a/.github/workflows/ci-pr.yml
+++ b/.github/workflows/ci-pr.yml
@@ -22,8 +22,8 @@ jobs:
with:
submodules: 'recursive'
- - name: Add MSBuild to PATH
- uses: microsoft/setup-msbuild@v2
+ - name: Install Nuget Packages
+ run: nuget restore .\packages.config -PackagesDirectory .\packages\
- name: Get changed files
id: get-changed-files
@@ -41,10 +41,10 @@ jobs:
WDS_ReportFileName: _overview.${{ matrix.configuration }}.${{ matrix.platform }}
- name: Archive build logs and overview build reports
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
if: always()
with:
- name: logs
+ name: logs-${{ matrix.configuration }}-${{ matrix.platform }}
path: _logs
report:
@@ -57,17 +57,17 @@ jobs:
uses: actions/checkout@v4
- name: Retrieve overview reports
- uses: actions/download-artifact@v3
+ uses: actions/download-artifact@v4
with:
- name: logs
path: _logs
+ pattern: logs-*
+ merge-multiple: true
- name: Join and generate global reports
- run: |
- .\.github\scripts\Join-CsvReports.ps1
+ run: .\.github\scripts\Join-CsvReports.ps1
- name: Archive global overview build reports
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: logs
path: _logs/_overview.all.*
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index ad92f83b..e43d74f5 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -22,22 +22,21 @@ jobs:
with:
submodules: 'recursive'
- - name: Add MSBuild to PATH
- uses: microsoft/setup-msbuild@v2
+ - name: Install Nuget Packages
+ run: nuget restore .\packages.config -PackagesDirectory .\packages\
- name: Retrieve and build all available solutions
- run: |
- .\Build-AllSamples.ps1 -Verbose
+ run: .\Build-AllSamples.ps1 -Verbose
env:
WDS_Configuration: ${{ matrix.configuration }}
WDS_Platform: ${{ matrix.platform }}
WDS_ReportFileName: _overview.${{ matrix.configuration }}.${{ matrix.platform }}
- name: Archive build logs and overview build reports
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
if: always()
with:
- name: logs
+ name: logs-${{ matrix.configuration }}-${{ matrix.platform }}
path: _logs
report:
@@ -50,17 +49,17 @@ jobs:
uses: actions/checkout@v4
- name: Retrieve overview reports
- uses: actions/download-artifact@v3
+ uses: actions/download-artifact@v4
with:
- name: logs
path: _logs
+ pattern: logs-*
+ merge-multiple: true
- name: Join and generate global reports
- run: |
- .\.github\scripts\Join-CsvReports.ps1
+ run: .\.github\scripts\Join-CsvReports.ps1
- name: Archive global overview build reports
- uses: actions/upload-artifact@v3
+ uses: actions/upload-artifact@v4
with:
name: logs
path: _logs/_overview.all.*
diff --git a/Build-SampleSet.ps1 b/Build-SampleSet.ps1
index b0da097a..f6765395 100644
--- a/Build-SampleSet.ps1
+++ b/Build-SampleSet.ps1
@@ -9,6 +9,14 @@ param(
)
$root = Get-Location
+
+# launch developer powershell (if necessary to prevent multiple developer sessions)
+if (-not $env:VSCMD_VER) {
+ Import-Module (Resolve-Path "$env:ProgramFiles\Microsoft Visual Studio\2022\*\Common7\Tools\Microsoft.VisualStudio.DevShell.dll")
+ Enter-VsDevShell -VsInstallPath (Resolve-Path "$env:ProgramFiles\Microsoft Visual Studio\2022\*")
+ cd $root
+}
+
$ThrottleFactor = 5
$LogicalProcessors = (Get-CIMInstance -Class 'CIM_Processor' -Verbose:$false).NumberOfLogicalProcessors
@@ -45,27 +53,31 @@ finally {
}
#
-# Determine build environment: 'GitHub', 'NuGet', 'EWDK', or 'WDK'. Only used to determine build number.
+# Determine build environment: 'GitHub', 'NuGet', 'EWDK', or 'WDK'.
# Determine build number (used for exclusions based on build number). Five digits. Say, '22621'.
+# Determine NuGet package version (if applicable).
#
$build_environment=""
$build_number=0
+$nuget_package_version=0
#
-# WDK NuGet will require presence of a folder 'packages'
+# In Github we build using NuGet.
#
-#
-# Hack: In GitHub we do not have an environment variable where we can see WDK build number, so we have it hard coded.
-#
-if (-not $env:GITHUB_REPOSITORY -eq '') {
+if ($env:GITHUB_REPOSITORY) {
$build_environment="GitHub"
- $build_number=22621
+ $nuget_package_version=([regex]'(?<=x64\.)(\d+\.)(\d+\.)(\d+\.)(\d+)').Matches((Get-Childitem .\packages\*WDK.x64* -Name)).Value
+ $build_number=$nuget_package_version.split('.')[2]
}
#
-# Hack: If user has hydrated nuget packages, then use those. That will be indicated by presence of a folder named .\packages.
+# WDK NuGet will require presence of a folder 'packages'. The version is sourced from repo .\Env-Vars.ps1.
+#
+# Hack: If user has hydrated nuget packages, then use those. That will be indicated by presence of a folder named '.\packages'.
+# Further, we need to test that the directory has been hydrated using '.\packages\*'.
#
-elseif(Test-Path(".\packages")) {
+elseif(Test-Path(".\packages\*")) {
$build_environment=("NuGet")
- $build_number=26100
+ $nuget_package_version=([regex]'(?<=x64\.)(\d+\.)(\d+\.)(\d+\.)(\d+)').Matches((Get-Childitem .\packages\*WDK.x64* -Name)).Value
+ $build_number=$nuget_package_version.split('.')[2]
}
#
# EWDK sets environment variable BuildLab. For example 'ni_release_svc_prod1.22621.2428'.
@@ -91,7 +103,15 @@ else {
Write-Error "Could not determine build environment."
exit 1
}
-
+#
+# Get the WDK extension version from installed packages
+$wdk_extension_ver = ls "${env:ProgramData}\Microsoft\VisualStudio\Packages\Microsoft.Windows.DriverKit,version=*" | Select -ExpandProperty Name
+$wdk_extension_ver = ([regex]'(\d+\.)(\d+\.)(\d+\.)(\d+)').Matches($wdk_extension_ver).Value
+if (-not $wdk_extension_ver) {
+ Write-Error "No version of the WDK Visual Studio Extension could be found. The WDK Extension is not installed."
+ exit 1
+}
+#
#
# InfVerif_AdditionalOptions
#
@@ -153,18 +173,22 @@ $jresult = @{
$SolutionsTotal = $sampleSet.Count * $Configurations.Count * $Platforms.Count
-Write-Output ("Build Environment: " + $build_environment)
-Write-Output ("Build Number: " + $build_number)
-Write-Output ("Samples: " + $sampleSet.Count)
-Write-Output ("Configurations: " + $Configurations.Count + " (" + $Configurations + ")")
-Write-Output ("Platforms: " + $Platforms.Count + " (" + $Platforms + ")")
+Write-Output "WDK Build Environment: $build_environment"
+Write-Output "WDK Build Number: $build_number"
+if (($build_environment -eq "GitHub") -or ($build_environment -eq "NuGet")) {
+Write-Output "WDK Nuget Version: $nuget_package_version"
+}
+Write-Output "WDK Extension Version: $wdk_extension_ver"
+Write-Output "Samples: $($sampleSet.Count)"
+Write-Output "Configurations: $($Configurations.Count) ($Configurations)"
+Write-Output "Platforms: $($Platforms.Count) ($Platforms)"
Write-Output "InfVerif_AdditionalOptions: $InfVerif_AdditionalOptions"
Write-Output "Combinations: $SolutionsTotal"
Write-Output "LogicalProcessors: $LogicalProcessors"
Write-Output "ThrottleFactor: $ThrottleFactor"
Write-Output "ThrottleLimit: $ThrottleLimit"
Write-Output "WDS_WipeOutputs: $env:WDS_WipeOutputs"
-Write-Output ("Disk Remaining (GB): " + (((Get-Volume ($DriveLetter = (Get-Item ".").PSDrive.Name)).SizeRemaining / 1GB)))
+Write-Output "Disk Remaining (GB): $(((Get-Volume ((Get-Item ".").PSDrive.Name)).SizeRemaining) / 1GB)"
Write-Output ""
Write-Output "T: Combinations"
Write-Output "B: Built"
diff --git a/Building-Locally.md b/Building-Locally.md
index bb9fc610..312c5967 100644
--- a/Building-Locally.md
+++ b/Building-Locally.md
@@ -2,16 +2,19 @@
## Step 1: Install Tools
-```
+```powershell
winget install --id Microsoft.Powershell --source winget
winget install --id Git.Git --source winget
```
For using WDK NuGet feed based build additionally:
-```
+
+```powershell
winget install --id Microsoft.NuGet --source winget
```
+---
+
## Step 2: Optional: Disable Strong Name Validation
When: This step is only required if you will be using pre-release versions of the WDK.
@@ -26,16 +29,20 @@ reg add HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\StrongName\Verification\*,31bf3856
reg add HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\StrongName\Verification\*,31bf3856ad364e35 /v TestPublicKey /t REG_SZ /d 00240000048000009400000006020000002400005253413100040000010001003f8c902c8fe7ac83af7401b14c1bd103973b26dfafb2b77eda478a2539b979b56ce47f36336741b4ec52bbc51fecd51ba23810cec47070f3e29a2261a2d1d08e4b2b4b457beaa91460055f78cc89f21cd028377af0cc5e6c04699b6856a1e49d5fad3ef16d3c3d6010f40df0a7d6cc2ee11744b5cfb42e0f19a52b8a29dc31b0 /f
```
+---
+
## Step 3: Optional: Install Microsoft .NET Framework 4.7.2 Targeting Pack and Microsoft .NET Framework 4.8.1 SDK
When: This step is only required to build sample usb\usbview .
### Option A: Install VS Components
+
Easy: If you will install Visual Studio (see later) you may at that point select to add both of following individual components:
* .NET Framework 4.7.2 targeting pack
* .NET Framework 4.8.1 SDK
### Option B: Use EWDK
+
Easy: If you use EWDK, then all necessary prequisites are included.
### Option C: Install Developer Pack
@@ -52,24 +59,30 @@ This will install following Apps:
* Microsoft .NET Framework 4.8.1 Targeting Pack
* Microsoft .NET Framework 4.8.1 Targeting Pack (ENU)
+---
+
## Step 4: Clone Windows Driver Samples and checkout relevant branch
-```
-cd path\to\your\repos
-git clone --recurse-submodules https://github.com/microsoft/Windows-driver-samples.git
-cd Windows-driver-samples
+```powershell
+cd "path\to\your\repos"
+git clone --recurse-submodules "https://github.com/microsoft/Windows-driver-samples.git"
+cd ".\Windows-driver-samples"
```
If you are planning to use in-market WDK, then you would typically want to use the 'main' branch:
+
```
git checkout main
```
If you are planning to use a WDK Preview or WDK EEAP release, then you would typically want to use the 'develop' branch:
+
```
git checkout develop
```
+---
+
## Step 5: Create a "driver build environment"
To build the Windows Driver Samples you need a "driver build environment". In essence an environment that consist of following prerequisites:
@@ -78,49 +91,55 @@ To build the Windows Driver Samples you need a "driver build environment". In e
* The Windows Driver Kit.
### Option A: Use WDK NuGet Packages
-* See [Download the Windows Driver Kit (WDK)](https://learn.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk) for instructions on how to install Visual Studio, but only complete "Step 1". You do not need to install the SDK or the WDK.
-* Install the Visual Studio Windows Driver Kit Extension (WDK.vsix). Open Visual Studio -> Extensions -> Manage Extensions... -> Online -> Visual Studio Market Place -> Windows Driver Kit -> 10.0.26100.0 -> Download
+
+* See [Download the Windows Driver Kit (WDK)](https://learn.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk) for instructions on how to install Visual Studio, but only complete `Step 1`. You do not need to install the SDK or the WDK.
* Launch a "Developer Command Prompt for VS 2022".
* Restore WDK packages from feed :
-```
->cd path\to\your\repos\Windows-driver-samples
->nuget restore -PackagesDirectory .\packages
+```powershell
+cd "path\to\your\repos\Windows-driver-samples"
+nuget restore -PackagesDirectory ".\packages"
```
-* When this is done you should have a .\packages folder that looks exactly as follows:
-```
->cd path\to\your\repos\Windows-driver-samples
->dir /b packages
+* When this is done you should have a .\packages folder that looks like example below:
+
+```powershell
+cd "path\to\your\repos\Windows-driver-samples"
+dir /b packages
Microsoft.Windows.SDK.CPP.10.0.26000.1
Microsoft.Windows.SDK.CPP.x64.10.0.26000.1
Microsoft.Windows.SDK.CPP.arm64.10.0.26000.1
Microsoft.Windows.WDK.x64.10.0.26000.1
Microsoft.Windows.WDK.arm64.10.0.26000.1
```
+
### Option B: Use the Windows Driver Kit
+
* Here you will install each of above prerequisites one at a time.
* See [Download the Windows Driver Kit (WDK)](https://learn.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk) for instructions on how to install Visual Studio, SDK, and WDK.
* Launch a "Developer Command Prompt for VS 2022".
### Option C: Use an Enterprise WDK
+
* You can also simply use the Enterprise WDK (EWDK), a standalone, self-contained command-line environment for building drivers that contains all prerequisites in one combined ISO.
* See [Download the Windows Driver Kit (WDK)](https://learn.microsoft.com/en-us/windows-hardware/drivers/download-the-wdk) for instructions on how to download the EWDK.
* Mount ISO image
* Open a terminal
* `.\LaunchBuildEnv`
+---
## Step 6: Check all samples builds with expected results for all flavors
-```
+```powershell
pwsh
.\Build-AllSamples
```
Above builds all samples for all configurations and platforms.
You can refine what exact samples to build, what configurations, and platforms to build. build Here are a few examples:
-```
+
+```powershell
# Get Help:
Get-Help .\Build-AllSamples
@@ -140,9 +159,9 @@ Get-Help .\Build-AllSamples
.\Build-AllSamples -Samples '^tools.' -Configurations 'Debug' -Platforms 'x64'
```
-Expected output:
+Example of expected output:
+
```
-PS > .\build-AllSamples.ps1
Build Environment: NuGet
Build Number: 26100
Samples: 132
@@ -186,6 +205,8 @@ Log files directory: .\_logs
Overview report: .\_overview.htm
```
+---
+
## 7: NuGet - Additional Notes
To restore a specific version of our WDK NuGet packages:
@@ -197,12 +218,13 @@ Follow these steps before running "nuget restore" command:
* Now you can run "nuget restore"
A few examples of how to interact with nuget:
-```
+
+```powershell
# To add an alternative online NuGet source:
-nuget sources add -Name "MyNuGetFeed" -Source https://nugetserver.com/_packaging/feedname/nuget/v3/index.json
+nuget sources add -Name "MyNuGetFeed" -Source "https://nugetserver.com/_packaging/feedname/nuget/v3/index.json"
# To add an alternative local NuGet source:
-nuget sources add -Name "MyNuGetFeed" -Source \\path\to\mylocalrepo
+nuget sources add -Name "MyNuGetFeed" -Source "\\path\to\mylocalrepo"
# To remove an alternative NuGet source:
nuget sources remove -Name "MyNuGetFeed"
diff --git a/Directory.Build.props b/Directory.Build.props
index 811c5f30..4f46faef 100644
--- a/Directory.Build.props
+++ b/Directory.Build.props
@@ -1,7 +1,7 @@
<Project>
-<Import Project="packages\Microsoft.Windows.WDK.x64.10.0.26100.1\build\native\Microsoft.Windows.WDK.x64.props" Condition="Exists('packages\Microsoft.Windows.WDK.x64.10.0.26100.1\build\native\Microsoft.Windows.WDK.x64.props') and '$(Platform)' == 'x64'"/>
-<Import Project="packages\Microsoft.Windows.WDK.arm64.10.0.26100.1\build\native\Microsoft.Windows.WDK.arm64.props" Condition="Exists('packages\Microsoft.Windows.WDK.arm64.10.0.26100.1\build\native\Microsoft.Windows.WDK.arm64.props') and '$(Platform)' == 'ARM64'"/>
-<Import Project="packages\Microsoft.Windows.SDK.CPP.x64.10.0.26100.1\build\native\Microsoft.Windows.SDK.cpp.x64.props" Condition="Exists('packages\Microsoft.Windows.SDK.CPP.x64.10.0.26100.1\build\native\Microsoft.Windows.SDK.cpp.x64.props') and '$(Platform)' == 'x64'"/>
-<Import Project="packages\Microsoft.Windows.SDK.CPP.arm64.10.0.26100.1\build\native\Microsoft.Windows.SDK.cpp.arm64.props" Condition="Exists('packages\Microsoft.Windows.SDK.CPP.arm64.10.0.26100.1\build\native\Microsoft.Windows.SDK.cpp.arm64.props') and '$(Platform)' == 'ARM64'"/>
-<Import Project="packages\Microsoft.Windows.SDK.CPP.10.0.26100.1\build\native\Microsoft.Windows.SDK.cpp.props" Condition="Exists('packages\Microsoft.Windows.SDK.CPP.10.0.26100.1\build\native\Microsoft.Windows.SDK.cpp.props')"/>
+<Import Project="packages\Microsoft.Windows.WDK.x64.10.0.26100.2454\build\native\Microsoft.Windows.WDK.x64.props" Condition="Exists('packages\Microsoft.Windows.WDK.x64.10.0.26100.2454\build\native\Microsoft.Windows.WDK.x64.props') and '$(Platform)' == 'x64'"/>
+<Import Project="packages\Microsoft.Windows.WDK.arm64.10.0.26100.2454\build\native\Microsoft.Windows.WDK.arm64.props" Condition="Exists('packages\Microsoft.Windows.WDK.arm64.10.0.26100.2454\build\native\Microsoft.Windows.WDK.arm64.props') and '$(Platform)' == 'ARM64'"/>
+<Import Project="packages\Microsoft.Windows.SDK.CPP.x64.10.0.26100.2454\build\native\Microsoft.Windows.SDK.cpp.x64.props" Condition="Exists('packages\Microsoft.Windows.SDK.CPP.x64.10.0.26100.2454\build\native\Microsoft.Windows.SDK.cpp.x64.props') and '$(Platform)' == 'x64'"/>
+<Import Project="packages\Microsoft.Windows.SDK.CPP.arm64.10.0.26100.2454\build\native\Microsoft.Windows.SDK.cpp.arm64.props" Condition="Exists('packages\Microsoft.Windows.SDK.CPP.arm64.10.0.26100.2454\build\native\Microsoft.Windows.SDK.cpp.arm64.props') and '$(Platform)' == 'ARM64'"/>
+<Import Project="packages\Microsoft.Windows.SDK.CPP.10.0.26100.2454\build\native\Microsoft.Windows.SDK.cpp.props" Condition="Exists('packages\Microsoft.Windows.SDK.CPP.10.0.26100.2454\build\native\Microsoft.Windows.SDK.cpp.props')"/>
</Project>
diff --git a/audio/Acx/Samples/AudioCodec/Driver/AudioCodec.inf b/audio/Acx/Samples/AudioCodec/Driver/AudioCodec.inf
index 889f9bdb..0bc5fe23 100644
--- a/audio/Acx/Samples/AudioCodec/Driver/AudioCodec.inf
+++ b/audio/Acx/Samples/AudioCodec/Driver/AudioCodec.inf
Binary files differ
diff --git a/audio/simpleaudiosample/Source/Filters/speakertoptable.h b/audio/simpleaudiosample/Source/Filters/speakertoptable.h
index 1b046d96..f9e54df6 100644
--- a/audio/simpleaudiosample/Source/Filters/speakertoptable.h
+++ b/audio/simpleaudiosample/Source/Filters/speakertoptable.h
@@ -87,7 +87,7 @@ static
KSJACK_DESCRIPTION SpeakerJackDescBridge =
{
KSAUDIO_SPEAKER_STEREO,
- 0xB3C98C, // Color spec for green
+ JACKDESC_RGB(0xB3,0xC9,0x8C), // Color spec for green
eConnTypeUnknown,
eGeoLocFront,
eGenLocPrimaryBox,
diff --git a/audio/simpleaudiosample/Source/Main/SimpleAudioSample.inx b/audio/simpleaudiosample/Source/Main/SimpleAudioSample.inx
index d0835f1f..db2b62c1 100644
--- a/audio/simpleaudiosample/Source/Main/SimpleAudioSample.inx
+++ b/audio/simpleaudiosample/Source/Main/SimpleAudioSample.inx
Binary files differ
diff --git a/audio/simpleaudiosample/Source/Main/common.cpp b/audio/simpleaudiosample/Source/Main/common.cpp
index 457bdb17..7c19130e 100644
--- a/audio/simpleaudiosample/Source/Main/common.cpp
+++ b/audio/simpleaudiosample/Source/Main/common.cpp
@@ -2511,7 +2511,7 @@ Return Value:
// Allocate the key value name string
pwstrKeyValueName = (PWSTR)ExAllocatePool2(POOL_FLAG_NON_PAGED, kvFullInfo->NameLength + sizeof(WCHAR)*2, MINADAPTER_POOLTAG);
- IF_TRUE_ACTION_JUMP(kvFullInfo == NULL, ntStatus = STATUS_INSUFFICIENT_RESOURCES, loop_exit);
+ IF_TRUE_ACTION_JUMP(pwstrKeyValueName == NULL, ntStatus = STATUS_INSUFFICIENT_RESOURCES, loop_exit);
// Copy the key value name from the full information struct
RtlStringCbCopyNW(pwstrKeyValueName, kvFullInfo->NameLength + sizeof(WCHAR)*2, kvFullInfo->Name, kvFullInfo->NameLength);
@@ -2531,6 +2531,7 @@ Return Value:
if (pwstrKeyValueName)
{
ExFreePoolWithTag(pwstrKeyValueName, MINADAPTER_POOLTAG);
+ pwstrKeyValueName = NULL;
}
// Bail if anything failed
@@ -2618,7 +2619,7 @@ Return Value:
// Allocate the key name string
pwstrKeyName = (PWSTR)ExAllocatePool2(POOL_FLAG_NON_PAGED, kBasicInfo->NameLength + sizeof(WCHAR), MINADAPTER_POOLTAG);
- IF_TRUE_ACTION_JUMP(kBasicInfo == NULL, ntStatus = STATUS_INSUFFICIENT_RESOURCES, loop_exit);
+ IF_TRUE_ACTION_JUMP(pwstrKeyName == NULL, ntStatus = STATUS_INSUFFICIENT_RESOURCES, loop_exit);
// Copy the key name from the basic information struct
RtlStringCbCopyNW(pwstrKeyName, kBasicInfo->NameLength + sizeof(WCHAR), kBasicInfo->Name, kBasicInfo->NameLength);
@@ -2652,6 +2653,7 @@ Return Value:
if (pwstrKeyName)
{
ExFreePoolWithTag(pwstrKeyName, MINADAPTER_POOLTAG);
+ pwstrKeyName = NULL;
}
// Close the current source key
diff --git a/audio/simpleaudiosample/Source/Main/minwavert.h b/audio/simpleaudiosample/Source/Main/minwavert.h
index 4c0ccd83..a5ed89ff 100644
--- a/audio/simpleaudiosample/Source/Main/minwavert.h
+++ b/audio/simpleaudiosample/Source/Main/minwavert.h
@@ -204,58 +204,6 @@ public:
};
#pragma code_seg()
- //---------------------------------------------------------------------------------------------------------
- // volume
- //---------------------------------------------------------------------------------------------------------
- NTSTATUS GetVolumeChannelCount
- (
- _Out_ UINT32* pulChannelCount
- );
-
- NTSTATUS GetVolumeSteppings
- (
- _Out_writes_bytes_(_ui32DataSize) PKSPROPERTY_STEPPING_LONG _pKsPropStepLong,
- _In_ UINT32 _ui32DataSize
- );
-
- NTSTATUS GetChannelVolume
- (
- _In_ UINT32 _uiChannel,
- _Out_ LONG* _pVolume
- );
-
- NTSTATUS SetChannelVolume
- (
- _In_ UINT32 _uiChannel,
- _In_ LONG _Volume
- );
-
- //-----------------------------------------------------------------------------
- // mute
- //-----------------------------------------------------------------------------
- NTSTATUS GetMuteChannelCount
- (
- _Out_ UINT32* pulChannelCount
- );
-
- NTSTATUS GetMuteSteppings
- (
- _Out_writes_bytes_(_ui32DataSize) PKSPROPERTY_STEPPING_LONG _pKsPropStepLong,
- _In_ UINT32 _ui32DataSize
- );
-
- NTSTATUS GetChannelMute
- (
- _In_ UINT32 _uiChannel,
- _Out_ BOOL* _pbMute
- );
-
- NTSTATUS SetChannelMute
- (
- _In_ UINT32 _uiChannel,
- _In_ BOOL _bMute
- );
-
private:
_IRQL_raises_(DISPATCH_LEVEL)
_Acquires_lock_(m_DeviceFormatsAndModesLock)
diff --git a/audio/simpleaudiosample/Source/Main/minwavertstream.h b/audio/simpleaudiosample/Source/Main/minwavertstream.h
index 5545e0d8..0124cab2 100644
--- a/audio/simpleaudiosample/Source/Main/minwavertstream.h
+++ b/audio/simpleaudiosample/Source/Main/minwavertstream.h
@@ -131,63 +131,11 @@ protected:
public:
- NTSTATUS GetVolumeChannelCount
- (
- _Out_ UINT32* puiChannelCount
- );
-
- NTSTATUS GetVolumeSteppings
- (
- _Out_writes_bytes_(_ui32DataSize) PKSPROPERTY_STEPPING_LONG _pKsPropStepLong,
- _In_ UINT32 _ui32DataSize
- );
-
- NTSTATUS GetChannelVolume
- (
- _In_ UINT32 _uiChannel,
- _Out_ LONG* _pVolume
- );
-
- NTSTATUS SetChannelVolume
- (
- _In_ UINT32 _uiChannel,
- _In_ LONG _Volume
- );
-
- NTSTATUS GetMuteChannelCount
- (
- _Out_ UINT32* puiChannelCount
- );
-
- NTSTATUS GetMuteSteppings
- (
- _Out_writes_bytes_(_ui32DataSize) PKSPROPERTY_STEPPING_LONG _pKsPropStepLong,
- _In_ UINT32 _ui32DataSize
- );
-
- NTSTATUS GetChannelMute
- (
- _In_ UINT32 _uiChannel,
- _Out_ BOOL* _pbMute
- );
-
- NTSTATUS SetChannelMute
- (
- _In_ UINT32 _uiChannel,
- _In_ BOOL _bMute
- );
-
//presentation
NTSTATUS GetPresentationPosition
(
_Out_ KSAUDIO_PRESENTATION_POSITION *_pPresentationPosition
);
-
- NTSTATUS SetCurrentWritePosition
- (
- _In_ ULONG ulCurrentWritePosition
- );
-
ULONG GetCurrentWaveRTWritePosition()
{
diff --git a/audio/sysvad/APO/AecApo/AecApo.vcxproj b/audio/sysvad/APO/AecApo/AecApo.vcxproj
index 7de1a862..37c814b1 100644
--- a/audio/sysvad/APO/AecApo/AecApo.vcxproj
+++ b/audio/sysvad/APO/AecApo/AecApo.vcxproj
@@ -32,7 +32,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -41,7 +40,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -50,7 +48,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -59,7 +56,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
diff --git a/audio/sysvad/APO/DelayAPO/DelayAPO.vcxproj b/audio/sysvad/APO/DelayAPO/DelayAPO.vcxproj
index a5d6ff37..81004ea0 100644
--- a/audio/sysvad/APO/DelayAPO/DelayAPO.vcxproj
+++ b/audio/sysvad/APO/DelayAPO/DelayAPO.vcxproj
@@ -32,7 +32,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -41,7 +40,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -50,7 +48,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -59,7 +56,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
diff --git a/audio/sysvad/APO/KWSApo/KWSApo.vcxproj b/audio/sysvad/APO/KWSApo/KWSApo.vcxproj
index 938e5974..05430973 100644
--- a/audio/sysvad/APO/KWSApo/KWSApo.vcxproj
+++ b/audio/sysvad/APO/KWSApo/KWSApo.vcxproj
@@ -32,7 +32,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -41,7 +40,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -50,7 +48,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -59,7 +56,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
diff --git a/audio/sysvad/APO/SwapAPO/SwapAPO.vcxproj b/audio/sysvad/APO/SwapAPO/SwapAPO.vcxproj
index 61bea0cb..c1e2f27a 100644
--- a/audio/sysvad/APO/SwapAPO/SwapAPO.vcxproj
+++ b/audio/sysvad/APO/SwapAPO/SwapAPO.vcxproj
@@ -32,7 +32,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -41,7 +40,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>False</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -50,7 +48,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
@@ -59,7 +56,6 @@
<TargetVersion>Windows10</TargetVersion>
<UseDebugLibraries>True</UseDebugLibraries>
<DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
- <EmbedManifest>false</EmbedManifest>
<DriverType />
<PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
<ConfigurationType>DynamicLibrary</ConfigurationType>
diff --git a/audio/sysvad/TabletAudioSample/ComponentizedApoSample.inx b/audio/sysvad/TabletAudioSample/ComponentizedApoSample.inx
index 7c08f86a..2cda2dae 100644
--- a/audio/sysvad/TabletAudioSample/ComponentizedApoSample.inx
+++ b/audio/sysvad/TabletAudioSample/ComponentizedApoSample.inx
Binary files differ
diff --git a/audio/sysvad/TabletAudioSample/ComponentizedAudioSample.inx b/audio/sysvad/TabletAudioSample/ComponentizedAudioSample.inx
index 1c638273..c6655868 100644
--- a/audio/sysvad/TabletAudioSample/ComponentizedAudioSample.inx
+++ b/audio/sysvad/TabletAudioSample/ComponentizedAudioSample.inx
Binary files differ
diff --git a/audio/sysvad/TabletAudioSample/ComponentizedAudioSampleExtension.inx b/audio/sysvad/TabletAudioSample/ComponentizedAudioSampleExtension.inx
index 2ce2f6a0..7511017c 100644
--- a/audio/sysvad/TabletAudioSample/ComponentizedAudioSampleExtension.inx
+++ b/audio/sysvad/TabletAudioSample/ComponentizedAudioSampleExtension.inx
Binary files differ
diff --git a/avstream/avscamera/sys/avscamera.inx b/avstream/avscamera/sys/avscamera.inx
index f75da695..a7c58505 100644
--- a/avstream/avscamera/sys/avscamera.inx
+++ b/avstream/avscamera/sys/avscamera.inx
Binary files differ
diff --git a/avstream/avshws/avshws.inx b/avstream/avshws/avshws.inx
index 9409635d..a2d94aba 100644
--- a/avstream/avshws/avshws.inx
+++ b/avstream/avshws/avshws.inx
Binary files differ
diff --git a/avstream/avssamp/avssamp.inx b/avstream/avssamp/avssamp.inx
index c06925ea..0036dc50 100644
--- a/avstream/avssamp/avssamp.inx
+++ b/avstream/avssamp/avssamp.inx
Binary files differ
diff --git a/bluetooth/bthecho/bthcli/sys/BthEchoSampleCli.inx b/bluetooth/bthecho/bthcli/sys/BthEchoSampleCli.inx
index 6f326ff3..1002f10d 100644
--- a/bluetooth/bthecho/bthcli/sys/BthEchoSampleCli.inx
+++ b/bluetooth/bthecho/bthcli/sys/BthEchoSampleCli.inx
Binary files differ
diff --git a/bluetooth/bthecho/bthsrv/sys/BthEchoSampleSrv.inx b/bluetooth/bthecho/bthsrv/sys/BthEchoSampleSrv.inx
index 3079c6d0..ea9238e1 100644
--- a/bluetooth/bthecho/bthsrv/sys/BthEchoSampleSrv.inx
+++ b/bluetooth/bthecho/bthsrv/sys/BthEchoSampleSrv.inx
Binary files differ
diff --git a/bluetooth/serialhcibus/WDK/SerialBusWdk.inx b/bluetooth/serialhcibus/WDK/SerialBusWdk.inx
index 27f70ab6..813c52f1 100644
--- a/bluetooth/serialhcibus/WDK/SerialBusWdk.inx
+++ b/bluetooth/serialhcibus/WDK/SerialBusWdk.inx
Binary files differ
diff --git a/configuration.dsc.yaml b/configuration.dsc.yaml
index f8245c08..3d25ff06 100644
--- a/configuration.dsc.yaml
+++ b/configuration.dsc.yaml
@@ -42,6 +42,7 @@ properties:
- Microsoft.VisualStudio.Component.VC.MFC.ARM64
- Microsoft.VisualStudio.Component.VC.MFC.ARM64.Spectre
- Microsoft.VisualStudio.Workload.NativeDesktop
+ - Component.Microsoft.Windows.DriverKit
- resource: Microsoft.WinGet.DSC/WinGetPackage
id: sdkPackage
directives:
@@ -62,20 +63,4 @@ properties:
id: Microsoft.WindowsWDK.10.0.26100
source: winget
useLatest: true
- - resource: PSDscResources/Script
- id: wdkVsix
- dependsOn:
- - wdkPackage
- - vsComponents
- directives:
- description: Install Windows Driver Kit VSIX
- settings:
- GetScript: |
- return & "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -nologo -version '[17.0,18.0)' -requires Microsoft.Windows.DriverKit -property installationVersion
- SetScript: |
- $installerPath = & "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -nologo -latest -products * -property enginePath | Join-Path -ChildPath 'VSIXInstaller.exe'
- if (Test-Path $installerPath) { & $installerPath /q "${env:ProgramFiles(x86)}\Windows Kits\10\Vsix\VS2022\10.0.26100.0\${env:PROCESSOR_ARCHITECTURE}\WDK.vsix" }
- TestScript: |
- $versionString = & "${env:ProgramFiles(x86)}\Microsoft Visual Studio\Installer\vswhere.exe" -nologo -version '[17.0,18.0)' -requires Microsoft.Windows.DriverKit -property installationVersion
- return $versionString -match "^17\."
- configurationVersion: 0.2.0
+ configurationVersion: 0.2.1
diff --git a/configuration_vsonly.dsc.yaml b/configuration_vsonly.dsc.yaml
index 6ce4fc83..9d86a4f7 100644
--- a/configuration_vsonly.dsc.yaml
+++ b/configuration_vsonly.dsc.yaml
@@ -42,4 +42,5 @@ properties:
- Microsoft.VisualStudio.Component.VC.MFC.ARM64
- Microsoft.VisualStudio.Component.VC.MFC.ARM64.Spectre
- Microsoft.VisualStudio.Workload.NativeDesktop
- configurationVersion: 0.2.0
+ - Component.Microsoft.Windows.DriverKit
+ configurationVersion: 0.2.1
diff --git a/filesys/miniFilter/MetadataManager/fmm.inf b/filesys/miniFilter/MetadataManager/fmm.inf
index ad231a8c..63f0bd4b 100644
--- a/filesys/miniFilter/MetadataManager/fmm.inf
+++ b/filesys/miniFilter/MetadataManager/fmm.inf
Binary files differ
diff --git a/filesys/miniFilter/NameChanger/NameChanger.inf b/filesys/miniFilter/NameChanger/NameChanger.inf
index 7c0b2364..b4474bb1 100644
--- a/filesys/miniFilter/NameChanger/NameChanger.inf
+++ b/filesys/miniFilter/NameChanger/NameChanger.inf
Binary files differ
diff --git a/filesys/miniFilter/avscan/avscan.inf b/filesys/miniFilter/avscan/avscan.inf
index cfc9c9ab..8c1e329d 100644
--- a/filesys/miniFilter/avscan/avscan.inf
+++ b/filesys/miniFilter/avscan/avscan.inf
Binary files differ
diff --git a/filesys/miniFilter/cancelSafe/cancelSafe.inf b/filesys/miniFilter/cancelSafe/cancelSafe.inf
index 69d0ccf1..5367e66e 100644
--- a/filesys/miniFilter/cancelSafe/cancelSafe.inf
+++ b/filesys/miniFilter/cancelSafe/cancelSafe.inf
Binary files differ
diff --git a/filesys/miniFilter/cdo/cdo.inf b/filesys/miniFilter/cdo/cdo.inf
index cdac24d9..37af1d59 100644
--- a/filesys/miniFilter/cdo/cdo.inf
+++ b/filesys/miniFilter/cdo/cdo.inf
Binary files differ
diff --git a/filesys/miniFilter/change/change.inf b/filesys/miniFilter/change/change.inf
index e7da4250..6a1923d2 100644
--- a/filesys/miniFilter/change/change.inf
+++ b/filesys/miniFilter/change/change.inf
Binary files differ
diff --git a/filesys/miniFilter/ctx/ctx.inf b/filesys/miniFilter/ctx/ctx.inf
index 8edaf764..bc637613 100644
--- a/filesys/miniFilter/ctx/ctx.inf
+++ b/filesys/miniFilter/ctx/ctx.inf
Binary files differ
diff --git a/filesys/miniFilter/delete/delete.inf b/filesys/miniFilter/delete/delete.inf
index da348874..e0c8c04c 100644
--- a/filesys/miniFilter/delete/delete.inf
+++ b/filesys/miniFilter/delete/delete.inf
Binary files differ
diff --git a/filesys/miniFilter/minispy/minispy.inf b/filesys/miniFilter/minispy/minispy.inf
index 60eb8684..a368bd75 100644
--- a/filesys/miniFilter/minispy/minispy.inf
+++ b/filesys/miniFilter/minispy/minispy.inf
Binary files differ
diff --git a/filesys/miniFilter/nullFilter/nullFilter.inf b/filesys/miniFilter/nullFilter/nullFilter.inf
index c04e9f06..1fffa028 100644
--- a/filesys/miniFilter/nullFilter/nullFilter.inf
+++ b/filesys/miniFilter/nullFilter/nullFilter.inf
Binary files differ
diff --git a/filesys/miniFilter/passThrough/passThrough.inf b/filesys/miniFilter/passThrough/passThrough.inf
index 129a2ab6..f77c3e4c 100644
--- a/filesys/miniFilter/passThrough/passThrough.inf
+++ b/filesys/miniFilter/passThrough/passThrough.inf
Binary files differ
diff --git a/filesys/miniFilter/scanner/scanner.inf b/filesys/miniFilter/scanner/scanner.inf
index d7bf6256..b7c3ac9e 100644
--- a/filesys/miniFilter/scanner/scanner.inf
+++ b/filesys/miniFilter/scanner/scanner.inf
Binary files differ
diff --git a/filesys/miniFilter/scanner/user/scanUser.c b/filesys/miniFilter/scanner/user/scanUser.c
index e766261c..08b948b3 100644
--- a/filesys/miniFilter/scanner/user/scanUser.c
+++ b/filesys/miniFilter/scanner/user/scanUser.c
@@ -254,8 +254,6 @@ Return Value
}
}
- free( message );
-
return hr;
}
@@ -268,13 +266,12 @@ main (
{
DWORD requestCount = SCANNER_DEFAULT_REQUEST_COUNT;
DWORD threadCount = SCANNER_DEFAULT_THREAD_COUNT;
- HANDLE threads[SCANNER_MAX_THREAD_COUNT];
+ HANDLE threads[SCANNER_MAX_THREAD_COUNT] = { NULL };
SCANNER_THREAD_CONTEXT context;
HANDLE port, completion;
- PSCANNER_MESSAGE msg;
+ PSCANNER_MESSAGE messages;
DWORD threadId;
HRESULT hr;
- DWORD i, j;
//
// Check how many threads and per thread requests are desired.
@@ -343,11 +340,23 @@ main (
context.Completion = completion;
//
- // Create specified number of threads.
+ // Allocate messages.
//
- for (i = 0; i < threadCount; i++) {
+ messages = calloc(((size_t) threadCount) * requestCount, sizeof(SCANNER_MESSAGE));
+
+ if (messages == NULL) {
+ hr = ERROR_NOT_ENOUGH_MEMORY;
+ goto main_cleanup;
+ }
+
+ //
+ // Create specified number of threads.
+ //
+
+ for (DWORD i = 0; i < threadCount; i++) {
+
threads[i] = CreateThread( NULL,
0,
(LPTHREAD_START_ROUTINE) ScannerWorker,
@@ -366,20 +375,9 @@ main (
goto main_cleanup;
}
- for (j = 0; j < requestCount; j++) {
-
- //
- // Allocate the message.
- //
-
-#pragma prefast(suppress:__WARNING_MEMORY_LEAK, "msg will not be leaked because it is freed in ScannerWorker")
- msg = malloc( sizeof( SCANNER_MESSAGE ) );
-
- if (msg == NULL) {
-
- hr = ERROR_NOT_ENOUGH_MEMORY;
- goto main_cleanup;
- }
+ for (DWORD j = 0; j < requestCount; j++) {
+
+ PSCANNER_MESSAGE msg = &(messages[i * requestCount + j]);
memset( &msg->Ovlp, 0, sizeof( OVERLAPPED ) );
@@ -393,24 +391,26 @@ main (
&msg->Ovlp );
if (hr != HRESULT_FROM_WIN32( ERROR_IO_PENDING )) {
-
- free( msg );
goto main_cleanup;
}
}
}
hr = S_OK;
-
- WaitForMultipleObjectsEx( i, threads, TRUE, INFINITE, FALSE );
-
+
main_cleanup:
+ for (INT i = 0; threads[i] != NULL; ++i) {
+ WaitForSingleObjectEx(threads[i], INFINITE, FALSE);
+ }
+
printf( "Scanner: All done. Result = 0x%08x\n", hr );
CloseHandle( port );
CloseHandle( completion );
+ free(messages);
+
return hr;
}
diff --git a/filesys/miniFilter/simrep/simrep.inf b/filesys/miniFilter/simrep/simrep.inf
index 8eea42ce..76aa1f0c 100644
--- a/filesys/miniFilter/simrep/simrep.inf
+++ b/filesys/miniFilter/simrep/simrep.inf
Binary files differ
diff --git a/filesys/miniFilter/swapBuffers/swapBuffers.inf b/filesys/miniFilter/swapBuffers/swapBuffers.inf
index 0aab9452..e5acbdd3 100644
--- a/filesys/miniFilter/swapBuffers/swapBuffers.inf
+++ b/filesys/miniFilter/swapBuffers/swapBuffers.inf
Binary files differ
diff --git a/general/DCHU/osrfx2_DCHU_base/osrfx2_DCHU_base/osrfx2_DCHU_base.inx b/general/DCHU/osrfx2_DCHU_base/osrfx2_DCHU_base/osrfx2_DCHU_base.inx
index 39bd5468..eca5c5cc 100644
--- a/general/DCHU/osrfx2_DCHU_base/osrfx2_DCHU_base/osrfx2_DCHU_base.inx
+++ b/general/DCHU/osrfx2_DCHU_base/osrfx2_DCHU_base/osrfx2_DCHU_base.inx
Binary files differ
diff --git a/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_component/osrfx2_DCHU_component.inx b/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_component/osrfx2_DCHU_component.inx
index 045fc91f..cc9e43a9 100644
--- a/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_component/osrfx2_DCHU_component.inx
+++ b/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_component/osrfx2_DCHU_component.inx
Binary files differ
diff --git a/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx b/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx
index a762b235..d824d08b 100644
--- a/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx
+++ b/general/DCHU/osrfx2_DCHU_extension_loose/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx
Binary files differ
diff --git a/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_component/osrfx2_DCHU_component.inx b/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_component/osrfx2_DCHU_component.inx
index 045fc91f..cc9e43a9 100644
--- a/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_component/osrfx2_DCHU_component.inx
+++ b/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_component/osrfx2_DCHU_component.inx
Binary files differ
diff --git a/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx b/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx
index 17670efa..a8f2a505 100644
--- a/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx
+++ b/general/DCHU/osrfx2_DCHU_extension_tight/osrfx2_DCHU_extension/osrfx2_DCHU_extension.inx
Binary files differ
diff --git a/general/PLX9x5x/sys/pci9x5x.inx b/general/PLX9x5x/sys/pci9x5x.inx
index 8fdb2eea..0d98041d 100644
--- a/general/PLX9x5x/sys/pci9x5x.inx
+++ b/general/PLX9x5x/sys/pci9x5x.inx
Binary files differ
diff --git a/general/SimpleMediaSource/SimpleMediaSourceDriver/SimpleMediaSourceDriver.inf b/general/SimpleMediaSource/SimpleMediaSourceDriver/SimpleMediaSourceDriver.inf
index d9f05402..aa21c882 100644
--- a/general/SimpleMediaSource/SimpleMediaSourceDriver/SimpleMediaSourceDriver.inf
+++ b/general/SimpleMediaSource/SimpleMediaSourceDriver/SimpleMediaSourceDriver.inf
Binary files differ
diff --git a/general/echo/kmdf/driver/AutoSync/echo.inx b/general/echo/kmdf/driver/AutoSync/echo.inx
index cd83b6c0..60be19a8 100644
--- a/general/echo/kmdf/driver/AutoSync/echo.inx
+++ b/general/echo/kmdf/driver/AutoSync/echo.inx
Binary files differ
diff --git a/general/echo/kmdf/driver/DriverSync/echo_2.inx b/general/echo/kmdf/driver/DriverSync/echo_2.inx
index b4cf3c25..73987894 100644
--- a/general/echo/kmdf/driver/DriverSync/echo_2.inx
+++ b/general/echo/kmdf/driver/DriverSync/echo_2.inx
Binary files differ
diff --git a/general/echo/umdf2/driver/AutoSync/echoum.inx b/general/echo/umdf2/driver/AutoSync/echoum.inx
index 00320858..9962e6c2 100644
--- a/general/echo/umdf2/driver/AutoSync/echoum.inx
+++ b/general/echo/umdf2/driver/AutoSync/echoum.inx
Binary files differ
diff --git a/general/ioctl/kmdf/exe/install.c b/general/ioctl/kmdf/exe/install.c
index 7060243a..ed2aa6e8 100644
--- a/general/ioctl/kmdf/exe/install.c
+++ b/general/ioctl/kmdf/exe/install.c
@@ -22,101 +22,44 @@ Environment:
--*/
-#include <DriverSpecs.h>
-_Analysis_mode_(_Analysis_code_type_user_code_)
-
#include <windows.h>
-#include <strsafe.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
+#include <strsafe.h>
#include "public.h"
-#include <wdfinstaller.h>
-
-#define ARRAY_SIZE(x) (sizeof(x) /sizeof(x[0]))
-
-extern
-PCHAR
-GetCoinstallerVersion(
- VOID
- ) ;
-
BOOLEAN
InstallDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName,
- IN LPCTSTR ServiceExe
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName,
+ _In_ LPCTSTR ServiceExe
);
BOOLEAN
RemoveDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName
);
BOOLEAN
StartDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName
);
BOOLEAN
StopDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName
);
-#define SYSTEM32_DRIVERS "\\System32\\Drivers\\"
-#define NONPNP_INF_FILENAME L"\\nonpnp.inf"
-#define WDF_SECTION_NAME L"nonpnp.NT.Wdf"
-
-//----------------------------------------------------------------------------
-//
-//----------------------------------------------------------------------------
-PFN_WDFPREDEVICEINSTALLEX pfnWdfPreDeviceInstallEx;
-PFN_WDFPOSTDEVICEINSTALL pfnWdfPostDeviceInstall;
-PFN_WDFPREDEVICEREMOVE pfnWdfPreDeviceRemove;
-PFN_WDFPOSTDEVICEREMOVE pfnWdfPostDeviceRemove;
-
-//-----------------------------------------------------------------------------
-// 4127 -- Conditional Expression is Constant warning
-//-----------------------------------------------------------------------------
-#define WHILE(a) \
-__pragma(warning(suppress:4127)) while(a)
-
-LONG
-GetPathToInf(
- _Out_writes_(InfFilePathSize) PWCHAR InfFilePath,
- IN ULONG InfFilePathSize
- )
-{
- LONG error = ERROR_SUCCESS;
-
- if (GetCurrentDirectoryW(InfFilePathSize, InfFilePath) == 0) {
- error = GetLastError();
- printf("InstallDriver failed! Error = %d \n", error);
- return error;
- }
- if (FAILED( StringCchCatW(InfFilePath,
- InfFilePathSize,
- NONPNP_INF_FILENAME) )) {
- error = ERROR_BUFFER_OVERFLOW;
- return error;
- }
- return error;
-
-}
-
-//----------------------------------------------------------------------------
-//
-//----------------------------------------------------------------------------
BOOLEAN
InstallDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName,
- IN LPCTSTR ServiceExe
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName,
+ _In_ LPCTSTR ServiceExe
)
/*++
@@ -130,10 +73,6 @@ Return Value:
{
SC_HANDLE schService;
DWORD err;
- WCHAR infPath[MAX_PATH];
- WDF_COINSTALLER_INSTALL_OPTIONS clientOptions;
-
- WDF_COINSTALLER_INSTALL_OPTIONS_INIT(&clientOptions);
//
// NOTE: This creates an entry for a standalone driver. If this
@@ -142,22 +81,6 @@ Return Value:
// query the registry for existing driver information
// (in order to determine a unique Tag, etc.).
//
- //
- // PRE-INSTALL for WDF support
- //
- err = GetPathToInf(infPath, ARRAY_SIZE(infPath) );
- if (err != ERROR_SUCCESS) {
- return FALSE;
- }
- err = pfnWdfPreDeviceInstallEx(infPath, WDF_SECTION_NAME, &clientOptions);
-
- if (err != ERROR_SUCCESS) {
- if (err == ERROR_SUCCESS_REBOOT_REQUIRED) {
- printf("System needs to be rebooted, before the driver installation can proceed.\n");
- }
-
- return FALSE;
- }
//
// Create a new a service object.
@@ -205,15 +128,10 @@ Return Value:
//
// Close the service object.
//
- CloseServiceHandle(schService);
- //
- // POST-INSTALL for WDF support
- //
- err = pfnWdfPostDeviceInstall( infPath, WDF_SECTION_NAME );
+ if (schService) {
- if (err != ERROR_SUCCESS) {
- return FALSE;
+ CloseServiceHandle(schService);
}
//
@@ -226,9 +144,9 @@ Return Value:
BOOLEAN
ManageDriver(
- IN LPCTSTR DriverName,
- IN LPCTSTR ServiceName,
- IN USHORT Function
+ _In_ LPCTSTR DriverName,
+ _In_ LPCTSTR ServiceName,
+ _In_ USHORT Function
)
{
@@ -337,7 +255,11 @@ ManageDriver(
//
// Close handle to service control manager.
//
- CloseServiceHandle(schSCManager);
+
+ if (schSCManager) {
+
+ CloseServiceHandle(schSCManager);
+ }
return rCode;
@@ -346,28 +268,12 @@ ManageDriver(
BOOLEAN
RemoveDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName
)
{
SC_HANDLE schService;
BOOLEAN rCode;
- DWORD err;
- WCHAR infPath[MAX_PATH];
-
- err = GetPathToInf(infPath, ARRAY_SIZE(infPath) );
- if (err != ERROR_SUCCESS) {
- return FALSE;
- }
-
- //
- // PRE-REMOVE of WDF support
- //
- err = pfnWdfPreDeviceRemove( infPath, WDF_SECTION_NAME );
-
- if (err != ERROR_SUCCESS) {
- return FALSE;
- }
//
// Open the handle to the existing service.
@@ -415,15 +321,10 @@ RemoveDriver(
//
// Close the service object.
//
- CloseServiceHandle(schService);
- //
- // POST-REMOVE of WDF support
- //
- err = pfnWdfPostDeviceRemove(infPath, WDF_SECTION_NAME );
+ if (schService) {
- if (err != ERROR_SUCCESS) {
- rCode = FALSE;
+ CloseServiceHandle(schService);
}
return rCode;
@@ -434,59 +335,73 @@ RemoveDriver(
BOOLEAN
StartDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName
)
{
SC_HANDLE schService;
DWORD err;
- BOOL ok;
//
// Open the handle to the existing service.
//
+
schService = OpenService(SchSCManager,
DriverName,
SERVICE_ALL_ACCESS
);
if (schService == NULL) {
+
+ printf("OpenService failed! Error = %d \n", GetLastError());
+
//
// Indicate failure.
//
- printf("OpenService failed! Error = %d\n", GetLastError());
+
return FALSE;
}
//
// Start the execution of the service (i.e. start the driver).
//
- ok = StartService( schService, 0, NULL );
- if (!ok) {
+ if (!StartService(schService, // service identifier
+ 0, // number of arguments
+ NULL // pointer to arguments
+ )) {
err = GetLastError();
if (err == ERROR_SERVICE_ALREADY_RUNNING) {
+
//
// Ignore this error.
//
+
return TRUE;
} else {
+
+ printf("StartService failure! Error = %d \n", err );
+
//
- // Indicate failure.
- // Fall through to properly close the service handle.
+ // Indicate failure. Fall through to properly close the service handle.
//
- printf("StartService failure! Error = %d\n", err );
+
return FALSE;
}
+
}
//
// Close the service object.
//
- CloseServiceHandle(schService);
+
+ if (schService) {
+
+ CloseServiceHandle(schService);
+ }
return TRUE;
@@ -496,8 +411,8 @@ StartDriver(
BOOLEAN
StopDriver(
- IN SC_HANDLE SchSCManager,
- IN LPCTSTR DriverName
+ _In_ SC_HANDLE SchSCManager,
+ _In_ LPCTSTR DriverName
)
{
BOOLEAN rCode = TRUE;
@@ -549,264 +464,87 @@ StopDriver(
//
// Close the service object.
//
- CloseServiceHandle (schService);
-
- return rCode;
-
-} // StopDriver
-
-
-//
-// Caller must free returned pathname string.
-//
-PCHAR
-BuildDriversDirPath(
- _In_ PSTR DriverName
- )
-{
- size_t remain;
- size_t len;
- PCHAR dir;
-
- if (!DriverName || strlen(DriverName) == 0) {
- return NULL;
- }
-
- remain = MAX_PATH;
-
- //
- // Allocate string space
- //
- dir = (PCHAR) malloc( remain + 1 );
-
- if (!dir) {
- return NULL;
- }
-
- //
- // Get the base windows directory path.
- //
- len = GetWindowsDirectory( dir, (UINT) remain );
-
- if (len == 0 ||
- (remain - len) < sizeof(SYSTEM32_DRIVERS)) {
- free(dir);
- return NULL;
- }
- remain -= len;
- //
- // Build dir to have "%windir%\System32\Drivers\<DriverName>".
- //
- if (FAILED( StringCchCat(dir, remain, SYSTEM32_DRIVERS) )) {
- free(dir);
- return NULL;
- }
-
- remain -= sizeof(SYSTEM32_DRIVERS);
- len += sizeof(SYSTEM32_DRIVERS);
- len += strlen(DriverName);
-
- if (remain < len) {
- free(dir);
- return NULL;
- }
+ if (schService) {
- if (FAILED( StringCchCat(dir, remain, DriverName) )) {
- free(dir);
- return NULL;
+ CloseServiceHandle (schService);
}
- dir[len] = '\0'; // keeps prefast happy
-
- return dir;
-}
+ return rCode;
+} // StopDriver
BOOLEAN
SetupDriverName(
- _Inout_updates_all_(BufferLength) PCHAR DriverLocation,
+ _Inout_updates_bytes_all_(BufferLength) PCHAR DriverLocation,
_In_ ULONG BufferLength
)
{
HANDLE fileHandle;
- DWORD driverLocLen = 0;
- BOOL ok;
- PCHAR driversDir;
+ DWORD driverLocLen = 0;
//
- // Setup path name to driver file.
+ // Get the current directory.
//
- driverLocLen =
- GetCurrentDirectory(BufferLength, DriverLocation);
- if (!driverLocLen) {
+ driverLocLen = GetCurrentDirectory(BufferLength,
+ DriverLocation
+ );
- printf("GetCurrentDirectory failed! Error = %d \n",
- GetLastError());
+ if (driverLocLen == 0) {
- return FALSE;
- }
+ printf("GetCurrentDirectory failed! Error = %d \n", GetLastError());
- if (FAILED( StringCchCat(DriverLocation, BufferLength, "\\" DRIVER_NAME ".sys") )) {
return FALSE;
}
//
- // Insure driver file is in the specified directory.
+ // Setup path name to driver file.
//
- fileHandle = CreateFile( DriverLocation,
- GENERIC_READ,
- FILE_SHARE_READ,
- NULL,
- OPEN_EXISTING,
- FILE_ATTRIBUTE_NORMAL,
- NULL );
-
- if (fileHandle == INVALID_HANDLE_VALUE) {
- //
- // Indicate failure.
- //
- printf("Driver: %s.SYS is not in the %s directory. \n",
- DRIVER_NAME, DriverLocation );
+ if (FAILED( StringCbCat(DriverLocation, BufferLength, "\\"DRIVER_NAME".sys") )) {
return FALSE;
}
//
- // Build %windir%\System32\Drivers\<DRIVER_NAME> path.
- // Copy the driver to %windir%\system32\drivers
+ // Insure driver file is in the specified directory.
//
- driversDir = BuildDriversDirPath( DRIVER_NAME ".sys" );
- if (!driversDir) {
- printf("BuildDriversDirPath failed!\n");
- return FALSE;
- }
+ if ((fileHandle = CreateFile(DriverLocation,
+ GENERIC_READ,
+ 0,
+ NULL,
+ OPEN_EXISTING,
+ FILE_ATTRIBUTE_NORMAL,
+ NULL
+ )) == INVALID_HANDLE_VALUE) {
- ok = CopyFile( DriverLocation, driversDir, FALSE );
- if(!ok) {
- printf("CopyFile failed: error(%d) - \"%s\"\n",
- GetLastError(), driversDir );
- free(driversDir);
- return FALSE;
- }
+ printf("%s.sys is not loaded.\n", DRIVER_NAME);
+
+ //
+ // Indicate failure.
+ //
- if (FAILED( StringCchCopy(DriverLocation, BufferLength, driversDir) )) {
- free(driversDir);
return FALSE;
}
- free(driversDir);
-
//
// Close open file handle.
//
+
if (fileHandle) {
+
CloseHandle(fileHandle);
}
//
// Indicate success.
//
- return TRUE;
-
-} // SetupDriverName
+ return TRUE;
-HMODULE
-LoadWdfCoInstaller(
- VOID
- )
-{
- HMODULE library = NULL;
- DWORD error = ERROR_SUCCESS;
- CHAR szCurDir[MAX_PATH];
- CHAR tempCoinstallerName[MAX_PATH];
- PCHAR coinstallerVersion;
-
- do {
-
- if (GetCurrentDirectory(MAX_PATH, szCurDir) == 0) {
-
- printf("GetCurrentDirectory failed! Error = %d \n", GetLastError());
- break;
- }
- coinstallerVersion = GetCoinstallerVersion();
- if (FAILED( StringCchPrintf(tempCoinstallerName,
- MAX_PATH,
- "\\WdfCoInstaller%s.dll",
- coinstallerVersion) )) {
- break;
- }
- if (FAILED( StringCchCat(szCurDir, MAX_PATH, tempCoinstallerName) )) {
- break;
- }
-
- library = LoadLibrary(szCurDir);
-
- if (library == NULL) {
- error = GetLastError();
- printf("LoadLibrary(%s) failed: %d\n", szCurDir, error);
- break;
- }
-
- pfnWdfPreDeviceInstallEx =
- (PFN_WDFPREDEVICEINSTALLEX) GetProcAddress( library, "WdfPreDeviceInstallEx" );
-
- if (pfnWdfPreDeviceInstallEx == NULL) {
- error = GetLastError();
- printf("GetProcAddress(\"WdfPreDeviceInstallEx\") failed: %d\n", error);
- return NULL;
- }
-
- pfnWdfPostDeviceInstall =
- (PFN_WDFPOSTDEVICEINSTALL) GetProcAddress( library, "WdfPostDeviceInstall" );
-
- if (pfnWdfPostDeviceInstall == NULL) {
- error = GetLastError();
- printf("GetProcAddress(\"WdfPostDeviceInstall\") failed: %d\n", error);
- return NULL;
- }
-
- pfnWdfPreDeviceRemove =
- (PFN_WDFPREDEVICEREMOVE) GetProcAddress( library, "WdfPreDeviceRemove" );
-
- if (pfnWdfPreDeviceRemove == NULL) {
- error = GetLastError();
- printf("GetProcAddress(\"WdfPreDeviceRemove\") failed: %d\n", error);
- return NULL;
- }
-
- pfnWdfPostDeviceRemove =
- (PFN_WDFPREDEVICEREMOVE) GetProcAddress( library, "WdfPostDeviceRemove" );
-
- if (pfnWdfPostDeviceRemove == NULL) {
- error = GetLastError();
- printf("GetProcAddress(\"WdfPostDeviceRemove\") failed: %d\n", error);
- return NULL;
- }
-
- } WHILE (0);
-
- if (error != ERROR_SUCCESS) {
- if (library) {
- FreeLibrary( library );
- }
- library = NULL;
- }
- return library;
-}
+} // SetupDriverName
-VOID
-UnloadWdfCoInstaller(
- HMODULE Library
- )
-{
- if (Library) {
- FreeLibrary( Library );
- }
-}
diff --git a/general/ioctl/kmdf/exe/nonpnp.inf b/general/ioctl/kmdf/exe/nonpnp.inf
deleted file mode 100644
index b20a58b4..00000000
--- a/general/ioctl/kmdf/exe/nonpnp.inf
+++ /dev/null
@@ -1,8 +0,0 @@
-[Version]
-Signature="$WINDOWS NT$"
-
-[nonpnp.NT.Wdf]
-KmdfService = nonpnp, nonpnp_Service_kmdfInst
-
-[nonpnp_Service_kmdfInst]
-KmdfLibraryVersion = 1.11
diff --git a/general/ioctl/kmdf/exe/testapp.c b/general/ioctl/kmdf/exe/testapp.c
index 6586401e..492c6355 100644
--- a/general/ioctl/kmdf/exe/testapp.c
+++ b/general/ioctl/kmdf/exe/testapp.c
@@ -54,16 +54,6 @@ ManageDriver(
IN USHORT Function
);
-HMODULE
-LoadWdfCoInstaller(
- VOID
- );
-
-VOID
-UnloadWdfCoInstaller(
- HMODULE Library
- );
-
BOOLEAN
SetupDriverName(
_Inout_updates_all_(BufferLength) PCHAR DriverLocation,
@@ -80,14 +70,7 @@ DoIoctls(
HANDLE hDevice
);
-// for example, WDF 1.9 is "01009". the size 6 includes the ending NULL marker
-//
-#define MAX_VERSION_SIZE 6
-
-CHAR G_coInstallerVersion[MAX_VERSION_SIZE] = {0};
BOOLEAN G_fLoop = FALSE;
-BOOL G_versionSpecified = FALSE;
-
//-----------------------------------------------------------------------------
@@ -98,30 +81,9 @@ __pragma(warning(disable: 4127)) while(constant); __pragma(warning(default: 4127
#define USAGE \
-"Usage: nonpnpapp <-V version> <-l> \n" \
- " -V version {if no version is specified the version specified in the build environment will be used.}\n" \
- " The version is the version of the KMDF coinstaller to use \n" \
- " The format of version is MMmmm where MM -- major #, mmm - serial# \n" \
+"Usage: nonpnpapp <-l> \n" \
" -l { option to continuously read & write to the file} \n"
-BOOL
-ValidateCoinstallerVersion(
- _In_ PSTR Version
- )
-{ BOOL ok = FALSE;
- INT i;
-
- for(i= 0; i<MAX_VERSION_SIZE ;i++){
- if( ! IsCharAlphaNumericA(Version[i])) {
- break;
- }
- }
- if (i == (MAX_VERSION_SIZE -sizeof(CHAR))) {
- ok = TRUE;
- }
- return ok;
-}
-
LONG
Parse(
_In_ int argc,
@@ -143,42 +105,12 @@ Return Value:
--*/
{
int i;
- BOOL ok;
LONG error = ERROR_SUCCESS;
for (i=0; i<argc; i++) {
if (argv[i][0] == '-' ||
argv[i][0] == '/') {
switch(argv[i][1]) {
- case 'V':
- case 'v':
- if (( (i+1 < argc ) &&
- ( argv[i+1][0] != '-' && argv[i+1][0] != '/'))) {
- //
- // use version in commandline
- //
- i++;
- ok = ValidateCoinstallerVersion(argv[i]);
- if (!ok) {
- printf("Not a valid format for coinstaller version\n"
- "It should be characters between A-Z, a-z , 0-9\n"
- "The version format is MMmmm where MM -- major #, mmm - serial#");
- error = ERROR_INVALID_PARAMETER;
- break;
- }
- if (FAILED( StringCchCopy(G_coInstallerVersion,
- MAX_VERSION_SIZE,
- argv[i]) )) {
- break;
- }
- G_versionSpecified = TRUE;
-
- }
- else{
- printf(USAGE);
- error = ERROR_INVALID_PARAMETER;
- }
- break;
case 'l':
case 'L':
G_fLoop = TRUE;
@@ -193,24 +125,6 @@ Return Value:
return error;
}
-PCHAR
-GetCoinstallerVersion(
- VOID
- )
-{
- if (!G_versionSpecified &&
- FAILED( StringCchPrintf(G_coInstallerVersion,
- MAX_VERSION_SIZE,
- "%02d%03d", // for example, "01009"
- KMDF_VERSION_MAJOR,
- KMDF_VERSION_MINOR)))
- {
- printf("StringCchCopy failed with error \n");
- }
-
- return (PCHAR)&G_coInstallerVersion;
-}
-
VOID __cdecl
main(
_In_ ULONG argc,
@@ -221,9 +135,7 @@ main(
DWORD errNum = 0;
CHAR driverLocation [MAX_PATH];
BOOL ok;
- HMODULE library = NULL;
LONG error;
- PCHAR coinstallerVersion;
//
// Parse command line args
@@ -236,19 +148,6 @@ main(
}
}
- if (!G_versionSpecified ) {
- coinstallerVersion = GetCoinstallerVersion();
-
- //
- // if no version is specified or an invalid one is specified use default version
- //
- printf("No version specified. Using default version:%s\n",
- coinstallerVersion);
-
- } else {
- coinstallerVersion = (PCHAR)&G_coInstallerVersion;
- }
-
//
// open the device
//
@@ -273,17 +172,6 @@ main(
}
//
- // Load WdfCoInstaller.dll.
- //
- library = LoadWdfCoInstaller();
-
- if (library == NULL) {
- printf("The WdfCoInstaller%s.dll library needs to be "
- "in same directory as nonpnpapp.exe\n", coinstallerVersion);
- return;
- }
-
- //
// The driver is not started yet so let us install the driver.
// First setup full path to driver name.
//
@@ -351,12 +239,6 @@ main(
driverLocation,
DRIVER_FUNC_REMOVE );
- //
- // Unload WdfCoInstaller.dll
- //
- if ( library ) {
- UnloadWdfCoInstaller( library );
- }
return;
}
diff --git a/general/pcidrv/kmdf/genpci.inx b/general/pcidrv/kmdf/genpci.inx
index f8581414..1c474ca2 100644
--- a/general/pcidrv/kmdf/genpci.inx
+++ b/general/pcidrv/kmdf/genpci.inx
Binary files differ
diff --git a/general/toaster/toastDrv/kmdf/bus/dynamic/dynambus.inx b/general/toaster/toastDrv/kmdf/bus/dynamic/dynambus.inx
index f557b6e3..e42b1969 100644
--- a/general/toaster/toastDrv/kmdf/bus/dynamic/dynambus.inx
+++ b/general/toaster/toastDrv/kmdf/bus/dynamic/dynambus.inx
Binary files differ
diff --git a/general/toaster/toastDrv/kmdf/bus/static/statbus.inx b/general/toaster/toastDrv/kmdf/bus/static/statbus.inx
index 094bce09..8f433735 100644
--- a/general/toaster/toastDrv/kmdf/bus/static/statbus.inx
+++ b/general/toaster/toastDrv/kmdf/bus/static/statbus.inx
Binary files differ
diff --git a/general/toaster/toastDrv/kmdf/filter/filter.inx b/general/toaster/toastDrv/kmdf/filter/filter.inx
index 8a2ca006..31c6cf93 100644
--- a/general/toaster/toastDrv/kmdf/filter/filter.inx
+++ b/general/toaster/toastDrv/kmdf/filter/filter.inx
Binary files differ
diff --git a/general/toaster/toastDrv/kmdf/func/featured/wdffeatured.inx b/general/toaster/toastDrv/kmdf/func/featured/wdffeatured.inx
index b91edc1b..7310ceb2 100644
--- a/general/toaster/toastDrv/kmdf/func/featured/wdffeatured.inx
+++ b/general/toaster/toastDrv/kmdf/func/featured/wdffeatured.inx
Binary files differ
diff --git a/general/toaster/toastDrv/kmdf/func/simple/wdfsimple.inx b/general/toaster/toastDrv/kmdf/func/simple/wdfsimple.inx
index 549f20e1..203e251f 100644
--- a/general/toaster/toastDrv/kmdf/func/simple/wdfsimple.inx
+++ b/general/toaster/toastDrv/kmdf/func/simple/wdfsimple.inx
Binary files differ
diff --git a/general/toaster/toastDrv/kmdf/toastmon/wdftoastmon.inx b/general/toaster/toastDrv/kmdf/toastmon/wdftoastmon.inx
index 0c1a410b..384344c0 100644
--- a/general/toaster/toastDrv/kmdf/toastmon/wdftoastmon.inx
+++ b/general/toaster/toastDrv/kmdf/toastmon/wdftoastmon.inx
Binary files differ
diff --git a/general/toaster/umdf2/filter/generic/filterum.inx b/general/toaster/umdf2/filter/generic/filterum.inx
index e7e04b65..fad4882d 100644
--- a/general/toaster/umdf2/filter/generic/filterum.inx
+++ b/general/toaster/umdf2/filter/generic/filterum.inx
Binary files differ
diff --git a/general/toaster/umdf2/func/featured/wdffeaturedum.inx b/general/toaster/umdf2/func/featured/wdffeaturedum.inx
index 7b5f9c07..f93fcf91 100644
--- a/general/toaster/umdf2/func/featured/wdffeaturedum.inx
+++ b/general/toaster/umdf2/func/featured/wdffeaturedum.inx
Binary files differ
diff --git a/general/toaster/umdf2/func/simple/wdfsimpleum.inx b/general/toaster/umdf2/func/simple/wdfsimpleum.inx
index e07cf3a1..10f52074 100644
--- a/general/toaster/umdf2/func/simple/wdfsimpleum.inx
+++ b/general/toaster/umdf2/func/simple/wdfsimpleum.inx
Binary files differ
diff --git a/gnss/gnssUmdf/gnssUmdf.inf b/gnss/gnssUmdf/gnssUmdf.inf
index b7f3363e..e3815c9e 100644
--- a/gnss/gnssUmdf/gnssUmdf.inf
+++ b/gnss/gnssUmdf/gnssUmdf.inf
Binary files differ
diff --git a/gpio/samples/simdevice/kmdf/simdevice.inx b/gpio/samples/simdevice/kmdf/simdevice.inx
index c758f27a..cdb02c81 100644
--- a/gpio/samples/simdevice/kmdf/simdevice.inx
+++ b/gpio/samples/simdevice/kmdf/simdevice.inx
Binary files differ
diff --git a/gpio/samples/simdevice/umdf/simdeviceumdf.inx b/gpio/samples/simdevice/umdf/simdeviceumdf.inx
index 587cd604..1cfda2e7 100644
--- a/gpio/samples/simdevice/umdf/simdeviceumdf.inx
+++ b/gpio/samples/simdevice/umdf/simdeviceumdf.inx
Binary files differ
diff --git a/gpio/samples/simgpio/simgpio.inx b/gpio/samples/simgpio/simgpio.inx
index fd8a4c18..7cd926a1 100644
--- a/gpio/samples/simgpio/simgpio.inx
+++ b/gpio/samples/simgpio/simgpio.inx
Binary files differ
diff --git a/gpio/samples/simgpio_i2c/simgpio_i2c.inx b/gpio/samples/simgpio_i2c/simgpio_i2c.inx
index 7706cfbf..e57a67d3 100644
--- a/gpio/samples/simgpio_i2c/simgpio_i2c.inx
+++ b/gpio/samples/simgpio_i2c/simgpio_i2c.inx
Binary files differ
diff --git a/hid/firefly/driver/firefly.inx b/hid/firefly/driver/firefly.inx
index caab90fc..aec3a013 100644
--- a/hid/firefly/driver/firefly.inx
+++ b/hid/firefly/driver/firefly.inx
Binary files differ
diff --git a/hid/hidusbfx2/sys/hidusbfx2.inx b/hid/hidusbfx2/sys/hidusbfx2.inx
index f45b9708..b4944828 100644
--- a/hid/hidusbfx2/sys/hidusbfx2.inx
+++ b/hid/hidusbfx2/sys/hidusbfx2.inx
Binary files differ
diff --git a/hid/vhidmini2/driver/kmdf/vhidmini.inx b/hid/vhidmini2/driver/kmdf/vhidmini.inx
index e126977f..98ad43ec 100644
--- a/hid/vhidmini2/driver/kmdf/vhidmini.inx
+++ b/hid/vhidmini2/driver/kmdf/vhidmini.inx
Binary files differ
diff --git a/hid/vhidmini2/driver/umdf2/VhidminiUm.inx b/hid/vhidmini2/driver/umdf2/VhidminiUm.inx
index aa617a3f..92cdd4b9 100644
--- a/hid/vhidmini2/driver/umdf2/VhidminiUm.inx
+++ b/hid/vhidmini2/driver/umdf2/VhidminiUm.inx
Binary files differ
diff --git a/input/kbfiltr/sys/kbfiltr.inx b/input/kbfiltr/sys/kbfiltr.inx
index 1412bc67..c489caf0 100644
--- a/input/kbfiltr/sys/kbfiltr.inx
+++ b/input/kbfiltr/sys/kbfiltr.inx
Binary files differ
diff --git a/input/moufiltr/moufiltr.inx b/input/moufiltr/moufiltr.inx
index c3cf47c4..92aea951 100644
--- a/input/moufiltr/moufiltr.inx
+++ b/input/moufiltr/moufiltr.inx
Binary files differ
diff --git a/network/modem/fakemodem/mdmfake.inx b/network/modem/fakemodem/mdmfake.inx
index ea95a9ad..29629983 100644
--- a/network/modem/fakemodem/mdmfake.inx
+++ b/network/modem/fakemodem/mdmfake.inx
Binary files differ
diff --git a/network/ndis/extension/samples/forward/msforwardext.inf b/network/ndis/extension/samples/forward/msforwardext.inf
index 4af1b0fb..be4d37dc 100644
--- a/network/ndis/extension/samples/forward/msforwardext.inf
+++ b/network/ndis/extension/samples/forward/msforwardext.inf
Binary files differ
diff --git a/network/ndis/extension/samples/passthrough/mspassthroughext.inf b/network/ndis/extension/samples/passthrough/mspassthroughext.inf
index 8339e7c8..71ecfbe8 100644
--- a/network/ndis/extension/samples/passthrough/mspassthroughext.inf
+++ b/network/ndis/extension/samples/passthrough/mspassthroughext.inf
Binary files differ
diff --git a/network/ndis/filter/netlwf.inf b/network/ndis/filter/netlwf.inf
index e59b56fb..42a80912 100644
--- a/network/ndis/filter/netlwf.inf
+++ b/network/ndis/filter/netlwf.inf
Binary files differ
diff --git a/network/ndis/mux/driver/60/mux_mp.inf b/network/ndis/mux/driver/60/mux_mp.inf
index f216ac16..5c0944bb 100644
--- a/network/ndis/mux/driver/60/mux_mp.inf
+++ b/network/ndis/mux/driver/60/mux_mp.inf
Binary files differ
diff --git a/network/ndis/mux/driver/60/muxp.inf b/network/ndis/mux/driver/60/muxp.inf
index f9c4c04e..ea09e77d 100644
--- a/network/ndis/mux/driver/60/muxp.inf
+++ b/network/ndis/mux/driver/60/muxp.inf
Binary files differ
diff --git a/network/ndis/ndisprot/6x/sys/60/ndisprot60.inf b/network/ndis/ndisprot/6x/sys/60/ndisprot60.inf
index bae3936c..7022c0e6 100644
--- a/network/ndis/ndisprot/6x/sys/60/ndisprot60.inf
+++ b/network/ndis/ndisprot/6x/sys/60/ndisprot60.inf
Binary files differ
diff --git a/network/ndis/ndisprot/6x/sys/630/ndisprot630.inf b/network/ndis/ndisprot/6x/sys/630/ndisprot630.inf
index c5d7adb6..6a3e7da1 100644
--- a/network/ndis/ndisprot/6x/sys/630/ndisprot630.inf
+++ b/network/ndis/ndisprot/6x/sys/630/ndisprot630.inf
Binary files differ
diff --git a/network/ndis/ndisprot_kmdf/60/ndisprot.inx b/network/ndis/ndisprot_kmdf/60/ndisprot.inx
index ecd932c1..1c5762f1 100644
--- a/network/ndis/ndisprot_kmdf/60/ndisprot.inx
+++ b/network/ndis/ndisprot_kmdf/60/ndisprot.inx
Binary files differ
diff --git a/network/ndis/netvmini/6x/60/netvmini60.inf b/network/ndis/netvmini/6x/60/netvmini60.inf
index 63382e9b..31361685 100644
--- a/network/ndis/netvmini/6x/60/netvmini60.inf
+++ b/network/ndis/netvmini/6x/60/netvmini60.inf
Binary files differ
diff --git a/network/ndis/netvmini/6x/620/netvmini620.inf b/network/ndis/netvmini/6x/620/netvmini620.inf
index 4dc1c9b6..f2ece226 100644
--- a/network/ndis/netvmini/6x/620/netvmini620.inf
+++ b/network/ndis/netvmini/6x/620/netvmini620.inf
Binary files differ
diff --git a/network/ndis/netvmini/6x/630/netvmini630.inf b/network/ndis/netvmini/6x/630/netvmini630.inf
index eb7d61c8..40db5135 100644
--- a/network/ndis/netvmini/6x/630/netvmini630.inf
+++ b/network/ndis/netvmini/6x/630/netvmini630.inf
Binary files differ
diff --git a/network/ndis/netvmini/6x/680/netvmini680.inf b/network/ndis/netvmini/6x/680/netvmini680.inf
index 4160c520..5da91049 100644
--- a/network/ndis/netvmini/6x/680/netvmini680.inf
+++ b/network/ndis/netvmini/6x/680/netvmini680.inf
Binary files differ
diff --git a/network/trans/inspect/sys/inspect.inf b/network/trans/inspect/sys/inspect.inf
index cf7f7e76..1a1aa466 100644
--- a/network/trans/inspect/sys/inspect.inf
+++ b/network/trans/inspect/sys/inspect.inf
Binary files differ
diff --git a/network/trans/msnmntr/sys/msnmntr.inf b/network/trans/msnmntr/sys/msnmntr.inf
index 38589761..e3ec3563 100644
--- a/network/trans/msnmntr/sys/msnmntr.inf
+++ b/network/trans/msnmntr/sys/msnmntr.inf
Binary files differ
diff --git a/network/wlan/WDI/PLATFORM/WinInf/SDIO/x64/netrtwlans.inf b/network/wlan/WDI/PLATFORM/WinInf/SDIO/x64/netrtwlans.inf
index e7753ef3..4640bc85 100644
--- a/network/wlan/WDI/PLATFORM/WinInf/SDIO/x64/netrtwlans.inf
+++ b/network/wlan/WDI/PLATFORM/WinInf/SDIO/x64/netrtwlans.inf
Binary files differ
diff --git a/network/wwan/cxwmbclass/cxwmbclass/cxwmbclass.inf b/network/wwan/cxwmbclass/cxwmbclass/cxwmbclass.inf
index 48f893c6..496e5c6a 100644
--- a/network/wwan/cxwmbclass/cxwmbclass/cxwmbclass.inf
+++ b/network/wwan/cxwmbclass/cxwmbclass/cxwmbclass.inf
Binary files differ
diff --git a/network/wwan/cxwmbclass/datapipe.cpp b/network/wwan/cxwmbclass/datapipe.cpp
index 4452b761..b753a9e9 100644
--- a/network/wwan/cxwmbclass/datapipe.cpp
+++ b/network/wwan/cxwmbclass/datapipe.cpp
@@ -428,6 +428,7 @@ MbbBusWriteData(__in MBB_BUS_HANDLE BusHandle, __in MBB_REQUEST_HANDLE RequestHa
WDFMEMORY BufferMemoryObject = NULL;
WDFREQUEST WriteRequestZLP = NULL;
PUSB_WRITE_REQ_CONTEXT writeContextZLP = NULL;
+ NTSTATUS ZlpStatus;
usbDeviceContext = GetUsbDeviceContext(BusObject->WdfUsbDevice);
@@ -641,7 +642,7 @@ MbbBusWriteData(__in MBB_BUS_HANDLE BusHandle, __in MBB_REQUEST_HANDLE RequestHa
if (WriteRequestZLP != NULL)
{
- NTSTATUS ZlpStatus;
+
Status = WdfUsbTargetPipeFormatRequestForWrite(usbDeviceContext->BulkOutputPipe, WriteRequestZLP, NULL, NULL);
if (!NT_SUCCESS(Status))
@@ -696,6 +697,7 @@ Cleanup:
if (WriteRequestZLP != NULL)
{
+ Status = ZlpStatus;
FreeWriteRequest(BusObject->WdfUsbDevice, WriteRequestZLP);
WriteRequestZLP = NULL;
}
diff --git a/network/wwan/cxwmbclass/inc/util.h b/network/wwan/cxwmbclass/inc/util.h
index 12d166b4..e55c07e0 100644
--- a/network/wwan/cxwmbclass/inc/util.h
+++ b/network/wwan/cxwmbclass/inc/util.h
@@ -2,14 +2,12 @@
// Copyright (C) Microsoft. All rights reserved.
//
#pragma once
-typedef enum
-{
- MbbPoolTagDefault = '0CBM',
- MbbPoolTagNtbSend = '1CBM',
- MbbPoolTagNblSend = '2CBM',
- MbbPoolTagNbSend = '3CBM',
- MbbPoolTagMdlReceive = '6CBM'
-} MBB_POOL_TAG;
+
+#define MbbPoolTagDefault '0CBM'
+#define MbbPoolTagNtbSend '1CBM'
+#define MbbPoolTagNblSend '2CBM'
+#define MbbPoolTagNbSend '3CBM'
+#define MbbPoolTagMdlReceive '6CBM'
#define ALLOCATE_PAGED_POOL(_y) ExAllocatePool2(POOL_FLAG_PAGED, _y, MbbPoolTagDefault)
#define ALLOCATE_NONPAGED_POOL(_y) ExAllocatePool2(POOL_FLAG_NON_PAGED, _y, MbbPoolTagDefault)
diff --git a/network/wwan/cxwmbclass/utils.cpp b/network/wwan/cxwmbclass/utils.cpp
index ec791ab4..bc74100d 100644
--- a/network/wwan/cxwmbclass/utils.cpp
+++ b/network/wwan/cxwmbclass/utils.cpp
@@ -248,7 +248,7 @@ MbbBusGetStat(__in MBB_BUS_HANDLE BusHandle, __in USHORT StatIndex, __out ULONGL
if (NT_SUCCESS(Status))
{
- if (BytesTransfered < sizeof(Value))
+ if (BytesTransfered < sizeof(*Value))
{
Status = STATUS_INFO_LENGTH_MISMATCH;
}
diff --git a/nfc/NfcCxSample/windows-drivertemplate-nfc/windows-drivertemplate-nfc.inf b/nfc/NfcCxSample/windows-drivertemplate-nfc/windows-drivertemplate-nfc.inf
index 5d1afa6e..38d5d022 100644
--- a/nfc/NfcCxSample/windows-drivertemplate-nfc/windows-drivertemplate-nfc.inf
+++ b/nfc/NfcCxSample/windows-drivertemplate-nfc/windows-drivertemplate-nfc.inf
Binary files differ
diff --git a/packages.config b/packages.config
index 257a510d..51860634 100644
--- a/packages.config
+++ b/packages.config
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
- <package id="Microsoft.Windows.SDK.CPP" version="10.0.26100.1" targetFramework="native" />
- <package id="Microsoft.Windows.SDK.CPP.x64" version="10.0.26100.1" targetFramework="native" />
- <package id="Microsoft.Windows.SDK.CPP.arm64" version="10.0.26100.1" targetFramework="native" />
- <package id="Microsoft.Windows.WDK.x64" version="10.0.26100.1" targetFramework="native" />
- <package id="Microsoft.Windows.WDK.arm64" version="10.0.26100.1" targetFramework="native" />
+ <package id="Microsoft.Windows.SDK.CPP" version="10.0.26100.2454" targetFramework="native" />
+ <package id="Microsoft.Windows.SDK.CPP.x64" version="10.0.26100.2454" targetFramework="native" />
+ <package id="Microsoft.Windows.SDK.CPP.arm64" version="10.0.26100.2454" targetFramework="native" />
+ <package id="Microsoft.Windows.WDK.x64" version="10.0.26100.2454" targetFramework="native" />
+ <package id="Microsoft.Windows.WDK.arm64" version="10.0.26100.2454" targetFramework="native" />
</packages>
diff --git a/pofx/PEP/acpi/sampleacpipep.inx b/pofx/PEP/acpi/sampleacpipep.inx
index 9f93ad5b..94063ad0 100644
--- a/pofx/PEP/acpi/sampleacpipep.inx
+++ b/pofx/PEP/acpi/sampleacpipep.inx
Binary files differ
diff --git a/pofx/UMDF2/Driver/SingleComp/SingleComponentSingleStateUm.inx b/pofx/UMDF2/Driver/SingleComp/SingleComponentSingleStateUm.inx
index ffdf5414..2a8dffc1 100644
--- a/pofx/UMDF2/Driver/SingleComp/SingleComponentSingleStateUm.inx
+++ b/pofx/UMDF2/Driver/SingleComp/SingleComponentSingleStateUm.inx
Binary files differ
diff --git a/pofx/WDF/Driver/MultiComp/driver/WdfMultiComp.inx b/pofx/WDF/Driver/MultiComp/driver/WdfMultiComp.inx
index 4642ce27..5bd9ee1c 100644
--- a/pofx/WDF/Driver/MultiComp/driver/WdfMultiComp.inx
+++ b/pofx/WDF/Driver/MultiComp/driver/WdfMultiComp.inx
Binary files differ
diff --git a/pofx/WDF/Driver/SingleComp/SingleComponentFStateSample.inx b/pofx/WDF/Driver/SingleComp/SingleComponentFStateSample.inx
index adaa2411..7f99b48c 100644
--- a/pofx/WDF/Driver/SingleComp/SingleComponentFStateSample.inx
+++ b/pofx/WDF/Driver/SingleComp/SingleComponentFStateSample.inx
Binary files differ
diff --git a/pos/drivers/MagneticStripeReader/SampleMagneticStripeReaderDrv.inf b/pos/drivers/MagneticStripeReader/SampleMagneticStripeReaderDrv.inf
index 1dbdcc58..94a9bd03 100644
--- a/pos/drivers/MagneticStripeReader/SampleMagneticStripeReaderDrv.inf
+++ b/pos/drivers/MagneticStripeReader/SampleMagneticStripeReaderDrv.inf
Binary files differ
diff --git a/pos/drivers/barcodescanner/SampleBarcodeScannerDrv.inf b/pos/drivers/barcodescanner/SampleBarcodeScannerDrv.inf
index 28a173ea..835a550a 100644
--- a/pos/drivers/barcodescanner/SampleBarcodeScannerDrv.inf
+++ b/pos/drivers/barcodescanner/SampleBarcodeScannerDrv.inf
Binary files differ
diff --git a/prm/PrmFunc/prmfuncsample.inf b/prm/PrmFunc/prmfuncsample.inf
index bdd78384..f583ca59 100644
--- a/prm/PrmFunc/prmfuncsample.inf
+++ b/prm/PrmFunc/prmfuncsample.inf
Binary files differ
diff --git a/sd/miniport/sdhc/sdhc.inx b/sd/miniport/sdhc/sdhc.inx
index 50026a87..f2b6c58a 100644
--- a/sd/miniport/sdhc/sdhc.inx
+++ b/sd/miniport/sdhc/sdhc.inx
Binary files differ
diff --git a/sensors/ADXL345Acc/ADXL345Acc.inx b/sensors/ADXL345Acc/ADXL345Acc.inx
index 73fd9d97..a2f05fb6 100644
--- a/sensors/ADXL345Acc/ADXL345Acc.inx
+++ b/sensors/ADXL345Acc/ADXL345Acc.inx
Binary files differ
diff --git a/sensors/Activity/Activity.inx b/sensors/Activity/Activity.inx
index 5d111d86..7570a42c 100644
--- a/sensors/Activity/Activity.inx
+++ b/sensors/Activity/Activity.inx
Binary files differ
diff --git a/sensors/CustomSensors/CustomSensors.inx b/sensors/CustomSensors/CustomSensors.inx
index 86438b0d..ff288b6f 100644
--- a/sensors/CustomSensors/CustomSensors.inx
+++ b/sensors/CustomSensors/CustomSensors.inx
Binary files differ
diff --git a/sensors/Fusion/FusionSensor.inx b/sensors/Fusion/FusionSensor.inx
index 44d590c4..21419ef8 100644
--- a/sensors/Fusion/FusionSensor.inx
+++ b/sensors/Fusion/FusionSensor.inx
Binary files differ
diff --git a/sensors/Pedometer/Pedometer.inx b/sensors/Pedometer/Pedometer.inx
index 91a304bf..16a752c2 100644
--- a/sensors/Pedometer/Pedometer.inx
+++ b/sensors/Pedometer/Pedometer.inx
Binary files differ
diff --git a/sensors/SensorsComboDriver/SensorsComboDriver.inx b/sensors/SensorsComboDriver/SensorsComboDriver.inx
index 699be4de..00c1eebf 100644
--- a/sensors/SensorsComboDriver/SensorsComboDriver.inx
+++ b/sensors/SensorsComboDriver/SensorsComboDriver.inx
Binary files differ
diff --git a/sensors/SimpleDeviceOrientationSensor/SimpleDeviceOrientationSensor.inx b/sensors/SimpleDeviceOrientationSensor/SimpleDeviceOrientationSensor.inx
index b2ccfaba..9ea73281 100644
--- a/sensors/SimpleDeviceOrientationSensor/SimpleDeviceOrientationSensor.inx
+++ b/sensors/SimpleDeviceOrientationSensor/SimpleDeviceOrientationSensor.inx
Binary files differ
diff --git a/serial/VirtualSerial2/ComPort/virtualserial2um.inx b/serial/VirtualSerial2/ComPort/virtualserial2um.inx
index 6679d7ab..f40e466d 100644
--- a/serial/VirtualSerial2/ComPort/virtualserial2um.inx
+++ b/serial/VirtualSerial2/ComPort/virtualserial2um.inx
Binary files differ
diff --git a/serial/VirtualSerial2/FakeModem/fakemodem2um.inx b/serial/VirtualSerial2/FakeModem/fakemodem2um.inx
index 235bdddd..ecb8f875 100644
--- a/serial/VirtualSerial2/FakeModem/fakemodem2um.inx
+++ b/serial/VirtualSerial2/FakeModem/fakemodem2um.inx
Binary files differ
diff --git a/serial/VirtualSerial2/queue.c b/serial/VirtualSerial2/queue.c
index 80571b42..83b022de 100644
--- a/serial/VirtualSerial2/queue.c
+++ b/serial/VirtualSerial2/queue.c
@@ -173,7 +173,6 @@ RequestCopyToBuffer(
return status;
}
- WdfRequestSetInformation(Request, NumBytesToCopyTo);
return status;
}
diff --git a/serial/serial/serial.inx b/serial/serial/serial.inx
index d6bfc3bb..2b26d20b 100644
--- a/serial/serial/serial.inx
+++ b/serial/serial/serial.inx
Binary files differ
diff --git a/simbatt/func/miniclass.c b/simbatt/func/miniclass.c
index ba2df340..612b4c66 100644
--- a/simbatt/func/miniclass.c
+++ b/simbatt/func/miniclass.c
@@ -202,7 +202,7 @@ Return Value:
}
Status = GetSimBattStateFromRegistry(Device, RegState);
- if (!NT_SUCCESS(Status)) {
+ if (NT_SUCCESS(Status)) {
RtlZeroMemory(RegState, sizeof(SIMBATT_STATE));
WdfWaitLockAcquire(DevExt->StateLock, NULL);
diff --git a/simbatt/func/simbatt.inx b/simbatt/func/simbatt.inx
index 5aab816a..c628040b 100644
--- a/simbatt/func/simbatt.inx
+++ b/simbatt/func/simbatt.inx
Binary files differ
diff --git a/smartcrd/pscr/pscr.inx b/smartcrd/pscr/pscr.inx
index ad9040fe..5e62eee6 100644
--- a/smartcrd/pscr/pscr.inx
+++ b/smartcrd/pscr/pscr.inx
Binary files differ
diff --git a/spb/SkeletonI2C/skeletoni2c.inx b/spb/SkeletonI2C/skeletoni2c.inx
index 056423f9..67ca6582 100644
--- a/spb/SkeletonI2C/skeletoni2c.inx
+++ b/spb/SkeletonI2C/skeletoni2c.inx
Binary files differ
diff --git a/spb/SpbTestTool/sys/spbtesttool.inx b/spb/SpbTestTool/sys/spbtesttool.inx
index baf82127..b52c4ccc 100644
--- a/spb/SpbTestTool/sys/spbtesttool.inx
+++ b/spb/SpbTestTool/sys/spbtesttool.inx
Binary files differ
diff --git a/storage/msdsm/src/SampleDSM.inf b/storage/msdsm/src/SampleDSM.inf
index a820c7ec..f0dbb34d 100644
--- a/storage/msdsm/src/SampleDSM.inf
+++ b/storage/msdsm/src/SampleDSM.inf
Binary files differ
diff --git a/thermal/simsensor/simsensor.inf b/thermal/simsensor/simsensor.inf
index 2b9a4394..f1aa5512 100644
--- a/thermal/simsensor/simsensor.inf
+++ b/thermal/simsensor/simsensor.inf
Binary files differ
diff --git a/thermal/thermalclient/simtc.inf b/thermal/thermalclient/simtc.inf
index 7c27c1d2..e015a83c 100644
--- a/thermal/thermalclient/simtc.inf
+++ b/thermal/thermalclient/simtc.inf
Binary files differ
diff --git a/tools/dv/samples/DV-FailDriver-WDM/driver/defect_toastmon.inf b/tools/dv/samples/DV-FailDriver-WDM/driver/defect_toastmon.inf
index edb7ee89..e577f586 100644
--- a/tools/dv/samples/DV-FailDriver-WDM/driver/defect_toastmon.inf
+++ b/tools/dv/samples/DV-FailDriver-WDM/driver/defect_toastmon.inf
Binary files differ
diff --git a/tools/kasan/samples/KasanDemo-WDM/KasanDemo.sln b/tools/kasan/samples/KasanDemo-WDM/KasanDemo.sln
new file mode 100644
index 00000000..fe0c0464
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/KasanDemo.sln
@@ -0,0 +1,46 @@
+
+Microsoft Visual Studio Solution File, Format Version 12.00
+# Visual Studio 2013
+VisualStudioVersion = 12.0
+MinimumVisualStudioVersion = 12.0
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Exe", "Exe", "{C4575BAC-8843-4B59-88F5-8D142A59F463}"
+EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Sys", "Sys", "{52CD4CBC-6018-4367-BE2B-EA5A2864E7BE}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "kasanagent", "exe\kasanagent.vcxproj", "{61899E58-10C2-4EB1-9508-58AE7DC3B3A9}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "kasantrigger", "sys\kasantrigger.vcxproj", "{29BD96E0-B6C5-42A0-B683-FD9740810699}"
+EndProject
+Global
+ GlobalSection(SolutionConfigurationPlatforms) = preSolution
+ Debug|ARM64 = Debug|ARM64
+ Release|ARM64 = Release|ARM64
+ Debug|x64 = Debug|x64
+ Release|x64 = Release|x64
+ EndGlobalSection
+ GlobalSection(ProjectConfigurationPlatforms) = postSolution
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Debug|ARM64.ActiveCfg = Debug|ARM64
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Debug|ARM64.Build.0 = Debug|ARM64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Debug|ARM64.ActiveCfg = Debug|ARM64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Debug|ARM64.Build.0 = Debug|ARM64
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Release|ARM64.ActiveCfg = Release|ARM64
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Release|ARM64.Build.0 = Release|ARM64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Release|ARM64.ActiveCfg = Release|ARM64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Release|ARM64.Build.0 = Release|ARM64
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Debug|x64.ActiveCfg = Debug|x64
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Debug|x64.Build.0 = Debug|x64
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Release|x64.ActiveCfg = Release|x64
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9}.Release|x64.Build.0 = Release|x64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Debug|x64.ActiveCfg = Debug|x64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Debug|x64.Build.0 = Debug|x64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Release|x64.ActiveCfg = Release|x64
+ {29BD96E0-B6C5-42A0-B683-FD9740810699}.Release|x64.Build.0 = Release|x64
+ EndGlobalSection
+ GlobalSection(SolutionProperties) = preSolution
+ HideSolutionNode = FALSE
+ EndGlobalSection
+ GlobalSection(NestedProjects) = preSolution
+ {61899E58-10C2-4EB1-9508-58AE7DC3B3A9} = {C4575BAC-8843-4B59-88F5-8D142A59F463}
+ {29BD96E0-B6C5-42A0-B683-FD9740810699} = {52CD4CBC-6018-4367-BE2B-EA5A2864E7BE}
+ EndGlobalSection
+EndGlobal
diff --git a/tools/kasan/samples/KasanDemo-WDM/README.md b/tools/kasan/samples/KasanDemo-WDM/README.md
new file mode 100644
index 00000000..0c9c6fef
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/README.md
@@ -0,0 +1,25 @@
+---
+page_type: sample
+description: "Demonstrates KASAN."
+languages:
+- cpp
+products:
+- windows
+- windows-wdk
+---
+
+# KasanDemo
+
+This sample demonstrates how KASAN detects illegal memory accesses.
+
+The sample consists of a legacy device driver that contains intentionally incorrect code that performs illegal memory accesses, and a Win32 console agent that interacts with the driver to trigger different types of illegal memory accesses that KASAN successfully detects.
+
+> [!CAUTION]
+> This driver contains INTENTIONALLY INCORRECT code. Neither this driver nor its sample programs are intended for use in a production environment. Instead, they are intended for educational purposes.
+
+> [!CAUTION]
+> This driver will cause KASAN to bugcheck your system.
+
+## Run the sample
+
+To run this sample, enable KASAN in your system, load the `kasantrigger.sys` driver, and then run the `kasanagent.exe` application.
diff --git a/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.c b/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.c
new file mode 100644
index 00000000..2b6b726c
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.c
@@ -0,0 +1,157 @@
+/*++
+
+Copyright (c) 2024 Microsoft Corporation All Rights Reserved
+
+Module Name:
+
+ agent.c
+
+Abstract:
+
+ Usermode agent that interacts with the kasantrigger.sys driver to
+ demonstrate how KASAN detects illegal memory accesses.
+
+Environment:
+
+ Win32 console multi-threaded application.
+
+--*/
+
+#include <windows.h>
+#include <winioctl.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <strsafe.h>
+#include <sys\kasantrigger.h>
+
+VOID __cdecl
+main(
+ _In_ ULONG argc,
+ _In_reads_(argc) PCHAR argv[]
+ )
+{
+ ULONG bytesReturned;
+ INT choice;
+ HANDLE hDevice;
+ ULONG index;
+ DWORD ioctlCode;
+ BOOLEAN isKasanEnabledOnDriver;
+ BOOL success;
+ UCHAR value;
+
+ UNREFERENCED_PARAMETER(argc);
+ UNREFERENCED_PARAMETER(argv);
+
+ printf(
+ " _ __ ______ \n"
+ "| | / / | _ \\ \n"
+ "| |/ / __ _ ___ __ _ _ __ | | | |___ _ __ ___ ___ \n"
+ "| \\ / _` / __|/ _` | '_ \\ | | | / _ \\ '_ ` _ \\ / _ \\ \n"
+ "| |\\ \\ (_| \\__ \\ (_| | | | | | |/ / __/ | | | | | (_) |\n"
+ "\\_| \\_/\\__,_|___/\\__,_|_| |_| |___/ \\___|_| |_| |_|\\___/ \n\n"
+ );
+
+ //
+ // Open the device.
+ //
+
+ hDevice = CreateFile("\\\\.\\KasanTrigger",
+ GENERIC_READ | GENERIC_WRITE,
+ 0,
+ NULL,
+ CREATE_ALWAYS,
+ FILE_ATTRIBUTE_NORMAL,
+ NULL);
+
+ if (hDevice == INVALID_HANDLE_VALUE) {
+ printf("CreateFile failed: %d. Did you forget to load kasantrigger.sys?\n",
+ GetLastError());
+ return;
+ }
+
+ //
+ // Check whether KASAN is enabled on the driver.
+ //
+
+ success = DeviceIoControl(hDevice,
+ (DWORD)IOCTL_KASANTRIGGER_INFO,
+ NULL,
+ 0,
+ &isKasanEnabledOnDriver,
+ sizeof(isKasanEnabledOnDriver),
+ &bytesReturned,
+ NULL);
+ if (!success) {
+ printf("DeviceIoControl failed: %d\n\n", GetLastError());
+ return;
+ }
+
+ if (!isKasanEnabledOnDriver) {
+ printf("WARNING: KASAN is not enabled on kasantrigger.sys\n\n");
+ }
+
+ printf("Enter a number in the menu below to trigger the desired condition:\n");
+ printf("1. Trigger a stack out-of-bounds read\n");
+ printf("2. Trigger a global out-of-bounds read\n");
+ printf("3. Trigger a heap out-of-bounds read\n\n");
+
+ while (TRUE) {
+ printf("> ");
+ while ((choice = getchar()) == '\n');
+
+ switch (choice) {
+ case '1':
+ ioctlCode = (DWORD)IOCTL_KASANTRIGGER_OOBR_STACK;
+ break;
+ case '2':
+ ioctlCode = (DWORD)IOCTL_KASANTRIGGER_OOBR_GLOBAL;
+ break;
+ case '3':
+ ioctlCode = (DWORD)IOCTL_KASANTRIGGER_OOBR_HEAP;
+ break;
+ default:
+ printf("Incorrect input, try again\n");
+ continue;
+ }
+
+ printf("You have selected %c. Excellent choice. ", choice);
+ Sleep(1000);
+ printf("Triggering in 3...");
+ Sleep(1000);
+ printf(" 2...");
+ Sleep(1000);
+ printf(" 1...");
+ Sleep(1000);
+ printf("\n");
+
+ index = KASANTRIGGER_ARRAY_SIZE;
+ value = 0;
+
+ success = DeviceIoControl(hDevice,
+ ioctlCode,
+ &index,
+ sizeof(index),
+ &value,
+ sizeof(value),
+ &bytesReturned,
+ NULL);
+ if (!success) {
+ printf("DeviceIoControl failed: %d\n", GetLastError());
+ return;
+ }
+
+ //
+ // KASAN should have normally triggered a bugcheck, so this should be
+ // unreachable.
+ //
+
+ if (isKasanEnabledOnDriver) {
+ printf("Still alive. The bugcheck was not issued. This is not expected.\n");
+ } else {
+ printf("Still alive, because KASAN was not enabled on the driver. The illegal access went undetected.\n");
+ }
+ }
+
+ CloseHandle(hDevice);
+} \ No newline at end of file
diff --git a/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj b/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj
new file mode 100644
index 00000000..9556e374
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj
@@ -0,0 +1,184 @@
+<?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|ARM64">
+ <Configuration>Debug</Configuration>
+ <Platform>ARM64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|ARM64">
+ <Configuration>Release</Configuration>
+ <Platform>ARM64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Debug|x64">
+ <Configuration>Debug</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|x64">
+ <Configuration>Release</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ </ItemGroup>
+ <PropertyGroup Label="Globals">
+ <ProjectGuid>{61899E58-10C2-4EB1-9508-58AE7DC3B3A9}</ProjectGuid>
+ <RootNamespace>$(MSBuildProjectName)</RootNamespace>
+ <Configuration Condition="'$(Configuration)' == ''">Debug</Configuration>
+ <Platform Condition="'$(Platform)' == ''">x64</Platform>
+ <SampleGuid>{14E9681A-41C8-43B1-885D-6CD8CB06AAD8}</SampleGuid>
+ <ProjectName>kasanagent</ProjectName>
+ <WindowsTargetPlatformVersion>$(LatestTargetPlatformVersion)</WindowsTargetPlatformVersion>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>False</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType />
+ <PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
+ <ConfigurationType>Application</ConfigurationType>
+ </PropertyGroup>
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>False</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType />
+ <PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
+ <ConfigurationType>Application</ConfigurationType>
+ </PropertyGroup>
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>True</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType />
+ <PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
+ <ConfigurationType>Application</ConfigurationType>
+ </PropertyGroup>
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>True</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType />
+ <PlatformToolset>WindowsApplicationForDrivers10.0</PlatformToolset>
+ <ConfigurationType>Application</ConfigurationType>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+ <PropertyGroup>
+ <OutDir>$(IntDir)</OutDir>
+ </PropertyGroup>
+ <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)'=='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)'=='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|ARM64'">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
+ </ImportGroup>
+ <ItemGroup Label="WrappedTaskItems" />
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <TargetName>kasanagent</TargetName>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
+ <TargetName>kasanagent</TargetName>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <TargetName>kasanagent</TargetName>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
+ <TargetName>kasanagent</TargetName>
+ </PropertyGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ClCompile>
+ <ResourceCompile>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Midl>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </Midl>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ClCompile>
+ <ResourceCompile>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Midl>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </Midl>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ClCompile>
+ <ResourceCompile>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Midl>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </Midl>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ClCompile>
+ <ResourceCompile>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </ResourceCompile>
+ <Midl>
+ <AdditionalIncludeDirectories>%(AdditionalIncludeDirectories);..\</AdditionalIncludeDirectories>
+ </Midl>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <ClCompile>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
+ <ClCompile>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <ClCompile>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
+ <ClCompile>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ </ItemDefinitionGroup>
+ <ItemGroup>
+ <ClCompile Include="kasanagent.c" />
+ </ItemGroup>
+ <ItemGroup>
+ <Inf Exclude="@(Inf)" Include="*.inf" />
+ <FilesToPackage Include="$(TargetPath)" Condition="'$(ConfigurationType)'=='Driver' or '$(ConfigurationType)'=='DynamicLibrary'" />
+ </ItemGroup>
+ <ItemGroup>
+ <None Exclude="@(None)" Include="*.txt;*.htm;*.html" />
+ <None Exclude="@(None)" Include="*.ico;*.cur;*.bmp;*.dlg;*.rct;*.gif;*.jpg;*.jpeg;*.wav;*.jpe;*.tiff;*.tif;*.png;*.rc2" />
+ <None Exclude="@(None)" Include="*.def;*.bat;*.hpj;*.asmx" />
+ </ItemGroup>
+ <ItemGroup>
+ <ClInclude Exclude="@(ClInclude)" Include="*.h;*.hpp;*.hxx;*.hm;*.inl;*.xsd" />
+ </ItemGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+</Project> \ No newline at end of file
diff --git a/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj.Filters b/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj.Filters
new file mode 100644
index 00000000..445aa804
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/exe/kasanagent.vcxproj.Filters
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <Filter Include="Source Files">
+ <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx;*</Extensions>
+ <UniqueIdentifier>{49310AE5-27D6-4E5F-8E16-7787FBBFC870}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="Header Files">
+ <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
+ <UniqueIdentifier>{10285CDD-3CE2-48BD-9108-C546303EC345}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="Resource Files">
+ <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms;man;xml</Extensions>
+ <UniqueIdentifier>{4DC87590-E3DB-45A9-8BF6-F0552982B4A7}</UniqueIdentifier>
+ </Filter>
+ </ItemGroup>
+ <ItemGroup>
+ <ClCompile Include="kasanagent.c">
+ <Filter>Source Files</Filter>
+ </ClCompile>
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.c b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.c
new file mode 100644
index 00000000..3605f7ff
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.c
@@ -0,0 +1,303 @@
+/*++
+
+Copyright (c) 2024 Microsoft Corporation All Rights Reserved
+
+Module Name:
+
+ kasantrigger.c
+
+Abstract:
+
+ The purpose of this driver is to demonstrate how KASAN detects illegal
+ memory accesses.
+
+Environment:
+
+ Kernel mode only.
+
+--*/
+
+#include <ntddk.h>
+#include <string.h>
+#include "kasantrigger.h"
+
+#define NT_DEVICE_NAME L"\\Device\\KASANTRIGGER"
+#define DOS_DEVICE_NAME L"\\DosDevices\\KasanTrigger"
+
+DRIVER_INITIALIZE DriverEntry;
+
+_Dispatch_type_(IRP_MJ_CREATE)
+_Dispatch_type_(IRP_MJ_CLOSE)
+DRIVER_DISPATCH KasanTriggerCreateClose;
+
+_Dispatch_type_(IRP_MJ_DEVICE_CONTROL)
+DRIVER_DISPATCH KasanTriggerDeviceControl;
+
+DRIVER_UNLOAD KasanTriggerUnloadDriver;
+
+#ifdef ALLOC_PRAGMA
+#pragma alloc_text(INIT, DriverEntry)
+#pragma alloc_text(PAGE, KasanTriggerCreateClose)
+#pragma alloc_text(PAGE, KasanTriggerDeviceControl)
+#pragma alloc_text(PAGE, KasanTriggerUnloadDriver)
+#endif
+
+// -----------------------------------------------------------------------------
+
+UCHAR GlobalVariable[KASANTRIGGER_ARRAY_SIZE];
+
+static
+UCHAR
+TriggerOobrStack(
+ _In_ ULONG Index
+ )
+{
+ UCHAR StackVariable[KASANTRIGGER_ARRAY_SIZE];
+
+ //
+ // This copy is only here to force the compiler not to optimize out the
+ // stack variable.
+ //
+
+ RtlCopyMemory(StackVariable, GlobalVariable, KASANTRIGGER_ARRAY_SIZE);
+
+ //
+ // WARNING: this is an intentionally INCORRECT code!
+ //
+
+ return StackVariable[Index];
+}
+
+static
+UCHAR
+TriggerOobrGlobal(
+ _In_ ULONG Index
+ )
+{
+ //
+ // WARNING: this is an intentionally INCORRECT code!
+ //
+
+ return GlobalVariable[Index];
+}
+
+static
+UCHAR
+TriggerOobrHeap(
+ _In_ ULONG Index
+ )
+{
+ PCHAR buffer;
+ UCHAR retVal;
+
+ buffer = ExAllocatePool2(POOL_FLAG_PAGED, KASANTRIGGER_ARRAY_SIZE, 'mDaK');
+ if (buffer == NULL) {
+ return 0;
+ }
+
+ //
+ // WARNING: this is an intentionally INCORRECT code!
+ //
+
+ retVal = buffer[Index];
+
+ ExFreePool(buffer);
+
+ return retVal;
+}
+
+// -----------------------------------------------------------------------------
+
+NTSTATUS
+DriverEntry(
+ _In_ PDRIVER_OBJECT DriverObject,
+ _In_ PUNICODE_STRING RegistryPath
+ )
+{
+ NTSTATUS ntStatus;
+ UNICODE_STRING ntUnicodeString;
+ UNICODE_STRING ntWin32NameString;
+ PDEVICE_OBJECT deviceObject;
+
+ UNREFERENCED_PARAMETER(RegistryPath);
+
+ RtlInitUnicodeString(&ntUnicodeString, NT_DEVICE_NAME);
+
+ ntStatus = IoCreateDevice(DriverObject,
+ 0,
+ &ntUnicodeString,
+ FILE_DEVICE_UNKNOWN,
+ FILE_DEVICE_SECURE_OPEN,
+ FALSE,
+ &deviceObject);
+ if (!NT_SUCCESS(ntStatus)) {
+ return ntStatus;
+ }
+
+ DriverObject->MajorFunction[IRP_MJ_CREATE] = KasanTriggerCreateClose;
+ DriverObject->MajorFunction[IRP_MJ_CLOSE] = KasanTriggerCreateClose;
+ DriverObject->MajorFunction[IRP_MJ_DEVICE_CONTROL] = KasanTriggerDeviceControl;
+ DriverObject->DriverUnload = KasanTriggerUnloadDriver;
+
+ RtlInitUnicodeString(&ntWin32NameString, DOS_DEVICE_NAME);
+
+ ntStatus = IoCreateSymbolicLink(&ntWin32NameString, &ntUnicodeString);
+
+ if (!NT_SUCCESS(ntStatus)) {
+ IoDeleteDevice(deviceObject);
+ }
+
+ return ntStatus;
+}
+
+NTSTATUS
+KasanTriggerCreateClose(
+ PDEVICE_OBJECT DeviceObject,
+ PIRP Irp
+ )
+{
+ UNREFERENCED_PARAMETER(DeviceObject);
+
+ PAGED_CODE();
+
+ Irp->IoStatus.Status = STATUS_SUCCESS;
+ Irp->IoStatus.Information = 0;
+
+ IoCompleteRequest(Irp, IO_NO_INCREMENT);
+
+ return STATUS_SUCCESS;
+}
+
+VOID
+KasanTriggerUnloadDriver(
+ _In_ PDRIVER_OBJECT DriverObject
+ )
+{
+ PDEVICE_OBJECT deviceObject = DriverObject->DeviceObject;
+ UNICODE_STRING uniWin32NameString;
+
+ PAGED_CODE();
+
+ RtlInitUnicodeString(&uniWin32NameString, DOS_DEVICE_NAME);
+ IoDeleteSymbolicLink(&uniWin32NameString);
+
+ if (deviceObject != NULL) {
+ IoDeleteDevice(deviceObject);
+ }
+
+ return;
+}
+
+NTSTATUS
+KasanTriggerDeviceControl(
+ PDEVICE_OBJECT DeviceObject,
+ PIRP Irp
+ )
+{
+ PIO_STACK_LOCATION irpSp;
+ NTSTATUS ntStatus;
+ ULONG inBufLength;
+ ULONG inIndex;
+ ULONG outBufLength;
+ PUCHAR outValue;
+ PBOOLEAN isKasanEnabledOnDriver;
+
+ UNREFERENCED_PARAMETER(DeviceObject);
+
+ PAGED_CODE();
+
+ irpSp = IoGetCurrentIrpStackLocation(Irp);
+ inBufLength = irpSp->Parameters.DeviceIoControl.InputBufferLength;
+ outBufLength = irpSp->Parameters.DeviceIoControl.OutputBufferLength;
+
+ ntStatus = STATUS_SUCCESS;
+
+ switch (irpSp->Parameters.DeviceIoControl.IoControlCode)
+ {
+ case IOCTL_KASANTRIGGER_INFO:
+
+ //
+ // Return information. Just a BOOLEAN that indicates whether the
+ // driver was compiled with KASAN or not.
+ //
+
+ if (inBufLength != 0 || outBufLength != sizeof(BOOLEAN)) {
+ ntStatus = STATUS_INVALID_PARAMETER;
+ goto End;
+ }
+
+ isKasanEnabledOnDriver = (PBOOLEAN)Irp->AssociatedIrp.SystemBuffer;
+#if defined(__SANITIZE_ADDRESS__)
+ *isKasanEnabledOnDriver = TRUE;
+#else
+ *isKasanEnabledOnDriver = FALSE;
+#endif
+
+ Irp->IoStatus.Information = sizeof(BOOLEAN);
+ break;
+
+ case IOCTL_KASANTRIGGER_OOBR_STACK:
+
+ //
+ // Trigger an out-of-bounds read on the stack.
+ //
+
+ if (inBufLength != sizeof(ULONG) || outBufLength != sizeof(UCHAR)) {
+ ntStatus = STATUS_INVALID_PARAMETER;
+ goto End;
+ }
+
+ inIndex = *((PULONG)Irp->AssociatedIrp.SystemBuffer);
+ outValue = (PUCHAR)Irp->AssociatedIrp.SystemBuffer;
+ *outValue = TriggerOobrStack(inIndex);
+
+ Irp->IoStatus.Information = sizeof(UCHAR);
+ break;
+
+ case IOCTL_KASANTRIGGER_OOBR_GLOBAL:
+
+ //
+ // Trigger an out-of-bounds read on a global variable.
+ //
+
+ if (inBufLength != sizeof(ULONG) || outBufLength != sizeof(UCHAR)) {
+ ntStatus = STATUS_INVALID_PARAMETER;
+ goto End;
+ }
+
+ inIndex = *((PULONG)Irp->AssociatedIrp.SystemBuffer);
+ outValue = (PUCHAR)Irp->AssociatedIrp.SystemBuffer;
+ *outValue = TriggerOobrGlobal(inIndex);
+
+ Irp->IoStatus.Information = sizeof(UCHAR);
+ break;
+
+ case IOCTL_KASANTRIGGER_OOBR_HEAP:
+
+ //
+ // Trigger an out-of-bounds read on a heap buffer.
+ //
+
+ if (inBufLength != sizeof(ULONG) || outBufLength != sizeof(UCHAR)) {
+ ntStatus = STATUS_INVALID_PARAMETER;
+ goto End;
+ }
+
+ inIndex = *((PULONG)Irp->AssociatedIrp.SystemBuffer);
+ outValue = (PUCHAR)Irp->AssociatedIrp.SystemBuffer;
+ *outValue = TriggerOobrHeap(inIndex);
+
+ Irp->IoStatus.Information = sizeof(UCHAR);
+ break;
+
+ default:
+ ntStatus = STATUS_INVALID_DEVICE_REQUEST;
+ break;
+ }
+
+End:
+
+ Irp->IoStatus.Status = ntStatus;
+ IoCompleteRequest(Irp, IO_NO_INCREMENT);
+ return ntStatus;
+}
diff --git a/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.h b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.h
new file mode 100644
index 00000000..aad3b5c2
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.h
@@ -0,0 +1,30 @@
+/*++
+
+Copyright (c) 2024 Microsoft Corporation
+
+Module Name:
+
+ kasantrigger.h
+
+--*/
+
+//
+// Device type.
+//
+
+#define KASANTRIGGER_TYPE 40000
+
+//
+// The IOCTL function codes from 0x800 to 0xFFF are for customer use.
+//
+
+#define IOCTL_KASANTRIGGER_INFO \
+ CTL_CODE(KASANTRIGGER_TYPE, 0x900, METHOD_BUFFERED, FILE_ANY_ACCESS)
+#define IOCTL_KASANTRIGGER_OOBR_STACK \
+ CTL_CODE(KASANTRIGGER_TYPE, 0x901, METHOD_BUFFERED, FILE_ANY_ACCESS)
+#define IOCTL_KASANTRIGGER_OOBR_GLOBAL \
+ CTL_CODE(KASANTRIGGER_TYPE, 0x902, METHOD_BUFFERED, FILE_ANY_ACCESS)
+#define IOCTL_KASANTRIGGER_OOBR_HEAP \
+ CTL_CODE(KASANTRIGGER_TYPE, 0x903, METHOD_BUFFERED, FILE_ANY_ACCESS)
+
+#define KASANTRIGGER_ARRAY_SIZE 8
diff --git a/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.rc b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.rc
new file mode 100644
index 00000000..409221ac
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.rc
@@ -0,0 +1,10 @@
+#include <windows.h>
+
+#include <ntverp.h>
+
+#define VER_FILETYPE VFT_DRV
+#define VER_FILESUBTYPE VFT2_DRV_SYSTEM
+#define VER_FILEDESCRIPTION_STR "Sample Driver"
+#define VER_INTERNALNAME_STR "kasantrigger.sys"
+
+#include "common.ver"
diff --git a/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj
new file mode 100644
index 00000000..f5946ed5
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj
@@ -0,0 +1,155 @@
+<?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|ARM64">
+ <Configuration>Debug</Configuration>
+ <Platform>ARM64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|ARM64">
+ <Configuration>Release</Configuration>
+ <Platform>ARM64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Debug|x64">
+ <Configuration>Debug</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ <ProjectConfiguration Include="Release|x64">
+ <Configuration>Release</Configuration>
+ <Platform>x64</Platform>
+ </ProjectConfiguration>
+ </ItemGroup>
+ <PropertyGroup Label="Globals">
+ <ProjectGuid>{29BD96E0-B6C5-42A0-B683-FD9740810699}</ProjectGuid>
+ <RootNamespace>$(MSBuildProjectName)</RootNamespace>
+ <Configuration Condition="'$(Configuration)' == ''">Debug</Configuration>
+ <Platform Condition="'$(Platform)' == ''">x64</Platform>
+ <SampleGuid>{A08AE94A-35FF-4A31-B152-5E3A43CE78A0}</SampleGuid>
+ <ProjectName>kasantrigger</ProjectName>
+ <WindowsTargetPlatformVersion>$(LatestTargetPlatformVersion)</WindowsTargetPlatformVersion>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>False</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType>WDM</DriverType>
+ <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
+ <ConfigurationType>Driver</ConfigurationType>
+ <EnableKASAN>true</EnableKASAN>
+ </PropertyGroup>
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>False</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType>WDM</DriverType>
+ <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
+ <ConfigurationType>Driver</ConfigurationType>
+ </PropertyGroup>
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>True</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType>WDM</DriverType>
+ <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
+ <ConfigurationType>Driver</ConfigurationType>
+ <EnableKASAN>true</EnableKASAN>
+ </PropertyGroup>
+ <PropertyGroup Label="Configuration" Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
+ <TargetVersion>Windows10</TargetVersion>
+ <UseDebugLibraries>True</UseDebugLibraries>
+ <DriverTargetPlatform>Windows Driver</DriverTargetPlatform>
+ <DriverType>WDM</DriverType>
+ <PlatformToolset>WindowsKernelModeDriver10.0</PlatformToolset>
+ <ConfigurationType>Driver</ConfigurationType>
+ </PropertyGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+ <PropertyGroup>
+ <OutDir>$(IntDir)</OutDir>
+ </PropertyGroup>
+ <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)'=='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)'=='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|ARM64'">
+ <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" />
+ </ImportGroup>
+ <ItemGroup Label="WrappedTaskItems" />
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <TargetName>kasantrigger</TargetName>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
+ <TargetName>kasantrigger</TargetName>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <TargetName>kasantrigger</TargetName>
+ </PropertyGroup>
+ <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
+ <TargetName>kasantrigger</TargetName>
+ </PropertyGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ <DriverSign>
+ <FileDigestAlgorithm>sha256</FileDigestAlgorithm>
+ </DriverSign>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ <DriverSign>
+ <FileDigestAlgorithm>sha256</FileDigestAlgorithm>
+ </DriverSign>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ <DriverSign>
+ <FileDigestAlgorithm>sha256</FileDigestAlgorithm>
+ </DriverSign>
+ </ItemDefinitionGroup>
+ <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
+ <ClCompile>
+ <TreatWarningAsError>true</TreatWarningAsError>
+ <WarningLevel>Level4</WarningLevel>
+ <ExceptionHandling>
+ </ExceptionHandling>
+ </ClCompile>
+ <DriverSign>
+ <FileDigestAlgorithm>sha256</FileDigestAlgorithm>
+ </DriverSign>
+ </ItemDefinitionGroup>
+ <ItemGroup>
+ <ClCompile Include="kasantrigger.c" />
+ <ResourceCompile Include="kasantrigger.rc" />
+ </ItemGroup>
+ <ItemGroup>
+ <Inf Exclude="@(Inf)" Include="*.inf" />
+ <FilesToPackage Include="$(TargetPath)" Condition="'$(ConfigurationType)'=='Driver' or '$(ConfigurationType)'=='DynamicLibrary'" />
+ </ItemGroup>
+ <ItemGroup>
+ <None Exclude="@(None)" Include="*.txt;*.htm;*.html" />
+ <None Exclude="@(None)" Include="*.ico;*.cur;*.bmp;*.dlg;*.rct;*.gif;*.jpg;*.jpeg;*.wav;*.jpe;*.tiff;*.tif;*.png;*.rc2" />
+ <None Exclude="@(None)" Include="*.def;*.bat;*.hpj;*.asmx" />
+ </ItemGroup>
+ <ItemGroup>
+ <ClInclude Exclude="@(ClInclude)" Include="kasantrigger.h" />
+ </ItemGroup>
+ <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+</Project> \ No newline at end of file
diff --git a/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj.Filters b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj.Filters
new file mode 100644
index 00000000..afae3e08
--- /dev/null
+++ b/tools/kasan/samples/KasanDemo-WDM/sys/kasantrigger.vcxproj.Filters
@@ -0,0 +1,36 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+ <ItemGroup>
+ <Filter Include="Source Files">
+ <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx;*</Extensions>
+ <UniqueIdentifier>{70613DC7-CE18-48E4-A282-83BAD5F14DB8}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="Header Files">
+ <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
+ <UniqueIdentifier>{61600929-B133-4CE1-A15E-E4E6B15BAFDD}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="Resource Files">
+ <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms;man;xml</Extensions>
+ <UniqueIdentifier>{E7360814-7364-44AA-933C-DD4BFBF95E8D}</UniqueIdentifier>
+ </Filter>
+ <Filter Include="Driver Files">
+ <Extensions>inf;inv;inx;mof;mc;</Extensions>
+ <UniqueIdentifier>{CF3AF6D6-43D2-4102-8996-8EF19621C095}</UniqueIdentifier>
+ </Filter>
+ </ItemGroup>
+ <ItemGroup>
+ <ClCompile Include="kasantrigger.c">
+ <Filter>Source Files</Filter>
+ </ClCompile>
+ </ItemGroup>
+ <ItemGroup>
+ <ResourceCompile Include="kasantrigger.rc">
+ <Filter>Resource Files</Filter>
+ </ResourceCompile>
+ </ItemGroup>
+ <ItemGroup>
+ <ClInclude Include="kasantrigger.h">
+ <Filter>Header Files</Filter>
+ </ClInclude>
+ </ItemGroup>
+</Project> \ No newline at end of file
diff --git a/usb/UcmCxUcsi/UcmCxUcsi.inf b/usb/UcmCxUcsi/UcmCxUcsi.inf
index 661424db..e238ba06 100644
--- a/usb/UcmCxUcsi/UcmCxUcsi.inf
+++ b/usb/UcmCxUcsi/UcmCxUcsi.inf
Binary files differ
diff --git a/usb/UcmTcpciCxClientSample/UcmTcpciCxClientSample.inf b/usb/UcmTcpciCxClientSample/UcmTcpciCxClientSample.inf
index 5a526ab9..6ee60372 100644
--- a/usb/UcmTcpciCxClientSample/UcmTcpciCxClientSample.inf
+++ b/usb/UcmTcpciCxClientSample/UcmTcpciCxClientSample.inf
Binary files differ
diff --git a/usb/UcmUcsiAcpiSample/UcmUcsiAcpiSample/UcmUcsiAcpiSample.inf b/usb/UcmUcsiAcpiSample/UcmUcsiAcpiSample/UcmUcsiAcpiSample.inf
index c52e7865..39b3c16a 100644
--- a/usb/UcmUcsiAcpiSample/UcmUcsiAcpiSample/UcmUcsiAcpiSample.inf
+++ b/usb/UcmUcsiAcpiSample/UcmUcsiAcpiSample/UcmUcsiAcpiSample.inf
Binary files differ
diff --git a/usb/kmdf_enumswitches/sys/kmdf_enumswitches.inx b/usb/kmdf_enumswitches/sys/kmdf_enumswitches.inx
index d9d1366b..eb3c3c4b 100644
--- a/usb/kmdf_enumswitches/sys/kmdf_enumswitches.inx
+++ b/usb/kmdf_enumswitches/sys/kmdf_enumswitches.inx
Binary files differ
diff --git a/usb/kmdf_fx2/driver/osrusbfx2.inx b/usb/kmdf_fx2/driver/osrusbfx2.inx
index 1185053e..b30e6dc9 100644
--- a/usb/kmdf_fx2/driver/osrusbfx2.inx
+++ b/usb/kmdf_fx2/driver/osrusbfx2.inx
Binary files differ
diff --git a/usb/ufxclientsample/UfxClientSample.inx b/usb/ufxclientsample/UfxClientSample.inx
index 01c37a10..357bf788 100644
--- a/usb/ufxclientsample/UfxClientSample.inx
+++ b/usb/ufxclientsample/UfxClientSample.inx
Binary files differ
diff --git a/usb/umdf2_fx2/driver/osrusbfx2um.inx b/usb/umdf2_fx2/driver/osrusbfx2um.inx
index 737295b0..de08b136 100644
--- a/usb/umdf2_fx2/driver/osrusbfx2um.inx
+++ b/usb/umdf2_fx2/driver/osrusbfx2um.inx
Binary files differ
diff --git a/usb/usbsamp/sys/driver/usbsamp.inx b/usb/usbsamp/sys/driver/usbsamp.inx
index 57dc4bf3..1dfa8473 100644
--- a/usb/usbsamp/sys/driver/usbsamp.inx
+++ b/usb/usbsamp/sys/driver/usbsamp.inx
Binary files differ
diff --git a/usb/wdf_osrfx2_lab/kmdf/step1/osrusbfx2.inx b/usb/wdf_osrfx2_lab/kmdf/step1/osrusbfx2.inx
index 0fc45d1a..3d5fe521 100644
--- a/usb/wdf_osrfx2_lab/kmdf/step1/osrusbfx2.inx
+++ b/usb/wdf_osrfx2_lab/kmdf/step1/osrusbfx2.inx
Binary files differ
diff --git a/usb/wdf_osrfx2_lab/kmdf/step2/osrusbfx2.inx b/usb/wdf_osrfx2_lab/kmdf/step2/osrusbfx2.inx
index f7e12d74..4805bc9c 100644
--- a/usb/wdf_osrfx2_lab/kmdf/step2/osrusbfx2.inx
+++ b/usb/wdf_osrfx2_lab/kmdf/step2/osrusbfx2.inx
Binary files differ
diff --git a/usb/wdf_osrfx2_lab/kmdf/step3/osrusbfx2.inx b/usb/wdf_osrfx2_lab/kmdf/step3/osrusbfx2.inx
index f7e12d74..4805bc9c 100644
--- a/usb/wdf_osrfx2_lab/kmdf/step3/osrusbfx2.inx
+++ b/usb/wdf_osrfx2_lab/kmdf/step3/osrusbfx2.inx
Binary files differ
diff --git a/usb/wdf_osrfx2_lab/kmdf/step4/osrusbfx2.inx b/usb/wdf_osrfx2_lab/kmdf/step4/osrusbfx2.inx
index f7e12d74..4805bc9c 100644
--- a/usb/wdf_osrfx2_lab/kmdf/step4/osrusbfx2.inx
+++ b/usb/wdf_osrfx2_lab/kmdf/step4/osrusbfx2.inx
Binary files differ
diff --git a/usb/wdf_osrfx2_lab/kmdf/step5/osrusbfx2.inx b/usb/wdf_osrfx2_lab/kmdf/step5/osrusbfx2.inx
index f7e12d74..4805bc9c 100644
--- a/usb/wdf_osrfx2_lab/kmdf/step5/osrusbfx2.inx
+++ b/usb/wdf_osrfx2_lab/kmdf/step5/osrusbfx2.inx
Binary files differ
diff --git a/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.inf b/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.inf
index dc63f6ad..4edee6b8 100644
--- a/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.inf
+++ b/video/IndirectDisplay/IddSampleDriver/IddSampleDriver.inf
Binary files differ
diff --git a/wia/ProdScan/ProdScan.inx b/wia/ProdScan/ProdScan.inx
index 6e8036ef..f27b79b9 100644
--- a/wia/ProdScan/ProdScan.inx
+++ b/wia/ProdScan/ProdScan.inx
Binary files differ
diff --git a/wia/microdrv/testmcro.inx b/wia/microdrv/testmcro.inx
index 86e3d220..3d084142 100644
--- a/wia/microdrv/testmcro.inx
+++ b/wia/microdrv/testmcro.inx
Binary files differ
diff --git a/wia/wiadriverex/usd/WiaDriver.inx b/wia/wiadriverex/usd/WiaDriver.inx
index 5d394e80..f527cde2 100644
--- a/wia/wiadriverex/usd/WiaDriver.inx
+++ b/wia/wiadriverex/usd/WiaDriver.inx
Binary files differ
diff --git a/wmi/wmisamp/wmisamp.inx b/wmi/wmisamp/wmisamp.inx
index bdf4152f..3b6250b9 100644
--- a/wmi/wmisamp/wmisamp.inx
+++ b/wmi/wmisamp/wmisamp.inx
Binary files differ