reloading Pci driver without reboot

Discussion in 'Windows Vista Drivers' started by Bogac, Apr 24, 2007.

  1. Bogac

    Bogac Guest

    hi all

    I am currently working on a new pci card with MPC8280. i wrote a windows
    driver that uses in bound translation and i use translated adress in windows
    driver to reach the mpc8280's internal map. it is working fine however, when
    card resets my driver doesn't reach internal map any more and i have to
    reboot the windows.
    Is there any solution for reloading driver dynamically on windows without
    restart. Or am i not evaluate some point in trasnlation ?

    Thanks Regards

    Bogac TURGUT
     
    Bogac, Apr 24, 2007
    #1
    1. Advertisements

  2. Surely yes. Just use Device Manager or command-line DEVCON.EXE.
     
    Maxim S. Shatskih, Apr 24, 2007
    #2
    1. Advertisements

  3. Bogac

    Bogac Guest

    thanks for advice however its not the solution for my problem.
    when i disable and after enable routine on device manager. i still can't use
    the driver and
    the translated adress of pci internal memory couldn't read by driver.

    when driver is stop and start in device manager, do my driver StartDevice()
    functions routine work?
     
    Bogac, Apr 24, 2007
    #3
  4. when driver is stop and start in device manager, do my driver StartDevice()
    Yes.
     
    Maxim S. Shatskih, Apr 24, 2007
    #4
  5. Bogac

    Bogac Guest

    but starting in device a manager ask restart question.
    is there any way to disapare this message and how can i stop in driver in
    code. is there any ioctl code for this?

    Why i can't still reach translated adress after starting device driver?

    thank again
     
    Bogac, Apr 24, 2007
    #5
  6. Bogac

    Mark Roddy Guest


    Yes sure see the devcon sample in the ddk. It shows you how to stop
    start disable enable install and replace devices and device drivers.

    However that is not really your problem. Your problem as you stated
    originally was that "when card resets my driver doesn't reach internal
    map any more", and that is either a problem in your hardware or a
    problem in how your driver manages your hardware, or both.


    =====================
    Mark Roddy DDK MVP
    Windows Vista/2003/XP Consulting
    Device and Filesystem Drivers
    Broken Driver Code? Call us.
    Hollis Technology Solutions 603-321-1032
    www.hollistech.com
     
    Mark Roddy, Apr 25, 2007
    #6
  7. Bogac

    Bogac Guest

    My detailed problem is;

    in my driver StartDevice() function makes all mapping IO resources. when
    i am reacheing the 8280 internal memory i am using this translated adress
    however when card resets this mapping is gone. in 8280 "the reset
    configuration for the windows is disabled;that is, after reset, the pci brige
    does not acknowledge externally mastered transactions on the pci bus by
    asserting DEVSELuntil the inboun translation windows are enabled." should you
    inform me about what happened in windows xp when a card reset. can pci bus
    driver detect the reset or so on ?
     
    Bogac, Apr 25, 2007
    #7
  8. Bogac

    Mark Roddy Guest

    I'd have to go read the many specs for the mpc8280 to figure this out.
    You are asking a rather detailed hardware specific question whose
    answer really depends on what exactly happens when what you call a
    'card reset' occurs. In general the OS is not going to manage an
    internal operation on a device.



    =====================
    Mark Roddy DDK MVP
    Windows Vista/2003/XP Consulting
    Device and Filesystem Drivers
    Broken Driver Code? Call us.
    Hollis Technology Solutions 603-321-1032
    www.hollistech.com
     
    Mark Roddy, Apr 25, 2007
    #8
  9. Any well designed ASIC should NOT reset its PCI interface during soft (not
    power-on) reset.
     
    Alexander Grigoriev, Apr 25, 2007
    #9
  10. Bogac

    Koen Guest

    Bogac,

    I do not know your device but you may want to try to eject your device
    using IoRequestDeviceEject(). Your driver will be unloaded and the pci
    drivere will re-enumerate the bus, causing your driver to be reloaded
    and its resources to be assigned again.
    Make sure to set the EjectSupported & Removable flags in your
    IRP_MJ_PNP / IRP_MN_QUERY_CAPABILITIES handler.

    Koen
     
    Koen, Apr 26, 2007
    #10
    1. Advertisements

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.