Saturday, December 7, 2024

Is There a Sample Driver?

Yes, you may get it over here. The sample driver, which demonstrates presence of a bus filter by adding a new compatible ID, "BffDevice", to the compatible IDs list, must be installed on Windows 7 or higher, x86.

If you have an old CalDight T3/T4, you may also try the experimental driver, which will add "BffDevice" compatible ID to each of the disks inserted to T3/T4. Thereafter, you may run as administrator asm106x\create_raid_volume.ps1 in PowerShell to create a RAID 5 volume with those disks.

Caution: Make sure you have backed up data in your disks before you run asm106x\create_raid_volume.ps1.

Friday, June 17, 2016

May I Make a Feature Request?

Yes, please fill this form. Please note that not every feature request will be accepted.

How Do I Get the WDM Device Object of a Bus Filter?

BFF provides the following routine for this purpose:
PDEVICE_OBJECT BffDeviceWdmGetDeviceObject(WDFOBJECT BffDevice);

where BffDevice is the WDF general object handle to the bus filter device object.

Thursday, June 16, 2016

BffDeviceWdmGetPhysicalDevice

Description


Retrieve the PDO from the device stack of the specified WDF object.

Declaration

PDEVICE_OBJECT BffDeviceWdmGetPhysicalDevice(WDFOBJECT BffDevice);

Parameter


BffDeviceThe WDF object as a bus filter device object.

Return value


The PDO for success; NULL otherwise.

BffDeviceWdmGetAttachedDevice

Description


Retrieve the next lower WDM device object in the device stack of the specified WDF object.

Declaration

PDEVICE_OBJECT BffDeviceWdmGetAttachedDevice(WDFOBJECT BffDevice);

Parameter


BffDeviceThe WDF object as a bus filter device object.

Return value


The next lower WDM device object for success; NULL otherwise.

BffDeviceWdmGetDeviceObject

Description


Retrieve the WDM bus filter device object that is associated with the specified WDF object.

Declaration

PDEVICE_OBJECT BffDeviceWdmGetDeviceObject(WDFOBJECT BffDevice);

Parameter


BffDeviceThe WDF object as a bus filter device object.

Return value


The WDM bus filter device object for success; NULL otherwise.

BffPreprocessQueryBusRelations

Description


The callback function for an upper filter driver to preprocess IRP_MN_QUERY_DEVICE_RELATIONS/BusRelations before KMDF. This routine can be passed as EvtDeviceWdmIrpPreprocess into WdfDeviceInitAssignWdmIrpPreprocessCallback for IRP_MJ_PNP/IRP_MN_QUERY_DEVICE_RELATIONS, or be invoked in an upper filter driver's EvtDeviceWdmIrpPreprocess callback function. In the latter case, the upper filter driver must return the value that this routine returns.

Declaration

NTSTATUS BffPreprocessQueryBusRelations(WDFDEVICE Device, PIRP Irp);

Parameters


DeviceThe WDF device object representing an upper filter device object.
IrpThe IRP_MN_QUERY_DEVICE_RELATIONS I/O request packet.

Return value


The value that WdfDeviceWdmDispatchPreprocessedIrp returns.