Installing PCI filter driver without reboot.

Hi all,

I’m new to windows driver development. I’m trying to install a PCI upper filter driver to communicate with the PCI Bus driver from my Application. Is it possible to achieve this without rebooting the system? I want to load, get the required information, and unload the driver from my application.

Requirement:
The original requirement is to read the ABAR of the AHCI controller in the system sitting on the PCI bus for which i need to read the config space of the controller. There are follwing ways that I have found for doing so:

  1. Read/Write using PCI IO Ports (0xcf8 and 0xcfc). Ideally, except for the device driver, nobody should do this as amny people in many forums have pointed out that this could lead to disaster in worst case.

  2. Getting PCI driver object using ObReferenceObjectByName which is no longer supported by the DDK.

  3. Using HalGetBusData() which is again not supported by the DDK.

  4. Put a filter driver above the PCI bus driver and create a symbolic link for that. Then, directly open a handle to it and communicate with it to get the information. This, as most people suggest, is the ideal approach. But AFAIK, putting a upper filter driver on PCI devnode requires a reboot. Can this be avoided by any means?

Thanks in advance for any help!!!

A filter doesn’t solve the exclusive access to the io ports problem either. What bigger problem are you trying to solve?

-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Tuesday, August 07, 2012 10:26 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] Installing PCI filter driver without reboot.

Hi all,

I’m new to windows driver development. I’m trying to install a PCI upper filter driver to communicate with the PCI Bus driver from my Application. Is it possible to achieve this without rebooting the system? I want to load, get the required information, and unload the driver from my application.

Requirement:
The original requirement is to read the ABAR of the AHCI controller in the system sitting on the PCI bus for which i need to read the config space of the controller. There are follwing ways that I have found for doing so:

  1. Read/Write using PCI IO Ports (0xcf8 and 0xcfc). Ideally, except for the device driver, nobody should do this as amny people in many forums have pointed out that this could lead to disaster in worst case.

  2. Getting PCI driver object using ObReferenceObjectByName which is no longer supported by the DDK.

  3. Using HalGetBusData() which is again not supported by the DDK.

  4. Put a filter driver above the PCI bus driver and create a symbolic link for that. Then, directly open a handle to it and communicate with it to get the information. This, as most people suggest, is the ideal approach. But AFAIK, putting a upper filter driver on PCI devnode requires a reboot. Can this be avoided by any means?

Thanks in advance for any help!!!


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

The problem is as I have mentioned in my message - Reading HBA Memory
Registers of any AHCI controller connected to PCI Bus in the system.

I’m not writing the filter to have exclusive access to IO Ports. The idea
is that the filter driver can query for bus interface of the PCI bus driver
and directly call ReadConfig to get the config space of any PCI device.

On Wed, Aug 8, 2012 at 11:15 AM, Doron Holan wrote:

> A filter doesn’t solve the exclusive access to the io ports problem
> either. What bigger problem are you trying to solve?
>
> -----Original Message-----
> From: xxxxx@lists.osr.com [mailto:
> xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
> Sent: Tuesday, August 07, 2012 10:26 PM
> To: Windows System Software Devs Interest List
> Subject: [ntdev] Installing PCI filter driver without reboot.
>
> Hi all,
>
> I’m new to windows driver development. I’m trying to install a PCI upper
> filter driver to communicate with the PCI Bus driver from my Application.
> Is it possible to achieve this without rebooting the system? I want to
> load, get the required information, and unload the driver from my
> application.
>
> Requirement:
> The original requirement is to read the ABAR of the AHCI controller in the
> system sitting on the PCI bus for which i need to read the config space of
> the controller. There are follwing ways that I have found for doing so:
>
> 1) Read/Write using PCI IO Ports (0xcf8 and 0xcfc). Ideally, except for
> the device driver, nobody should do this as amny people in many forums have
> pointed out that this could lead to disaster in worst case.
>
> 2) Getting PCI driver object using ObReferenceObjectByName which is no
> longer supported by the DDK.
>
> 3) Using HalGetBusData() which is again not supported by the DDK.
>
> 4) Put a filter driver above the PCI bus driver and create a symbolic link
> for that. Then, directly open a handle to it and communicate with it to get
> the information. This, as most people suggest, is the ideal approach. But
> AFAIK, putting a upper filter driver on PCI devnode requires a reboot. Can
> this be avoided by any means?
>
> Thanks in advance for any help!!!
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Doesn’t work that way. What problem are you solving by reading the hba memory registers?

