/* xircom_remove is called on module-unload or on device-eject. it unregisters the irq, io-region and network device. Interrupts and such are already stopped in the "ifconfig ethX down" code.  */
static void __devexit xircom_remove(struct pci_dev *pdev)
/* xircom_remove is called on module-unload or on device-eject. it unregisters the irq, io-region and network device. Interrupts and such are already stopped in the "ifconfig ethX down" code.  */
static void __devexit xircom_remove(struct pci_dev *pdev)
{
	struct net_device *dev = pci_get_drvdata(pdev);
	struct xircom_private *card = netdev_priv(dev);
	enter("xircom_remove");
	pci_free_consistent(pdev,8192,card->rx_buffer,card->rx_dma_handle);
	pci_free_consistent(pdev,8192,card->tx_buffer,card->tx_dma_handle);
	release_region(dev->base_addr, 128);
	unregister_netdev(dev);
	free_netdev(dev);
	pci_set_drvdata(pdev, NULL);
	leave("xircom_remove");
}