13 #include <linux/module.h>
14 #include <linux/slab.h>
16 #include <linux/netdevice.h>
17 #include <linux/pci.h>
18 #include <linux/hdlc.h>
19 #include <linux/if_arp.h>
23 static void check_leds(
unsigned long arg)
25 struct card *
card = (
struct card *)arg;
30 if (has_two_ports(channel0->
pdev))
50 pci_set_drvdata(pdev,
NULL);
90 pci_read_config_dword(channel->
pdev, 0x40, &val);
91 pci_write_config_dword(channel->
pdev, 0x40, val & 0x3FFFFFFF);
103 pci_set_drvdata(pdev, channel);
119 struct channel *channel0 = pci_get_drvdata(pdev);
120 struct card *card = channel0->
card;
123 if (has_two_ports(channel0->
pdev)) {
124 t3e3_remove_channel(&card->channels[1]);
127 t3e3_remove_channel(channel0);
138 if (has_two_ports(pdev)) {
142 if (pdev1->
bus == pdev->
bus &&
154 card = kzalloc(
sizeof(
struct card) + channels *
sizeof(
struct channel),
GFP_KERNEL);
163 err = t3e3_init_channel(&card->channels[0], pdev, card);
168 err = t3e3_init_channel(&card->channels[1], pdev1, card);
170 t3e3_remove_channel(&card->channels[0]);
177 card->timer.function = check_leds;
179 card->timer.data = (
unsigned long)card;
199 .id_table = t3e3_pci_tbl,
200 .probe = t3e3_init_card,
201 .remove = t3e3_remove_card,