From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of Anirudha Kumar
Sent: Tuesday, August 07, 2012 11:04 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Installing PCI filter driver without reboot.

The problem is as I have mentioned in my message - Reading HBA Memory Registers of any AHCI controller connected to PCI Bus in the system.

I’m not writing the filter to have exclusive access to IO Ports. The idea is that the filter driver can query for bus interface of the PCI bus driver and directly call ReadConfig to get the config space of any PCI device.

On Wed, Aug 8, 2012 at 11:15 AM, Doron Holan > wrote:
A filter doesn’t solve the exclusive access to the io ports problem either. What bigger problem are you trying to solve?

-----Original Message-----
From: xxxxx@lists.osr.commailto:xxxxx [mailto:xxxxx@lists.osr.commailto:xxxxx] On Behalf Of xxxxx@gmail.commailto:xxxxx
Sent: Tuesday, August 07, 2012 10:26 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] Installing PCI filter driver without reboot.

Hi all,

I’m new to windows driver development. I’m trying to install a PCI upper filter driver to communicate with the PCI Bus driver from my Application. Is it possible to achieve this without rebooting the system? I want to load, get the required information, and unload the driver from my application.

Requirement:
The original requirement is to read the ABAR of the AHCI controller in the system sitting on the PCI bus for which i need to read the config space of the controller. There are follwing ways that I have found for doing so:

1) Read/Write using PCI IO Ports (0xcf8 and 0xcfc). Ideally, except for the device driver, nobody should do this as amny people in many forums have pointed out that this could lead to disaster in worst case.

2) Getting PCI driver object using ObReferenceObjectByName which is no longer supported by the DDK.

3) Using HalGetBusData() which is again not supported by the DDK.

4) Put a filter driver above the PCI bus driver and create a symbolic link for that. Then, directly open a handle to it and communicate with it to get the information. This, as most people suggest, is the ideal approach. But AFAIK, putting a upper filter driver on PCI devnode requires a reboot. Can this be avoided by any means?

Thanks in advance for any help!!!


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer</mailto:xxxxx></mailto:xxxxx></mailto:xxxxx>

These registers hold properties of the Controller like SATA mode supported,
capabilities, etc.

On Wed, Aug 8, 2012 at 11:40 AM, Doron Holan wrote:

