Windows: Remove kernel filter driver, add self-extracting installer with version management and conflict detection#7
Open
hangzqcom wants to merge 9 commits intoqualcomm:mainfrom
Conversation
8f3aa5e to
991c0d9
Compare
21079d7 to
28194da
Compare
- Remove kernel filter driver (qcusbfilter) binaries, INF, and catalog files - Remove all .cat files from version control (build artifacts) - Add build.bat script to generate and optionally sign .cat files using inf2cat/signtool - Add .gitignore to exclude .cat files - Update README with build instructions and updated repository structure Signed-off-by: Hang Zhao (QCT) <hangz@qti.qualcomm.com>
28194da to
184805f
Compare
- Add version.h (v1.00.1.7) with version constants and registry key definitions - Add version comparison, /query, /force, /version, /help CLI options to installer - Auto-uninstall old driver packages on upgrade before installing new ones - Record installed version, INF list, and install date in registry - Include version in packaged installer filename (QcomUsbDriverInstaller_<ver>.exe) - Update README with installer CLI reference and building instructions - Update .gitignore for versioned installer filename pattern
Before installing, the installer now detects and removes three types of conflicting packages: 1. Previous userspace installations (tracked in registry INF list) 2. Kernel-mode driver packages: qcfilter, qcwwan, qdbusb, qcwdfmdm, qcwdfser 3. Legacy QPM-managed packages: QUD, QUD.internal, Qualcomm_Userspace_Driver All conflict removal is non-fatal — installation proceeds even if a package is not found or removal fails. Updated README with conflict detection table.
Signed-off-by: chehan <chehan@qti.qualcomm.com>
Signed-off-by: chehan <chehan@qti.qualcomm.com>
Signed-off-by: chehan <chehan@qti.qualcomm.com>
Signed-off-by: chehan <chehan@qti.qualcomm.com>
Signed-off-by: chehan <chehan@qti.qualcomm.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Remove the kernel-mode USB filter driver from the Windows variant of this userspace-only repository, and introduce a self-extracting installer that manages driver lifecycle — including version tracking, upgrade/downgrade logic, and automatic detection and removal of all conflicting driver packages.
Changes
1. Remove kernel filter driver and build artifacts (184805f)
The kernel-mode USB filter driver (
qcusbfilter.sys) and pre-built.catcatalog files do not belong in a userspace driver repository.src/windows/filter/directory (qcusbfilter binaries for amd64/arm/arm64/i386)src/windows/qcfilter.inf(kernel filter driver INF).catfiles from version control (build artifacts, not source)src/windows/build.bat— generates.catcatalog files usinginf2catsrc/windows/sign.bat— production code-signing script usingsigntool.gitignore— excludes.catfiles and build artifacts2. Add self-extracting installer with version tracking (63bc4a0)
A new Windows installer packages all INF+CAT driver files into a single self-extracting EXE with an appended ZIP payload and binary trailer.
New files:
src/windows/installer/install.c— Installer C source (~1100 lines)src/windows/installer/version.h— Version constants (v1.00.1.7), package name, registry key definitionssrc/windows/installer/CMakeLists.txt— CMake build configuration (MSVC, UAC elevation manifest)src/windows/installer/package.py— Python script to create ZIP payload and append trailer with CRC32src/windows/installer/package.bat— One-command build+package scriptsrc/windows/installer/miniz.c,miniz.h,miniz-LICENSE— Embedded ZIP decompression (public domain)Installer features:
qcom-usb-userspace-drivers.exeqcom-usb-userspace-drivers.exe /queryqcom-usb-userspace-drivers.exe /forceqcom-usb-userspace-drivers.exe /versionqcom-usb-userspace-drivers.exe /helpHKLM\SOFTWARE\Qualcomm\QcomUsbDrivers/forceto override)qcom-usb-userspace-drivers_1.00.1.7.exe3. Add conflicting driver package detection and removal (61abd29)
Before installing (both fresh and upgrade), the installer automatically detects and removes all conflicting driver packages in this order:
QUD,QUD.internal,Qualcomm_Userspace_Driver)qpm-cliavailability on PATHqpm-cli --uninstall <package>HKLM\SOFTWARE\Qualcomm\QcomUsbDriverspnputil /delete-driverper INFqcfilter,qcwwan,qdbusb,qcwdfmdm,qcwdfser)pnputil /enum-driversmatching original INF namepnputil /delete-driver /uninstall /forceAll conflict removal is non-fatal — if a package is not found or removal fails, installation proceeds normally.
Enhanced
/querycommand reports four sections:README updates
package.batTesting
cd src\windows\installer && package.bat/querywith no drivers installed/querywith kernel drivers present/querywith legacy QPM packages/forcereinstall and downgrade/versionand/helpoutput