aic7xxx and hotplug
Subsystems (2)
So following my previous post concerning my APA1480 card, here is a patch that solve my problem. I intent to push it to the driver maintener if you agree with it. It only export the pci table but I have to include the module.h before that.
It works as expected but It's not yet clear in my mind so could you please try to answer to the following questions:
1. Are we supposed to unload module before removing a card. When I remove a card I see something like cb_free(20) but the driver is not unloaded.
I was expecting at least to see something indicating that a device was removed at the module level (the cb_free comes from the cardbus code level).
I looks like the removing of the card is not passed to the hotplug code.
2. My undersatnding about cardbus is that is look like a pci2pci bridge. What's about 16bits pcmcia cards ? Is it possible to integrate this kind of cards in the hotplug framework (like is ISApnp) ?
3. My adaptec card is often not detected. With the pcmcia-cs stuff it's detected each time but most of the time the card is seen as a 16 bits card. Then I imagine that when the hotplug stuff fails to detect my card it's because it's detected, at the HW level, as a 16 bits card. I suspect that the problem is with my card and not in my laptop.
This makes sense to you or you think it's a SW bug ?
Thanks,
Christophe
Signature · 2 lines
Christophe Barbé <[email protected]> GnuPG FingerPrint: E0F6 FADF 2A5C F072 6AF8 F67A 8F45 2F1E D72C B41E
drivers/scsi/aic7xxx/aic7xxx_linux_pci.c +5 -0
@@ -33,6 +33,9 @@#include "aic7xxx_osm.h" +#define __NO_VERSION__ +#include <linux/module.h> +#if LINUX_VERSION_CODE <KERNEL_VERSION (2 ,4 ,0 )struct pci_device_id {
@@ -56,6 +59,8 @@ }, { 0 } }; + +MODULE_DEVICE_TABLE (pci, ahc_linux_pci_id_table);struct pci_driver aic7xxx_pci_driver = { name:"aic7xxx" ,
Quoted 4 lines · christophe barbe
2. My undersatnding about cardbus is that is look like a pci2pci bridge. What's about 16bits pcmcia cards ? Is it possible to integrate this kind of cards in the hotplug framework (like is ISApnp) ?
In principle yes but it will require a rewrite of some parts of the PCMCIA support code.
Quoted 5 lines
3. My adaptec card is often not detected. With the pcmcia-cs stuff it's detected each time but most of the time the card is seen as a 16 bits card. Then I imagine that when the hotplug stuff fails to detect my card it's because it's detected, at the HW level, as a 16 bits card. I suspect that the problem is with my card and not in my laptop.
I can't say for sure. The detection of card type (16 vs 32 bit, and 3v versus 5v) is supposed to be done in the bridge hardware; there is no software intervention in the process. A damaged connector could make it misbehave.
-- Dave
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel
Quoted 4 lines · christophe barbe
So following my previous post concerning my APA1480 card, here is a patch that solve my problem. I intent to push it to the driver maintener if you agree with it. It only export the pci table but I have to include the
module.hbefore that.
You should send the patch to the author of the driver, not us :)
Quoted 10 lines
It works as expected but It's not yet clear in my mind so could you please try to answer to the following questions:
1. Are we supposed to unload module before removing a card. When I remove a card I see something like
cb_free(20)but the driver is not unloaded.
I was expecting at least to see something indicating that a device was removed at the module level (thecb_freecomes from the cardbus code level).
I looks like the removing of the card is not passed to the hotplug code.
/sbin/hotplug should get called when your card is removed, but the current linux-hotplug package does not unload the driver. There are too many potential race issues for it to do that right now. If you want the driver unloaded, right now you have to do it by hand, or you can modify the scripts to do it.
thanks,
greg k-h
_______________________________________________
Linux-hotplug-devel mailing list http://linux-hotplug.sourceforge.net
[email protected]
https://lists.sourceforge.net/lists/listinfo/linux-hotplug-devel