> Doesn?t work that way. What problem are you solving by reading the hba
> memory registers?
>
>
>
> From: xxxxx@lists.osr.com [mailto:
> xxxxx@lists.osr.com] *On Behalf Of *Anirudha Kumar
> Sent: Tuesday, August 07, 2012 11:04 PM
>
> To: Windows System Software Devs Interest List
> Subject: Re: [ntdev] Installing PCI filter driver without reboot.
>
>
>
> The problem is as I have mentioned in my message - Reading HBA Memory
> Registers of any AHCI controller connected to PCI Bus in the system.
>
>
>
> I’m not writing the filter to have exclusive access to IO Ports. The idea
> is that the filter driver can query for bus interface of the PCI bus driver
> and directly call ReadConfig to get the config space of any PCI device.
>
>
>
> On Wed, Aug 8, 2012 at 11:15 AM, Doron Holan
> wrote:
>
> A filter doesn’t solve the exclusive access to the io ports problem
> either. What bigger problem are you trying to solve?
>
>
> -----Original Message-----
> From: xxxxx@lists.osr.com [mailto:
> xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
> Sent: Tuesday, August 07, 2012 10:26 PM
> To: Windows System Software Devs Interest List
> Subject: [ntdev] Installing PCI filter driver without reboot.
>
> Hi all,
>
> I’m new to windows driver development. I’m trying to install a PCI upper
> filter driver to communicate with the PCI Bus driver from my Application.
> Is it possible to achieve this without rebooting the system? I want to
> load, get the required information, and unload the driver from my
> application.
>
> Requirement:
> The original requirement is to read the ABAR of the AHCI controller in the
> system sitting on the PCI bus for which i need to read the config space of
> the controller. There are follwing ways that I have found for doing so:
>
> 1) Read/Write using PCI IO Ports (0xcf8 and 0xcfc). Ideally, except for
> the device driver, nobody should do this as amny people in many forums have
> pointed out that this could lead to disaster in worst case.
>
> 2) Getting PCI driver object using ObReferenceObjectByName which is no
> longer supported by the DDK.
>
> 3) Using HalGetBusData() which is again not supported by the DDK.
>
> 4) Put a filter driver above the PCI bus driver and create a symbolic link
> for that. Then, directly open a handle to it and communicate with it to get
> the information. This, as most people suggest, is the ideal approach. But
> AFAIK, putting a upper filter driver on PCI devnode requires a reboot. Can
> this be avoided by any means?
>
> Thanks in advance for any help!!!
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
>
> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit
> the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Which are controlled by the ahci driver. Why are you poking around in registers another driver owns?

d

debt from my phone


From: Anirudha Kumar
Sent: 8/7/2012 11:16 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Installing PCI filter driver without reboot.

These registers hold properties of the Controller like SATA mode supported, capabilities, etc.

On Wed, Aug 8, 2012 at 11:40 AM, Doron Holan > wrote:
Doesn?t work that way. What problem are you solving by reading the hba memory registers?

From: xxxxx@lists.osr.commailto:xxxxx [mailto:xxxxx@lists.osr.commailto:xxxxx] On Behalf Of Anirudha Kumar
Sent: Tuesday, August 07, 2012 11:04 PM

To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Installing PCI filter driver without reboot.

The problem is as I have mentioned in my message - Reading HBA Memory Registers of any AHCI controller connected to PCI Bus in the system.

I’m not writing the filter to have exclusive access to IO Ports. The idea is that the filter driver can query for bus interface of the PCI bus driver and directly call ReadConfig to get the config space of any PCI device.

On Wed, Aug 8, 2012 at 11:15 AM, Doron Holan > wrote:
A filter doesn’t solve the exclusive access to the io ports problem either. What bigger problem are you trying to solve?

-----Original Message-----
From: xxxxx@lists.osr.commailto:xxxxx [mailto:xxxxx@lists.osr.commailto:xxxxx] On Behalf Of xxxxx@gmail.commailto:xxxxx
Sent: Tuesday, August 07, 2012 10:26 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] Installing PCI filter driver without reboot.

Hi all,

I’m new to windows driver development. I’m trying to install a PCI upper filter driver to communicate with the PCI Bus driver from my Application. Is it possible to achieve this without rebooting the system? I want to load, get the required information, and unload the driver from my application.

Requirement:
The original requirement is to read the ABAR of the AHCI controller in the system sitting on the PCI bus for which i need to read the config space of the controller. There are follwing ways that I have found for doing so:

1) Read/Write using PCI IO Ports (0xcf8 and 0xcfc). Ideally, except for the device driver, nobody should do this as amny people in many forums have pointed out that this could lead to disaster in worst case.

2) Getting PCI driver object using ObReferenceObjectByName which is no longer supported by the DDK.

3) Using HalGetBusData() which is again not supported by the DDK.

4) Put a filter driver above the PCI bus driver and create a symbolic link for that. Then, directly open a handle to it and communicate with it to get the information. This, as most people suggest, is the ideal approach. But AFAIK, putting a upper filter driver on PCI devnode requires a reboot. Can this be avoided by any means?

