Commit e4c8bb11 authored by Kai Germaschewski's avatar Kai Germaschewski

ISDN/HiSax: Remove empty ->cardmsg

A lot of the subdrivers don't do anything in their ->cardmsg function
anymore, so we just remove those and make the callers check for NULL.

Also, add ops->bc_{,de}activate() for the drivers which want to be notified
of B-Channel activation.
parent e418cea5
...@@ -686,31 +686,19 @@ static void init_amd7930(struct IsdnCardState *cs) ...@@ -686,31 +686,19 @@ static void init_amd7930(struct IsdnCardState *cs)
Bchan_mode(cs->bcs + 1, 0, 0); Bchan_mode(cs->bcs + 1, 0, 0);
} }
void
release_amd7930(struct IsdnCardState *cs)
{
}
static int static int
amd7930_card_msg(struct IsdnCardState *cs, int mt, void *arg) amd7930_init(struct IsdnCardState *cs)
{ {
switch (mt) { cs->l1cmd = amd7930_l1cmd;
case CARD_RESET: amd7930_liu_init(0, &amd7930_liu_callback, (void *)cs);
return(0); init_amd7930(cs);
case CARD_RELEASE: return 0;
release_amd7930(cs);
return(0);
case CARD_INIT:
cs->l1cmd = amd7930_l1cmd;
amd7930_liu_init(0, &amd7930_liu_callback, (void *)cs);
init_amd7930(cs);
return(0);
case CARD_TEST:
return(0);
}
return(0);
} }
static struct card_ops amd7930_ops = {
.init = amd7930_init,
};
int __init int __init
setup_amd7930(struct IsdnCard *card) setup_amd7930(struct IsdnCard *card)
{ {
...@@ -720,13 +708,12 @@ setup_amd7930(struct IsdnCard *card) ...@@ -720,13 +708,12 @@ setup_amd7930(struct IsdnCard *card)
strcpy(tmp, amd7930_revision); strcpy(tmp, amd7930_revision);
printk(KERN_INFO "HiSax: AMD7930 driver Rev. %s\n", HiSax_getrev(tmp)); printk(KERN_INFO "HiSax: AMD7930 driver Rev. %s\n", HiSax_getrev(tmp));
if (cs->typ != ISDN_CTYPE_AMD7930) if (cs->typ != ISDN_CTYPE_AMD7930)
return (0); return 0;
cs->irq = amd7930_get_irqnum(0); cs->irq = amd7930_get_irqnum(0);
if (cs->irq == 0) if (cs->irq == 0)
return (0); return 0;
cs->cardmsg = &amd7930_card_msg;
return (1); cs->card_ops = &amd7930_ops;
return 1;
} }
...@@ -217,12 +217,6 @@ asuscom_ipac_reset(struct IsdnCardState *cs) ...@@ -217,12 +217,6 @@ asuscom_ipac_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
Asus_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops asuscom_ops = { static struct card_ops asuscom_ops = {
.init = inithscxisac, .init = inithscxisac,
.reset = asuscom_reset, .reset = asuscom_reset,
...@@ -316,7 +310,6 @@ setup_asuscom(struct IsdnCard *card) ...@@ -316,7 +310,6 @@ setup_asuscom(struct IsdnCard *card)
goto err; goto err;
printk(KERN_INFO "ISDNLink: defined at 0x%x IRQ %d\n", printk(KERN_INFO "ISDNLink: defined at 0x%x IRQ %d\n",
cs->hw.asus.cfg_reg, cs->irq); cs->hw.asus.cfg_reg, cs->irq);
cs->cardmsg = &Asus_card_msg;
cs->hw.asus.adr = cs->hw.asus.cfg_reg + ASUS_IPAC_ALE; cs->hw.asus.adr = cs->hw.asus.cfg_reg + ASUS_IPAC_ALE;
val = readreg(cs, cs->hw.asus.cfg_reg + ASUS_IPAC_DATA, IPAC_ID); val = readreg(cs, cs->hw.asus.cfg_reg + ASUS_IPAC_DATA, IPAC_ID);
if ((val == 1) || (val == 2)) { if ((val == 1) || (val == 2)) {
......
...@@ -146,12 +146,6 @@ avm_a1_interrupt(int intno, void *dev_id, struct pt_regs *regs) ...@@ -146,12 +146,6 @@ avm_a1_interrupt(int intno, void *dev_id, struct pt_regs *regs)
spin_unlock(&cs->lock); spin_unlock(&cs->lock);
} }
static int
AVM_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static void static void
avm_a1_init(struct IsdnCardState *cs) avm_a1_init(struct IsdnCardState *cs)
{ {
...@@ -238,7 +232,6 @@ setup_avm_a1(struct IsdnCard *card) ...@@ -238,7 +232,6 @@ setup_avm_a1(struct IsdnCard *card)
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &AVM_card_msg;
cs->card_ops = &avm_a1_ops; cs->card_ops = &avm_a1_ops;
ISACVersion(cs, "AVM A1:"); ISACVersion(cs, "AVM A1:");
if (HscxVersion(cs, "AVM A1:")) { if (HscxVersion(cs, "AVM A1:")) {
......
...@@ -189,12 +189,6 @@ avm_a1p_interrupt(int intno, void *dev_id, struct pt_regs *regs) ...@@ -189,12 +189,6 @@ avm_a1p_interrupt(int intno, void *dev_id, struct pt_regs *regs)
spin_unlock(&cs->lock); spin_unlock(&cs->lock);
} }
static int
AVM_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return 0;
}
static void static void
avm_a1p_init(struct IsdnCardState *cs) avm_a1p_init(struct IsdnCardState *cs)
{ {
...@@ -257,7 +251,6 @@ setup_avm_a1_pcmcia(struct IsdnCard *card) ...@@ -257,7 +251,6 @@ setup_avm_a1_pcmcia(struct IsdnCard *card)
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &AVM_card_msg;
cs->card_ops = &avm_a1p_ops; cs->card_ops = &avm_a1p_ops;
ISACVersion(cs, "AVM A1 PCMCIA:"); ISACVersion(cs, "AVM A1 PCMCIA:");
......
...@@ -556,12 +556,6 @@ avm_pcipnp_interrupt(int intno, void *dev_id, struct pt_regs *regs) ...@@ -556,12 +556,6 @@ avm_pcipnp_interrupt(int intno, void *dev_id, struct pt_regs *regs)
WriteISAC(cs, ISAC_MASK, 0x0); WriteISAC(cs, ISAC_MASK, 0x0);
} }
static int
AVM_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static int static int
avm_pcipnp_reset(struct IsdnCardState *cs) avm_pcipnp_reset(struct IsdnCardState *cs)
{ {
...@@ -711,7 +705,6 @@ setup_avm_pcipnp(struct IsdnCard *card) ...@@ -711,7 +705,6 @@ setup_avm_pcipnp(struct IsdnCard *card)
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hdlc_hw_ops; cs->bc_hw_ops = &hdlc_hw_ops;
cs->bc_l1_ops = &hdlc_l1_ops; cs->bc_l1_ops = &hdlc_l1_ops;
cs->cardmsg = &AVM_card_msg;
cs->card_ops = &avm_pci_ops; cs->card_ops = &avm_pci_ops;
ISACVersion(cs, (cs->subtyp == AVM_FRITZ_PCI) ? "AVM PCI:" : "AVM PnP:"); ISACVersion(cs, (cs->subtyp == AVM_FRITZ_PCI) ? "AVM PCI:" : "AVM PnP:");
return 1; return 1;
......
...@@ -221,12 +221,6 @@ reset_bkm(struct IsdnCardState *cs) ...@@ -221,12 +221,6 @@ reset_bkm(struct IsdnCardState *cs)
} }
} }
static int
BKM_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return (0);
}
static void static void
bkm_a4t_init(struct IsdnCardState *cs) bkm_a4t_init(struct IsdnCardState *cs)
{ {
...@@ -325,7 +319,6 @@ setup_bkm_a4t(struct IsdnCard *card) ...@@ -325,7 +319,6 @@ setup_bkm_a4t(struct IsdnCard *card)
reset_bkm(cs); reset_bkm(cs);
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &jade_ops; cs->bc_hw_ops = &jade_ops;
cs->cardmsg = &BKM_card_msg;
cs->irq_flags |= SA_SHIRQ; cs->irq_flags |= SA_SHIRQ;
cs->card_ops = &bkm_a4t_ops; cs->card_ops = &bkm_a4t_ops;
ISACVersion(cs, "Telekom A4T:"); ISACVersion(cs, "Telekom A4T:");
......
...@@ -121,12 +121,6 @@ reset_bkm(struct IsdnCardState *cs) ...@@ -121,12 +121,6 @@ reset_bkm(struct IsdnCardState *cs)
} }
} }
static int
BKM_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return (0);
}
static void static void
bkm_a8_init(struct IsdnCardState *cs) bkm_a8_init(struct IsdnCardState *cs)
{ {
...@@ -302,7 +296,6 @@ setup_sct_quadro(struct IsdnCard *card) ...@@ -302,7 +296,6 @@ setup_sct_quadro(struct IsdnCard *card)
cs->dc_hw_ops = &ipac_dc_ops; cs->dc_hw_ops = &ipac_dc_ops;
cs->bc_hw_ops = &ipac_bc_ops; cs->bc_hw_ops = &ipac_bc_ops;
cs->cardmsg = &BKM_card_msg;
cs->card_ops = &bkm_a8_ops; cs->card_ops = &bkm_a8_ops;
printk(KERN_INFO "HiSax: %s (%s): IPAC Version %d\n", printk(KERN_INFO "HiSax: %s (%s): IPAC Version %d\n",
......
...@@ -205,13 +205,34 @@ lli_deliver_cause(struct Channel *chanp) ...@@ -205,13 +205,34 @@ lli_deliver_cause(struct Channel *chanp)
} }
static inline void static inline void
mdl_info_rel(struct Channel *chanp)
{
if (chanp->cs->cardmsg)
chanp->cs->cardmsg(chanp->cs, MDL_INFO_REL, (void *) (long)chanp->chan);
}
static inline void
mdl_info_setup(struct Channel *chanp)
{
if (chanp->cs->cardmsg)
chanp->cs->cardmsg(chanp->cs, MDL_INFO_SETUP, (void *) (long)chanp->chan);
}
static inline void
mdl_info_conn(struct Channel *chanp)
{
if (chanp->cs->cardmsg)
chanp->cs->cardmsg(chanp->cs, MDL_INFO_CONN, (void *) (long)chanp->chan);
}
static void
lli_close(struct FsmInst *fi) lli_close(struct FsmInst *fi)
{ {
struct Channel *chanp = fi->userdata; struct Channel *chanp = fi->userdata;
FsmChangeState(fi, ST_NULL); FsmChangeState(fi, ST_NULL);
chanp->Flags = 0; chanp->Flags = 0;
chanp->cs->cardmsg(chanp->cs, MDL_INFO_REL, (void *) (long)chanp->chan); mdl_info_rel(chanp);
} }
static void static void
...@@ -223,7 +244,8 @@ lli_leased_in(struct FsmInst *fi, int event, void *arg) ...@@ -223,7 +244,8 @@ lli_leased_in(struct FsmInst *fi, int event, void *arg)
if (!chanp->leased) if (!chanp->leased)
return; return;
chanp->cs->cardmsg(chanp->cs, MDL_INFO_SETUP, (void *) (long)chanp->chan);
mdl_info_setup(chanp);
FsmChangeState(fi, ST_IN_WAIT_LL); FsmChangeState(fi, ST_IN_WAIT_LL);
if (chanp->debug & 1) if (chanp->debug & 1)
link_debug(chanp, 0, "STAT_ICALL_LEASED"); link_debug(chanp, 0, "STAT_ICALL_LEASED");
...@@ -240,7 +262,7 @@ lli_leased_in(struct FsmInst *fi, int event, void *arg) ...@@ -240,7 +262,7 @@ lli_leased_in(struct FsmInst *fi, int event, void *arg)
if (chanp->debug & 1) if (chanp->debug & 1)
link_debug(chanp, 1, "statcallb ret=%d", ret); link_debug(chanp, 1, "statcallb ret=%d", ret);
if (!ret) { if (!ret) {
chanp->cs->cardmsg(chanp->cs, MDL_INFO_REL, (void *) (long)chanp->chan); mdl_info_rel(chanp);
FsmChangeState(fi, ST_NULL); FsmChangeState(fi, ST_NULL);
} }
} }
...@@ -270,7 +292,7 @@ lli_prep_dialout(struct FsmInst *fi, int event, void *arg) ...@@ -270,7 +292,7 @@ lli_prep_dialout(struct FsmInst *fi, int event, void *arg)
FsmDelTimer(&chanp->dial_timer, 73); FsmDelTimer(&chanp->dial_timer, 73);
chanp->l2_active_protocol = chanp->l2_protocol; chanp->l2_active_protocol = chanp->l2_protocol;
chanp->incoming = 0; chanp->incoming = 0;
chanp->cs->cardmsg(chanp->cs, MDL_INFO_SETUP, (void *) (long)chanp->chan); mdl_info_setup(chanp);
if (chanp->leased) { if (chanp->leased) {
lli_init_bchan_out(fi, event, arg); lli_init_bchan_out(fi, event, arg);
} else { } else {
...@@ -288,7 +310,7 @@ lli_resume(struct FsmInst *fi, int event, void *arg) ...@@ -288,7 +310,7 @@ lli_resume(struct FsmInst *fi, int event, void *arg)
FsmDelTimer(&chanp->dial_timer, 73); FsmDelTimer(&chanp->dial_timer, 73);
chanp->l2_active_protocol = chanp->l2_protocol; chanp->l2_active_protocol = chanp->l2_protocol;
chanp->incoming = 0; chanp->incoming = 0;
chanp->cs->cardmsg(chanp->cs, MDL_INFO_SETUP, (void *) (long)chanp->chan); mdl_info_setup(chanp);
if (chanp->leased) { if (chanp->leased) {
lli_init_bchan_out(fi, event, arg); lli_init_bchan_out(fi, event, arg);
} else { } else {
...@@ -316,7 +338,7 @@ lli_go_active(struct FsmInst *fi, int event, void *arg) ...@@ -316,7 +338,7 @@ lli_go_active(struct FsmInst *fi, int event, void *arg)
ic.command = ISDN_STAT_BCONN; ic.command = ISDN_STAT_BCONN;
ic.arg = chanp->chan; ic.arg = chanp->chan;
chanp->cs->iif.statcallb(&ic); chanp->cs->iif.statcallb(&ic);
chanp->cs->cardmsg(chanp->cs, MDL_INFO_CONN, (void *) (long)chanp->chan); mdl_info_conn(chanp);
} }
...@@ -333,7 +355,7 @@ lli_deliver_call(struct FsmInst *fi, int event, void *arg) ...@@ -333,7 +355,7 @@ lli_deliver_call(struct FsmInst *fi, int event, void *arg)
isdn_ctrl ic; isdn_ctrl ic;
int ret; int ret;
chanp->cs->cardmsg(chanp->cs, MDL_INFO_SETUP, (void *) (long)chanp->chan); mdl_info_setup(chanp);
/* /*
* Report incoming calls only once to linklevel, use CallFlags * Report incoming calls only once to linklevel, use CallFlags
* which is set to 3 with each broadcast message in isdnl1.c * which is set to 3 with each broadcast message in isdnl1.c
...@@ -381,13 +403,13 @@ lli_deliver_call(struct FsmInst *fi, int event, void *arg) ...@@ -381,13 +403,13 @@ lli_deliver_call(struct FsmInst *fi, int event, void *arg)
case 0: /* OK, nobody likes this call */ case 0: /* OK, nobody likes this call */
default: /* statcallb problems */ default: /* statcallb problems */
L4L3(chanp->d_st, CC_IGNORE | REQUEST, chanp->proc); L4L3(chanp->d_st, CC_IGNORE | REQUEST, chanp->proc);
chanp->cs->cardmsg(chanp->cs, MDL_INFO_REL, (void *) (long)chanp->chan); mdl_info_rel(chanp);
FsmChangeState(fi, ST_NULL); FsmChangeState(fi, ST_NULL);
break; break;
} }
} else { } else {
L4L3(chanp->d_st, CC_IGNORE | REQUEST, chanp->proc); L4L3(chanp->d_st, CC_IGNORE | REQUEST, chanp->proc);
chanp->cs->cardmsg(chanp->cs, MDL_INFO_REL, (void *) (long)chanp->chan); mdl_info_rel(chanp);
} }
} }
...@@ -730,7 +752,7 @@ lli_failure_l(struct FsmInst *fi, int event, void *arg) ...@@ -730,7 +752,7 @@ lli_failure_l(struct FsmInst *fi, int event, void *arg)
chanp->cs->iif.statcallb(&ic); chanp->cs->iif.statcallb(&ic);
HL_LL(chanp, ISDN_STAT_DHUP); HL_LL(chanp, ISDN_STAT_DHUP);
chanp->Flags = 0; chanp->Flags = 0;
chanp->cs->cardmsg(chanp->cs, MDL_INFO_REL, (void *) (long)chanp->chan); mdl_info_rel(chanp);
} }
static void static void
......
...@@ -1744,7 +1744,6 @@ static void hisax_d_l1l2(struct hisax_if *ifc, int pr, void *arg); ...@@ -1744,7 +1744,6 @@ static void hisax_d_l1l2(struct hisax_if *ifc, int pr, void *arg);
static void hisax_b_l1l2(struct hisax_if *ifc, int pr, void *arg); static void hisax_b_l1l2(struct hisax_if *ifc, int pr, void *arg);
static void hisax_d_l2l1(struct PStack *st, int pr, void *arg); static void hisax_d_l2l1(struct PStack *st, int pr, void *arg);
static void hisax_b_l2l1(struct PStack *st, int pr, void *arg); static void hisax_b_l2l1(struct PStack *st, int pr, void *arg);
static int hisax_cardmsg(struct IsdnCardState *cs, int mt, void *arg);
static int hisax_bc_setstack(struct PStack *st, struct BCState *bcs); static int hisax_bc_setstack(struct PStack *st, struct BCState *bcs);
static void hisax_bc_close(struct BCState *bcs); static void hisax_bc_close(struct BCState *bcs);
static void hisax_bh(void *data); static void hisax_bh(void *data);
...@@ -1782,7 +1781,6 @@ int hisax_register(struct hisax_d_if *hisax_d_if, struct hisax_b_if *b_if[], ...@@ -1782,7 +1781,6 @@ int hisax_register(struct hisax_d_if *hisax_d_if, struct hisax_b_if *b_if[],
cs = cards[i].cs; cs = cards[i].cs;
hisax_d_if->cs = cs; hisax_d_if->cs = cs;
cs->hw.hisax_d_if = hisax_d_if; cs->hw.hisax_d_if = hisax_d_if;
cs->cardmsg = hisax_cardmsg;
cs->iif.owner = hisax_d_if->owner; // FIXME should be done before registering cs->iif.owner = hisax_d_if->owner; // FIXME should be done before registering
dc_l1_init(cs, &hisax_l1_ops); dc_l1_init(cs, &hisax_l1_ops);
cs->channel[0].d_st->l1.l2l1 = hisax_d_l2l1; cs->channel[0].d_st->l1.l2l1 = hisax_d_l2l1;
...@@ -1961,11 +1959,6 @@ static void hisax_d_l2l1(struct PStack *st, int pr, void *arg) ...@@ -1961,11 +1959,6 @@ static void hisax_d_l2l1(struct PStack *st, int pr, void *arg)
} }
} }
static int hisax_cardmsg(struct IsdnCardState *cs, int mt, void *arg)
{
return 0;
}
static void hisax_b_l2l1(struct PStack *st, int pr, void *arg) static void hisax_b_l2l1(struct PStack *st, int pr, void *arg)
{ {
struct BCState *bcs = st->l1.bcs; struct BCState *bcs = st->l1.bcs;
......
...@@ -152,12 +152,35 @@ reset_enpci(struct IsdnCardState *cs) ...@@ -152,12 +152,35 @@ reset_enpci(struct IsdnCardState *cs)
OutByte(cs->hw.njet.auxa, cs->hw.njet.auxd); // LED off OutByte(cs->hw.njet.auxa, cs->hw.njet.auxd); // LED off
} }
static void
enpci_bc_activate(struct IsdnCardState *cs, int chan)
{
if (cs->debug & L1_DEB_ISAC)
debugl1(cs, "enter:now PCI: assign phys. BC %d in AMD LMR1", chan);
cs->dc.amd7930.ph_command(cs, (cs->dc.amd7930.lmr1 | (chan + 1)), "MDL_BC_ASSIGN");
/* at least one b-channel in use, LED 2 on */
cs->hw.njet.auxd |= TJ_AMD_IRQ << 2;
OutByte(cs->hw.njet.base + NETJET_AUXDATA, cs->hw.njet.auxd);
}
static void
enpci_bc_deactivate(struct IsdnCardState *cs, int chan)
{
if (cs->debug & L1_DEB_ISAC)
debugl1(cs, "enter:now PCI: release phys. BC %d in Amd LMR1", chan);
cs->dc.amd7930.ph_command(cs, (cs->dc.amd7930.lmr1 & ~(chan + 1)), "MDL_BC_RELEASE");
/* no b-channel active -> LED2 off */
if (!(cs->dc.amd7930.lmr1 & 3)) {
cs->hw.njet.auxd &= ~(TJ_AMD_IRQ << 2);
OutByte(cs->hw.njet.base + NETJET_AUXDATA, cs->hw.njet.auxd);
}
}
static int static int
enpci_card_msg(struct IsdnCardState *cs, int mt, void *arg) enpci_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{ {
BYTE *chan;
if (cs->debug & L1_DEB_ISAC) if (cs->debug & L1_DEB_ISAC)
debugl1(cs, "enter:now PCI: card_msg: 0x%04X", mt); debugl1(cs, "enter:now PCI: card_msg: 0x%04X", mt);
...@@ -172,35 +195,6 @@ enpci_card_msg(struct IsdnCardState *cs, int mt, void *arg) ...@@ -172,35 +195,6 @@ enpci_card_msg(struct IsdnCardState *cs, int mt, void *arg)
cs->hw.njet.auxd = 0; cs->hw.njet.auxd = 0;
OutByte(cs->hw.njet.base + NETJET_AUXDATA, 0x00); OutByte(cs->hw.njet.base + NETJET_AUXDATA, 0x00);
break; break;
case MDL_BC_ASSIGN:
/* activate B-channel */
chan = (BYTE *)arg;
if (cs->debug & L1_DEB_ISAC)
debugl1(cs, "enter:now PCI: assign phys. BC %d in AMD LMR1", *chan);
cs->dc.amd7930.ph_command(cs, (cs->dc.amd7930.lmr1 | (*chan + 1)), "MDL_BC_ASSIGN");
/* at least one b-channel in use, LED 2 on */
cs->hw.njet.auxd |= TJ_AMD_IRQ << 2;
OutByte(cs->hw.njet.base + NETJET_AUXDATA, cs->hw.njet.auxd);
break;
case MDL_BC_RELEASE:
/* deactivate B-channel */
chan = (BYTE *)arg;
if (cs->debug & L1_DEB_ISAC)
debugl1(cs, "enter:now PCI: release phys. BC %d in Amd LMR1", *chan);
cs->dc.amd7930.ph_command(cs, (cs->dc.amd7930.lmr1 & ~(*chan + 1)), "MDL_BC_RELEASE");
/* no b-channel active -> LED2 off */
if (!(cs->dc.amd7930.lmr1 & 3)) {
cs->hw.njet.auxd &= ~(TJ_AMD_IRQ << 2);
OutByte(cs->hw.njet.base + NETJET_AUXDATA, cs->hw.njet.auxd);
}
break;
default:
break;
} }
return(0); return(0);
} }
...@@ -351,6 +345,8 @@ setup_enternow_pci(struct IsdnCard *card) ...@@ -351,6 +345,8 @@ setup_enternow_pci(struct IsdnCard *card)
return 0; return 0;
reset_enpci(cs); reset_enpci(cs);
cs->hw.njet.last_is0 = 0; cs->hw.njet.last_is0 = 0;
cs->hw.njet.bc_activate = enpci_bc_activate;
cs->hw.njet.bc_deactivate = enpci_bc_deactivate;
cs->dc_hw_ops = &enternow_ops; cs->dc_hw_ops = &enternow_ops;
cs->dc.amd7930.setIrqMask = &enpci_setIrqMask; cs->dc.amd7930.setIrqMask = &enpci_setIrqMask;
......
...@@ -282,12 +282,6 @@ r742_reset(struct IsdnCardState *cs) ...@@ -282,12 +282,6 @@ r742_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
Gazel_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return (0);
}
static void static void
gazel_init(struct IsdnCardState *cs) gazel_init(struct IsdnCardState *cs)
{ {
...@@ -547,8 +541,6 @@ setup_gazel(struct IsdnCard *card) ...@@ -547,8 +541,6 @@ setup_gazel(struct IsdnCard *card)
return (0); return (0);
} }
cs->cardmsg = &Gazel_card_msg;
switch (cs->subtyp) { switch (cs->subtyp) {
case R647: case R647:
case R685: case R685:
......
...@@ -1361,17 +1361,6 @@ inithfcpci(struct IsdnCardState *cs) ...@@ -1361,17 +1361,6 @@ inithfcpci(struct IsdnCardState *cs)
mode_hfcpci(cs->bcs + 1, 0, 1); mode_hfcpci(cs->bcs + 1, 0, 1);
} }
/*******************************************/
/* handle card messages from control layer */
/*******************************************/
static int
hfcpci_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return (0);
}
static void static void
hfcpci_init(struct IsdnCardState *cs) hfcpci_init(struct IsdnCardState *cs)
{ {
...@@ -1477,7 +1466,6 @@ setup_hfcpci(struct IsdnCard *card) ...@@ -1477,7 +1466,6 @@ setup_hfcpci(struct IsdnCard *card)
init_timer(&cs->hw.hfcpci.timer); init_timer(&cs->hw.hfcpci.timer);
hfcpci_reset(cs); hfcpci_reset(cs);
cs->cardmsg = &hfcpci_card_msg;
cs->auxcmd = &hfcpci_auxcmd; cs->auxcmd = &hfcpci_auxcmd;
cs->card_ops = &hfcpci_ops; cs->card_ops = &hfcpci_ops;
return 1; return 1;
......
...@@ -1139,17 +1139,6 @@ inithfcsx(struct IsdnCardState *cs) ...@@ -1139,17 +1139,6 @@ inithfcsx(struct IsdnCardState *cs)
mode_hfcsx(cs->bcs + 1, 0, 1); mode_hfcsx(cs->bcs + 1, 0, 1);
} }
/*******************************************/
/* handle card messages from control layer */
/*******************************************/
static int
hfcsx_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return (0);
}
static void static void
hfcsx_init(struct IsdnCardState *cs) hfcsx_init(struct IsdnCardState *cs)
{ {
...@@ -1290,7 +1279,6 @@ setup_hfcsx(struct IsdnCard *card) ...@@ -1290,7 +1279,6 @@ setup_hfcsx(struct IsdnCard *card)
init_timer(&cs->hw.hfcsx.timer); init_timer(&cs->hw.hfcsx.timer);
hfcsx_reset(cs); hfcsx_reset(cs);
cs->cardmsg = &hfcsx_card_msg;
cs->auxcmd = &hfcsx_auxcmd; cs->auxcmd = &hfcsx_auxcmd;
cs->card_ops = &hfcsx_ops; cs->card_ops = &hfcsx_ops;
return (1); return (1);
......
...@@ -113,12 +113,6 @@ hfcs_reset(struct IsdnCardState *cs) ...@@ -113,12 +113,6 @@ hfcs_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
hfcs_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static void static void
hfcs_init(struct IsdnCardState *cs) hfcs_init(struct IsdnCardState *cs)
{ {
...@@ -253,7 +247,6 @@ setup_hfcs(struct IsdnCard *card) ...@@ -253,7 +247,6 @@ setup_hfcs(struct IsdnCard *card)
cs->hw.hfcD.timer.data = (long) cs; cs->hw.hfcD.timer.data = (long) cs;
init_timer(&cs->hw.hfcD.timer); init_timer(&cs->hw.hfcD.timer);
hfcs_reset(cs); hfcs_reset(cs);
cs->cardmsg = &hfcs_card_msg;
cs->card_ops = &hfcs_ops; cs->card_ops = &hfcs_ops;
return (1); return (1);
} }
...@@ -67,8 +67,6 @@ ...@@ -67,8 +67,6 @@
#define DL_FLUSH 0x0224 #define DL_FLUSH 0x0224
#define DL_UNIT_DATA 0x0230 #define DL_UNIT_DATA 0x0230
#define MDL_BC_RELEASE 0x0278 // Formula-n enter:now
#define MDL_BC_ASSIGN 0x027C // Formula-n enter:now
#define MDL_ASSIGN 0x0280 #define MDL_ASSIGN 0x0280
#define MDL_REMOVE 0x0284 #define MDL_REMOVE 0x0284
#define MDL_ERROR 0x0288 #define MDL_ERROR 0x0288
...@@ -683,6 +681,8 @@ struct njet_hw { ...@@ -683,6 +681,8 @@ struct njet_hw {
unsigned char irqstat0; unsigned char irqstat0;
unsigned char last_is0; unsigned char last_is0;
struct pci_dev *pdev; struct pci_dev *pdev;
void (*bc_activate)(struct IsdnCardState *cs, int bc);
void (*bc_deactivate)(struct IsdnCardState *cs, int bc);
}; };
struct hfcPCI_hw { struct hfcPCI_hw {
......
...@@ -145,12 +145,6 @@ reset_isurf(struct IsdnCardState *cs, u8 chips) ...@@ -145,12 +145,6 @@ reset_isurf(struct IsdnCardState *cs, u8 chips)
schedule_timeout((10*HZ)/1000); schedule_timeout((10*HZ)/1000);
} }
static int
ISurf_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static int static int
isurf_auxcmd(struct IsdnCardState *cs, isdn_ctrl *ic) { isurf_auxcmd(struct IsdnCardState *cs, isdn_ctrl *ic) {
int ret; int ret;
...@@ -265,7 +259,6 @@ setup_isurf(struct IsdnCard *card) ...@@ -265,7 +259,6 @@ setup_isurf(struct IsdnCard *card)
card->para[2], card->para[2],
cs->irq); cs->irq);
cs->cardmsg = &ISurf_card_msg;
cs->auxcmd = &isurf_auxcmd; cs->auxcmd = &isurf_auxcmd;
cs->card_ops = &isurf_ops; cs->card_ops = &isurf_ops;
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
......
...@@ -155,12 +155,6 @@ ix1_reset(struct IsdnCardState *cs) ...@@ -155,12 +155,6 @@ ix1_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
ix1_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops ix1_ops = { static struct card_ops ix1_ops = {
.init = inithscxisac, .init = inithscxisac,
.reset = ix1_reset, .reset = ix1_reset,
...@@ -250,7 +244,6 @@ setup_ix1micro(struct IsdnCard *card) ...@@ -250,7 +244,6 @@ setup_ix1micro(struct IsdnCard *card)
ix1_reset(cs); ix1_reset(cs);
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &ix1_card_msg;
cs->card_ops = &ix1_ops; cs->card_ops = &ix1_ops;
ISACVersion(cs, "ix1-Micro:"); ISACVersion(cs, "ix1-Micro:");
if (HscxVersion(cs, "ix1-Micro:")) { if (HscxVersion(cs, "ix1-Micro:")) {
......
...@@ -132,12 +132,6 @@ static struct bc_hw_ops hscx_ops = { ...@@ -132,12 +132,6 @@ static struct bc_hw_ops hscx_ops = {
.write_fifo = hscx_write_fifo, .write_fifo = hscx_write_fifo,
}; };
static int
mic_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops mic_ops = { static struct card_ops mic_ops = {
.init = inithscxisac, .init = inithscxisac,
.release = hisax_release_resources, .release = hisax_release_resources,
...@@ -170,7 +164,6 @@ setup_mic(struct IsdnCard *card) ...@@ -170,7 +164,6 @@ setup_mic(struct IsdnCard *card)
cs->irq); cs->irq);
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &mic_card_msg;
cs->card_ops = &mic_ops; cs->card_ops = &mic_ops;
ISACVersion(cs, "mic:"); ISACVersion(cs, "mic:");
if (HscxVersion(cs, "mic:")) { if (HscxVersion(cs, "mic:")) {
......
...@@ -839,6 +839,7 @@ static void ...@@ -839,6 +839,7 @@ static void
tiger_l2l1(struct PStack *st, int pr, void *arg) tiger_l2l1(struct PStack *st, int pr, void *arg)
{ {
struct sk_buff *skb = arg; struct sk_buff *skb = arg;
struct IsdnCardState *cs = st->l1.bcs->cs;
switch (pr) { switch (pr) {
case (PH_DATA | REQUEST): case (PH_DATA | REQUEST):
...@@ -853,13 +854,13 @@ tiger_l2l1(struct PStack *st, int pr, void *arg) ...@@ -853,13 +854,13 @@ tiger_l2l1(struct PStack *st, int pr, void *arg)
case (PH_ACTIVATE | REQUEST): case (PH_ACTIVATE | REQUEST):
test_and_set_bit(BC_FLG_ACTIV, &st->l1.bcs->Flag); test_and_set_bit(BC_FLG_ACTIV, &st->l1.bcs->Flag);
mode_tiger(st->l1.bcs, st->l1.mode, st->l1.bc); mode_tiger(st->l1.bcs, st->l1.mode, st->l1.bc);
/* 2001/10/04 Christoph Ersfeld, Formula-n Europe AG */ if (cs->hw.njet.bc_activate)
st->l1.bcs->cs->cardmsg(st->l1.bcs->cs, MDL_BC_ASSIGN, (void *)(&st->l1.bc)); (cs->hw.njet.bc_activate)(cs, st->l1.bc);
l1_msg_b(st, pr, arg); l1_msg_b(st, pr, arg);
break; break;
case (PH_DEACTIVATE | REQUEST): case (PH_DEACTIVATE | REQUEST):
/* 2001/10/04 Christoph Ersfeld, Formula-n Europe AG */ if (cs->hw.njet.bc_deactivate)
st->l1.bcs->cs->cardmsg(st->l1.bcs->cs, MDL_BC_RELEASE, (void *)(&st->l1.bc)); (cs->hw.njet.bc_deactivate)(cs, st->l1.bc);
l1_msg_b(st, pr, arg); l1_msg_b(st, pr, arg);
break; break;
case (PH_DEACTIVATE | CONFIRM): case (PH_DEACTIVATE | CONFIRM):
......
...@@ -192,12 +192,6 @@ niccy_reset(struct IsdnCardState *cs) ...@@ -192,12 +192,6 @@ niccy_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
niccy_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops niccy_ops = { static struct card_ops niccy_ops = {
.init = inithscxisac, .init = inithscxisac,
.reset = niccy_reset, .reset = niccy_reset,
...@@ -312,7 +306,6 @@ setup_niccy(struct IsdnCard *card) ...@@ -312,7 +306,6 @@ setup_niccy(struct IsdnCard *card)
cs->irq, cs->hw.niccy.isac, cs->hw.niccy.isac_ale); cs->irq, cs->hw.niccy.isac, cs->hw.niccy.isac_ale);
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &niccy_card_msg;
cs->card_ops = &niccy_ops; cs->card_ops = &niccy_ops;
ISACVersion(cs, "Niccy:"); ISACVersion(cs, "Niccy:");
if (HscxVersion(cs, "Niccy:")) { if (HscxVersion(cs, "Niccy:")) {
......
...@@ -92,12 +92,6 @@ nj_s_reset(struct IsdnCardState *cs) ...@@ -92,12 +92,6 @@ nj_s_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
NETjet_S_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static void static void
nj_s_init(struct IsdnCardState *cs) nj_s_init(struct IsdnCardState *cs)
{ {
...@@ -203,7 +197,6 @@ setup_netjet_s(struct IsdnCard *card) ...@@ -203,7 +197,6 @@ setup_netjet_s(struct IsdnCard *card)
nj_s_reset(cs); nj_s_reset(cs);
cs->dc_hw_ops = &netjet_dc_ops; cs->dc_hw_ops = &netjet_dc_ops;
cs->cardmsg = &NETjet_S_card_msg;
cs->irq_flags |= SA_SHIRQ; cs->irq_flags |= SA_SHIRQ;
cs->card_ops = &nj_s_ops; cs->card_ops = &nj_s_ops;
ISACVersion(cs, "NETjet-S:"); ISACVersion(cs, "NETjet-S:");
......
...@@ -94,12 +94,6 @@ nj_u_reset(struct IsdnCardState *cs) ...@@ -94,12 +94,6 @@ nj_u_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
NETjet_U_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static void static void
nj_u_init(struct IsdnCardState *cs) nj_u_init(struct IsdnCardState *cs)
{ {
...@@ -199,7 +193,6 @@ setup_netjet_u(struct IsdnCard *card) ...@@ -199,7 +193,6 @@ setup_netjet_u(struct IsdnCard *card)
nj_u_reset(cs); nj_u_reset(cs);
cs->dc_hw_ops = &netjet_dc_ops; cs->dc_hw_ops = &netjet_dc_ops;
cs->cardmsg = &NETjet_U_card_msg;
cs->irq_flags |= SA_SHIRQ; cs->irq_flags |= SA_SHIRQ;
cs->card_ops = &nj_u_ops; cs->card_ops = &nj_u_ops;
ICCVersion(cs, "NETspider-U:"); ICCVersion(cs, "NETspider-U:");
......
...@@ -166,12 +166,6 @@ static struct bc_hw_ops hscx_ops = { ...@@ -166,12 +166,6 @@ static struct bc_hw_ops hscx_ops = {
.write_fifo = hscx_write_fifo, .write_fifo = hscx_write_fifo,
}; };
static int
S0Box_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops s0box_ops = { static struct card_ops s0box_ops = {
.init = inithscxisac, .init = inithscxisac,
.release = hisax_release_resources, .release = hisax_release_resources,
...@@ -208,7 +202,6 @@ setup_s0box(struct IsdnCard *card) ...@@ -208,7 +202,6 @@ setup_s0box(struct IsdnCard *card)
cs->hw.teles3.hscx[0], cs->hw.teles3.hscx[1]); cs->hw.teles3.hscx[0], cs->hw.teles3.hscx[1]);
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &S0Box_card_msg;
cs->card_ops = &s0box_ops; cs->card_ops = &s0box_ops;
ISACVersion(cs, "S0Box:"); ISACVersion(cs, "S0Box:");
if (HscxVersion(cs, "S0Box:")) { if (HscxVersion(cs, "S0Box:")) {
......
...@@ -194,12 +194,6 @@ saphir_reset(struct IsdnCardState *cs) ...@@ -194,12 +194,6 @@ saphir_reset(struct IsdnCardState *cs)
return (0); return (0);
} }
static int
saphir_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops saphir_ops = { static struct card_ops saphir_ops = {
.init = inithscxisac, .init = inithscxisac,
.reset = saphir_reset, .reset = saphir_reset,
...@@ -242,7 +236,6 @@ setup_saphir(struct IsdnCard *card) ...@@ -242,7 +236,6 @@ setup_saphir(struct IsdnCard *card)
} }
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &saphir_card_msg;
cs->card_ops = &saphir_ops; cs->card_ops = &saphir_ops;
ISACVersion(cs, "saphir:"); ISACVersion(cs, "saphir:");
if (HscxVersion(cs, "saphir:")) { if (HscxVersion(cs, "saphir:")) {
......
...@@ -74,6 +74,20 @@ static char *strTeiEvent[] = ...@@ -74,6 +74,20 @@ static char *strTeiEvent[] =
"EV_T202", "EV_T202",
}; };
static inline void
mdl_assign(struct IsdnCardState *cs)
{
if (cs->cardmsg)
cs->cardmsg(cs, MDL_ASSIGN | REQUEST, NULL);
}
static inline void
mdl_remove(struct IsdnCardState *cs)
{
if (cs->cardmsg)
cs->cardmsg(cs, MDL_REMOVE | REQUEST, NULL);
}
unsigned int unsigned int
random_ri(void) random_ri(void)
{ {
...@@ -167,7 +181,7 @@ tei_id_assign(struct FsmInst *fi, int event, void *arg) ...@@ -167,7 +181,7 @@ tei_id_assign(struct FsmInst *fi, int event, void *arg)
FsmChangeState(&st->ma.tei_m, ST_TEI_NOP); FsmChangeState(&st->ma.tei_m, ST_TEI_NOP);
L3L2(st, MDL_ASSIGN | REQUEST, (void *) (long) tei); L3L2(st, MDL_ASSIGN | REQUEST, (void *) (long) tei);
cs = (struct IsdnCardState *) st->l1.hardware; cs = (struct IsdnCardState *) st->l1.hardware;
cs->cardmsg(cs, MDL_ASSIGN | REQUEST, NULL); mdl_assign(cs);
} }
} }
...@@ -241,7 +255,7 @@ tei_id_remove(struct FsmInst *fi, int event, void *arg) ...@@ -241,7 +255,7 @@ tei_id_remove(struct FsmInst *fi, int event, void *arg)
FsmChangeState(&st->ma.tei_m, ST_TEI_NOP); FsmChangeState(&st->ma.tei_m, ST_TEI_NOP);
L3L2(st, MDL_REMOVE | REQUEST, 0); L3L2(st, MDL_REMOVE | REQUEST, 0);
cs = (struct IsdnCardState *) st->l1.hardware; cs = (struct IsdnCardState *) st->l1.hardware;
cs->cardmsg(cs, MDL_REMOVE | REQUEST, NULL); mdl_remove(cs);
} }
} }
...@@ -277,7 +291,7 @@ tei_id_req_tout(struct FsmInst *fi, int event, void *arg) ...@@ -277,7 +291,7 @@ tei_id_req_tout(struct FsmInst *fi, int event, void *arg)
st->ma.tei_m.printdebug(&st->ma.tei_m, "assign req failed"); st->ma.tei_m.printdebug(&st->ma.tei_m, "assign req failed");
L3L2(st, MDL_ERROR | RESPONSE, 0); L3L2(st, MDL_ERROR | RESPONSE, 0);
cs = (struct IsdnCardState *) st->l1.hardware; cs = (struct IsdnCardState *) st->l1.hardware;
cs->cardmsg(cs, MDL_REMOVE | REQUEST, NULL); mdl_remove(cs);
FsmChangeState(fi, ST_TEI_NOP); FsmChangeState(fi, ST_TEI_NOP);
} }
} }
...@@ -300,7 +314,7 @@ tei_id_ver_tout(struct FsmInst *fi, int event, void *arg) ...@@ -300,7 +314,7 @@ tei_id_ver_tout(struct FsmInst *fi, int event, void *arg)
"verify req for tei %d failed", st->l2.tei); "verify req for tei %d failed", st->l2.tei);
L3L2(st, MDL_REMOVE | REQUEST, 0); L3L2(st, MDL_REMOVE | REQUEST, 0);
cs = (struct IsdnCardState *) st->l1.hardware; cs = (struct IsdnCardState *) st->l1.hardware;
cs->cardmsg(cs, MDL_REMOVE | REQUEST, NULL); mdl_remove(cs);
FsmChangeState(fi, ST_TEI_NOP); FsmChangeState(fi, ST_TEI_NOP);
} }
} }
...@@ -373,7 +387,7 @@ tei_l2tei(struct PStack *st, int pr, void *arg) ...@@ -373,7 +387,7 @@ tei_l2tei(struct PStack *st, int pr, void *arg)
"fixed assign tei %d", st->l2.tei); "fixed assign tei %d", st->l2.tei);
L3L2(st, MDL_ASSIGN | REQUEST, (void *) (long) st->l2.tei); L3L2(st, MDL_ASSIGN | REQUEST, (void *) (long) st->l2.tei);
cs = (struct IsdnCardState *) st->l1.hardware; cs = (struct IsdnCardState *) st->l1.hardware;
cs->cardmsg(cs, MDL_ASSIGN | REQUEST, NULL); mdl_assign(cs);
} }
return; return;
} }
......
...@@ -240,12 +240,6 @@ teleint_reset(struct IsdnCardState *cs) ...@@ -240,12 +240,6 @@ teleint_reset(struct IsdnCardState *cs)
return 0; return 0;
} }
static int
TeleInt_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static void static void
teleint_init(struct IsdnCardState *cs) teleint_init(struct IsdnCardState *cs)
{ {
...@@ -325,7 +319,6 @@ setup_TeleInt(struct IsdnCard *card) ...@@ -325,7 +319,6 @@ setup_TeleInt(struct IsdnCard *card)
teleint_reset(cs); teleint_reset(cs);
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hfc_ops; cs->bc_hw_ops = &hfc_ops;
cs->cardmsg = &TeleInt_card_msg;
cs->card_ops = &teleint_ops; cs->card_ops = &teleint_ops;
ISACVersion(cs, "TeleInt:"); ISACVersion(cs, "TeleInt:");
return 1; return 1;
......
...@@ -158,12 +158,6 @@ teles0_reset(struct IsdnCardState *cs) ...@@ -158,12 +158,6 @@ teles0_reset(struct IsdnCardState *cs)
return(0); return(0);
} }
static int
Teles_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops teles0_ops = { static struct card_ops teles0_ops = {
.init = inithscxisac, .init = inithscxisac,
.reset = teles0_reset, .reset = teles0_reset,
...@@ -236,7 +230,6 @@ setup_teles0(struct IsdnCard *card) ...@@ -236,7 +230,6 @@ setup_teles0(struct IsdnCard *card)
} }
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &Teles_card_msg;
cs->card_ops = &teles0_ops; cs->card_ops = &teles0_ops;
ISACVersion(cs, "Teles0:"); ISACVersion(cs, "Teles0:");
if (HscxVersion(cs, "Teles0:")) { if (HscxVersion(cs, "Teles0:")) {
......
...@@ -169,12 +169,6 @@ teles3_reset(struct IsdnCardState *cs) ...@@ -169,12 +169,6 @@ teles3_reset(struct IsdnCardState *cs)
return(0); return(0);
} }
static int
Teles_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops teles3_ops = { static struct card_ops teles3_ops = {
.init = inithscxisac, .init = inithscxisac,
.reset = teles3_reset, .reset = teles3_reset,
...@@ -344,7 +338,6 @@ setup_teles3(struct IsdnCard *card) ...@@ -344,7 +338,6 @@ setup_teles3(struct IsdnCard *card)
} }
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &Teles_card_msg;
cs->card_ops = &teles3_ops; cs->card_ops = &teles3_ops;
ISACVersion(cs, "Teles3:"); ISACVersion(cs, "Teles3:");
if (HscxVersion(cs, "Teles3:")) { if (HscxVersion(cs, "Teles3:")) {
......
...@@ -225,12 +225,6 @@ telespci_interrupt(int intno, void *dev_id, struct pt_regs *regs) ...@@ -225,12 +225,6 @@ telespci_interrupt(int intno, void *dev_id, struct pt_regs *regs)
spin_unlock(&cs->lock); spin_unlock(&cs->lock);
} }
static int
TelesPCI_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return(0);
}
static struct card_ops telespci_ops = { static struct card_ops telespci_ops = {
.init = inithscxisac, .init = inithscxisac,
.release = hisax_release_resources, .release = hisax_release_resources,
...@@ -285,7 +279,6 @@ setup_telespci(struct IsdnCard *card) ...@@ -285,7 +279,6 @@ setup_telespci(struct IsdnCard *card)
cs->dc_hw_ops = &isac_ops; cs->dc_hw_ops = &isac_ops;
cs->bc_hw_ops = &hscx_ops; cs->bc_hw_ops = &hscx_ops;
cs->cardmsg = &TelesPCI_card_msg;
cs->irq_flags |= SA_SHIRQ; cs->irq_flags |= SA_SHIRQ;
cs->card_ops = &telespci_ops; cs->card_ops = &telespci_ops;
ISACVersion(cs, "TelesPCI:"); ISACVersion(cs, "TelesPCI:");
......
...@@ -644,12 +644,6 @@ w6692_release(struct IsdnCardState *cs) ...@@ -644,12 +644,6 @@ w6692_release(struct IsdnCardState *cs)
hisax_release_resources(cs); hisax_release_resources(cs);
} }
static int
w6692_card_msg(struct IsdnCardState *cs, int mt, void *arg)
{
return (0);
}
static struct card_ops w6692_ops = { static struct card_ops w6692_ops = {
.init = w6692_init, .init = w6692_init,
.reset = w6692_reset, .reset = w6692_reset,
...@@ -745,7 +739,6 @@ setup_w6692(struct IsdnCard *card) ...@@ -745,7 +739,6 @@ setup_w6692(struct IsdnCard *card)
cs->bc_hw_ops = &w6692_bc_hw_ops; cs->bc_hw_ops = &w6692_bc_hw_ops;
dc_l1_init(cs, &w6692_dc_l1_ops); dc_l1_init(cs, &w6692_dc_l1_ops);
cs->bc_l1_ops = &w6692_bc_l1_ops; cs->bc_l1_ops = &w6692_bc_l1_ops;
cs->cardmsg = &w6692_card_msg;
cs->irq_flags |= SA_SHIRQ; cs->irq_flags |= SA_SHIRQ;
cs->card_ops = &w6692_ops; cs->card_ops = &w6692_ops;
W6692Version(cs, "W6692:"); W6692Version(cs, "W6692:");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment