rminnichinitial1fcdf7916 years agoHistory
49 lines · 870 B · C
RawDownload
/* Bitsy pcmcia code for wavelan.c */ #include "u.h"#include "../port/lib.h"#include "mem.h"#include "dat.h"#include "fns.h"#include "io.h"#include "../port/error.h"#include "../port/netif.h"#include "etherif.h"#include "../pc/wavelan.h" static intwavelanpcmciareset(Ether *ether){	Ctlr *ctlr; 	if((ctlr = malloc(sizeof(Ctlr))) == nil)		return -1; 	ilock(ctlr);	ctlr->ctlrno = ether->ctlrno; 	if (ether->ports == nil){		ether->ports = malloc(sizeof(Devport));		ether->ports[0].port = 0;		ether->ports[0].size = 0;		ether->nports= 1;	}	if (ether->ports[0].port==0)		ether->ports[0].port=WDfltIOB;	ctlr->iob = ether->ports[0].port; 	if(wavelanreset(ether, ctlr) < 0){		iunlock(ctlr);		free(ctlr);		ether->ctlr = nil;		return -1;	}	iunlock(ctlr);	return 0;} voidetherwavelanlink(void){	addethercard("wavelan", wavelanpcmciareset);}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t