Thanks in advance for any help!!!


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer</mailto:xxxxx></mailto:xxxxx></mailto:xxxxx></mailto:xxxxx></mailto:xxxxx>

> 4) Put a filter driver above the PCI bus driver and create a symbolic link for that.

  1. Open the AHCI’s driver devnode by name from kmode and send MN_QUERY_INTERFACE to it, then call the functions of this interface.


Maxim S. Shatskih
Windows DDK MVP
xxxxx@storagecraft.com
http://www.storagecraft.com

Actually, the ABAR in its PCI Config Space contains the address where the
Hba memory registers are mapped. If you know how to get this information
from the Controller driver, please share. But AFAIK, the miniport driver
also gets this information from tue storage class driver which in turn
retrives his information using the same technique that i’m trying to use.
Also, I already have a filter driver throuh which i’m able to get he ABAR
of that controller and then map it to the kernel space and read it. Problem
is i have to restart the system to install this driver which i cannot
afford.
On Aug 8, 2012 12:18 PM, “Doron Holan” wrote:

> Which are controlled by the ahci driver. Why are you poking around in
> registers another driver owns?
>
> d
>
> debt from my phone
> ------------------------------
> From: Anirudha Kumar
> Sent: 8/7/2012 11:16 PM
> To: Windows System Software Devs Interest List
> Subject: Re: [ntdev] Installing PCI filter driver without reboot.
>
> These registers hold properties of the Controller like SATA mode
> supported, capabilities, etc.
>
> On Wed, Aug 8, 2012 at 11:40 AM, Doron Holan wrote:
>
>> Doesn?t work that way. What problem are you solving by reading the hba
>> memory registers?
>>
>>
>>
>> From: xxxxx@lists.osr.com [mailto:
>> xxxxx@lists.osr.com] *On Behalf Of *Anirudha Kumar
>> Sent: Tuesday, August 07, 2012 11:04 PM
>>
>> To: Windows System Software Devs Interest List
>> Subject: Re: [ntdev] Installing PCI filter driver without reboot.
>>
>>
>>
>> The problem is as I have mentioned in my message - Reading HBA Memory
>> Registers of any AHCI controller connected to PCI Bus in the system.
>>
>>
>>
>> I’m not writing the filter to have exclusive access to IO Ports. The idea
>> is that the filter driver can query for bus interface of the PCI bus driver
>> and directly call ReadConfig to get the config space of any PCI device.
>>
>>
>>
>> On Wed, Aug 8, 2012 at 11:15 AM, Doron Holan
>> wrote:
>>
>> A filter doesn’t solve the exclusive access to the io ports problem
>> either. What bigger problem are you trying to solve?
>>
>>
>> -----Original Message-----
>> From: xxxxx@lists.osr.com [mailto:
>> xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
>> Sent: Tuesday, August 07, 2012 10:26 PM
>> To: Windows System Software Devs Interest List
>> Subject: [ntdev] Installing PCI filter driver without reboot.
>>
>> Hi all,
>>
>> I’m new to windows driver development. I’m trying to install a PCI upper
>> filter driver to communicate with the PCI Bus driver from my Application.
>> Is it possible to achieve this without rebooting the system? I want to
>> load, get the required information, and unload the driver from my
>> application.
>>
>> Requirement:
>> The original requirement is to read the ABAR of the AHCI controller in
>> the system sitting on the PCI bus for which i need to read the config space
>> of the controller. There are follwing ways that I have found for doing so:
>>
>> 1) Read/Write using PCI IO Ports (0xcf8 and 0xcfc). Ideally, except for
>> the device driver, nobody should do this as amny people in many forums have
>> pointed out that this could lead to disaster in worst case.
>>
>> 2) Getting PCI driver object using ObReferenceObjectByName which is no
>> longer supported by the DDK.
>>
>> 3) Using HalGetBusData() which is again not supported by the DDK.
>>
>> 4) Put a filter driver above the PCI bus driver and create a symbolic
>> link for that. Then, directly open a handle to it and communicate with it
>> to get the information. This, as most people suggest, is the ideal
>> approach. But AFAIK, putting a upper filter driver on PCI devnode requires
>> a reboot. Can this be avoided by any means?
>>
>> Thanks in advance for any help!!!
>>
>> —
>> NTDEV is sponsored by OSR
>>
>> For our schedule of WDF, WDM, debugging and other seminars visit:
>> http://www.osr.com/seminars
>>
>> To unsubscribe, visit the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>>
>>
>> —
>> NTDEV is sponsored by OSR
>>
>> For our schedule of WDF, WDM, debugging and other seminars visit:
>> http://www.osr.com/seminars
>>
>> To unsubscribe, visit the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>>
>> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
>> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit
>> the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>> —
>> NTDEV is sponsored by OSR
>>
>> For our schedule of WDF, WDM, debugging and other seminars visit:
>> http://www.osr.com/seminars
>>
>> To unsubscribe, visit the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>
> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit
> the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Hi maxim,

Can you please elaborate or point me to some document explaining the
interface provided by Ahci driver? Also is it mandatory for Ahci driver
providers to implements this interface? Because many vendors replace the
Ahci driver provided by MS but nobody replaces the PCI driver…
On Aug 8, 2012 12:45 PM, “Maxim S. Shatskih” wrote:

> > 4) Put a filter driver above the PCI bus driver and create a symbolic
> link for that.
>
> 5) Open the AHCI’s driver devnode by name from kmode and send
> MN_QUERY_INTERFACE to it, then call the functions of this interface.
>
> –
> Maxim S. Shatskih
> Windows DDK MVP
> xxxxx@storagecraft.com
> http://www.storagecraft.com
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

See if WMI with MS_SM* classes allows you to get the required information.

No, they don’t. I havn’t found any class which gives AHCI specific
information. Also, if I can access the ACPI tables using any of these
classes, I can read the address where the whole PCI config space is mapped.
But, it appears that its impossible to get the ACPI tables in Win XP.

On Wed, Aug 8, 2012 at 9:54 PM, wrote:

> See if WMI with MS_SM* classes allows you to get the required information.
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Can anybody give a simple yes/no answer to my question:

Is it possible to install PCI filter driver without reboot???

On Thu, Aug 9, 2012 at 10:37 AM, Anirudha Kumar wrote:

> No, they don’t. I havn’t found any class which gives AHCI specific
> information. Also, if I can access the ACPI tables using any of these
> classes, I can read the address where the whole PCI config space is mapped.
> But, it appears that its impossible to get the ACPI tables in Win XP.
>
>
> On Wed, Aug 8, 2012 at 9:54 PM, wrote:
>
>> See if WMI with MS_SM* classes allows you to get the required information.
>>
>> —
>> NTDEV is sponsored by OSR
>>
>> For our schedule of WDF, WDM, debugging and other seminars visit:
>> http://www.osr.com/seminars
>>
>> To unsubscribe, visit the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>>
>
>

It is not possible

d

debt from my phone


From: Anirudha Kumar
Sent: 8/8/2012 10:14 PM
To: Windows System Software Devs Interest List
Subject: Re: [ntdev] Installing PCI filter driver without reboot.

Can anybody give a simple yes/no answer to my question:

Is it possible to install PCI filter driver without reboot???

On Thu, Aug 9, 2012 at 10:37 AM, Anirudha Kumar > wrote:
No, they don’t. I havn’t found any class which gives AHCI specific information. Also, if I can access the ACPI tables using any of these classes, I can read the address where the whole PCI config space is mapped. But, it appears that its impossible to get the ACPI tables in Win XP.

On Wed, Aug 8, 2012 at 9:54 PM, > wrote:
See if WMI with MS_SM* classes allows you to get the required information.


NTDEV is sponsored by OSR

For our schedule of WDF, WDM, debugging and other seminars visit:
http://www.osr.com/seminars

To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

— NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the List Server section of OSR Online at http://www.osronline.com/page.cfm?name=ListServer

>mapped. But, it appears that its impossible to get the ACPI tables in Win XP.

Correct, the Windows paradigm is that there is only 1 driver for each device, who is of a total control over it.

So, the really correct way for you would be to replace the AHCI driver with your own.


Maxim S. Shatskih
Windows DDK MVP
xxxxx@storagecraft.com
http://www.storagecraft.com

Hi Maxim,

I tried this. I called IoGetDeviceObjectPointer to get pdo for the AHCI
controller. Using this pdo I sent IPR_MN_QUERY_INTERFACE to get the bus
interface but IRP fails with status STATUS_NOT_SUPPORTED (0xc00000bb). What
could be going wrong? Does my AHCI controller driver doesn’t supports
QUERY_INTERFACE? Or there’s something wrong in the code?

Anirudha

On Wed, Aug 8, 2012 at 12:43 PM, Maxim S. Shatskih
wrote:

> > 4) Put a filter driver above the PCI bus driver and create a symbolic
> link for that.
>
> 5) Open the AHCI’s driver devnode by name from kmode and send
> MN_QUERY_INTERFACE to it, then call the functions of this interface.
>
> –
> Maxim S. Shatskih
> Windows DDK MVP
> xxxxx@storagecraft.com
> http://www.storagecraft.com
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Anirudha Kumar wrote:

Can anybody give a simple yes/no answer to my question:

Is it possible to install PCI filter driver without reboot???

That depends. If the driver you are filtering is correctly set up to
handle it, and the device is not currently being used by anyone, you can
install the driver and then restart the device (using “devcon restart”
or “devcon disable/enable”).

However, a measurable percentage of PCI drivers assume they will never
be removed, so it’s a gamble.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

Ok, so bottom line, I cannot install PCI filter driver without reboot. So,
I’m thinking of using direct PCI IO port read/write (cfc/cf8) approach. If
anybody has practically faced any issue with this approach, please reply
back with the problem. I’m not gonna be doing this very frequently. In
fact, I’ll do it only once every system restart and that too only once the
system has booted up. Practically, I havn’t seen any crashes due to the use
of utilities like PCITree which use this approach.

Thanks in advance. Any information will be appreciated.

Anirudha

On Thu, Aug 9, 2012 at 11:08 PM, Tim Roberts wrote:

> Anirudha Kumar wrote:
> > Can anybody give a simple yes/no answer to my question:
> >
> > Is it possible to install PCI filter driver without reboot???
>
> That depends. If the driver you are filtering is correctly set up to
> handle it, and the device is not currently being used by anyone, you can
> install the driver and then restart the device (using “devcon restart”
> or “devcon disable/enable”).
>
> However, a measurable percentage of PCI drivers assume they will never
> be removed, so it’s a gamble.
>
> –
> Tim Roberts, xxxxx@probo.com
> Providenza & Boekelheide, Inc.
>
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Well I had random crashes on client systems because of shit like this.
In the end they sued the little company that had done that crap. If you
really want this, install a filter once and only use it when needed.
Even then be careful, PCI bus filters are not documented on how to do
them, and there are no good examples. I did one once successfully (at
least I think) but I had seen the PCI driver source.

Don Burn
Windows Filesystem and Driver Consulting
Website: http://www.windrvr.com
Blog: http://msmvps.com/blogs/WinDrvr

“Anirudha Kumar” wrote in message
news:xxxxx@ntdev:

> Ok, so bottom line, I cannot install PCI filter driver without reboot. So,
> I’m thinking of using direct PCI IO port read/write (cfc/cf8) approach. If
> anybody has practically faced any issue with this approach, please reply
> back with the problem. I’m not gonna be doing this very frequently. In
> fact, I’ll do it only once every system restart and that too only once the
> system has booted up. Practically, I havn’t seen any crashes due to the use
> of utilities like PCITree which use this approach.
>
> Thanks in advance. Any information will be appreciated.
>
> Anirudha
>
> On Thu, Aug 9, 2012 at 11:08 PM, Tim Roberts wrote:
>
> > Anirudha Kumar wrote:
> > > Can anybody give a simple yes/no answer to my question:
> > >
> > > Is it possible to install PCI filter driver without reboot???
> >
> > That depends. If the driver you are filtering is correctly set up to
> > handle it, and the device is not currently being used by anyone, you can
> > install the driver and then restart the device (using “devcon restart”
> > or “devcon disable/enable”).
> >
> > However, a measurable percentage of PCI drivers assume they will never
> > be removed, so it’s a gamble.
> >
> > –
> > Tim Roberts, xxxxx@probo.com
> > Providenza & Boekelheide, Inc.
> >
> >
> > —
> > NTDEV is sponsored by OSR
> >
> > For our schedule of WDF, WDM, debugging and other seminars visit:
> > http://www.osr.com/seminars
> >
> > To unsubscribe, visit the List Server section of OSR Online at
> > http://www.osronline.com/page.cfm?name=ListServer
> >

Anirudha Kumar wrote:

Ok, so bottom line, I cannot install PCI filter driver without reboot.
So, I’m thinking of using direct PCI IO port read/write (cfc/cf8)
approach. If anybody has practically faced any issue with this
approach, please reply back with the problem.

The problem is that you do not own those I/O ports. The CF8/CFC pair
are an index/data set. If the PCI bus driver writes to CF8, then you
come in and change CF8 before the other bus driver writes to CFC, then
you have a screwup. There is no way to defend against that, because
there’s no interlocking – the PCI bus driver knows that he owns that
resource.


Tim Roberts, xxxxx@probo.com
Providenza & Boekelheide, Inc.

You will break many platforms doing that. A very bad idea that you
have been repeatedly told is a very bad idea.

Mark Roddy

On Fri, Aug 10, 2012 at 4:52 AM, Anirudha Kumar wrote:
> Ok, so bottom line, I cannot install PCI filter driver without reboot. So,
> I’m thinking of using direct PCI IO port read/write (cfc/cf8) approach. If
> anybody has practically faced any issue with this approach, please reply
> back with the problem. I’m not gonna be doing this very frequently. In fact,
> I’ll do it only once every system restart and that too only once the system
> has booted up. Practically, I havn’t seen any crashes due to the use of
> utilities like PCITree which use this approach.
>
> Thanks in advance. Any information will be appreciated.
>
> Anirudha
>
> On Thu, Aug 9, 2012 at 11:08 PM, Tim Roberts wrote:
>>
>> Anirudha Kumar wrote:
>> > Can anybody give a simple yes/no answer to my question:
>> >
>> > Is it possible to install PCI filter driver without reboot???
>>
>> That depends. If the driver you are filtering is correctly set up to
>> handle it, and the device is not currently being used by anyone, you can
>> install the driver and then restart the device (using “devcon restart”
>> or “devcon disable/enable”).
>>
>> However, a measurable percentage of PCI drivers assume they will never
>> be removed, so it’s a gamble.
>>
>> –
>> Tim Roberts, xxxxx@probo.com
>> Providenza & Boekelheide, Inc.
>>
>>
>> —
>> NTDEV is sponsored by OSR
>>
>> For our schedule of WDF, WDM, debugging and other seminars visit:
>> http://www.osr.com/seminars
>>
>> To unsubscribe, visit the List Server section of OSR Online at
>> http://www.osronline.com/page.cfm?name=ListServer
>
>
> — NTDEV is sponsored by OSR For our schedule of WDF, WDM, debugging and
> other seminars visit: http://www.osr.com/seminars To unsubscribe, visit the
> List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer