taglinefilesource code
dev144arch/alpha/boot/main.cstatic inline long close(long dev)
dev146arch/alpha/boot/main.creturn dispatch(CCB_CLOSE, dev);
dev149arch/alpha/boot/main.cstatic inline long load(long dev, unsigned long addr, unsigned long count)
dev161arch/alpha/boot/main.creturn dispatch(CCB_READ, dev, count, addr, BOOT_SIZE/512 + 1);
dev181arch/alpha/boot/main.clong dev;
dev191arch/alpha/boot/main.cdev = openboot();
dev192arch/alpha/boot/main.cif (dev < 0) {
dev193arch/alpha/boot/main.cprintk("Unable to open boot device: %016lx\n", dev);
dev196arch/alpha/boot/main.cdev &= 0xffffffff;
dev198arch/alpha/boot/main.ci = load(dev, START_ADDR, START_SIZE);
dev199arch/alpha/boot/main.cclose(dev);
dev92arch/alpha/kernel/bios32.cstatic void layout_dev(struct pci_dev *dev)
dev98arch/alpha/kernel/bios32.cbus = dev->bus;
dev99arch/alpha/kernel/bios32.cpcibios_read_config_word(bus->number, dev->devfn, PCI_COMMAND, &cmd);
dev106arch/alpha/kernel/bios32.cpcibios_write_config_dword(bus->number, dev->devfn, reg,
dev108arch/alpha/kernel/bios32.cpcibios_read_config_dword(bus->number, dev->devfn, reg, &base);
dev128arch/alpha/kernel/bios32.cpcibios_write_config_dword(bus->number, dev->devfn, 
dev149arch/alpha/kernel/bios32.cPCI_SLOT(dev->devfn),
dev150arch/alpha/kernel/bios32.cPCI_FUNC(dev->devfn));
dev167arch/alpha/kernel/bios32.cPCI_SLOT(dev->devfn),
dev168arch/alpha/kernel/bios32.cPCI_FUNC(dev->devfn));
dev192arch/alpha/kernel/bios32.cPCI_SLOT(dev->devfn),
dev193arch/alpha/kernel/bios32.cPCI_FUNC(dev->devfn), size);
dev207arch/alpha/kernel/bios32.cpcibios_write_config_dword(bus->number, dev->devfn,
dev212arch/alpha/kernel/bios32.cpcibios_write_config_word(bus->number, dev->devfn, PCI_COMMAND,
dev221arch/alpha/kernel/bios32.cstruct pci_dev *dev;
dev236arch/alpha/kernel/bios32.cfor (dev = bus->devices; dev; dev = dev->sibling) {
dev237arch/alpha/kernel/bios32.cif (dev->class >> 16 != PCI_BASE_CLASS_BRIDGE) {
dev238arch/alpha/kernel/bios32.clayout_dev(dev);
dev301arch/alpha/kernel/bios32.cstruct pci_dev *dev;
dev303arch/alpha/kernel/bios32.cfor (dev = pci_devices; dev; dev = dev->next) {
dev304arch/alpha/kernel/bios32.cif (dev->vendor == vendor && dev->device == device_id) {
dev306arch/alpha/kernel/bios32.c*devfn = dev->devfn;
dev307arch/alpha/kernel/bios32.c*bus = dev->bus->number;
dev325arch/alpha/kernel/bios32.cstruct pci_dev *dev;
dev327arch/alpha/kernel/bios32.cfor (dev = pci_devices; dev; dev = dev->next) {
dev328arch/alpha/kernel/bios32.cif (dev->class == class_code) {
dev330arch/alpha/kernel/bios32.c*devfn = dev->devfn;
dev331arch/alpha/kernel/bios32.c*bus = dev->bus->number;
dev364arch/alpha/kernel/bios32.cstruct pci_dev *dev;
dev399arch/alpha/kernel/bios32.cfor (dev = pci_devices; dev; dev = dev->next) {
dev400arch/alpha/kernel/bios32.cdev->irq = 0;
dev401arch/alpha/kernel/bios32.cif (dev->bus->number != 0 ||
dev402arch/alpha/kernel/bios32.cPCI_SLOT(dev->devfn) < 6 || PCI_SLOT(dev->devfn) > 10)
dev405arch/alpha/kernel/bios32.cdev->bus->number, PCI_SLOT(dev->devfn));
dev409arch/alpha/kernel/bios32.cpcibios_read_config_byte(dev->bus->number, dev->devfn,
dev412arch/alpha/kernel/bios32.cif (dev->vendor == PCI_VENDOR_ID_S3 &&
dev413arch/alpha/kernel/bios32.c(dev->device == PCI_DEVICE_ID_S3_864_1 ||
dev414arch/alpha/kernel/bios32.cdev->device == PCI_DEVICE_ID_S3_864_2))
dev421arch/alpha/kernel/bios32.cpirq = pirq_tab[PCI_SLOT(dev->devfn) - 6][pin - 1];
dev425arch/alpha/kernel/bios32.cdev->irq = (route_tab >> (8 * pirq)) & 0xff;
dev428arch/alpha/kernel/bios32.cpcibios_write_config_byte(dev->bus->number, dev->devfn,
dev429arch/alpha/kernel/bios32.cPCI_INTERRUPT_LINE, dev->irq);
dev243arch/alpha/kernel/osf_sys.cdev_t dev;
dev259arch/alpha/kernel/osf_sys.cdev = inode->i_rdev;
dev260arch/alpha/kernel/osf_sys.cif (MAJOR(dev) >= MAX_BLKDEV) {
dev264arch/alpha/kernel/osf_sys.cfops = get_blkfops(MAJOR(dev));
dev340arch/alpha/kernel/osf_sys.cdev_t dev;
dev348arch/alpha/kernel/osf_sys.cdev = get_unnamed_dev();
dev349arch/alpha/kernel/osf_sys.cif (!dev)
dev351arch/alpha/kernel/osf_sys.cretval = do_mount(dev, dirname, "proc", flags, NULL);
dev353arch/alpha/kernel/osf_sys.cput_unnamed_dev(dev);
dev187drivers/block/aztcd.c(CURRENT && MAJOR(CURRENT -> dev) == MAJOR_NR && CURRENT -> cmd == READ \
dev22drivers/block/blk.h((s1)->dev < (s2)->dev || (((s1)->dev == (s2)->dev && \
dev33drivers/block/blk.hblksize_size[MAJOR_NR][MINOR(CURRENT->dev)] ? \
dev34drivers/block/blk.h((blksize_size[MAJOR_NR][MINOR(CURRENT->dev)] >> 9) - 1) :  \
dev76drivers/block/blk.hextern void set_device_ro(int dev,int flag);
dev85drivers/block/blk.h#define RO_IOCTLS(dev,where) \
dev87drivers/block/blk.hset_device_ro((dev),get_fs_long((long *) (where))); return 0; \
dev89drivers/block/blk.hif (!__err) put_fs_long(0!=is_read_only(dev),(long *) (where)); return __err; }
dev284drivers/block/blk.h#define CURRENT_DEV DEVICE_NR(CURRENT->dev)
dev323drivers/block/blk.hif (MAJOR(CURRENT->dev) != MAJOR_NR) \
dev348drivers/block/blk.h(unsigned long)req->dev, req->sector);
dev374drivers/block/blk.hDEVICE_OFF(req->dev);
dev379drivers/block/blk.hreq->dev = -1;
dev1404drivers/block/cdu31a.cif (CURRENT && (CURRENT->dev > 0))
dev1433drivers/block/cdu31a.cif (!(CURRENT) || CURRENT->dev < 0)
dev1445drivers/block/cdu31a.cin.i_rdev = CURRENT->dev;
dev1452drivers/block/cdu31a.cif (MAJOR(CURRENT->dev) != MAJOR_NR)
dev651drivers/block/cm206.cif (CURRENT == NULL || CURRENT->dev == -1) return;
dev2384drivers/block/floppy.cset_fdc(DRIVE(CURRENT->dev));
dev2629drivers/block/floppy.cif (CURRENT && CURRENT->dev < 0){
dev2640drivers/block/floppy.cif (MAJOR(CURRENT->dev) != MAJOR_NR)
dev2646drivers/block/floppy.c(CURRENT->errors || error == CURRENT->dev)){
dev2647drivers/block/floppy.cerror=CURRENT->dev;
dev2653drivers/block/floppy.cdevice = CURRENT->dev;
dev3305drivers/block/floppy.cstatic int check_floppy_change(dev_t dev)
dev3307drivers/block/floppy.cint drive = DRIVE( dev );
dev3309drivers/block/floppy.cif (MAJOR(dev) != MAJOR_NR) {
dev3325drivers/block/floppy.c(!TYPE(dev) && !current_type[drive]))
dev3334drivers/block/floppy.cstatic int floppy_revalidate(dev_t dev)
dev3336drivers/block/floppy.c#define NO_GEOM (!current_type[drive] && !TYPE(dev))
dev3338drivers/block/floppy.cint drive=DRIVE(dev);
dev3358drivers/block/floppy.cint size = floppy_blocksizes[MINOR(dev)];
dev3361drivers/block/floppy.cif (!(bh = getblk(dev,0,size))){
dev56drivers/block/genhd.cstatic void extended_partition(struct gendisk *hd, int dev)
dev63drivers/block/genhd.cfirst_sector = hd->part[MINOR(dev)].start_sect;
dev69drivers/block/genhd.cif (!(bh = bread(dev,0,1024)))
dev102drivers/block/genhd.cdev = ((hd->major) << 8) | current_minor;
dev111drivers/block/genhd.cstatic int msdos_partition(struct gendisk *hd, unsigned int dev, unsigned long first_sector)
dev122drivers/block/genhd.cif (!(bh = bread(dev,0,1024))) {
dev152drivers/block/genhd.chd->part[MINOR(dev)].start_sect += p->end_sector;
dev153drivers/block/genhd.chd->part[MINOR(dev)].nr_sects   -= p->end_sector;
dev155drivers/block/genhd.cide_xlate_1024(dev);  /* harmless if not an IDE drive */
dev170drivers/block/genhd.cide_xlate_1024(dev);  /* harmless if not an IDE drive */
dev210drivers/block/genhd.cstatic int osf_partition(struct gendisk *hd, unsigned int dev, unsigned long first_sector)
dev248drivers/block/genhd.cif (!(bh = bread(dev,0,1024))) {
dev278drivers/block/genhd.cstatic void check_partition(struct gendisk *hd, unsigned int dev)
dev286drivers/block/genhd.cfirst_sector = hd->part[MINOR(dev)].start_sect;
dev293drivers/block/genhd.chd->part[MINOR(dev)].start_sect = 0;
dev297drivers/block/genhd.cprintk("  %s%c:", hd->major_name, minor_name(hd, MINOR(dev)));
dev299drivers/block/genhd.cif (msdos_partition(hd, dev, first_sector))
dev303drivers/block/genhd.cif (osf_partition(hd, dev, first_sector))
dev318drivers/block/genhd.cvoid resetup_one_dev(struct gendisk *dev, int drive)
dev321drivers/block/genhd.cint start = drive<<dev->minor_shift;
dev322drivers/block/genhd.cint j = start + dev->max_p;
dev323drivers/block/genhd.cint major = dev->major << 8;
dev325drivers/block/genhd.ccurrent_minor = 1+(drive<<dev->minor_shift);
dev326drivers/block/genhd.ccheck_partition(dev, major+(drive<<dev->minor_shift));
dev329drivers/block/genhd.cdev->sizes[i] = dev->part[i].nr_sects >> (BLOCK_SIZE_BITS - 9);
dev332drivers/block/genhd.cstatic void setup_dev(struct gendisk *dev)
dev335drivers/block/genhd.cint j = dev->max_nr * dev->max_p;
dev336drivers/block/genhd.cint major = dev->major << 8;
dev341drivers/block/genhd.cdev->part[i].start_sect = 0;
dev342drivers/block/genhd.cdev->part[i].nr_sects = 0;
dev344drivers/block/genhd.cdev->init();  
dev345drivers/block/genhd.cfor (drive=0 ; drive<dev->nr_real ; drive++) {
dev346drivers/block/genhd.ccurrent_minor = 1+(drive<<dev->minor_shift);
dev347drivers/block/genhd.ccheck_partition(dev, major+(drive<<dev->minor_shift));
dev350drivers/block/genhd.cdev->sizes[i] = dev->part[i].nr_sects >> (BLOCK_SIZE_BITS - 9);
dev351drivers/block/genhd.cblk_size[dev->major] = dev->sizes;
dev269drivers/block/gscd.cunsigned int block,dev;
dev273drivers/block/gscd.cif (!(CURRENT) || CURRENT->dev < 0) return;
dev275drivers/block/gscd.cdev = MINOR(CURRENT->dev);
dev289drivers/block/gscd.cif (MINOR(CURRENT -> dev) != 0)
dev307drivers/block/gscd.cprintk ("GSCD: dev %d, block %d, nsect %d\n", dev, block, nsect );
dev136drivers/block/hd.cdevc = CURRENT ? 'a' + DEVICE_NR(CURRENT->dev) : '?';
dev285drivers/block/hd.cunsigned int dev = DEVICE_NR(CURRENT->dev);
dev287drivers/block/hd.cstruct hd_driveid *id = hd_ident_info[dev];
dev289drivers/block/hd.cif (unmask_intr[dev])
dev292drivers/block/hd.cprintk ("  hd%c: non-IDE device, %dMB, CHS=%d/%d/%d\n", dev+'a',
dev293drivers/block/hd.chd_info[dev].cyl*hd_info[dev].head*hd_info[dev].sect / 2048,
dev294drivers/block/hd.chd_info[dev].cyl, hd_info[dev].head, hd_info[dev].sect);
dev296drivers/block/hd.chd_ident_info[dev] = NULL;
dev301drivers/block/hd.cmax_mult[dev] = id->max_multsect;
dev310drivers/block/hd.chd_info[dev].cyl  = id->cur_cyls;
dev311drivers/block/hd.chd_info[dev].head = id->cur_heads;
dev312drivers/block/hd.chd_info[dev].sect = id->cur_sectors; 
dev318drivers/block/hd.cdev+'a', id->model, id->cyls*id->heads*id->sectors/2048,
dev319drivers/block/hd.cid->buf_size/2, bios_info[dev].cyl, bios_info[dev].head,
dev320drivers/block/hd.cbios_info[dev].sect, id->max_multsect);
dev327drivers/block/hd.cspecial_op[dev] = recalibrate[dev] = 1;
dev338drivers/block/hd.cunsigned int dev = DEVICE_NR(CURRENT->dev), stat = inb_p(HD_STATUS);
dev340drivers/block/hd.cif (unmask_intr[dev])
dev343drivers/block/hd.cmult_req[dev] = mult_count[dev] = 0;
dev346drivers/block/hd.cif ((mult_count[dev] = mult_req[dev]))
dev348drivers/block/hd.cdev+'a', mult_count[dev]);
dev350drivers/block/hd.cprintk ("  hd%c: disabled multiple mode\n", dev+'a');
dev448drivers/block/hd.cint dev;
dev452drivers/block/hd.cdev = DEVICE_NR(CURRENT->dev);
dev455drivers/block/hd.cspecial_op[dev] = recalibrate[dev] = 1;
dev459drivers/block/hd.cspecial_op[dev] = recalibrate[dev] = 1;
dev476drivers/block/hd.cunsigned int dev = DEVICE_NR(CURRENT->dev);
dev477drivers/block/hd.cint i, retries = 100000, msect = mult_count[dev], nsect;
dev479drivers/block/hd.cif (unmask_intr[dev])
dev509drivers/block/hd.cdev+'a', CURRENT->sector, CURRENT->sector+nsect,
dev529drivers/block/hd.cstatic inline void multwrite (unsigned int dev)
dev531drivers/block/hd.cunsigned int mcount = mult_count[dev];
dev551drivers/block/hd.cunsigned int dev = DEVICE_NR(WCURRENT.dev);
dev553drivers/block/hd.cif (unmask_intr[dev])
dev558drivers/block/hd.cmultwrite(dev);
dev587drivers/block/hd.cif (unmask_intr[DEVICE_NR(WCURRENT.dev)])
dev637drivers/block/hd.cunsigned int dev;
dev645drivers/block/hd.cdev = DEVICE_NR(CURRENT->dev);
dev646drivers/block/hd.cprintk("hd%c: timeout\n", dev+'a');
dev649drivers/block/hd.cprintk("hd%c: too many errors\n", dev+'a');
dev658drivers/block/hd.cint do_special_op (unsigned int dev)
dev660drivers/block/hd.cif (recalibrate[dev]) {
dev661drivers/block/hd.crecalibrate[dev] = 0;
dev662drivers/block/hd.chd_out(dev,hd_info[dev].sect,0,0,0,WIN_RESTORE,&recal_intr);
dev665drivers/block/hd.cif (!identified[dev]) {
dev666drivers/block/hd.cidentified[dev]  = 1;
dev667drivers/block/hd.cunmask_intr[dev] = DEFAULT_UNMASK_INTR;
dev668drivers/block/hd.cmult_req[dev]    = DEFAULT_MULT_COUNT;
dev669drivers/block/hd.chd_out(dev,0,0,0,0,WIN_IDENTIFY,&identify_intr);
dev672drivers/block/hd.cif (mult_req[dev] != mult_count[dev]) {
dev673drivers/block/hd.chd_out(dev,mult_req[dev],0,0,0,WIN_SETMULT,&set_multmode_intr);
dev676drivers/block/hd.cif (hd_info[dev].head > 16) {
dev677drivers/block/hd.cprintk ("hd%c: cannot handle device with more than 16 heads - giving up\n", dev+'a');
dev680drivers/block/hd.cspecial_op[dev] = 0;
dev698drivers/block/hd.cunsigned int dev, block, nsect, sec, track, head, cyl;
dev700drivers/block/hd.cif (CURRENT && CURRENT->dev < 0) return;
dev712drivers/block/hd.cdev = MINOR(CURRENT->dev);
dev715drivers/block/hd.cif (dev >= (NR_HD<<6) || block >= hd[dev].nr_sects || ((block+nsect) > hd[dev].nr_sects)) {
dev717drivers/block/hd.cif (dev >= (NR_HD<<6))
dev718drivers/block/hd.cprintk("hd: bad minor number: device=0x%04x\n", CURRENT->dev);
dev721drivers/block/hd.c(CURRENT->dev>>6)+'a', block, nsect);
dev726drivers/block/hd.cblock += hd[dev].start_sect;
dev727drivers/block/hd.cdev >>= 6;
dev728drivers/block/hd.cif (special_op[dev]) {
dev729drivers/block/hd.cif (do_special_op(dev))
dev733drivers/block/hd.csec   = block % hd_info[dev].sect + 1;
dev734drivers/block/hd.ctrack = block / hd_info[dev].sect;
dev735drivers/block/hd.chead  = track % hd_info[dev].head;
dev736drivers/block/hd.ccyl   = track / hd_info[dev].head;
dev739drivers/block/hd.cdev+'a', (CURRENT->cmd == READ)?"read":"writ",
dev742drivers/block/hd.cif (!unmask_intr[dev])
dev745drivers/block/hd.cunsigned int cmd = mult_count[dev] > 1 ? WIN_MULTREAD : WIN_READ;
dev746drivers/block/hd.chd_out(dev,nsect,sec,head,cyl,cmd,&read_intr);
dev752drivers/block/hd.cif (mult_count[dev])
dev753drivers/block/hd.chd_out(dev,nsect,sec,head,cyl,WIN_MULTWRITE,&multwrite_intr);
dev755drivers/block/hd.chd_out(dev,nsect,sec,head,cyl,WIN_WRITE,&write_intr);
dev762drivers/block/hd.cif (mult_count[dev]) {
dev764drivers/block/hd.cmultwrite(dev);
dev783drivers/block/hd.cint dev, err;
dev788drivers/block/hd.cdev = DEVICE_NR(inode->i_rdev);
dev789drivers/block/hd.cif (dev >= NR_HD)
dev797drivers/block/hd.cput_user(bios_info[dev].head,
dev799drivers/block/hd.cput_user(bios_info[dev].sect,
dev801drivers/block/hd.cput_user(bios_info[dev].cyl,
dev838drivers/block/hd.cunmask_intr[dev] = arg;
dev846drivers/block/hd.cput_user(unmask_intr[dev], (long *) arg);
dev854drivers/block/hd.cput_user(mult_count[dev], (long *) arg);
dev862drivers/block/hd.cif (arg > max_mult[dev])
dev864drivers/block/hd.celse if (mult_req[dev] != mult_count[dev]) {
dev865drivers/block/hd.cspecial_op[dev] = 1;
dev868drivers/block/hd.cmult_req[dev] = arg;
dev869drivers/block/hd.cspecial_op[dev] = 1;
dev878drivers/block/hd.cif (hd_ident_info[dev] == NULL)  return -ENOMSG;
dev882drivers/block/hd.cmemcpy_tofs((char *)arg, (char *) hd_ident_info[dev], sizeof(struct hd_driveid));
dev1081drivers/block/hd.cstatic int revalidate_hddisk(int dev, int maxusage)
dev1090drivers/block/hd.ctarget =  DEVICE_NR(dev);
dev74drivers/block/ide-cd.c#define OUT_WORDS(b,n)  output_ide_data(dev,b,(n)/2)
dev75drivers/block/ide-cd.c#define IN_WORDS(b,n)  input_ide_data(dev,b,(n)/2)
dev150drivers/block/ide-cd.c#define CDROM_FLAGS(dev) ((struct ide_cd_flags *)&((dev)->bios_sect))
dev362drivers/block/ide-cd.cvoid cdrom_analyze_sense_data (ide_dev_t *dev, 
dev380drivers/block/ide-cd.cprintk ("ATAPI device %s:\n", dev->name);
dev440drivers/block/ide-cd.cdev->name,
dev461drivers/block/ide-cd.cstatic void cdrom_queue_request_sense (ide_dev_t *dev)
dev487drivers/block/ide-cd.creqbuf = &cdrom_info[DEV_HWIF][dev->select.b.drive].sense_data;
dev498drivers/block/ide-cd.crq->dev = MKDEV (major, (dev->select.b.drive) << PARTN_BITS);
dev521drivers/block/ide-cd.cstatic void cdrom_end_request (int uptodate, ide_dev_t *dev)
dev537drivers/block/ide-cd.creqbuf = &cdrom_info[DEV_HWIF][dev->select.b.drive].sense_data;
dev538drivers/block/ide-cd.ccdrom_analyze_sense_data (dev, reqbuf, NULL);
dev547drivers/block/ide-cd.cstatic void cdrom_saw_media_change (ide_dev_t *dev)
dev549drivers/block/ide-cd.cCDROM_FLAGS (dev)->media_changed = 1;
dev550drivers/block/ide-cd.cCDROM_FLAGS (dev)->toc_valid = 0;
dev551drivers/block/ide-cd.ccdrom_info[DEV_HWIF][dev->select.b.drive].nsectors_buffered = 0;
dev557drivers/block/ide-cd.cstatic int cdrom_decode_status (ide_dev_t *dev, int good_stat, int *stat_ret)
dev574drivers/block/ide-cd.cprintk ("%s : missing request in cdrom_decode_status\n", dev->name);
dev583drivers/block/ide-cd.ccdrom_saw_media_change (dev);
dev588drivers/block/ide-cd.cprintk ("%s : tray open\n", dev->name);
dev589drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev602drivers/block/ide-cd.cprintk ("%s : tray open\n", dev->name);
dev606drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev613drivers/block/ide-cd.ccdrom_saw_media_change (dev);
dev614drivers/block/ide-cd.cprintk ("%s: media changed\n", dev->name);
dev624drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev631drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev641drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev648drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev654drivers/block/ide-cd.cide_error (dev, "cdrom_decode_status", stat);
dev660drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev668drivers/block/ide-cd.ccdrom_queue_request_sense (dev);
dev681drivers/block/ide-cd.cstatic int cdrom_start_packet_command (ide_dev_t *dev, int xferlen)
dev684drivers/block/ide-cd.cif (wait_stat (dev, 0, BUSY_STAT, WAIT_READY)) return 1;
dev693drivers/block/ide-cd.cOUT_BYTE (dev->ctl, HD_CMD);
dev703drivers/block/ide-cd.cstatic int cdrom_transfer_packet_command (ide_dev_t *dev,
dev706drivers/block/ide-cd.cif (CDROM_FLAGS (dev)->drq_interrupt)
dev713drivers/block/ide-cd.cif (cdrom_decode_status (dev, DRQ_STAT, &stat_dum)) return 1;
dev718drivers/block/ide-cd.cif (wait_stat (dev, DRQ_STAT, BUSY_STAT, WAIT_READY)) return 1;
dev740drivers/block/ide-cd.cstatic void cdrom_buffer_sectors (ide_dev_t *dev, unsigned long sector,
dev743drivers/block/ide-cd.cstruct cdrom_info *info = &cdrom_info[DEV_HWIF][dev->select.b.drive];
dev795drivers/block/ide-cd.cint cdrom_read_check_ireason (ide_dev_t *dev, int len, int ireason)
dev805drivers/block/ide-cd.cdev->name);
dev821drivers/block/ide-cd.cdev->name, ireason);
dev824drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev833drivers/block/ide-cd.cstatic void cdrom_read_intr (ide_dev_t *dev)
dev841drivers/block/ide-cd.cif (cdrom_decode_status (dev, 0, &stat)) return;
dev855drivers/block/ide-cd.cdev->name, rq->current_nr_sectors);
dev856drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev859drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev866drivers/block/ide-cd.cif (cdrom_read_check_ireason (dev, len, ireason)) return;
dev873drivers/block/ide-cd.cdev->name, len);
dev875drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev907drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev913drivers/block/ide-cd.ccdrom_buffer_sectors (dev, rq->sector, sectors_to_transfer);
dev948drivers/block/ide-cd.cstatic int cdrom_read_from_buffer (ide_dev_t *dev)
dev950drivers/block/ide-cd.cstruct cdrom_info *info = &cdrom_info[DEV_HWIF][dev->select.b.drive];
dev963drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev978drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev984drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev994drivers/block/ide-cd.cdev->name, rq->sector);
dev995drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev1010drivers/block/ide-cd.cstatic int cdrom_start_read_continuation (ide_dev_t *dev)
dev1036drivers/block/ide-cd.cdev->name, rq->current_nr_sectors);
dev1037drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev1074drivers/block/ide-cd.cif (cdrom_transfer_packet_command (dev, pc.c, sizeof (pc.c)))
dev1090drivers/block/ide-cd.cstatic int cdrom_start_read (ide_dev_t *dev, unsigned int block)
dev1099drivers/block/ide-cd.cif (cdrom_read_from_buffer (dev))
dev1103drivers/block/ide-cd.ccdrom_info[DEV_HWIF][dev->select.b.drive].nsectors_buffered = 0;
dev1105drivers/block/ide-cd.cif (cdrom_start_packet_command (dev, 32768))
dev1108drivers/block/ide-cd.cif (CDROM_FLAGS (dev)->drq_interrupt)
dev1112drivers/block/ide-cd.cif (cdrom_start_read_continuation (dev))
dev1128drivers/block/ide-cd.ccdrom_request_sense (ide_dev_t *dev, struct atapi_request_sense *reqbuf);
dev1132drivers/block/ide-cd.cstatic void cdrom_pc_intr (ide_dev_t *dev)
dev1139drivers/block/ide-cd.cif (cdrom_decode_status (dev, 0, &stat)) return;
dev1159drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev1163drivers/block/ide-cd.cdev->name, pc->buflen);
dev1165drivers/block/ide-cd.ccdrom_end_request (1, dev);
dev1183drivers/block/ide-cd.cdev->name);
dev1212drivers/block/ide-cd.cdev->name);
dev1237drivers/block/ide-cd.cdev->name, ireason);
dev1246drivers/block/ide-cd.cstatic int cdrom_do_pc_continuation (ide_dev_t *dev)
dev1251drivers/block/ide-cd.cif (cdrom_transfer_packet_command (dev, pc->c, sizeof (pc->c)))
dev1261drivers/block/ide-cd.cstatic int cdrom_do_packet_command (ide_dev_t *dev)
dev1272drivers/block/ide-cd.cif (cdrom_start_packet_command (dev, len))
dev1275drivers/block/ide-cd.cif (CDROM_FLAGS (dev)->drq_interrupt)
dev1279drivers/block/ide-cd.cif (cdrom_do_pc_continuation (dev))
dev1288drivers/block/ide-cd.cint cdrom_queue_packet_command (ide_dev_t *dev, struct packet_command *pc)
dev1297drivers/block/ide-cd.creq.dev = MKDEV (major, (dev->select.b.drive) << PARTN_BITS);
dev1334drivers/block/ide-cd.c&cdrom_info[DEV_HWIF][dev->select.b.drive].sense_data;
dev1336drivers/block/ide-cd.cif (pc->c[0] == REQUEST_SENSE || cdrom_request_sense (dev, reqbuf))
dev1341drivers/block/ide-cd.ccdrom_analyze_sense_data (dev, reqbuf, pc);
dev1363drivers/block/ide-cd.cstatic int do_rw_cdrom (ide_dev_t *dev, unsigned long block)
dev1368drivers/block/ide-cd.creturn cdrom_do_packet_command (dev);
dev1373drivers/block/ide-cd.ccdrom_end_request (0, dev);
dev1377drivers/block/ide-cd.creturn cdrom_start_read (dev, block);
dev1436drivers/block/ide-cd.ccdrom_check_status (ide_dev_t  *dev)
dev1444drivers/block/ide-cd.c(void) cdrom_queue_packet_command (dev, &pc);
dev1449drivers/block/ide-cd.ccdrom_request_sense (ide_dev_t *dev, struct atapi_request_sense *reqbuf)
dev1460drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1467drivers/block/ide-cd.ccdrom_lockdoor (ide_dev_t *dev, int lockflag)
dev1475drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1483drivers/block/ide-cd.ccdrom_eject (ide_dev_t *dev, int ejectflag)
dev1491drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1496drivers/block/ide-cd.ccdrom_pause (ide_dev_t *dev, int pauseflag)
dev1504drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1509drivers/block/ide-cd.ccdrom_startstop (ide_dev_t *dev, int startflag)
dev1518drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1523drivers/block/ide-cd.ccdrom_read_tocentry (ide_dev_t *dev, int trackno, int msf_flag,
dev1537drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1543drivers/block/ide-cd.ccdrom_read_toc (ide_dev_t *dev)
dev1547drivers/block/ide-cd.cstruct atapi_toc *toc = cdrom_info[DEV_HWIF][dev->select.b.drive].toc;
dev1554drivers/block/ide-cd.ccdrom_info[DEV_HWIF][dev->select.b.drive].toc = toc;
dev1559drivers/block/ide-cd.cprintk ("%s: No cdrom TOC buffer!\n", dev->name);
dev1565drivers/block/ide-cd.cif (CDROM_FLAGS (dev)->toc_valid)
dev1566drivers/block/ide-cd.ccdrom_check_status (dev);
dev1568drivers/block/ide-cd.cif (CDROM_FLAGS (dev)->toc_valid) return 0;
dev1571drivers/block/ide-cd.cmsf_flag = (CDROM_FLAGS (dev)->no_lba_toc);
dev1574drivers/block/ide-cd.cstat = cdrom_read_tocentry (dev, 0, msf_flag, (char *)toc,
dev1584drivers/block/ide-cd.cstat = cdrom_read_tocentry (dev, 0, msf_flag, (char *)toc,
dev1601drivers/block/ide-cd.cCDROM_FLAGS (dev)->toc_valid = 1;
dev1608drivers/block/ide-cd.ccdrom_read_subchannel (ide_dev_t *dev,
dev1622drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1628drivers/block/ide-cd.ccdrom_mode_sense (ide_dev_t *dev, int pageno, int modeflag,
dev1641drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1646drivers/block/ide-cd.ccdrom_mode_select (ide_dev_t *dev, int pageno, char *buf, int buflen)
dev1659drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1664drivers/block/ide-cd.ccdrom_play_lba_range_play12 (ide_dev_t *dev, int lba_start, int lba_end)
dev1676drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1681drivers/block/ide-cd.ccdrom_play_lba_range_msf (ide_dev_t *dev, int lba_start, int lba_end)
dev1691drivers/block/ide-cd.cif (CDROM_FLAGS (dev)->msf_as_bcd)
dev1701drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1708drivers/block/ide-cd.ccdrom_play_lba_range (ide_dev_t *dev, int lba_start, int lba_end)
dev1721drivers/block/ide-cd.cif (CDROM_FLAGS (dev)->no_playaudio12)
dev1722drivers/block/ide-cd.creturn cdrom_play_lba_range_msf (dev, lba_start, lba_end);
dev1728drivers/block/ide-cd.cstat = cdrom_play_lba_range_play12 (dev, lba_start, lba_end);
dev1732drivers/block/ide-cd.creqbuf = &cdrom_info[DEV_HWIF][dev->select.b.drive].sense_data;
dev1738drivers/block/ide-cd.c"trying PLAYAUDIO_MSF\n", dev->name);
dev1739drivers/block/ide-cd.cCDROM_FLAGS (dev)->no_playaudio12 = 1;
dev1740drivers/block/ide-cd.cCDROM_FLAGS (dev)->msf_as_bcd = 1;
dev1741drivers/block/ide-cd.creturn cdrom_play_lba_range_msf (dev, lba_start, lba_end);
dev1751drivers/block/ide-cd.cint cdrom_get_toc_entry (ide_dev_t *dev, int track,
dev1758drivers/block/ide-cd.cstat = cdrom_read_toc (dev);
dev1761drivers/block/ide-cd.ctoc = cdrom_info[DEV_HWIF][dev->select.b.drive].toc;
dev1777drivers/block/ide-cd.cstatic int ide_cdrom_ioctl (ide_dev_t *dev, struct inode *inode,
dev1783drivers/block/ide-cd.creturn cdrom_eject (dev, 0);
dev1786drivers/block/ide-cd.creturn cdrom_pause (dev, 1);
dev1789drivers/block/ide-cd.creturn cdrom_pause (dev, 0);
dev1792drivers/block/ide-cd.creturn cdrom_startstop (dev, 1);
dev1795drivers/block/ide-cd.creturn cdrom_startstop (dev, 0);
dev1814drivers/block/ide-cd.creturn cdrom_play_lba_range (dev, lba_start, lba_end);
dev1830drivers/block/ide-cd.cstat = cdrom_get_toc_entry (dev, ti.cdti_trk0, &first_toc);
dev1832drivers/block/ide-cd.cstat = cdrom_get_toc_entry (dev, ti.cdti_trk1, &last_toc);
dev1841drivers/block/ide-cd.creturn cdrom_play_lba_range (dev, lba_start, lba_end);
dev1854drivers/block/ide-cd.cstat = cdrom_read_toc (dev);
dev1857drivers/block/ide-cd.ctoc = cdrom_info[DEV_HWIF][dev->select.b.drive].toc;
dev1879drivers/block/ide-cd.cstat = cdrom_get_toc_entry (dev, tocentry.cdte_track, &toce);
dev1914drivers/block/ide-cd.cstat = cdrom_read_subchannel (dev, buffer, sizeof (buffer));
dev1959drivers/block/ide-cd.cstat = cdrom_mode_sense (dev, 0x0e, 0, buffer, sizeof (buffer));
dev1961drivers/block/ide-cd.cstat = cdrom_mode_sense (dev, 0x0e, 1, mask  , sizeof (buffer));
dev1971drivers/block/ide-cd.creturn cdrom_mode_select (dev, 0x0e, buffer, sizeof (buffer));
dev1986drivers/block/ide-cd.creturn cdrom_queue_packet_command (dev, &pc);
dev1997drivers/block/ide-cd.cstat = cdrom_request_sense (dev, &reqbuf);
dev2017drivers/block/ide-cd.cstatic int cdrom_check_media_change (ide_dev_t *dev)
dev2021drivers/block/ide-cd.ccdrom_check_status (dev);
dev2023drivers/block/ide-cd.cretval = CDROM_FLAGS (dev)->media_changed;
dev2024drivers/block/ide-cd.cCDROM_FLAGS (dev)->media_changed = 0;
dev2031drivers/block/ide-cd.ccdrom_open (struct inode *ip, struct file *fp, ide_dev_t *dev)
dev2038drivers/block/ide-cd.cif (dev->usage == 1)
dev2039drivers/block/ide-cd.c(void) cdrom_lockdoor (dev, 1);
dev2052drivers/block/ide-cd.ccdrom_release (struct inode *inode, struct file *file, ide_dev_t *dev)
dev2054drivers/block/ide-cd.cif (dev->usage == 0)
dev2060drivers/block/ide-cd.c(void) cdrom_lockdoor (dev, 0);
dev2071drivers/block/ide-cd.cstatic void cdrom_setup (ide_dev_t *dev)
dev2074drivers/block/ide-cd.cide_capacity[DEV_HWIF][dev->select.b.drive] = 0x1fffff;
dev2076drivers/block/ide-cd.cide_blksizes[DEV_HWIF][dev->select.b.drive << PARTN_BITS] = CD_FRAMESIZE;
dev2078drivers/block/ide-cd.cdev->special.all = 0;
dev2080drivers/block/ide-cd.cCDROM_FLAGS (dev)->media_changed = 0;
dev2081drivers/block/ide-cd.cCDROM_FLAGS (dev)->toc_valid     = 0;
dev2083drivers/block/ide-cd.cCDROM_FLAGS (dev)->no_playaudio12 = 0;
dev2084drivers/block/ide-cd.cCDROM_FLAGS (dev)->no_lba_toc = 0;
dev2085drivers/block/ide-cd.cCDROM_FLAGS (dev)->msf_as_bcd = 0;
dev2086drivers/block/ide-cd.cCDROM_FLAGS (dev)->drq_interrupt = ((dev->id->config & 0x0060) == 0x20);
dev2089drivers/block/ide-cd.cif (strcmp (dev->id->model, "CD220E") == 0)  /* Creative Labs */
dev2090drivers/block/ide-cd.cCDROM_FLAGS (dev)->no_lba_toc = 1;
dev2092drivers/block/ide-cd.celse if (strcmp (dev->id->model, "TO-ICSLYAL") == 0 ||  /* Acer CD525E */
dev2093drivers/block/ide-cd.cstrcmp (dev->id->model, "OTI-SCYLLA") == 0)
dev2094drivers/block/ide-cd.cCDROM_FLAGS (dev)->no_lba_toc = 1;
dev2096drivers/block/ide-cd.celse if (strcmp (dev->id->model, "CDA26803I SE") == 0) /* Aztech */
dev2098drivers/block/ide-cd.cCDROM_FLAGS (dev)->no_lba_toc = 1;
dev2101drivers/block/ide-cd.cCDROM_FLAGS (dev)->no_playaudio12 = 1;
dev2104drivers/block/ide-cd.ccdrom_info[DEV_HWIF][dev->select.b.drive].toc               = NULL;
dev2105drivers/block/ide-cd.ccdrom_info[DEV_HWIF][dev->select.b.drive].sector_buffer     = NULL;
dev2106drivers/block/ide-cd.ccdrom_info[DEV_HWIF][dev->select.b.drive].sector_buffered   = 0;
dev2107drivers/block/ide-cd.ccdrom_info[DEV_HWIF][dev->select.b.drive].nsectors_buffered = 0;
dev203drivers/block/ide.c#define DEV_HWIF    (dev->hwif)
dev259drivers/block/ide.c#define BIOS_SECTORS(dev)  (dev->bios_head*dev->bios_sect*dev->bios_cyl)
dev430drivers/block/ide.c#define WAIT_STAT(dev,good,bad,timeout,msg,label)      \
dev443drivers/block/ide.cide_error(dev, msg " error", stat);      \
dev451drivers/block/ide.cvoid input_ide_data (ide_dev_t *dev, void *buffer, uint wcount)
dev454drivers/block/ide.cif (dev->vlb_32bit) {
dev456drivers/block/ide.cif (dev->vlb_sync) {
dev460drivers/block/ide.cif (dev->unmask)
dev473drivers/block/ide.cvoid output_ide_data (ide_dev_t *dev, void *buffer, uint wcount)
dev476drivers/block/ide.cif (dev->vlb_32bit) {
dev478drivers/block/ide.cif (dev->vlb_sync) {
dev482drivers/block/ide.cif (dev->unmask)
dev503drivers/block/ide.cstatic void do_ide_reset (ide_dev_t *dev)
dev527drivers/block/ide.cOUT_BYTE(dev->ctl|6,HD_CMD);  /* set nIEN, set SRST */
dev529drivers/block/ide.cOUT_BYTE(dev->ctl|2,HD_CMD);  /* clear SRST */
dev570drivers/block/ide.cstatic void end_drive_cmd (ide_dev_t *dev, byte stat, byte err)
dev596drivers/block/ide.cide_dev_t *dev = ide_cur_dev[HWIF];
dev597drivers/block/ide.cconst char *name = dev ? dev->name : ide_name[HWIF];
dev603drivers/block/ide.cif (dev && dev->type == disk) {
dev624drivers/block/ide.cif (dev && dev->type == disk) {
dev665drivers/block/ide.cstatic void ide_error (ide_dev_t *dev, const char *msg, byte stat)
dev671drivers/block/ide.cif ((rq = ide_cur_rq[DEV_HWIF]) == NULL || dev == NULL)
dev675drivers/block/ide.cend_drive_cmd(dev, stat, err);
dev682drivers/block/ide.cif (dev->type == disk && (stat & ERR_STAT)) {
dev690drivers/block/ide.cint i = dev->mult_count ? dev->mult_count<<8 : 1<<8;
dev692drivers/block/ide.c(void) IN_BYTE(HD_DATA, dev->hwif);
dev695drivers/block/ide.cif (GET_STAT(dev->hwif) & (BUSY_STAT|DRQ_STAT))
dev702drivers/block/ide.cdo_ide_reset(dev);
dev704drivers/block/ide.cdev->special.b.recalibrate = 1;
dev709drivers/block/ide.cstatic void read_intr (ide_dev_t *dev)
dev718drivers/block/ide.cide_error(dev, "read_intr", stat);
dev722drivers/block/ide.cmsect = dev->mult_count;
dev731drivers/block/ide.cinput_ide_data(dev, rq->buffer, nsect * SECTOR_WORDS);
dev734drivers/block/ide.cdev->name, rq->sector, rq->sector+nsect-1,
dev753drivers/block/ide.cstatic void write_intr (ide_dev_t *dev)
dev759drivers/block/ide.cif (OK_STAT(stat=GET_STAT(DEV_HWIF),DRIVE_READY,dev->bad_wstat)) {
dev762drivers/block/ide.cdev->name, rq->sector, (unsigned long) rq->buffer,
dev775drivers/block/ide.coutput_ide_data(dev, rq->buffer, SECTOR_WORDS);
dev783drivers/block/ide.cide_error(dev, "write_intr", stat);
dev787drivers/block/ide.cstatic void multwrite (ide_dev_t *dev)
dev790drivers/block/ide.cunsigned int mcount = dev->mult_count;
dev798drivers/block/ide.coutput_ide_data(dev, rq->buffer, nsect<<7);
dev801drivers/block/ide.cdev->name, rq->sector, (unsigned long) rq->buffer,
dev811drivers/block/ide.cpanic("%s: buffer list corrupted\n", dev->name);
dev820drivers/block/ide.cstatic void multwrite_intr (ide_dev_t *dev)
dev826drivers/block/ide.cif (OK_STAT(stat=GET_STAT(DEV_HWIF),DRIVE_READY,dev->bad_wstat)) {
dev829drivers/block/ide.cif (dev->mult_count)
dev830drivers/block/ide.cmultwrite(dev);
dev847drivers/block/ide.cide_error(dev, "multwrite_intr", stat);
dev855drivers/block/ide.cstatic inline void ide_cmd(ide_dev_t *dev, byte cmd, byte nsect,
dev856drivers/block/ide.cvoid (*handler)(ide_dev_t *dev))
dev858drivers/block/ide.cOUT_BYTE(dev->ctl,HD_CMD);
dev864drivers/block/ide.cstatic void set_multmode_intr (ide_dev_t *dev)
dev870drivers/block/ide.cdev->mult_req = dev->mult_count = 0;
dev871drivers/block/ide.cdev->special.b.recalibrate = 1;
dev873drivers/block/ide.c} else if (!dev->be_quiet) {
dev874drivers/block/ide.cif ((dev->mult_count = dev->mult_req))
dev876drivers/block/ide.cdev->name, dev->mult_count);
dev878drivers/block/ide.cprintk ("  %s: multiple mode turned off\n", dev->name);
dev880drivers/block/ide.cdev->be_quiet = 0;
dev884drivers/block/ide.cstatic void set_geometry_intr (ide_dev_t *dev)
dev890drivers/block/ide.cide_error(dev, "set_geometry_intr", stat);
dev894drivers/block/ide.cstatic void recal_intr (ide_dev_t *dev)
dev900drivers/block/ide.cide_error(dev, "recal_intr", stat);
dev904drivers/block/ide.cstatic void drive_cmd_intr (ide_dev_t *dev)
dev910drivers/block/ide.cide_error(dev, "drive_cmd", stat); /* calls end_drive_cmd() */
dev912drivers/block/ide.cend_drive_cmd (dev, stat, GET_ERR(DEV_HWIF));
dev962drivers/block/ide.cstatic int do_special (ide_dev_t *dev)
dev964drivers/block/ide.cspecial_t *s = &dev->special;
dev966drivers/block/ide.cprintk("%s: do_special: 0x%02x\n", dev->name, s->all);
dev970drivers/block/ide.cif (dev->type == disk) {
dev971drivers/block/ide.cOUT_BYTE(dev->sect,HD_SECTOR);
dev972drivers/block/ide.cOUT_BYTE(dev->cyl,HD_LCYL);
dev973drivers/block/ide.cOUT_BYTE(dev->cyl>>8,HD_HCYL);
dev974drivers/block/ide.cOUT_BYTE(((dev->head-1)|dev->select.all)&0xBF,HD_CURRENT);
dev975drivers/block/ide.cide_cmd(dev, WIN_SPECIFY, dev->sect, &set_geometry_intr);
dev979drivers/block/ide.cif (dev->type == disk)
dev980drivers/block/ide.cide_cmd(dev,WIN_RESTORE,dev->sect,&recal_intr);
dev982drivers/block/ide.cif (dev->type == disk) {
dev983drivers/block/ide.cif (dev->id && dev->mult_req > dev->id->max_multsect)
dev984drivers/block/ide.cdev->mult_req = dev->id->max_multsect;
dev985drivers/block/ide.cide_cmd(dev,WIN_SETMULT,dev->mult_req,&set_multmode_intr);
dev987drivers/block/ide.cdev->mult_req = 0;
dev988drivers/block/ide.cprintk("%s: multmode not supported by this device\n", dev->name);
dev993drivers/block/ide.cprintk("%s: bad special flag: 0x%02x\n", dev->name, s->all);
dev1001drivers/block/ide.cstatic byte wait_stat (ide_dev_t *dev, byte good, byte bad, unsigned long timeout)
dev1007drivers/block/ide.cWAIT_STAT(dev, good, bad, timeout, "status", error);
dev1018drivers/block/ide.cstatic inline int do_rw_disk (ide_dev_t *dev, struct request *rq, unsigned long block)
dev1020drivers/block/ide.cOUT_BYTE(dev->ctl,HD_CMD);
dev1022drivers/block/ide.cif (dev->select.b.lba) {
dev1025drivers/block/ide.cdev->name, (rq->cmd==READ)?"read":"writ", 
dev1031drivers/block/ide.cOUT_BYTE(((block>>8)&0x0f)|dev->select.all,HD_CURRENT);
dev1034drivers/block/ide.ctrack = block / dev->sect;
dev1035drivers/block/ide.csect  = block % dev->sect + 1;
dev1037drivers/block/ide.chead  = track % dev->head;
dev1038drivers/block/ide.ccyl   = track / dev->head;
dev1041drivers/block/ide.cOUT_BYTE(head|dev->select.all,HD_CURRENT);
dev1044drivers/block/ide.cdev->name, (rq->cmd==READ)?"read":"writ", cyl,
dev1049drivers/block/ide.cOUT_BYTE(dev->mult_count ? WIN_MULTREAD : WIN_READ, HD_COMMAND);
dev1054drivers/block/ide.cOUT_BYTE(dev->wpcom,HD_PRECOMP);  /* for ancient drives */
dev1055drivers/block/ide.cOUT_BYTE(dev->mult_count ? WIN_MULTWRITE : WIN_WRITE, HD_COMMAND);
dev1056drivers/block/ide.cWAIT_STAT(dev,DATA_READY,dev->bad_wstat,WAIT_DRQ,"DRQ",error);
dev1057drivers/block/ide.cif (!dev->unmask)
dev1059drivers/block/ide.cif (dev->mult_count) {
dev1061drivers/block/ide.cmultwrite(dev);
dev1064drivers/block/ide.coutput_ide_data(dev, rq->buffer, SECTOR_WORDS);
dev1074drivers/block/ide.cide_cmd(dev, args[0], args[1], &drive_cmd_intr);
dev1076drivers/block/ide.cdev->name, args[0], args[1], args[2]);
dev1080drivers/block/ide.cprintk("%s: DRIVE_CMD (null)\n", dev->name);
dev1082drivers/block/ide.cend_drive_cmd(dev,GET_STAT(DEV_HWIF),GET_ERR(DEV_HWIF));
dev1087drivers/block/ide.cprintk("%s: bad command: %d\n", dev->name, rq->cmd);
dev1109drivers/block/ide.cide_dev_t *dev;
dev1117drivers/block/ide.cif ((rq == NULL) || (rq->dev < 0)) {
dev1120drivers/block/ide.cif (sharing_single_irq && (dev = ide_cur_dev[hwif])) /* disable irq */
dev1121drivers/block/ide.cOUT_BYTE(dev->ctl|2,HD_CMD);
dev1123drivers/block/ide.cif ((rq != NULL) && (rq->dev >= 0))
dev1135drivers/block/ide.cminor = MINOR(rq->dev);
dev1137drivers/block/ide.cide_cur_dev[HWIF] = dev = &ide_dev[HWIF][drive];
dev1138drivers/block/ide.cif ((MAJOR(rq->dev) != ide_major[HWIF]) || (drive >= MAX_DRIVES)) {
dev1139drivers/block/ide.cprintk("%s: bad device number: 0x%04x\n", ide_name[HWIF], rq->dev);
dev1152drivers/block/ide.cdev->name, block, rq->nr_sectors);
dev1160drivers/block/ide.cOUT_BYTE(dev->select.all,HD_CURRENT);
dev1162drivers/block/ide.cWAIT_STAT(dev, (dev->type == cdrom) ? 0 : READY_STAT,
dev1165drivers/block/ide.cWAIT_STAT(dev, READY_STAT, BUSY_STAT|DRQ_STAT, WAIT_READY, "DRDY", repeat);
dev1167drivers/block/ide.cif (!dev->special.all) {
dev1169drivers/block/ide.cif (dev->type == disk) {
dev1171drivers/block/ide.cif (do_rw_disk(dev, rq, block))
dev1175drivers/block/ide.cif (do_rw_cdrom(dev, block))
dev1180drivers/block/ide.cif (do_special(dev))
dev1263drivers/block/ide.cide_dev_t *dev;          \
dev1269drivers/block/ide.cdev = ide_cur_dev[hwif];    \
dev1270drivers/block/ide.cif (dev->unmask)      \
dev1272drivers/block/ide.chandler(dev);        \
dev1333drivers/block/ide.cide_dev_t *dev;
dev1337drivers/block/ide.ccase IDE0_MAJOR:  dev = &ide_dev[0][drive];
dev1338drivers/block/ide.cif (dev->present) return dev;
dev1340drivers/block/ide.ccase IDE1_MAJOR:  dev = &ide_dev[1][drive];
dev1341drivers/block/ide.cif (dev->present) return dev;
dev1350drivers/block/ide.cide_dev_t *dev;
dev1353drivers/block/ide.cif ((dev = get_info_ptr(inode->i_rdev)) == NULL)
dev1357drivers/block/ide.cwhile (dev->busy)
dev1358drivers/block/ide.csleep_on(&dev->wqueue);
dev1359drivers/block/ide.cdev->usage++;
dev1361drivers/block/ide.cif (dev->id && (dev->id->config & (1<<7)))  /* for removeable disks */
dev1364drivers/block/ide.cif (dev->type == cdrom)
dev1365drivers/block/ide.creturn cdrom_open (inode, filp, dev);
dev1376drivers/block/ide.cide_dev_t *dev;
dev1378drivers/block/ide.cif ((dev = get_info_ptr(inode->i_rdev)) != NULL) {
dev1380drivers/block/ide.cdev->usage--;
dev1382drivers/block/ide.cif (dev->type == cdrom)
dev1383drivers/block/ide.ccdrom_release (inode, file, dev);
dev1399drivers/block/ide.cide_dev_t *dev;
dev1403drivers/block/ide.cif ((dev = get_info_ptr(i_rdev)) == NULL)
dev1408drivers/block/ide.cif (dev->busy || (dev->usage > 1)) {
dev1412drivers/block/ide.cdev->busy = 1;
dev1431drivers/block/ide.cdev->busy = 0;
dev1432drivers/block/ide.cwake_up(&dev->wqueue);
dev1443drivers/block/ide.cstatic int do_drive_cmd(int dev, char *args)
dev1446drivers/block/ide.cunsigned int major = MAJOR(dev);
dev1462drivers/block/ide.crq.dev = dev;
dev1500drivers/block/ide.cide_dev_t *dev;
dev1505drivers/block/ide.cif ((dev = get_info_ptr(inode->i_rdev)) == NULL)
dev1509drivers/block/ide.cif (!loc || dev->type != disk) return -EINVAL;
dev1512drivers/block/ide.cput_user(dev->bios_head,
dev1514drivers/block/ide.cput_user(dev->bios_sect,
dev1516drivers/block/ide.cput_user(dev->bios_cyl,
dev1543drivers/block/ide.creturn write_fs_long(arg, dev->keep_settings);
dev1546drivers/block/ide.creturn write_fs_long(arg, dev->unmask);
dev1549drivers/block/ide.creturn write_fs_long(arg, dev->chipset);
dev1552drivers/block/ide.creturn write_fs_long(arg, dev->mult_count);
dev1557drivers/block/ide.cif (dev->id == NULL)
dev1559drivers/block/ide.cerr = verify_area(VERIFY_WRITE, (char *)arg, sizeof(*dev->id));
dev1561drivers/block/ide.cmemcpy_tofs((char *)arg, (char *)dev->id, sizeof(*dev->id));
dev1565drivers/block/ide.creturn write_fs_long(arg, dev->bad_wstat == BAD_R_STAT);
dev1578drivers/block/ide.cdev->keep_settings = arg;
dev1581drivers/block/ide.cdev->unmask = arg;
dev1584drivers/block/ide.cdev->bad_wstat = arg ? BAD_R_STAT : BAD_W_STAT;
dev1587drivers/block/ide.cdev->chipset   = arg;
dev1588drivers/block/ide.cdev->vlb_sync  = (arg & 2) >> 1;
dev1589drivers/block/ide.cdev->vlb_32bit = (arg & 1);
dev1599drivers/block/ide.cif ((dev->id != NULL) && (arg > dev->id->max_multsect))
dev1603drivers/block/ide.cif (dev->special.b.set_multmode) {
dev1607drivers/block/ide.cdev->mult_req = arg;
dev1608drivers/block/ide.cdev->special.b.set_multmode = 1;
dev1614drivers/block/ide.creturn (dev->mult_count == arg) ? 0 : -EIO;
dev1640drivers/block/ide.cif (dev->type == cdrom)
dev1641drivers/block/ide.creturn ide_cdrom_ioctl(dev, inode, file, cmd, arg);
dev1649drivers/block/ide.cide_dev_t *dev;
dev1651drivers/block/ide.cif ((dev = get_info_ptr(full_dev)) == NULL)
dev1654drivers/block/ide.cif (dev->type == cdrom)
dev1655drivers/block/ide.creturn cdrom_check_media_change (dev);
dev1657drivers/block/ide.cif (dev->id && (dev->id->config & (1<<7))) /* for removeable disks */
dev1716drivers/block/ide.cstatic void do_identify (ide_dev_t *dev, byte cmd)
dev1722drivers/block/ide.cid = dev->id = (struct hd_driveid *) probe_mem_start; /* kmalloc() */
dev1724drivers/block/ide.cinput_ide_data(dev, id, SECTOR_WORDS);  /* read 512 bytes of id info */
dev1732drivers/block/ide.cprintk("%s: EATA SCSI HBA %.10s\n", dev->name, id->model);
dev1733drivers/block/ide.cdev->present = 0;
dev1758drivers/block/ide.cprintk("%s: %s, ATAPI,", dev->name, id->model);
dev1764drivers/block/ide.cdev->type = cdrom;  /* until we do it "correctly" above */
dev1765drivers/block/ide.cdev->present = 1;
dev1772drivers/block/ide.cdev->type = disk;
dev1774drivers/block/ide.cif (!dev->present) {
dev1775drivers/block/ide.cdev->present = 1;
dev1776drivers/block/ide.cdev->cyl     = dev->bios_cyl  = id->cyls;
dev1777drivers/block/ide.cdev->head    = dev->bios_head = id->heads;
dev1778drivers/block/ide.cdev->sect    = dev->bios_sect = id->sectors; 
dev1794drivers/block/ide.cdev->cyl  = id->cur_cyls;
dev1795drivers/block/ide.cdev->head = id->cur_heads;
dev1796drivers/block/ide.cdev->sect = id->cur_sectors;
dev1797drivers/block/ide.ccapacity  = dev->cyl * dev->head * dev->sect;
dev1808drivers/block/ide.cif ((!dev->head || dev->head > 16) && id->heads && id->heads <= 16) {
dev1809drivers/block/ide.cdev->cyl  = id->cyls;
dev1810drivers/block/ide.cdev->head = id->heads;
dev1811drivers/block/ide.cdev->sect = id->sectors; 
dev1814drivers/block/ide.cif (dev->sect == dev->bios_sect && dev->head == dev->bios_head) {
dev1815drivers/block/ide.cif (dev->cyl > dev->bios_cyl)
dev1816drivers/block/ide.cdev->bios_cyl = dev->cyl;
dev1820drivers/block/ide.cdev->select.b.lba = 1;
dev1823drivers/block/ide.ccapacity = dev->cyl * dev->head * dev->sect;
dev1826drivers/block/ide.cide_capacity[DEV_HWIF][dev->select.b.drive] = capacity;
dev1828drivers/block/ide.cdev->name, id->model, capacity/2048L, id->buf_size/2,
dev1829drivers/block/ide.cdev->select.b.lba ? "LBA, " : "",
dev1830drivers/block/ide.cdev->bios_cyl, dev->bios_head, dev->bios_sect);
dev1832drivers/block/ide.cdev->mult_count = 0;
dev1834drivers/block/ide.cdev->mult_req = INITIAL_MULT_COUNT;
dev1835drivers/block/ide.cif (dev->mult_req > id->max_multsect)
dev1836drivers/block/ide.cdev->mult_req = id->max_multsect;
dev1837drivers/block/ide.cif (dev->mult_req || ((id->multsect_valid & 1) && id->multsect)) {
dev1838drivers/block/ide.cdev->special.b.set_multmode = 1;
dev1839drivers/block/ide.cdev->be_quiet = 1;
dev1857drivers/block/ide.cstatic int try_to_identify (ide_dev_t *dev, byte cmd)
dev1871drivers/block/ide.cOUT_BYTE(dev->ctl|2,HD_CMD);    /* disable device irq */
dev1876drivers/block/ide.cOUT_BYTE(dev->ctl,HD_CMD);  /* enable device irq */
dev1882drivers/block/ide.cprintk("%s: probing with STATUS instead of ALTSTATUS\n", dev->name);
dev1901drivers/block/ide.cdo_identify(dev, cmd);  /* drive returned ID */
dev1912drivers/block/ide.cprintk("%s: IRQ probe failed (%d)\n", dev->name, irqs);
dev1928drivers/block/ide.cstatic int do_probe (ide_dev_t *dev, byte cmd)
dev1940drivers/block/ide.cif (dev->present) {  /* avoid waiting for inappropriate probes */
dev1941drivers/block/ide.cif ((dev->type == disk) ^ (cmd == WIN_IDENTIFY))
dev1947drivers/block/ide.cdev->name, dev->present, dev->type ? "cdrom":"disk",
dev1950drivers/block/ide.cOUT_BYTE(dev->select.all,HD_CURRENT);  /* select target drive */
dev1952drivers/block/ide.cif (IN_BYTE(HD_CURRENT,DEV_HWIF) != dev->select.all && !dev->present) {
dev1958drivers/block/ide.c|| dev->present || cmd == WIN_PIDENTIFY)
dev1960drivers/block/ide.cif ((rc = try_to_identify(dev, cmd)))  /* send cmd and wait */
dev1961drivers/block/ide.crc = try_to_identify(dev, cmd);  /* failed: try again */
dev1964drivers/block/ide.cdev->name, GET_STAT(DEV_HWIF));
dev1965drivers/block/ide.cOUT_BYTE(dev->ctl|2,HD_CMD);  /* disable device irq */
dev1971drivers/block/ide.cif (dev->select.b.drive == 1) {
dev1974drivers/block/ide.cOUT_BYTE(dev->ctl|2,HD_CMD);  /* disable device irq */
dev1981drivers/block/ide.cstatic byte probe_for_drive (ide_dev_t *dev)
dev1987drivers/block/ide.cif (dev->noprobe)      /* skip probing? */
dev1988drivers/block/ide.creturn dev->present;
dev1989drivers/block/ide.cif (do_probe(dev, WIN_IDENTIFY) >= 2) {  /* if !(success || timed-out) */
dev1991drivers/block/ide.c(void) do_probe(dev, WIN_PIDENTIFY); /* look for ATAPI device */
dev1994drivers/block/ide.cif (!dev->present)
dev1996drivers/block/ide.cif (dev->id == NULL) {      /* identification failed? */
dev1997drivers/block/ide.cif (dev->type == disk) {
dev1999drivers/block/ide.cdev->name, dev->cyl, dev->head, dev->sect);
dev2002drivers/block/ide.celse if (dev->type == cdrom) {
dev2003drivers/block/ide.cprintk("%s: ATAPI cdrom (?)\n", dev->name);
dev2007drivers/block/ide.cdev->present = 0;  /* nuke it */
dev2012drivers/block/ide.cif (dev->type == cdrom)
dev2013drivers/block/ide.ccdrom_setup(dev);
dev2015drivers/block/ide.cif (dev->type == disk && !dev->select.b.lba) {
dev2016drivers/block/ide.cif (!dev->head || dev->head > 16) {
dev2018drivers/block/ide.cdev->name, dev->head);
dev2019drivers/block/ide.cdev->present = 0;
dev2060drivers/block/ide.cide_dev_t *dev;
dev2083drivers/block/ide.cdev = &ide_dev[hwif][drive];
dev2084drivers/block/ide.cif (dev->present)
dev2103drivers/block/ide.cdev->noprobe = 1;  /* don't probe for this drive */
dev2108drivers/block/ide.cdev->bad_wstat = BAD_R_STAT; /* ignore WRERR_STAT */
dev2114drivers/block/ide.cdev->present = 1;  /* force autoprobe to find it */
dev2115drivers/block/ide.cdev->type = cdrom;
dev2125drivers/block/ide.cdev->type    = disk;
dev2126drivers/block/ide.cdev->cyl     = dev->bios_cyl  = ints[1];
dev2127drivers/block/ide.cdev->head    = dev->bios_head = ints[2];
dev2128drivers/block/ide.cdev->ctl     = (ints[2] > 8 ? 8 : 0);
dev2129drivers/block/ide.cdev->sect    = dev->bios_sect = ints[3];
dev2130drivers/block/ide.cdev->wpcom   = (ints[0] >= 4) ? ints[4] : 0;
dev2133drivers/block/ide.cide_capacity[HWIF][drive] = BIOS_SECTORS(dev);
dev2134drivers/block/ide.cdev->present = 1;
dev2165drivers/block/ide.cide_dev_t *dev;
dev2167drivers/block/ide.cif ((dev = get_info_ptr(full_dev)) != NULL) {
dev2168drivers/block/ide.cdev->bios_cyl -= 1;    /* keeps fdisk sane */
dev2169drivers/block/ide.cwhile (dev->bios_cyl > 1024) {
dev2170drivers/block/ide.cif (dev->bios_head > 32)
dev2172drivers/block/ide.cdev->bios_head *= 2;
dev2173drivers/block/ide.cdev->bios_cyl  /= 2;
dev2201drivers/block/ide.cide_dev_t *dev = &ide_dev[0][drive];
dev2202drivers/block/ide.cif ((cmos_disks & (0xf0 >> (drive*4))) && !dev->present) {
dev2203drivers/block/ide.cdev->cyl     = dev->bios_cyl  = *(unsigned short *)BIOS;
dev2204drivers/block/ide.cdev->head    = dev->bios_head = * (BIOS+2);
dev2205drivers/block/ide.cdev->sect    = dev->bios_sect = * (BIOS+14);
dev2206drivers/block/ide.cdev->wpcom   = (*(unsigned short *)(BIOS+5))>>2;
dev2207drivers/block/ide.cdev->ctl     = *(BIOS+8);
dev2208drivers/block/ide.cdev->wpcom   = 0;
dev2209drivers/block/ide.cdev->type    = disk;
dev2210drivers/block/ide.cdev->present = 1;
dev2211drivers/block/ide.cide_capacity[0][drive] = BIOS_SECTORS(dev);
dev2229drivers/block/ide.cide_dev_t *dev = &ide_dev[hwif][drive];
dev2230drivers/block/ide.cdev->select.all      = (drive<<4)|0xa0;
dev2231drivers/block/ide.cdev->hwif      = hwif;
dev2232drivers/block/ide.cdev->unmask      = 0;
dev2233drivers/block/ide.cdev->busy      = 0;
dev2234drivers/block/ide.cdev->mult_count      = 0; /* set by do_identify() */
dev2235drivers/block/ide.cdev->mult_req      = 0; /* set by do_identify() */
dev2236drivers/block/ide.cdev->usage      = 0;
dev2237drivers/block/ide.cdev->vlb_32bit      = 0;
dev2238drivers/block/ide.cdev->vlb_sync      = 0;
dev2239drivers/block/ide.cdev->id        = NULL;
dev2240drivers/block/ide.cdev->ctl      = 0x08;
dev2241drivers/block/ide.cdev->wqueue      = NULL;
dev2242drivers/block/ide.cdev->special.all    = 0;
dev2243drivers/block/ide.cdev->special.b.recalibrate  = 1;
dev2244drivers/block/ide.cdev->special.b.set_geometry  = 1;
dev2245drivers/block/ide.cdev->keep_settings    = 0;
dev2247drivers/block/ide.cdev->name = ide_devname[hwif][drive];
dev2248drivers/block/ide.cif (!dev->bad_wstat)
dev2249drivers/block/ide.cdev->bad_wstat = BAD_W_STAT;
dev2300drivers/block/ide.cide_dev_t *dev = &ide_dev[HWIF][drive];
dev2301drivers/block/ide.cif (dev->present) {
dev2304drivers/block/ide.cif (dev->type == cdrom)
dev107drivers/block/ll_rw_blk.cstatic void plug_device(struct blk_dev_struct * dev, struct request * plug)
dev111drivers/block/ll_rw_blk.cplug->dev = -1;
dev116drivers/block/ll_rw_blk.cif (!dev->current_request)
dev117drivers/block/ll_rw_blk.cdev->current_request = plug;
dev124drivers/block/ll_rw_blk.cstatic void unplug_device(struct blk_dev_struct * dev)
dev131drivers/block/ll_rw_blk.creq = dev->current_request;
dev132drivers/block/ll_rw_blk.cif (req && req->dev == -1 && req->cmd == -1) {
dev133drivers/block/ll_rw_blk.cdev->current_request = req->next;
dev134drivers/block/ll_rw_blk.c(dev->request_fn)();
dev144drivers/block/ll_rw_blk.cstatic inline struct request * get_request(int n, int dev)
dev160drivers/block/ll_rw_blk.cif (req->dev < 0)
dev166drivers/block/ll_rw_blk.creq->dev = dev;
dev173drivers/block/ll_rw_blk.cstatic struct request * __get_request_wait(int n, int dev)
dev180drivers/block/ll_rw_blk.cunplug_device(MAJOR(dev)+blk_dev);
dev183drivers/block/ll_rw_blk.creq = get_request(n, dev);
dev194drivers/block/ll_rw_blk.cstatic inline struct request * get_request_wait(int n, int dev)
dev199drivers/block/ll_rw_blk.creq = get_request(n, dev);
dev203drivers/block/ll_rw_blk.creturn __get_request_wait(n, dev);
dev210drivers/block/ll_rw_blk.cint is_read_only(int dev)
dev214drivers/block/ll_rw_blk.cmajor = MAJOR(dev);
dev215drivers/block/ll_rw_blk.cminor = MINOR(dev);
dev220drivers/block/ll_rw_blk.cvoid set_device_ro(int dev,int flag)
dev224drivers/block/ll_rw_blk.cmajor = MAJOR(dev);
dev225drivers/block/ll_rw_blk.cminor = MINOR(dev);
dev236drivers/block/ll_rw_blk.cstatic void add_request(struct blk_dev_struct * dev, struct request * req)
dev241drivers/block/ll_rw_blk.cswitch (MAJOR(req->dev)) {
dev242drivers/block/ll_rw_blk.ccase SCSI_DISK_MAJOR:  disk_index = (MINOR(req->dev) & 0x0070) >> 4;
dev247drivers/block/ll_rw_blk.ccase XT_DISK_MAJOR:  disk_index = (MINOR(req->dev) & 0x0040) >> 6;
dev250drivers/block/ll_rw_blk.ccase IDE1_MAJOR:  disk_index = ((MINOR(req->dev) & 0x0040) >> 6) + 2;
dev259drivers/block/ll_rw_blk.cif (!(tmp = dev->current_request)) {
dev260drivers/block/ll_rw_blk.cdev->current_request = req;
dev261drivers/block/ll_rw_blk.c(dev->request_fn)();
dev275drivers/block/ll_rw_blk.cif (scsi_major(MAJOR(req->dev)))
dev276drivers/block/ll_rw_blk.c(dev->request_fn)();
dev347drivers/block/ll_rw_blk.cif (req->dev == bh->b_dev &&
dev361drivers/block/ll_rw_blk.cif (req->dev == bh->b_dev &&
dev409drivers/block/ll_rw_blk.cvoid ll_rw_page(int rw, int dev, unsigned long page, char * buffer)
dev412drivers/block/ll_rw_blk.cunsigned int major = MAJOR(dev);
dev417drivers/block/ll_rw_blk.cprintk("Trying to read nonexistent block-device %04x (%ld)\n",dev,sector);
dev422drivers/block/ll_rw_blk.cif (rw == WRITE && is_read_only(dev)) {
dev423drivers/block/ll_rw_blk.cprintk("Can't page to read-only device 0x%X\n",dev);
dev426drivers/block/ll_rw_blk.creq = get_request_wait(NR_REQUEST, dev);
dev450drivers/block/ll_rw_blk.cstruct blk_dev_struct * dev;
dev460drivers/block/ll_rw_blk.cdev = NULL;
dev462drivers/block/ll_rw_blk.cdev = blk_dev + major;
dev463drivers/block/ll_rw_blk.cif (!dev || !dev->request_fn) {
dev499drivers/block/ll_rw_blk.cplug_device(dev, &plug);
dev510drivers/block/ll_rw_blk.cunplug_device(dev);
dev521drivers/block/ll_rw_blk.cvoid ll_rw_swap_file(int rw, int dev, unsigned int *b, int nb, char *buf)
dev526drivers/block/ll_rw_blk.cunsigned int major = MAJOR(dev);
dev538drivers/block/ll_rw_blk.cif (rw == WRITE && is_read_only(dev)) {
dev539drivers/block/ll_rw_blk.cprintk("Can't swap to read-only device 0x%X\n",dev);
dev550drivers/block/ll_rw_blk.creq[j] = get_request_wait(NR_REQUEST, dev);
dev553drivers/block/ll_rw_blk.creq[j] = get_request(NR_REQUEST, dev);
dev582drivers/block/ll_rw_blk.creq->dev = -1;
dev142drivers/block/mcd.c(CURRENT && MAJOR(CURRENT -> dev) == MAJOR_NR && CURRENT -> cmd == READ \
dev458drivers/block/mcdx.cint dev;
dev465drivers/block/mcdx.cif ((CURRENT == NULL) || (CURRENT->dev < 0))  {
dev470drivers/block/mcdx.cstuffp = mcdx_stuffp[MINOR(CURRENT->dev)];
dev474drivers/block/mcdx.cdev = MINOR(CURRENT->dev);
dev476drivers/block/mcdx.cif ((dev < 0) || (dev >= MCDX_NDRIVES) || (!stuffp->present)) {
dev477drivers/block/mcdx.cprintk(MCD "do_request(): bad device: 0x%04x\n", CURRENT->dev);
dev43drivers/block/ramdisk.cif ((MINOR(CURRENT->dev) != RAMDISK_MINOR) ||
dev4374drivers/block/sbpcd.cif ((CURRENT==NULL)||(CURRENT->dev<0)) goto err_done;
dev4381drivers/block/sbpcd.ci = MINOR(CURRENT->dev);
dev4384drivers/block/sbpcd.cmsg(DBG_INF, "do_request: bad device: %04X\n", CURRENT->dev);
dev911drivers/block/sjcd.c( CURRENT != NULL && MAJOR( CURRENT->dev ) == MAJOR_NR && \
dev817drivers/block/sonycd535.cunsigned int dev;
dev835drivers/block/sonycd535.cif (!(CURRENT) || CURRENT->dev < 0) {
dev839drivers/block/sonycd535.cdev = MINOR(CURRENT->dev);
dev842drivers/block/sonycd535.cif (dev != 0) {
dev1113drivers/block/sonycd535.cunsigned int dev;
dev1123drivers/block/sonycd535.cdev = MINOR(inode->i_rdev) >> 6;
dev1124drivers/block/sonycd535.cif (dev != 0) {
dev195drivers/block/xd.cint dev = DEVICE_NR(MINOR(inode->i_rdev));
dev197drivers/block/xd.cif (dev < xd_drives) {
dev198drivers/block/xd.cwhile (!xd_valid[dev])
dev201drivers/block/xd.cxd_access[dev]++;
dev219drivers/block/xd.cif (CURRENT_DEV < xd_drives && CURRENT->sector + CURRENT->nr_sectors <= xd[MINOR(CURRENT->dev)].nr_sects) {
dev220drivers/block/xd.cblock = CURRENT->sector + xd[MINOR(CURRENT->dev)].start_sect;
dev241drivers/block/xd.cint dev = DEVICE_NR(MINOR(inode->i_rdev)),err;
dev243drivers/block/xd.cif (inode && (dev < xd_drives))
dev249drivers/block/xd.cput_user(xd_info[dev].heads, &geometry->heads);
dev250drivers/block/xd.cput_user(xd_info[dev].sectors, &geometry->sectors);
dev251drivers/block/xd.cput_user(xd_info[dev].cylinders, &geometry->cylinders);
dev289drivers/block/xd.cint dev = DEVICE_NR(MINOR(inode->i_rdev));
dev291drivers/block/xd.cif (dev < xd_drives) {
dev292drivers/block/xd.csync_dev(dev);
dev293drivers/block/xd.cxd_access[dev]--;
dev298drivers/block/xd.cstatic int xd_reread_partitions(int dev)
dev300drivers/block/xd.cint target = DEVICE_NR(MINOR(dev)),start = target << xd_gendisk.minor_shift,partition;
dev1921drivers/char/tpqic02.cdev_t dev = inode->i_rdev;
dev1934drivers/char/tpqic02.cMINOR(dev), buf, count, (unsigned long) filp->f_pos, flags);
dev2096drivers/char/tpqic02.cdev_t dev = inode->i_rdev;
dev2108drivers/char/tpqic02.cMINOR(dev), buf, count, (unsigned long) filp->f_pos, flags);
dev2247drivers/char/tpqic02.cdev_t dev = inode->i_rdev;
dev2253drivers/char/tpqic02.cif (TP_DIAGS(dev)) {
dev2254drivers/char/tpqic02.cprintk("qic02_tape_open: dev=%x, flags=%x     ", dev, flags);
dev2257drivers/char/tpqic02.cif (MINOR(dev)==255)  /* special case for resetting */
dev2333drivers/char/tpqic02.cif ((TP_DENS(dev)!=0) && (TP_DENS(current_tape_dev) != TP_DENS(dev))) {
dev2346drivers/char/tpqic02.ccurrent_tape_dev = dev;
dev2382drivers/char/tpqic02.cif (TP_DENS(current_tape_dev) == TP_DENS(dev) )
dev2385drivers/char/tpqic02.ccurrent_tape_dev = dev;
dev2388drivers/char/tpqic02.cdens = TP_DENS(dev);
dev2395drivers/char/tpqic02.cswitch (TP_DENS(dev)) {
dev2440drivers/char/tpqic02.cdev_t dev = inode->i_rdev;
dev2442drivers/char/tpqic02.cif (TP_DIAGS(dev))
dev2443drivers/char/tpqic02.cprintk("qic02_tape_release: dev=%x\n", dev);
dev2459drivers/char/tpqic02.cif ((TP_REWCLOSE(dev)) && (status_bytes_rd | status_bytes_wr)) {
dev120drivers/net/3c501.cint el1_probe(struct device *dev);
dev121drivers/net/3c501.cstatic int  el1_probe1(struct device *dev, int ioaddr);
dev122drivers/net/3c501.cstatic int  el_open(struct device *dev);
dev123drivers/net/3c501.cstatic int  el_start_xmit(struct sk_buff *skb, struct device *dev);
dev125drivers/net/3c501.cstatic void el_receive(struct device *dev);
dev126drivers/net/3c501.cstatic void el_reset(struct device *dev);
dev127drivers/net/3c501.cstatic int  el1_close(struct device *dev);
dev128drivers/net/3c501.cstatic struct enet_statistics *el1_get_stats(struct device *dev);
dev129drivers/net/3c501.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev198drivers/net/3c501.cel1_probe(struct device *dev)
dev201drivers/net/3c501.cint base_addr = dev ? dev->base_addr : 0;
dev204drivers/net/3c501.creturn el1_probe1(dev, base_addr);
dev212drivers/net/3c501.cif (el1_probe1(dev, ioaddr) == 0)
dev222drivers/net/3c501.cel1_probe1(struct device *dev, int ioaddr)
dev252drivers/net/3c501.cif (dev->irq < 2) {
dev273drivers/net/3c501.cdev->base_addr = ioaddr;
dev274drivers/net/3c501.cmemcpy(dev->dev_addr, station_addr, ETH_ALEN);
dev275drivers/net/3c501.cif (dev->mem_start & 0xf)
dev276drivers/net/3c501.cel_debug = dev->mem_start & 0x7;
dev278drivers/net/3c501.cdev->irq = autoirq;
dev281drivers/net/3c501.cdev->name, mname, dev->base_addr,
dev282drivers/net/3c501.cautoirq ? "auto":"assigned ", dev->irq);
dev292drivers/net/3c501.cif (dev->priv == NULL)
dev293drivers/net/3c501.cdev->priv = kmalloc(sizeof(struct net_local), GFP_KERNEL);
dev294drivers/net/3c501.cmemset(dev->priv, 0, sizeof(struct net_local));
dev297drivers/net/3c501.cdev->open = &el_open;
dev298drivers/net/3c501.cdev->hard_start_xmit = &el_start_xmit;
dev299drivers/net/3c501.cdev->stop = &el1_close;
dev300drivers/net/3c501.cdev->get_stats = &el1_get_stats;
dev301drivers/net/3c501.cdev->set_multicast_list = &set_multicast_list;
dev303drivers/net/3c501.cether_setup(dev);
dev311drivers/net/3c501.cel_open(struct device *dev)
dev313drivers/net/3c501.cint ioaddr = dev->base_addr;
dev316drivers/net/3c501.cprintk("%s: Doing el_open()...", dev->name);
dev318drivers/net/3c501.cif (request_irq(dev->irq, &el_interrupt, 0, "3c501")) {
dev321drivers/net/3c501.cirq2dev_map[dev->irq] = dev;
dev323drivers/net/3c501.cel_reset(dev);
dev325drivers/net/3c501.cdev->start = 1;
dev333drivers/net/3c501.cel_start_xmit(struct sk_buff *skb, struct device *dev)
dev335drivers/net/3c501.cstruct net_local *lp = (struct net_local *)dev->priv;
dev336drivers/net/3c501.cint ioaddr = dev->base_addr;
dev339drivers/net/3c501.cif (dev->tbusy) {
dev340drivers/net/3c501.cif (jiffies - dev->trans_start < 20) {
dev347drivers/net/3c501.cdev->name, inb(TX_STATUS), inb(AX_STATUS), inb(RX_STATUS));
dev353drivers/net/3c501.cdev->tbusy = 0;
dev354drivers/net/3c501.cdev->trans_start = jiffies;
dev358drivers/net/3c501.cdev_tint(dev);
dev368drivers/net/3c501.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev371drivers/net/3c501.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev403drivers/net/3c501.cprintk("%s: burped during tx load.\n", dev->name);
dev407drivers/net/3c501.cdev->trans_start = jiffies;
dev422drivers/net/3c501.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev427drivers/net/3c501.cif (dev == NULL  ||  dev->irq != irq) {
dev432drivers/net/3c501.cioaddr = dev->base_addr;
dev433drivers/net/3c501.clp = (struct net_local *)dev->priv;
dev437drivers/net/3c501.cprintk("%s: el_interrupt() aux=%#02x", dev->name, axsr);
dev438drivers/net/3c501.cif (dev->interrupt)
dev439drivers/net/3c501.cprintk("%s: Reentering the interrupt driver!\n", dev->name);
dev440drivers/net/3c501.cdev->interrupt = 1;
dev444drivers/net/3c501.cif (dev->tbusy) {
dev462drivers/net/3c501.c" gp=%03x rp=%03x.\n", dev->name, txsr, axsr,
dev464drivers/net/3c501.cdev->tbusy = 0;
dev472drivers/net/3c501.cdev->name);
dev485drivers/net/3c501.cdev->interrupt = 0;
dev498drivers/net/3c501.cdev->tbusy = 0;
dev524drivers/net/3c501.cel_receive(dev);
dev528drivers/net/3c501.cdev->name, rxsr);
dev529drivers/net/3c501.cel_reset(dev);
dev542drivers/net/3c501.cdev->interrupt = 0;
dev550drivers/net/3c501.cel_receive(struct device *dev)
dev552drivers/net/3c501.cstruct net_local *lp = (struct net_local *)dev->priv;
dev553drivers/net/3c501.cint ioaddr = dev->base_addr;
dev564drivers/net/3c501.cprintk("%s: bogus packet, length=%d\n", dev->name, pkt_len);
dev581drivers/net/3c501.cprintk("%s: Memory squeeze, dropping packet.\n", dev->name);
dev586drivers/net/3c501.cskb->dev = dev;
dev595drivers/net/3c501.cskb->protocol=eth_type_trans(skb,dev);
dev603drivers/net/3c501.cel_reset(struct device *dev)
dev605drivers/net/3c501.cint ioaddr = dev->base_addr;
dev614drivers/net/3c501.coutb(dev->dev_addr[i], ioaddr + i);
dev623drivers/net/3c501.cdev->interrupt = 0;
dev624drivers/net/3c501.cdev->tbusy = 0;
dev629drivers/net/3c501.cel1_close(struct device *dev)
dev631drivers/net/3c501.cint ioaddr = dev->base_addr;
dev634drivers/net/3c501.cprintk("%s: Shutting down ethercard at %#x.\n", dev->name, ioaddr);
dev636drivers/net/3c501.cdev->tbusy = 1;
dev637drivers/net/3c501.cdev->start = 0;
dev640drivers/net/3c501.cfree_irq(dev->irq);
dev642drivers/net/3c501.cirq2dev_map[dev->irq] = 0;
dev649drivers/net/3c501.cel1_get_stats(struct device *dev)
dev651drivers/net/3c501.cstruct net_local *lp = (struct net_local *)dev->priv;
dev662drivers/net/3c501.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev664drivers/net/3c501.cint ioaddr = dev->base_addr;
dev41drivers/net/3c503.cextern struct device *init_etherdev(struct device *dev, int sizeof_private,
dev44drivers/net/3c503.cint el2_probe(struct device *dev);
dev45drivers/net/3c503.cint el2_pio_probe(struct device *dev);
dev46drivers/net/3c503.cint el2_probe1(struct device *dev, int ioaddr);
dev63drivers/net/3c503.cstatic int el2_open(struct device *dev);
dev64drivers/net/3c503.cstatic int el2_close(struct device *dev);
dev65drivers/net/3c503.cstatic void el2_reset_8390(struct device *dev);
dev66drivers/net/3c503.cstatic void el2_init_card(struct device *dev);
dev67drivers/net/3c503.cstatic void el2_block_output(struct device *dev, int count,
dev69drivers/net/3c503.cstatic int el2_block_input(struct device *dev, int count, char *buf,
dev81drivers/net/3c503.cel2_probe(struct device *dev)
dev84drivers/net/3c503.cint base_addr = dev->base_addr;
dev87drivers/net/3c503.creturn el2_probe1(dev, base_addr);
dev102drivers/net/3c503.cif (el2_probe1(dev, netcard_portlist[i]) == 0)
dev106drivers/net/3c503.creturn el2_pio_probe(dev);
dev116drivers/net/3c503.cel2_pio_probe(struct device *dev)
dev119drivers/net/3c503.cint base_addr = dev ? dev->base_addr : 0;
dev122drivers/net/3c503.creturn el2_probe1(dev, base_addr);
dev130drivers/net/3c503.cif (el2_probe1(dev, ioaddr) == 0)
dev142drivers/net/3c503.cel2_probe1(struct device *dev, int ioaddr)
dev177drivers/net/3c503.cif (dev == NULL)
dev178drivers/net/3c503.cdev = init_etherdev(0, sizeof(struct ei_device), 0);
dev183drivers/net/3c503.cdev->base_addr = ioaddr;
dev184drivers/net/3c503.cethdev_init(dev);
dev186drivers/net/3c503.cprintk("%s: 3c503 at %#3x,", dev->name, ioaddr);
dev190drivers/net/3c503.cprintk(" %2.2x", dev->dev_addr[i] = inb(ioaddr + i));
dev206drivers/net/3c503.cei_status.interface_num = dev->mem_end & 0xf;
dev210drivers/net/3c503.cdev->mem_start = 0;
dev212drivers/net/3c503.cdev->mem_start = ((membase_reg & 0xc0) ? 0xD8000 : 0xC8000) +
dev219drivers/net/3c503.cint *mem_base = (int *)dev->mem_start;
dev227drivers/net/3c503.cdev->mem_start = 0;
dev238drivers/net/3c503.cdev->mem_end = dev->rmem_end = dev->mem_start + EL2_MEMSIZE;
dev239drivers/net/3c503.cdev->rmem_start = TX_PAGES*256 + dev->mem_start;
dev251drivers/net/3c503.cif (dev->irq == 2)
dev252drivers/net/3c503.cdev->irq = 9;
dev253drivers/net/3c503.celse if (dev->irq > 5 && dev->irq != 9) {
dev255drivers/net/3c503.cdev->irq);
dev256drivers/net/3c503.cdev->irq = 0;
dev259drivers/net/3c503.cei_status.saved_irq = dev->irq;
dev261drivers/net/3c503.cdev->start = 0;
dev262drivers/net/3c503.cdev->open = &el2_open;
dev263drivers/net/3c503.cdev->stop = &el2_close;
dev265drivers/net/3c503.cif (dev->mem_start)
dev267drivers/net/3c503.cdev->name, ei_status.name, dev->mem_start, dev->mem_end-1);
dev270drivers/net/3c503.cdev->name, ei_status.name);
dev279drivers/net/3c503.cel2_open(struct device *dev)
dev282drivers/net/3c503.cif (dev->irq < 2) {
dev294drivers/net/3c503.c&& request_irq (dev->irq = *irqp, &ei_interrupt, 0, "3c503") == 0)
dev303drivers/net/3c503.cif (request_irq(dev->irq, &ei_interrupt, 0, "3c503")) {
dev307drivers/net/3c503.cel2_init_card(dev);
dev308drivers/net/3c503.creturn ei_open(dev);
dev312drivers/net/3c503.cel2_close(struct device *dev)
dev314drivers/net/3c503.cfree_irq(dev->irq);
dev315drivers/net/3c503.cdev->irq = ei_status.saved_irq;
dev316drivers/net/3c503.cirq2dev_map[dev->irq] = NULL;
dev319drivers/net/3c503.cNS8390_init(dev, 0);
dev320drivers/net/3c503.cdev->start = 0;
dev330drivers/net/3c503.cel2_reset_8390(struct device *dev)
dev333drivers/net/3c503.cprintk("%s: Resetting the 3c503 board...", dev->name);
dev340drivers/net/3c503.cel2_init_card(dev);
dev346drivers/net/3c503.cel2_init_card(struct device *dev)
dev361drivers/net/3c503.coutb_p(0x00,  dev->base_addr + EN0_IMR);
dev366drivers/net/3c503.coutb_p((0x04 << (dev->irq == 9 ? 2 : dev->irq)), E33G_IDCFR);
dev376drivers/net/3c503.cel2_block_output(struct device *dev, int count,
dev385drivers/net/3c503.cif (dev->mem_start) {  /* Shared memory transfer */
dev386drivers/net/3c503.cvoid *dest_addr = (void *)(dev->mem_start +
dev391drivers/net/3c503.cdev->name, (int) dest_addr);
dev409drivers/net/3c503.cdev->name, i, count, boguscount);
dev420drivers/net/3c503.cel2_block_input(struct device *dev, int count, char *buf, int ring_offset)
dev423drivers/net/3c503.cint end_of_ring = dev->rmem_end;
dev427drivers/net/3c503.cif (dev->mem_start) {  /* Use the shared memory. */
dev429drivers/net/3c503.cif (dev->mem_start + ring_offset + count > end_of_ring) {
dev431drivers/net/3c503.cint semi_count = end_of_ring - (dev->mem_start + ring_offset);
dev432drivers/net/3c503.cmemcpy(buf, (char *)dev->mem_start + ring_offset, semi_count);
dev434drivers/net/3c503.cmemcpy(buf + semi_count, (char *)dev->rmem_start, count);
dev435drivers/net/3c503.creturn dev->rmem_start + count;
dev437drivers/net/3c503.cmemcpy(buf, (char *)dev->mem_start + ring_offset, count);
dev453drivers/net/3c503.cdev->name, i, count, boguscount);
dev6drivers/net/3c503.h#define EL2H (dev->base_addr + 0x400)
dev7drivers/net/3c503.h#define EL2L (dev->base_addr)
dev263drivers/net/3c505.cadapter_reset (struct device * dev)
dev266drivers/net/3c505.cunsigned char orig_hcr=inb_control(dev->base_addr);
dev268drivers/net/3c505.celp_device * adapter=dev->priv;
dev270drivers/net/3c505.coutb_control(0,dev->base_addr);
dev272drivers/net/3c505.cif (inb_status(dev->base_addr)&ACRF) {
dev274drivers/net/3c505.cinb_command(dev->base_addr);
dev276drivers/net/3c505.cwhile ((jiffies<=timeout) && !(inb_status(dev->base_addr)&ACRF))
dev278drivers/net/3c505.c} while (inb_status(dev->base_addr)&ACRF);
dev279drivers/net/3c505.cset_hsf(dev->base_addr,HSF_PCB_NAK);
dev282drivers/net/3c505.coutb_control(inb_control(dev->base_addr)|ATTN|DIR,dev->base_addr);
dev286drivers/net/3c505.coutb_control(inb_control(dev->base_addr)&~ATTN,dev->base_addr);
dev290drivers/net/3c505.coutb_control(inb_control(dev->base_addr)|FLSH,dev->base_addr);
dev294drivers/net/3c505.coutb_control(inb_control(dev->base_addr)&~FLSH,dev->base_addr);
dev299drivers/net/3c505.coutb_control(orig_hcr, dev->base_addr);
dev300drivers/net/3c505.cif (!start_receive(dev, &adapter->tx_pcb))
dev301drivers/net/3c505.cprintk("%s: start receive command failed \n", dev->name);
dev320drivers/net/3c505.csend_pcb (struct device * dev, pcb_struct * pcb)
dev331drivers/net/3c505.cset_hsf(dev->base_addr,0); 
dev332drivers/net/3c505.cif ((cont = WAIT_HCRE(dev->base_addr,5))) {
dev335drivers/net/3c505.coutb_control(inb_control(dev->base_addr)&~DIR,dev->base_addr);
dev336drivers/net/3c505.coutb_command(pcb->command, dev->base_addr);
dev338drivers/net/3c505.ccont = WAIT_HCRE(dev->base_addr,5);
dev342drivers/net/3c505.coutb_command(pcb->length, dev->base_addr);
dev343drivers/net/3c505.ccont = WAIT_HCRE(dev->base_addr,5);
dev348drivers/net/3c505.coutb_command(pcb->data.raw[i], dev->base_addr);
dev349drivers/net/3c505.ccont = wait_fast_hcre(dev->base_addr,20000,__LINE__);
dev356drivers/net/3c505.cset_hsf(dev->base_addr,HSF_PCB_END);
dev357drivers/net/3c505.coutb_command(2+pcb->length, dev->base_addr);
dev361drivers/net/3c505.ci = GET_ASF(dev->base_addr);
dev371drivers/net/3c505.cprintk("%s: PCB send was NAKed\n", dev->name);
dev373drivers/net/3c505.cprintk("%s: timeout after sending PCB\n", dev->name);
dev376drivers/net/3c505.cprintk("%s: timeout in middle of sending PCB\n", dev->name);
dev378drivers/net/3c505.cadapter_reset(dev);
dev396drivers/net/3c505.creceive_pcb (struct device * dev, pcb_struct * pcb)
dev404drivers/net/3c505.cCHECK_NULL(dev);
dev406drivers/net/3c505.cset_hsf(dev->base_addr,0);
dev410drivers/net/3c505.cwhile (((stat = get_status(dev->base_addr))&ACRF) == 0 && jiffies < timeout)
dev417drivers/net/3c505.cpcb->command = inb_command(dev->base_addr);
dev421drivers/net/3c505.cwhile (((stat = get_status(dev->base_addr)) & ACRF) == 0 && jiffies < timeout)
dev427drivers/net/3c505.cpcb->length = inb_command(dev->base_addr);
dev431drivers/net/3c505.cadapter_reset(dev);
dev440drivers/net/3c505.cwhile (((stat = get_status(dev->base_addr))&ACRF) == 0 && j++ < 20000)
dev442drivers/net/3c505.cpcb->data.raw[i++] = inb_command(dev->base_addr);
dev458drivers/net/3c505.cprintk("%s: mangled PCB received\n", dev->name);
dev459drivers/net/3c505.cset_hsf(dev->base_addr,HSF_PCB_NAK);
dev463drivers/net/3c505.cset_hsf(dev->base_addr,HSF_PCB_ACK);
dev469drivers/net/3c505.cadapter_hard_reset (struct device * dev)
dev473drivers/net/3c505.cCHECK_NULL(dev);
dev477drivers/net/3c505.cdev->name);
dev481drivers/net/3c505.coutb_control(ATTN|FLSH, dev->base_addr);
dev492drivers/net/3c505.coutb_control(0, dev->base_addr);
dev504drivers/net/3c505.cif (GET_ASF(dev->base_addr) != ASF_PCB_END)
dev516drivers/net/3c505.cstart_receive (struct device * dev, pcb_struct * tx_pcb)
dev518drivers/net/3c505.cCHECK_NULL(dev);
dev522drivers/net/3c505.cprintk("%s: restarting receiver\n", dev->name);
dev529drivers/net/3c505.creturn send_pcb(dev, tx_pcb); 
dev542drivers/net/3c505.creceive_packet (struct device * dev, int len)
dev551drivers/net/3c505.cCHECK_NULL(dev);
dev552drivers/net/3c505.cadapter=dev->priv;
dev569drivers/net/3c505.coutb_control(inb_control(dev->base_addr)|DIR, dev->base_addr);
dev577drivers/net/3c505.cwhile ((inb_status(dev->base_addr)&HRDY) == 0 && timeout++ < 20000)
dev585drivers/net/3c505.cinw_data(dev->base_addr);
dev591drivers/net/3c505.cskb->dev = dev;
dev599drivers/net/3c505.cwhile ((inb_status(dev->base_addr)&HRDY) == 0 && timeout++ < 20000) 
dev609drivers/net/3c505.c*ptr = inw_data(dev->base_addr); 
dev614drivers/net/3c505.cskb->protocol=eth_type_trans(skb,dev);
dev618drivers/net/3c505.coutb_control(inb_control(dev->base_addr)&~DIR, dev->base_addr);
dev633drivers/net/3c505.cstruct device *dev;
dev642drivers/net/3c505.cdev = irq2dev_map[irq];
dev644drivers/net/3c505.cif (dev == NULL) {
dev649drivers/net/3c505.cadapter = (elp_device *) dev->priv;
dev653drivers/net/3c505.cif (dev->interrupt)
dev655drivers/net/3c505.cprintk("%s: Re-entering the interrupt handler.\n", dev->name);
dev656drivers/net/3c505.cdev->interrupt = 1;
dev667drivers/net/3c505.cwhile ((inb_status(dev->base_addr)&ACRF) != 0 && jiffies < timeout) {
dev669drivers/net/3c505.cif (receive_pcb(dev, &adapter->irx_pcb)) {
dev678drivers/net/3c505.cif (dev->start == 0)
dev682drivers/net/3c505.coutb_control(inb_control(dev->base_addr)|DIR,
dev683drivers/net/3c505.cdev->base_addr);
dev687drivers/net/3c505.cprintk("%s: interrupt - packet not received correctly\n", dev->name);
dev692drivers/net/3c505.cprintk("%s: interrupt - packet received of length %i (%i)\n", dev->name, len, dlen);
dev695drivers/net/3c505.creceive_packet(dev, dlen);
dev698drivers/net/3c505.cprintk("%s: packet received\n", dev->name);
dev700drivers/net/3c505.cif (dev->start && !start_receive(dev, &adapter->itx_pcb)) 
dev702drivers/net/3c505.cprintk("%s: interrupt - failed to send receive start PCB\n", dev->name);
dev704drivers/net/3c505.cprintk("%s: receive procedure complete\n", dev->name);
dev714drivers/net/3c505.cprintk("%s: interrupt - configure response received\n", dev->name);
dev723drivers/net/3c505.cprintk("%s: Adapter memory configuration %s.\n",dev->name,
dev733drivers/net/3c505.cprintk("%s: Multicast address list loading %s.\n",dev->name,
dev743drivers/net/3c505.cprintk("%s: Ethernet address setting %s.\n",dev->name,
dev759drivers/net/3c505.cprintk("%s: interrupt - statistics response received\n", dev->name);
dev767drivers/net/3c505.cprintk("%s: interrupt - packet sent\n", dev->name);
dev768drivers/net/3c505.cif (dev->start == 0)
dev773drivers/net/3c505.cdev->name, adapter->irx_pcb.data.xmit_resp.c_stat);
dev774drivers/net/3c505.cdev->tbusy = 0;
dev782drivers/net/3c505.cprintk("%s: unknown PCB received - %2.2x\n", dev->name, adapter->irx_pcb.command);
dev786drivers/net/3c505.cprintk("%s: failed to read PCB on interrupt\n", dev->name);
dev787drivers/net/3c505.cadapter_reset(dev);
dev794drivers/net/3c505.cdev->interrupt = 0;
dev805drivers/net/3c505.celp_open (struct device *dev)
dev809drivers/net/3c505.cCHECK_NULL(dev);
dev811drivers/net/3c505.cadapter = dev->priv;
dev814drivers/net/3c505.cprintk("%s: request to open device\n", dev->name);
dev820drivers/net/3c505.cprintk("%s: Opening a non-existent physical device\n", dev->name);
dev827drivers/net/3c505.coutb_control(0x00, dev->base_addr);
dev832drivers/net/3c505.cinb_command(dev->base_addr);
dev833drivers/net/3c505.cadapter_reset(dev);
dev838drivers/net/3c505.cdev->interrupt = 0;
dev843drivers/net/3c505.cdev->tbusy = 0;
dev848drivers/net/3c505.cirq2dev_map[dev->irq] = dev;
dev853drivers/net/3c505.cif (request_irq(dev->irq, &elp_interrupt, 0, "3c505")) {
dev854drivers/net/3c505.cirq2dev_map[dev->irq] = NULL;
dev861drivers/net/3c505.coutb_control(CMDE, dev->base_addr);
dev866drivers/net/3c505.cdev->start = 1;
dev872drivers/net/3c505.cprintk("%s: sending 3c505 memory configuration command\n", dev->name);
dev882drivers/net/3c505.cif (!send_pcb(dev, &adapter->tx_pcb))
dev883drivers/net/3c505.cprintk("%s: couldn't send memory configuration command\n", dev->name);
dev897drivers/net/3c505.cprintk("%s: sending 82586 configure command\n", dev->name);
dev902drivers/net/3c505.cif (!send_pcb(dev, &adapter->tx_pcb))
dev903drivers/net/3c505.cprintk("%s: couldn't send 82586 configure command\n", dev->name);
dev915drivers/net/3c505.cif (!start_receive(dev, &adapter->tx_pcb))
dev916drivers/net/3c505.cprintk("%s: start receive command failed \n", dev->name);
dev918drivers/net/3c505.cprintk("%s: start receive command sent\n", dev->name);
dev931drivers/net/3c505.csend_packet (struct device * dev, unsigned char * ptr, int len)
dev942drivers/net/3c505.cCHECK_NULL(dev);
dev945drivers/net/3c505.cadapter = dev->priv;
dev959drivers/net/3c505.cif (!send_pcb(dev, &adapter->tx_pcb)) {
dev968drivers/net/3c505.cwhile (((inb_status(dev->base_addr)&HRDY) == 0)
dev974drivers/net/3c505.cdev->name,filename,__LINE__, i, nlen/2);
dev978drivers/net/3c505.coutw_data(*(short *)ptr, dev->base_addr);
dev994drivers/net/3c505.celp_start_xmit (struct sk_buff *skb, struct device *dev)
dev996drivers/net/3c505.cCHECK_NULL(dev);
dev1002drivers/net/3c505.cdev_tint(dev);
dev1013drivers/net/3c505.cprintk("%s: request to send packet of length %d\n", dev->name, (int)skb->len);
dev1018drivers/net/3c505.cif (dev->tbusy) {
dev1019drivers/net/3c505.cint tickssofar = jiffies - dev->trans_start;
dev1023drivers/net/3c505.cprintk("%s: transmit timed out, not resetting adapter\n", dev->name);
dev1024drivers/net/3c505.cif (((stat=inb_status(dev->base_addr))&ACRF) != 0) 
dev1025drivers/net/3c505.cprintk("%s: hmmm...seemed to have missed an interrupt!\n", dev->name);
dev1026drivers/net/3c505.cprintk("%s: status %#02x\n", dev->name, stat);
dev1027drivers/net/3c505.cdev->trans_start = jiffies;
dev1028drivers/net/3c505.cdev->tbusy = 0;
dev1034drivers/net/3c505.cif (!send_packet(dev, skb->data, skb->len)) {
dev1035drivers/net/3c505.cprintk("%s: send packet PCB failed\n", dev->name);
dev1040drivers/net/3c505.cprintk("%s: packet of length %d sent\n", dev->name, (int)skb->len);
dev1046drivers/net/3c505.cdev->trans_start = jiffies;
dev1051drivers/net/3c505.cdev->tbusy = 1;
dev1068drivers/net/3c505.celp_get_stats (struct device *dev)
dev1070drivers/net/3c505.celp_device *adapter = (elp_device *) dev->priv;
dev1073drivers/net/3c505.cprintk("%s: request for stats\n", dev->name);
dev1077drivers/net/3c505.cif (!dev->start)
dev1084drivers/net/3c505.cif (!send_pcb(dev, &adapter->tx_pcb))
dev1085drivers/net/3c505.cprintk("%s: couldn't send get statistics command\n", dev->name);
dev1107drivers/net/3c505.celp_close (struct device *dev)
dev1111drivers/net/3c505.cCHECK_NULL(dev);
dev1112drivers/net/3c505.cadapter = dev->priv;
dev1116drivers/net/3c505.cprintk("%s: request to close device\n", dev->name);
dev1122drivers/net/3c505.c(void) elp_get_stats(dev);
dev1127drivers/net/3c505.coutb_control(0x00, dev->base_addr);
dev1132drivers/net/3c505.cdev->tbusy = 1;
dev1137drivers/net/3c505.cdev->start = 0;
dev1142drivers/net/3c505.cfree_irq(dev->irq);
dev1147drivers/net/3c505.cirq2dev_map[dev->irq] = 0;
dev1163drivers/net/3c505.celp_set_mc_list (struct device *dev, int num_addrs, void *addrs)
dev1165drivers/net/3c505.celp_device *adapter = (elp_device *) dev->priv;
dev1169drivers/net/3c505.cprintk("%s: request to set multicast list\n", dev->name);
dev1179drivers/net/3c505.cif (!send_pcb(dev, &adapter->tx_pcb))
dev1180drivers/net/3c505.cprintk("%s: couldn't send set_multicast command\n", dev->name);
dev1200drivers/net/3c505.cprintk("%s: sending 82586 configure command\n", dev->name);
dev1204drivers/net/3c505.cif (!send_pcb(dev, &adapter->tx_pcb))
dev1205drivers/net/3c505.cprintk("%s: couldn't send 82586 configure command\n", dev->name);
dev1222drivers/net/3c505.celp_init (struct device *dev)
dev1226drivers/net/3c505.cCHECK_NULL(dev);
dev1231drivers/net/3c505.cdev->open = elp_open;  /* local */
dev1232drivers/net/3c505.cdev->stop = elp_close;  /* local */
dev1233drivers/net/3c505.cdev->get_stats = elp_get_stats;  /* local */
dev1234drivers/net/3c505.cdev->hard_start_xmit = elp_start_xmit;  /* local */
dev1235drivers/net/3c505.cdev->set_multicast_list = elp_set_mc_list;  /* local */
dev1238drivers/net/3c505.cether_setup(dev);
dev1243drivers/net/3c505.cadapter = (elp_device *)(dev->priv = kmalloc(sizeof(elp_device), GFP_KERNEL));
dev1250drivers/net/3c505.cdev->mem_start = dev->mem_end = dev->rmem_end = dev->rmem_start = 0;
dev1260drivers/net/3c505.celp_sense (struct device * dev)
dev1263drivers/net/3c505.cint addr=dev->base_addr;
dev1264drivers/net/3c505.cchar *name=dev->name;
dev1319drivers/net/3c505.cadapter_hard_reset(dev);
dev1330drivers/net/3c505.celp_autodetect (struct device * dev)
dev1336drivers/net/3c505.cif (dev->base_addr != 0) { /* dev->base_addr == 0 ==> plain autodetect */
dev1337drivers/net/3c505.cif (elp_sense(dev) == 0)
dev1338drivers/net/3c505.creturn dev->base_addr;
dev1339drivers/net/3c505.c} else while ( (dev->base_addr=addr_list[idx++]) ) {
dev1340drivers/net/3c505.cif (elp_sense(dev) == 0)
dev1341drivers/net/3c505.creturn dev->base_addr;
dev1346drivers/net/3c505.cprintk(couldnot_msg, dev->name);
dev1358drivers/net/3c505.celplus_probe (struct device *dev)
dev1363drivers/net/3c505.cCHECK_NULL(dev);
dev1369drivers/net/3c505.cdev->base_addr = elp_autodetect(dev);
dev1370drivers/net/3c505.cif ( !(dev->base_addr) )
dev1377drivers/net/3c505.coutb_control(inb_control(dev->base_addr) | CMDE, dev->base_addr);
dev1386drivers/net/3c505.cif (!send_pcb   (dev, &adapter.tx_pcb) ||
dev1387drivers/net/3c505.c!receive_pcb(dev, &adapter.rx_pcb) ||
dev1390drivers/net/3c505.cprintk("%s: not responding to first PCB\n", dev->name);
dev1394drivers/net/3c505.cif (dev->irq) { /* Is there a preset IRQ? */
dev1395drivers/net/3c505.cif (dev->irq != autoirq_report(0)) {
dev1396drivers/net/3c505.cprintk("%s: Detected IRQ doesn't match user-defined one.\n",dev->name);
dev1401drivers/net/3c505.cdev->irq=autoirq_report(0);
dev1402drivers/net/3c505.cswitch (dev->irq) { /* Legal, sane? */
dev1404drivers/net/3c505.cprintk("%s: No IRQ reported by autoirq_report().\n",dev->name);
dev1405drivers/net/3c505.cprintk("%s: Check the jumpers of your 3c505 board.\n",dev->name);
dev1412drivers/net/3c505.cdev->name, dev->irq);
dev1419drivers/net/3c505.coutb_control(inb_control(dev->base_addr) & ~CMDE, dev->base_addr);
dev1425drivers/net/3c505.cdev->dev_addr[i] = adapter.rx_pcb.data.eth_addr[i];
dev1432drivers/net/3c505.cdev->name, dev->base_addr, dev->irq,
dev1433drivers/net/3c505.cdev->dev_addr[0], dev->dev_addr[1], dev->dev_addr[2],
dev1434drivers/net/3c505.cdev->dev_addr[3], dev->dev_addr[4], dev->dev_addr[5]);
dev1439drivers/net/3c505.crequest_region(dev->base_addr,16,"3c505");
dev1444drivers/net/3c505.celp_init(dev);
dev62drivers/net/3c507.cextern struct device *init_etherdev(struct device *dev, int sizeof_private,
dev164drivers/net/3c507.c#define SCB_BASE    ((unsigned)64*1024 - (dev->mem_end - dev->mem_start))
dev199drivers/net/3c507.c#define RX_BUF_END    (dev->mem_end - dev->mem_start)
dev280drivers/net/3c507.cextern int el16_probe(struct device *dev);  /* Called from Space.c */
dev282drivers/net/3c507.cstatic int  el16_probe1(struct device *dev, int ioaddr);
dev283drivers/net/3c507.cstatic int  el16_open(struct device *dev);
dev284drivers/net/3c507.cstatic int  el16_send_packet(struct sk_buff *skb, struct device *dev);
dev286drivers/net/3c507.cstatic void el16_rx(struct device *dev);
dev287drivers/net/3c507.cstatic int  el16_close(struct device *dev);
dev288drivers/net/3c507.cstatic struct enet_statistics *el16_get_stats(struct device *dev);
dev290drivers/net/3c507.cstatic void hardware_send_packet(struct device *dev, void *buf, short length);
dev291drivers/net/3c507.cvoid init_82586_mem(struct device *dev);
dev306drivers/net/3c507.cel16_probe(struct device *dev)
dev308drivers/net/3c507.cint base_addr = dev ? dev->base_addr : 0;
dev312drivers/net/3c507.creturn el16_probe1(dev, base_addr);
dev320drivers/net/3c507.cif (el16_probe1(dev, ioaddr) == 0)
dev327drivers/net/3c507.cint el16_probe1(struct device *dev, int ioaddr)
dev353drivers/net/3c507.cif (dev == NULL)
dev354drivers/net/3c507.cdev = init_etherdev(0, sizeof(struct net_local), 0);
dev359drivers/net/3c507.cprintk("%s: 3c507 at %#x,", dev->name, ioaddr);
dev374drivers/net/3c507.cdev->base_addr = ioaddr;
dev378drivers/net/3c507.cdev->dev_addr[i] = inb(ioaddr + i);
dev379drivers/net/3c507.cprintk(" %02x", dev->dev_addr[i]);
dev382drivers/net/3c507.cif ((dev->mem_start & 0xf) > 0)
dev383drivers/net/3c507.cnet_debug = dev->mem_start & 7;
dev386drivers/net/3c507.cdev->mem_start = MEM_BASE;
dev387drivers/net/3c507.cdev->mem_end = dev->mem_start + 0x10000;
dev401drivers/net/3c507.cdev->mem_start = base;
dev402drivers/net/3c507.cdev->mem_end = base + size;
dev406drivers/net/3c507.cdev->if_port = (inb(ioaddr + ROM_CONFIG) & 0x80) ? 1 : 0;
dev407drivers/net/3c507.cdev->irq = inb(ioaddr + IRQ_CONFIG) & 0x0f;
dev409drivers/net/3c507.cprintk(", IRQ %d, %sternal xcvr, memory %#lx-%#lx.\n", dev->irq,
dev410drivers/net/3c507.cdev->if_port ? "ex" : "in", dev->mem_start, dev->mem_end-1);
dev416drivers/net/3c507.cif (dev->priv == NULL)
dev417drivers/net/3c507.cdev->priv = kmalloc(sizeof(struct net_local), GFP_KERNEL);
dev418drivers/net/3c507.cmemset(dev->priv, 0, sizeof(struct net_local));
dev420drivers/net/3c507.cdev->open    = el16_open;
dev421drivers/net/3c507.cdev->stop    = el16_close;
dev422drivers/net/3c507.cdev->hard_start_xmit = el16_send_packet;
dev423drivers/net/3c507.cdev->get_stats  = el16_get_stats;
dev425drivers/net/3c507.cether_setup(dev);  /* Generic ethernet behaviour */
dev433drivers/net/3c507.cel16_open(struct device *dev)
dev435drivers/net/3c507.cirq2dev_map[dev->irq] = dev;
dev438drivers/net/3c507.cinit_82586_mem(dev);
dev440drivers/net/3c507.cdev->tbusy = 0;
dev441drivers/net/3c507.cdev->interrupt = 0;
dev442drivers/net/3c507.cdev->start = 1;
dev447drivers/net/3c507.cel16_send_packet(struct sk_buff *skb, struct device *dev)
dev449drivers/net/3c507.cstruct net_local *lp = (struct net_local *)dev->priv;
dev450drivers/net/3c507.cint ioaddr = dev->base_addr;
dev451drivers/net/3c507.cshort *shmem = (short*)dev->mem_start;
dev453drivers/net/3c507.cif (dev->tbusy) {
dev456drivers/net/3c507.cint tickssofar = jiffies - dev->trans_start;
dev460drivers/net/3c507.cprintk("%s: transmit timed out, %s?  ", dev->name,
dev467drivers/net/3c507.cinit_82586_mem(dev);
dev475drivers/net/3c507.cdev->tbusy=0;
dev476drivers/net/3c507.cdev->trans_start = jiffies;
dev483drivers/net/3c507.cdev_tint(dev);
dev488drivers/net/3c507.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev489drivers/net/3c507.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev496drivers/net/3c507.chardware_send_packet(dev, buf, length);
dev497drivers/net/3c507.cdev->trans_start = jiffies;
dev514drivers/net/3c507.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev520drivers/net/3c507.cif (dev == NULL) {
dev524drivers/net/3c507.cdev->interrupt = 1;
dev526drivers/net/3c507.cioaddr = dev->base_addr;
dev527drivers/net/3c507.clp = (struct net_local *)dev->priv;
dev528drivers/net/3c507.cshmem = ((ushort*)dev->mem_start);
dev533drivers/net/3c507.cprintk("%s: 3c507 interrupt, status %4.4x.\n", dev->name, status);
dev550drivers/net/3c507.cdev->tbusy = 0;
dev571drivers/net/3c507.cel16_rx(dev);
dev577drivers/net/3c507.cif ((status & 0x0700) != 0x0200 && dev->start) {
dev580drivers/net/3c507.cdev->name, status);
dev587drivers/net/3c507.cif ((status & 0x0070) != 0x0040  &&  dev->start) {
dev593drivers/net/3c507.cdev->name, status);
dev594drivers/net/3c507.cinit_rx_bufs(dev);
dev612drivers/net/3c507.cel16_close(struct device *dev)
dev614drivers/net/3c507.cint ioaddr = dev->base_addr;
dev615drivers/net/3c507.cushort *shmem = (short*)dev->mem_start;
dev617drivers/net/3c507.cdev->tbusy = 1;
dev618drivers/net/3c507.cdev->start = 0;
dev630drivers/net/3c507.cirq2dev_map[dev->irq] = 0;
dev640drivers/net/3c507.cel16_get_stats(struct device *dev)
dev642drivers/net/3c507.cstruct net_local *lp = (struct net_local *)dev->priv;
dev651drivers/net/3c507.cinit_rx_bufs(struct device *dev)
dev653drivers/net/3c507.cstruct net_local *lp = (struct net_local *)dev->priv;
dev662drivers/net/3c507.cwrite_ptr = (unsigned short *)(dev->mem_start + cur_rxbuf);
dev690drivers/net/3c507.c(dev->mem_start + lp->rx_tail + 2);
dev697drivers/net/3c507.cinit_82586_mem(struct device *dev)
dev699drivers/net/3c507.cstruct net_local *lp = (struct net_local *)dev->priv;
dev700drivers/net/3c507.cshort ioaddr = dev->base_addr;
dev701drivers/net/3c507.cushort *shmem = (short*)dev->mem_start;
dev712drivers/net/3c507.cmemcpy((void*)dev->mem_end-10, init_words, 10);
dev715drivers/net/3c507.cmemcpy((char*)dev->mem_start, init_words + 5, sizeof(init_words) - 10);
dev718drivers/net/3c507.cmemcpy((char*)dev->mem_start+SA_OFFSET, dev->dev_addr,
dev719drivers/net/3c507.csizeof(dev->dev_addr));
dev725drivers/net/3c507.cinit_rx_bufs(dev);
dev739drivers/net/3c507.c"cmd %04x.\n", dev->name,
dev750drivers/net/3c507.cprintk("%s: Initialized 82586, status %04x.\n", dev->name,
dev756drivers/net/3c507.chardware_send_packet(struct device *dev, void *buf, short length)
dev758drivers/net/3c507.cstruct net_local *lp = (struct net_local *)dev->priv;
dev759drivers/net/3c507.cshort ioaddr = dev->base_addr;
dev761drivers/net/3c507.cushort *write_ptr =    (ushort *)(dev->mem_start + tx_block);
dev784drivers/net/3c507.c*(ushort*)(dev->mem_start + lp->tx_cmd_link) = tx_block;
dev794drivers/net/3c507.cdev->name, ioaddr, length, tx_block, lp->tx_head);
dev798drivers/net/3c507.cdev->tbusy = 0;
dev802drivers/net/3c507.cel16_rx(struct device *dev)
dev804drivers/net/3c507.cstruct net_local *lp = (struct net_local *)dev->priv;
dev805drivers/net/3c507.cshort *shmem = (short*)dev->mem_start;
dev812drivers/net/3c507.cushort *read_frame =  (short *)(dev->mem_start + rx_head);
dev816drivers/net/3c507.cushort *data_frame = (short *)(dev->mem_start + data_buffer_addr);
dev822drivers/net/3c507.c"next %04x data-buf @%04x %04x.\n", dev->name, rx_head,
dev840drivers/net/3c507.cprintk("%s: Memory squeeze, dropping packet.\n", dev->name);
dev846drivers/net/3c507.cskb->dev = dev;
dev851drivers/net/3c507.cskb->protocol=eth_type_trans(skb,dev);
dev860drivers/net/3c507.c*(short*)(dev->mem_start + rx_tail + 2) = 0x0000;
dev103drivers/net/3c509.cstatic int el3_open(struct device *dev);
dev104drivers/net/3c509.cstatic int el3_start_xmit(struct sk_buff *skb, struct device *dev);
dev106drivers/net/3c509.cstatic void update_stats(int addr, struct device *dev);
dev107drivers/net/3c509.cstatic struct enet_statistics *el3_get_stats(struct device *dev);
dev108drivers/net/3c509.cstatic int el3_rx(struct device *dev);
dev109drivers/net/3c509.cstatic int el3_close(struct device *dev);
dev111drivers/net/3c509.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev116drivers/net/3c509.cint el3_probe(struct device *dev)
dev120drivers/net/3c509.cshort *phys_addr = (short *)dev->dev_addr;
dev206drivers/net/3c509.cif (dev->base_addr != 0
dev207drivers/net/3c509.c&&  dev->base_addr != (unsigned short)ioaddr) {
dev224drivers/net/3c509.cdev->base_addr = ioaddr;
dev225drivers/net/3c509.cdev->irq = irq;
dev226drivers/net/3c509.cdev->if_port = if_port;
dev227drivers/net/3c509.crequest_region(dev->base_addr, 16,"3c509");
dev232drivers/net/3c509.cdev->name, dev->base_addr, current_tag, if_names[dev->if_port]);
dev237drivers/net/3c509.cprintk(" %2.2x", dev->dev_addr[i]);
dev238drivers/net/3c509.cprintk(", IRQ %d.\n", dev->irq);
dev241drivers/net/3c509.cdev->priv = kmalloc(sizeof(struct el3_private), GFP_KERNEL);
dev242drivers/net/3c509.cmemset(dev->priv, 0, sizeof(struct el3_private));
dev248drivers/net/3c509.cdev->open = &el3_open;
dev249drivers/net/3c509.cdev->hard_start_xmit = &el3_start_xmit;
dev250drivers/net/3c509.cdev->stop = &el3_close;
dev251drivers/net/3c509.cdev->get_stats = &el3_get_stats;
dev253drivers/net/3c509.cdev->set_multicast_list = &set_multicast_list;
dev257drivers/net/3c509.cether_setup(dev);
dev300drivers/net/3c509.cel3_open(struct device *dev)
dev302drivers/net/3c509.cint ioaddr = dev->base_addr;
dev309drivers/net/3c509.cif (request_irq(dev->irq, &el3_interrupt, 0, "3c509")) {
dev315drivers/net/3c509.cprintk("%s: Opening, IRQ %d   status@%x %4.4x.\n", dev->name,
dev316drivers/net/3c509.cdev->irq, ioaddr + EL3_STATUS, inw(ioaddr + EL3_STATUS));
dev321drivers/net/3c509.cirq2dev_map[dev->irq] = dev;
dev324drivers/net/3c509.coutw((dev->irq << 12) | 0x0f00, ioaddr + WN0_IRQ);
dev330drivers/net/3c509.coutb(dev->dev_addr[i], ioaddr + i);
dev332drivers/net/3c509.cif (dev->if_port == 3)
dev335drivers/net/3c509.celse if (dev->if_port == 0) {
dev356drivers/net/3c509.cdev->interrupt = 0;
dev357drivers/net/3c509.cdev->tbusy = 0;
dev358drivers/net/3c509.cdev->start = 1;
dev369drivers/net/3c509.cdev->name, dev->irq, inw(ioaddr + EL3_STATUS));
dev378drivers/net/3c509.cel3_start_xmit(struct sk_buff *skb, struct device *dev)
dev380drivers/net/3c509.cstruct el3_private *lp = (struct el3_private *)dev->priv;
dev381drivers/net/3c509.cint ioaddr = dev->base_addr;
dev384drivers/net/3c509.cif (dev->tbusy) {
dev385drivers/net/3c509.cint tickssofar = jiffies - dev->trans_start;
dev389drivers/net/3c509.cdev->name, inb(ioaddr + TX_STATUS), inw(ioaddr + EL3_STATUS));
dev390drivers/net/3c509.cdev->trans_start = jiffies;
dev394drivers/net/3c509.cdev->tbusy = 0;
dev398drivers/net/3c509.cdev_tint(dev);
dev407drivers/net/3c509.cdev->name, skb->len, inw(ioaddr + EL3_STATUS));
dev415drivers/net/3c509.c"  Tx %2.2x Rx %4.4x.\n", dev->name, status,
dev427drivers/net/3c509.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev428drivers/net/3c509.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev436drivers/net/3c509.cdev->trans_start = jiffies;
dev438drivers/net/3c509.cdev->tbusy = 0;
dev465drivers/net/3c509.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev469drivers/net/3c509.cif (dev == NULL) {
dev474drivers/net/3c509.cif (dev->interrupt)
dev475drivers/net/3c509.cprintk("%s: Re-entering the interrupt handler.\n", dev->name);
dev476drivers/net/3c509.cdev->interrupt = 1;
dev478drivers/net/3c509.cioaddr = dev->base_addr;
dev482drivers/net/3c509.cprintk("%s: interrupt, status %4.4x.\n", dev->name, status);
dev487drivers/net/3c509.cel3_rx(dev);
dev494drivers/net/3c509.cdev->tbusy = 0;
dev498drivers/net/3c509.cupdate_stats(ioaddr, dev);
dev502drivers/net/3c509.cdev->name, status);
dev513drivers/net/3c509.cprintk("%s: exiting interrupt, status %4.4x.\n", dev->name,
dev517drivers/net/3c509.cdev->interrupt = 0;
dev523drivers/net/3c509.cel3_get_stats(struct device *dev)
dev525drivers/net/3c509.cstruct el3_private *lp = (struct el3_private *)dev->priv;
dev530drivers/net/3c509.cupdate_stats(dev->base_addr, dev);
dev540drivers/net/3c509.cstatic void update_stats(int ioaddr, struct device *dev)
dev542drivers/net/3c509.cstruct el3_private *lp = (struct el3_private *)dev->priv;
dev569drivers/net/3c509.cel3_rx(struct device *dev)
dev571drivers/net/3c509.cstruct el3_private *lp = (struct el3_private *)dev->priv;
dev572drivers/net/3c509.cint ioaddr = dev->base_addr;
dev599drivers/net/3c509.cskb->dev = dev;
dev606drivers/net/3c509.cskb->protocol=eth_type_trans(skb,dev);
dev613drivers/net/3c509.cdev->name, pkt_len);
dev633drivers/net/3c509.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev635drivers/net/3c509.cshort ioaddr = dev->base_addr;
dev640drivers/net/3c509.cprintk("%s: Setting Rx mode to %d addresses.\n", dev->name, num_addrs);
dev654drivers/net/3c509.cel3_close(struct device *dev)
dev656drivers/net/3c509.cint ioaddr = dev->base_addr;
dev659drivers/net/3c509.cprintk("%s: Shutting down ethercard.\n", dev->name);
dev661drivers/net/3c509.cdev->tbusy = 1;
dev662drivers/net/3c509.cdev->start = 0;
dev671drivers/net/3c509.cif (dev->if_port == 3)
dev674drivers/net/3c509.celse if (dev->if_port == 0) {
dev680drivers/net/3c509.cfree_irq(dev->irq);
dev687drivers/net/3c509.cirq2dev_map[dev->irq] = 0;
dev689drivers/net/3c509.cupdate_stats(ioaddr, dev);
dev95drivers/net/8390.cstatic void ei_tx_intr(struct device *dev);
dev96drivers/net/8390.cstatic void ei_receive(struct device *dev);
dev97drivers/net/8390.cstatic void ei_rx_overrun(struct device *dev);
dev100drivers/net/8390.cstatic void NS8390_trigger_send(struct device *dev, unsigned int length,
dev103drivers/net/8390.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev111drivers/net/8390.cint ei_open(struct device *dev)
dev113drivers/net/8390.cstruct ei_device *ei_local = (struct ei_device *) dev->priv;
dev116drivers/net/8390.cprintk("%s: Opening a non-existent physical device\n", dev->name);
dev120drivers/net/8390.cirq2dev_map[dev->irq] = dev;
dev121drivers/net/8390.cNS8390_init(dev, 1);
dev122drivers/net/8390.cdev->start = 1;
dev127drivers/net/8390.cstatic int ei_start_xmit(struct sk_buff *skb, struct device *dev)
dev129drivers/net/8390.cint e8390_base = dev->base_addr;
dev130drivers/net/8390.cstruct ei_device *ei_local = (struct ei_device *) dev->priv;
dev139drivers/net/8390.cif (dev->tbusy) {  /* Do timeouts, just like the 8003 driver. */
dev141drivers/net/8390.cint tickssofar = jiffies - dev->trans_start;
dev146drivers/net/8390.cif (dev->start == 0) {
dev147drivers/net/8390.cprintk("%s: xmit on stopped card\n", dev->name);
dev151drivers/net/8390.cdev->name, txsr, isr);
dev154drivers/net/8390.cprintk(KERN_DEBUG "%s: Possible IRQ conflict on IRQ%d?\n", dev->name, dev->irq);
dev157drivers/net/8390.cprintk(KERN_DEBUG "%s: Possible network cable problem?\n", dev->name);
dev162drivers/net/8390.cei_reset_8390(dev);
dev163drivers/net/8390.cNS8390_init(dev, 1);
dev164drivers/net/8390.cdev->trans_start = jiffies;
dev171drivers/net/8390.cdev_tint(dev);
dev181drivers/net/8390.cif (dev->interrupt) {
dev182drivers/net/8390.cprintk("%s: Tx request while isr active.\n",dev->name);
dev197drivers/net/8390.cdev->name, ei_local->tx2, ei_local->lasttx,
dev204drivers/net/8390.cdev->name, ei_local->tx1, ei_local->lasttx,
dev209drivers/net/8390.cdev->name, dev->interrupt, ei_local->tx1, 
dev212drivers/net/8390.cdev->tbusy = 1;
dev216drivers/net/8390.cei_block_output(dev, length, skb->data, output_page);
dev219drivers/net/8390.cNS8390_trigger_send(dev, send_length, output_page);
dev220drivers/net/8390.cdev->trans_start = jiffies;
dev228drivers/net/8390.cdev->tbusy = (ei_local->tx1  &&  ei_local->tx2);
dev230drivers/net/8390.cei_block_output(dev, length, skb->data, ei_local->tx_start_page);
dev232drivers/net/8390.cNS8390_trigger_send(dev, send_length, ei_local->tx_start_page);
dev233drivers/net/8390.cdev->trans_start = jiffies;
dev234drivers/net/8390.cdev->tbusy = 1;
dev250drivers/net/8390.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev255drivers/net/8390.cif (dev == NULL) {
dev259drivers/net/8390.ce8390_base = dev->base_addr;
dev260drivers/net/8390.cei_local = (struct ei_device *) dev->priv;
dev261drivers/net/8390.cif (dev->interrupt || ei_local->irqlock) {
dev266drivers/net/8390.cdev->name, inb_p(e8390_base + EN0_ISR),
dev271drivers/net/8390.cdev->interrupt = 1;
dev276drivers/net/8390.cprintk("%s: interrupt(isr=%#2.2x).\n", dev->name,
dev282drivers/net/8390.cif (dev->start == 0) {
dev283drivers/net/8390.cprintk("%s: interrupt from stopped card\n", dev->name);
dev288drivers/net/8390.cei_rx_overrun(dev);
dev291drivers/net/8390.cei_receive(dev);
dev295drivers/net/8390.cei_tx_intr(dev);
dev320drivers/net/8390.cdev->name, interrupts);
dev323drivers/net/8390.cprintk("%s: unknown interrupt %#2x\n", dev->name, interrupts);
dev327drivers/net/8390.cdev->interrupt = 0;
dev333drivers/net/8390.cstatic void ei_tx_intr(struct device *dev)
dev335drivers/net/8390.cint e8390_base = dev->base_addr;
dev337drivers/net/8390.cstruct ei_device *ei_local = (struct ei_device *) dev->priv;
dev348drivers/net/8390.cdev->tbusy = 0;
dev351drivers/net/8390.cNS8390_trigger_send(dev, ei_local->tx2, ei_local->tx_start_page + 6);
dev352drivers/net/8390.cdev->trans_start = jiffies;
dev362drivers/net/8390.cdev->tbusy = 0;
dev365drivers/net/8390.cNS8390_trigger_send(dev, ei_local->tx1, ei_local->tx_start_page);
dev366drivers/net/8390.cdev->trans_start = jiffies;
dev373drivers/net/8390.cdev->name, ei_local->lasttx);
dev376drivers/net/8390.cdev->tbusy = 0;
dev397drivers/net/8390.cstatic void ei_receive(struct device *dev)
dev399drivers/net/8390.cint e8390_base = dev->base_addr;
dev400drivers/net/8390.cstruct ei_device *ei_local = (struct ei_device *) dev->priv;
dev423drivers/net/8390.cdev->name, this_frame, ei_local->current_page);
dev429drivers/net/8390.cei_block_input(dev, sizeof(rx_frame), (char *)&rx_frame,
dev452drivers/net/8390.cdev->name, rx_frame.count, rx_frame.status,
dev462drivers/net/8390.cdev->name, pkt_len);
dev467drivers/net/8390.cskb->dev = dev;
dev469drivers/net/8390.cei_block_input(dev, pkt_len, skb_put(skb,pkt_len),
dev471drivers/net/8390.cskb->protocol=eth_type_trans(skb,dev);
dev479drivers/net/8390.cdev->name, rx_frame.status, rx_frame.next,
dev488drivers/net/8390.cprintk("%s: next frame inconsistency, %#2x\n", dev->name,
dev510drivers/net/8390.cstatic void ei_rx_overrun(struct device *dev)
dev512drivers/net/8390.cint e8390_base = dev->base_addr;
dev514drivers/net/8390.cstruct ei_device *ei_local = (struct ei_device *) dev->priv;
dev520drivers/net/8390.cprintk("%s: Receiver overrun.\n", dev->name);
dev533drivers/net/8390.cdev->name);
dev534drivers/net/8390.cNS8390_init(dev, 1);
dev539drivers/net/8390.cei_receive(dev);
dev547drivers/net/8390.cstatic struct enet_statistics *get_stats(struct device *dev)
dev549drivers/net/8390.cshort ioaddr = dev->base_addr;
dev550drivers/net/8390.cstruct ei_device *ei_local = (struct ei_device *) dev->priv;
dev553drivers/net/8390.cif (dev->start == 0) return &ei_local->stat;
dev570drivers/net/8390.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev572drivers/net/8390.cshort ioaddr = dev->base_addr;
dev586drivers/net/8390.cint ethdev_init(struct device *dev)
dev591drivers/net/8390.cif (dev->priv == NULL) {
dev594drivers/net/8390.cdev->priv = kmalloc(sizeof(struct ei_device), GFP_KERNEL);
dev595drivers/net/8390.cmemset(dev->priv, 0, sizeof(struct ei_device));
dev596drivers/net/8390.cei_local = (struct ei_device *)dev->priv;
dev603drivers/net/8390.cif (dev->open == NULL)
dev604drivers/net/8390.cdev->open = &ei_open;
dev606drivers/net/8390.cdev->hard_start_xmit = &ei_start_xmit;
dev607drivers/net/8390.cdev->get_stats  = get_stats;
dev609drivers/net/8390.cdev->set_multicast_list = &set_multicast_list;
dev612drivers/net/8390.cether_setup(dev);
dev620drivers/net/8390.cvoid NS8390_init(struct device *dev, int startp)
dev622drivers/net/8390.cint e8390_base = dev->base_addr;
dev623drivers/net/8390.cstruct ei_device *ei_local = (struct ei_device *) dev->priv;
dev654drivers/net/8390.coutb_p(dev->dev_addr[i], e8390_base + EN1_PHYS + i);
dev664drivers/net/8390.cdev->tbusy = 0;
dev665drivers/net/8390.cdev->interrupt = 0;
dev680drivers/net/8390.cstatic void NS8390_trigger_send(struct device *dev, unsigned int length,
dev683drivers/net/8390.cint e8390_base = dev->base_addr;
dev689drivers/net/8390.cdev->name);
dev23drivers/net/8390.hextern int ethif_init(struct device *dev);
dev24drivers/net/8390.hextern int ethdev_init(struct device *dev);
dev25drivers/net/8390.hextern void NS8390_init(struct device *dev, int startp);
dev26drivers/net/8390.hextern int ei_open(struct device *dev);
dev69drivers/net/8390.h#define ei_status (*(struct ei_device *)(dev->priv))
dev41drivers/net/Space.cextern int hp100_probe(struct device *dev);
dev42drivers/net/Space.cextern int ultra_probe(struct device *dev);
dev43drivers/net/Space.cextern int wd_probe(struct device *dev);
dev44drivers/net/Space.cextern int el2_probe(struct device *dev);
dev45drivers/net/Space.cextern int ne_probe(struct device *dev);
dev46drivers/net/Space.cextern int hp_probe(struct device *dev);
dev47drivers/net/Space.cextern int hp_plus_probe(struct device *dev);
dev77drivers/net/Space.cethif_probe(struct device *dev)
dev79drivers/net/Space.cu_long base_addr = dev->base_addr;
dev86drivers/net/Space.c&& seeq8005_probe(dev)
dev89drivers/net/Space.c&& hp100_probe(dev)
dev92drivers/net/Space.c&& ultra_probe(dev)
dev95drivers/net/Space.c&& wd_probe(dev)
dev98drivers/net/Space.c&& el2_probe(dev)
dev101drivers/net/Space.c&& ne_probe(dev)
dev104drivers/net/Space.c&& hp_probe(dev)
dev107drivers/net/Space.c&& hp_plus_probe(dev)
dev110drivers/net/Space.c&& at1500_probe(dev)
dev113drivers/net/Space.c&& at1700_probe(dev)
dev116drivers/net/Space.c&& el3_probe(dev)
dev119drivers/net/Space.c&& znet_probe(dev)
dev122drivers/net/Space.c&& express_probe(dev)
dev125drivers/net/Space.c&& eepro_probe(dev)
dev128drivers/net/Space.c&& depca_probe(dev)
dev131drivers/net/Space.c&& ewrk3_probe(dev)
dev134drivers/net/Space.c&& de4x5_probe(dev)
dev137drivers/net/Space.c&& apricot_probe(dev)
dev140drivers/net/Space.c&& el1_probe(dev)
dev143drivers/net/Space.c&& wavelan_probe(dev)
dev146drivers/net/Space.c&& el16_probe(dev)
dev149drivers/net/Space.c&& elplus_probe(dev)
dev152drivers/net/Space.c&& ac3200_probe(dev)
dev155drivers/net/Space.c&& e2100_probe(dev)
dev158drivers/net/Space.c&& de600_probe(dev)
dev161drivers/net/Space.c&& de620_probe(dev)
dev164drivers/net/Space.c&& SK_init(dev)
dev167drivers/net/Space.c&& ni52_probe(dev)
dev170drivers/net/Space.c&& ni65_probe(dev)
dev200drivers/net/Space.cextern int arcnet_probe(struct device *dev);
dev349drivers/net/Space.cextern int dummy_init(struct device *dev);
dev357drivers/net/Space.cextern int eql_init(struct device *dev);
dev374drivers/net/Space.cextern int tok_probe(struct device *dev);
dev391drivers/net/Space.cextern int tok_probe(struct device *dev);
dev445drivers/net/Space.cextern int loopback_init(struct device *dev);
dev57drivers/net/ac3200.cint ac3200_probe(struct device *dev);
dev58drivers/net/ac3200.cstatic int ac_probe1(int ioaddr, struct device *dev);
dev60drivers/net/ac3200.cstatic int ac_open(struct device *dev);
dev61drivers/net/ac3200.cstatic void ac_reset_8390(struct device *dev);
dev62drivers/net/ac3200.cstatic int ac_block_input(struct device *dev, int count,
dev64drivers/net/ac3200.cstatic void ac_block_output(struct device *dev, const int count,
dev66drivers/net/ac3200.cstatic int ac_close_card(struct device *dev);
dev75drivers/net/ac3200.cint ac3200_probe(struct device *dev)
dev77drivers/net/ac3200.cunsigned short ioaddr = dev->base_addr;
dev80drivers/net/ac3200.creturn ac_probe1(ioaddr, dev);
dev89drivers/net/ac3200.cif (ac_probe1(ioaddr, dev) == 0)
dev95drivers/net/ac3200.cstatic int ac_probe1(int ioaddr, struct device *dev)
dev126drivers/net/ac3200.cdev->dev_addr[i] = inb(ioaddr + AC_SA_PROM + i);
dev136drivers/net/ac3200.cif (dev->irq == 0)
dev137drivers/net/ac3200.cdev->irq = config2irq(inb(ioaddr + AC_CONFIG));
dev138drivers/net/ac3200.celse if (dev->irq == 2)
dev139drivers/net/ac3200.cdev->irq = 9;
dev141drivers/net/ac3200.cif (request_irq(dev->irq, ei_interrupt, 0, "ac3200")) {
dev142drivers/net/ac3200.cprintk (" unable to get IRQ %d.\n", dev->irq);
dev146drivers/net/ac3200.cdev->base_addr = ioaddr;
dev149drivers/net/ac3200.cif (dev->mem_start)  {    /* Override the value from the board. */
dev151drivers/net/ac3200.cif (addrmap[i] == dev->mem_start)
dev159drivers/net/ac3200.cdev->if_port = inb(ioaddr + AC_CONFIG) >> 6;
dev160drivers/net/ac3200.cdev->mem_start = config2mem(inb(ioaddr + AC_CONFIG));
dev161drivers/net/ac3200.cdev->rmem_start = dev->mem_start + TX_PAGES*256;
dev162drivers/net/ac3200.cdev->mem_end = dev->rmem_end = dev->mem_start
dev165drivers/net/ac3200.cethdev_init(dev);
dev174drivers/net/ac3200.cdev->name, ioaddr, dev->irq, port_name[dev->if_port],
dev175drivers/net/ac3200.cdev->mem_start, dev->mem_end-1);
dev184drivers/net/ac3200.cdev->open = &ac_open;
dev185drivers/net/ac3200.cdev->stop = &ac_close_card;
dev186drivers/net/ac3200.cNS8390_init(dev, 0);
dev190drivers/net/ac3200.cstatic int ac_open(struct device *dev)
dev194drivers/net/ac3200.cint ioaddr = dev->base_addr;
dev196drivers/net/ac3200.cif (request_irq(dev->irq, ei_interrupt, 0, "ac3200"))
dev200drivers/net/ac3200.creturn ei_open(dev);
dev203drivers/net/ac3200.cstatic void ac_reset_8390(struct device *dev)
dev205drivers/net/ac3200.cushort ioaddr = dev->base_addr;
dev220drivers/net/ac3200.cstatic int ac_block_input(struct device *dev, int count, char *buf,
dev223drivers/net/ac3200.clong xfer_start = dev->mem_start + ring_offset - (AC_START_PG<<8);
dev225drivers/net/ac3200.cif (xfer_start + count > dev->rmem_end) {
dev227drivers/net/ac3200.cint semi_count = dev->rmem_end - xfer_start;
dev230drivers/net/ac3200.cmemcpy(buf + semi_count, (char *)dev->rmem_start, count);
dev231drivers/net/ac3200.creturn dev->rmem_start + count;
dev238drivers/net/ac3200.cstatic void ac_block_output(struct device *dev, int count,
dev241drivers/net/ac3200.clong shmem = dev->mem_start + ((start_page - AC_START_PG)<<8);
dev246drivers/net/ac3200.cstatic int ac_close_card(struct device *dev)
dev248drivers/net/ac3200.cdev->start = 0;
dev249drivers/net/ac3200.cdev->tbusy = 1;
dev252drivers/net/ac3200.cprintk("%s: Shutting down ethercard.\n", dev->name);
dev257drivers/net/ac3200.cfree_irq(dev->irq);
dev258drivers/net/ac3200.cirq2dev_map[dev->irq] = 0;
dev261drivers/net/ac3200.cNS8390_init(dev, 0);
dev187drivers/net/apricot.cstatic int i596_open(struct device *dev);
dev188drivers/net/apricot.cstatic int i596_start_xmit(struct sk_buff *skb, struct device *dev);
dev190drivers/net/apricot.cstatic int i596_close(struct device *dev);
dev191drivers/net/apricot.cstatic struct enet_statistics *i596_get_stats(struct device *dev);
dev192drivers/net/apricot.cstatic void i596_add_cmd(struct device *dev, struct i596_cmd *cmd);
dev195drivers/net/apricot.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev200drivers/net/apricot.cinit_rx_bufs(struct device *dev, int num)
dev202drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev208drivers/net/apricot.cif (i596_debug > 1) printk ("%s: init_rx_bufs %d.\n", dev->name, num);
dev238drivers/net/apricot.cremove_rx_bufs(struct device *dev)
dev240drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev255drivers/net/apricot.cinit_i596_mem(struct device *dev)
dev257drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev258drivers/net/apricot.cshort ioaddr = dev->base_addr;
dev278drivers/net/apricot.cif (i596_debug > 2) printk("%s: starting i82596.\n", dev->name);
dev288drivers/net/apricot.cdev->name, lp->scb.status, lp->scb.command);
dev296drivers/net/apricot.ci596_add_cmd(dev, &lp->set_conf);
dev298drivers/net/apricot.cmemcpy (lp->eth_addr, dev->dev_addr, 6);
dev300drivers/net/apricot.ci596_add_cmd(dev, &lp->set_add);
dev303drivers/net/apricot.ci596_add_cmd(dev, &lp->tdr);
dev310drivers/net/apricot.cdev->name, lp->scb.status, lp->scb.command);
dev330drivers/net/apricot.ci596_rx(struct device *dev)
dev332drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev351drivers/net/apricot.cprintk ("%s: i596_rx Memory squeeze, dropping packet.\n", dev->name);
dev356drivers/net/apricot.cskb->dev = dev;    
dev359drivers/net/apricot.cskb->protocol=eth_type_trans(skb,dev);
dev447drivers/net/apricot.ci596_reset(struct device *dev, struct i596_private *lp, int ioaddr)
dev461drivers/net/apricot.cdev->start = 0;
dev462drivers/net/apricot.cdev->tbusy = 1;
dev479drivers/net/apricot.ci596_rx(dev);
dev481drivers/net/apricot.cdev->start = 1;
dev482drivers/net/apricot.cdev->tbusy = 0;
dev483drivers/net/apricot.cdev->interrupt = 0;
dev484drivers/net/apricot.cinit_i596_mem(dev);
dev487drivers/net/apricot.cstatic void i596_add_cmd(struct device *dev, struct i596_cmd *cmd)
dev489drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev490drivers/net/apricot.cint ioaddr = dev->base_addr;
dev531drivers/net/apricot.cprintk("%s: command unit timed out, status resetting.\n", dev->name);
dev533drivers/net/apricot.ci596_reset(dev, lp, ioaddr);
dev538drivers/net/apricot.ci596_open(struct device *dev)
dev543drivers/net/apricot.cprintk("%s: i596_open() irq %d.\n", dev->name, dev->irq);
dev545drivers/net/apricot.cif (request_irq(dev->irq, &i596_interrupt, 0, "apricot"))
dev548drivers/net/apricot.cirq2dev_map[dev->irq] = dev;
dev550drivers/net/apricot.ci = init_rx_bufs(dev, RX_RING_SIZE);
dev552drivers/net/apricot.cif ((i = init_rx_bufs(dev, RX_RING_SIZE)) < RX_RING_SIZE)
dev553drivers/net/apricot.cprintk("%s: only able to allocate %d receive buffers\n", dev->name, i);
dev557drivers/net/apricot.cfree_irq(dev->irq);
dev558drivers/net/apricot.cirq2dev_map[dev->irq] = 0;
dev562drivers/net/apricot.cdev->tbusy = 0;
dev563drivers/net/apricot.cdev->interrupt = 0;
dev564drivers/net/apricot.cdev->start = 1;
dev570drivers/net/apricot.cinit_i596_mem(dev);
dev576drivers/net/apricot.ci596_start_xmit(struct sk_buff *skb, struct device *dev)
dev578drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev579drivers/net/apricot.cint ioaddr = dev->base_addr;
dev582drivers/net/apricot.cif (i596_debug > 2) printk ("%s: Apricot start xmit\n", dev->name);
dev585drivers/net/apricot.cif (dev->tbusy) {
dev586drivers/net/apricot.cint tickssofar = jiffies - dev->trans_start;
dev590drivers/net/apricot.cdev->name);
dev597drivers/net/apricot.ci596_reset(dev,lp, ioaddr);
dev607drivers/net/apricot.cdev->tbusy = 0;
dev608drivers/net/apricot.cdev->trans_start = jiffies;
dev615drivers/net/apricot.cdev_tint(dev);
dev622drivers/net/apricot.cif (i596_debug > 3) printk("%s: i596_start_xmit() called\n", dev->name);
dev626drivers/net/apricot.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev627drivers/net/apricot.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev631drivers/net/apricot.cdev->trans_start = jiffies;
dev636drivers/net/apricot.cprintk ("%s: i596_xmit Memory squeeze, dropping packet.\n", dev->name);
dev657drivers/net/apricot.ci596_add_cmd(dev, (struct i596_cmd *)tx_cmd);
dev663drivers/net/apricot.cdev->tbusy = 0;
dev685drivers/net/apricot.cint apricot_probe(struct device *dev)
dev719drivers/net/apricot.cdev->base_addr = ioaddr;
dev720drivers/net/apricot.cether_setup(dev);
dev721drivers/net/apricot.cprintk("%s: Apricot 82596 at %#3x,", dev->name, ioaddr);
dev724drivers/net/apricot.cprintk(" %2.2X", dev->dev_addr[i] = eth_addr[i]);
dev726drivers/net/apricot.cdev->base_addr = ioaddr;
dev727drivers/net/apricot.cdev->irq = 10;
dev728drivers/net/apricot.cprintk(" IRQ %d.\n", dev->irq);
dev733drivers/net/apricot.cdev->open = &i596_open;
dev734drivers/net/apricot.cdev->stop = &i596_close;
dev735drivers/net/apricot.cdev->hard_start_xmit = &i596_start_xmit;
dev736drivers/net/apricot.cdev->get_stats = &i596_get_stats;
dev738drivers/net/apricot.cdev->set_multicast_list = &set_multicast_list;
dev741drivers/net/apricot.cdev->mem_start = (int)kmalloc(sizeof(struct i596_private)+ 0x0f, GFP_KERNEL);
dev743drivers/net/apricot.cdev->priv = (void *)((dev->mem_start + 0xf) & 0xfffffff0);
dev745drivers/net/apricot.clp = (struct i596_private *)dev->priv;
dev757drivers/net/apricot.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev763drivers/net/apricot.cif (dev == NULL) {
dev768drivers/net/apricot.cif (i596_debug > 3) printk ("%s: i596_interrupt(): irq %d\n",dev->name, irq);
dev770drivers/net/apricot.cif (dev->interrupt)
dev771drivers/net/apricot.cprintk("%s: Re-entering the interrupt handler.\n", dev->name);
dev773drivers/net/apricot.cdev->interrupt = 1;
dev775drivers/net/apricot.cioaddr = dev->base_addr;
dev777drivers/net/apricot.clp = (struct i596_private *)dev->priv;
dev782drivers/net/apricot.cprintk("%s: i596 interrupt, timeout status %4.4x command %4.4x.\n", dev->name, lp->scb.status, lp->scb.command);
dev788drivers/net/apricot.cprintk("%s: i596 interrupt, status %4.4x.\n", dev->name, status);
dev797drivers/net/apricot.cprintk("%s: i596 interrupt completed command.\n", dev->name);
dev799drivers/net/apricot.cprintk("%s: i596 interrupt command unit inactive %x.\n", dev->name, status & 0x0700);
dev851drivers/net/apricot.cprintk("%s: link ok.\n", dev->name);
dev856drivers/net/apricot.cprintk("%s: Transceiver problem.\n", dev->name);
dev858drivers/net/apricot.cprintk("%s: Termination problem.\n", dev->name);
dev860drivers/net/apricot.cprintk("%s: Short circuit.\n", dev->name);
dev862drivers/net/apricot.cprintk("%s: Time %ld.\n", dev->name, status & 0x07ff);
dev879drivers/net/apricot.cif ((lp->cmd_head != (struct i596_cmd *) I596_NULL) && (dev->start)) ack_cmd |= CUC_START;
dev886drivers/net/apricot.cprintk("%s: i596 interrupt received a frame.\n", dev->name);
dev888drivers/net/apricot.cprintk("%s: i596 interrupt receive unit inactive %x.\n", dev->name, status & 0x0070);
dev890drivers/net/apricot.ci596_rx(dev);
dev892drivers/net/apricot.cif (dev->start) ack_cmd |= RX_START;
dev904drivers/net/apricot.cprintk("%s: i596 interrupt, timeout status %4.4x command %4.4x.\n", dev->name, lp->scb.status, lp->scb.command);
dev914drivers/net/apricot.cprintk("%s: exiting interrupt.\n", dev->name);
dev916drivers/net/apricot.cdev->interrupt = 0;
dev921drivers/net/apricot.ci596_close(struct device *dev)
dev923drivers/net/apricot.cint ioaddr = dev->base_addr;
dev924drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev927drivers/net/apricot.cdev->start = 0;
dev928drivers/net/apricot.cdev->tbusy = 1;
dev932drivers/net/apricot.cdev->name, lp->scb.status);
dev943drivers/net/apricot.cdev->name, lp->scb.status, lp->scb.command);
dev946drivers/net/apricot.cfree_irq(dev->irq);
dev947drivers/net/apricot.cirq2dev_map[dev->irq] = 0;
dev948drivers/net/apricot.cremove_rx_bufs(dev);
dev958drivers/net/apricot.ci596_get_stats(struct device *dev)
dev960drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev973drivers/net/apricot.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev975drivers/net/apricot.cstruct i596_private *lp = (struct i596_private *)dev->priv;
dev979drivers/net/apricot.cprintk ("%s: set multicast list %d\n", dev->name, num_addrs);
dev985drivers/net/apricot.cprintk ("%s: set_multicast Memory squeeze.\n", dev->name);
dev994drivers/net/apricot.ci596_add_cmd(dev, cmd);
dev1003drivers/net/apricot.ci596_add_cmd(dev, &lp->set_conf);
dev424drivers/net/arcnet.cextern int arcnet_probe(struct device *dev);
dev426drivers/net/arcnet.cstatic int arcnet_memprobe(struct device *dev,u_char *addr);
dev427drivers/net/arcnet.cstatic int arcnet_ioprobe(struct device *dev, short ioaddr);
dev429drivers/net/arcnet.cstatic int arcnetW_init(struct device *dev);
dev431drivers/net/arcnet.cstatic int arcnet_open(struct device *dev);
dev432drivers/net/arcnet.cstatic int arcnet_close(struct device *dev);
dev433drivers/net/arcnet.cstatic int arcnet_reset(struct device *dev);
dev435drivers/net/arcnet.cstatic int arcnetA_send_packet(struct sk_buff *skb, struct device *dev);
dev436drivers/net/arcnet.cstatic void arcnetA_continue_tx(struct device *dev);
dev437drivers/net/arcnet.cstatic void arcnetA_prepare_tx(struct device *dev,struct ClientData *hdr,
dev439drivers/net/arcnet.cstatic void arcnetA_go_tx(struct device *dev);
dev441drivers/net/arcnet.cstatic int arcnetW_send_packet(struct sk_buff *skb, struct device *dev);
dev444drivers/net/arcnet.cstatic void arcnet_inthandler(struct device *dev);
dev446drivers/net/arcnet.cstatic void arcnet_rx(struct device *dev,int recbuf);
dev447drivers/net/arcnet.cstatic void arcnetA_rx(struct device *dev,struct ClientData *arcsoft,
dev449drivers/net/arcnet.cstatic void arcnetW_rx(struct device *dev,u_char *arcsoft,
dev452drivers/net/arcnet.cstatic struct enet_statistics *arcnet_get_stats(struct device *dev);
dev453drivers/net/arcnet.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev456drivers/net/arcnet.cint arcnetA_header(struct sk_buff *skb,struct device *dev,unsigned short type,
dev458drivers/net/arcnet.cint arcnetA_rebuild_header(void *eth,struct device *dev,unsigned long raddr,
dev460drivers/net/arcnet.cunsigned short arcnetA_type_trans(struct sk_buff *skb,struct device *dev);
dev467drivers/net/arcnet.c#define tx_done(dev) 1
dev487drivers/net/arcnet.carcnet_probe(struct device *dev)
dev514drivers/net/arcnet.cint base_addr=dev->base_addr, status=0;
dev532drivers/net/arcnet.cdev->base_addr,dev->irq,dev->mem_start);
dev536drivers/net/arcnet.cstatus=arcnet_ioprobe(dev, base_addr);
dev550drivers/net/arcnet.cstatus=arcnet_ioprobe(dev, ioaddr);
dev566drivers/net/arcnet.cdev->mem_start);
dev567drivers/net/arcnet.cif (dev->mem_start)  /* value given - probe just that one */
dev569drivers/net/arcnet.cstatus=arcnet_memprobe(dev,(u_char *)dev->mem_start);
dev575drivers/net/arcnet.cstatus=arcnet_memprobe(dev,(u_char *)(*addr));
dev582drivers/net/arcnet.cif (!dev->base_addr || !dev->irq || !dev->mem_start 
dev583drivers/net/arcnet.c|| !dev->rmem_start)
dev593drivers/net/arcnet.cint irqval = request_irq(dev->irq, &arcnet_interrupt, 0,
dev597drivers/net/arcnet.cdev->name,dev->irq, irqval);
dev603drivers/net/arcnet.crequest_region(dev->base_addr, ARCNET_TOTAL_SIZE,"arcnet");
dev606drivers/net/arcnet.cdev->name, dev->base_addr, dev->irq, dev->mem_start);
dev609drivers/net/arcnet.cdev->priv = kmalloc(sizeof(struct arcnet_local), GFP_KERNEL);
dev610drivers/net/arcnet.cmemset(dev->priv, 0, sizeof(struct arcnet_local));
dev611drivers/net/arcnet.clp=(struct arcnet_local *)(dev->priv);
dev613drivers/net/arcnet.cdev->open=arcnet_open;
dev614drivers/net/arcnet.cdev->stop=arcnet_close;
dev615drivers/net/arcnet.cdev->hard_start_xmit=arcnetA_send_packet;
dev616drivers/net/arcnet.cdev->get_stats=arcnet_get_stats;
dev618drivers/net/arcnet.cdev->set_multicast_list = &set_multicast_list;
dev624drivers/net/arcnet.cether_setup(dev);
dev627drivers/net/arcnet.cdev->type=ARPHRD_ARCNET;
dev628drivers/net/arcnet.cdev->hard_header_len=sizeof(struct ClientData);
dev636drivers/net/arcnet.cdev->addr_len=1;
dev637drivers/net/arcnet.cdev->broadcast[0]=0x00;
dev640drivers/net/arcnet.carcnet_reset(dev);
dev649drivers/net/arcnet.cdev->dev_addr[0]=lp->arcnum;
dev653drivers/net/arcnet.cdev->hard_header=arcnetA_header;
dev654drivers/net/arcnet.cdev->rebuild_header=arcnetA_rebuild_header;
dev661drivers/net/arcnet.cint arcnet_ioprobe(struct device *dev, short ioaddr)
dev750drivers/net/arcnet.cif (!airq && !(dev->base_addr && dev->irq))
dev774drivers/net/arcnet.cif (!dev->base_addr) dev->base_addr=ioaddr;
dev776drivers/net/arcnet.cif (dev->irq < 2)    /* "Auto-IRQ" */
dev779drivers/net/arcnet.cdev->irq=airq;
dev781drivers/net/arcnet.celse if (dev->irq == 2)
dev785drivers/net/arcnet.cdev->irq = 9;
dev790drivers/net/arcnet.cdev->base_addr,dev->irq);
dev799drivers/net/arcnet.cint arcnet_memprobe(struct device *dev,u_char *addr)
dev804drivers/net/arcnet.cdev->mem_start=0;
dev826drivers/net/arcnet.cdev->mem_start=(unsigned long)addr;
dev827drivers/net/arcnet.cdev->mem_end=dev->mem_start+512*4-1;
dev828drivers/net/arcnet.cdev->rmem_start=dev->mem_start+512*0;
dev829drivers/net/arcnet.cdev->rmem_end=dev->mem_start+512*2-1;
dev837drivers/net/arcnet.cint arcnet_reset(struct device *dev)
dev839drivers/net/arcnet.cstruct arcnet_local *lp=(struct arcnet_local *)dev->priv;
dev840drivers/net/arcnet.cshort ioaddr=dev->base_addr;
dev848drivers/net/arcnet.cdev->name,inb(STATUS));
dev859drivers/net/arcnet.ccardmem = (u_char *) dev->mem_start;
dev877drivers/net/arcnet.cmemset((void *)dev->mem_start,0x42,2048);
dev889drivers/net/arcnet.cstatic int arcnetW_init(struct device *dev)
dev891drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev894drivers/net/arcnet.cdev->dev_addr[0]=0;
dev895drivers/net/arcnet.cdev->dev_addr[5]=lp->arcnum;
dev896drivers/net/arcnet.cdev->mtu=493;  /* MTU is small because of missing packet splitting */
dev924drivers/net/arcnet.carcnet_open(struct device *dev)
dev926drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev928drivers/net/arcnet.cif (dev->metric>=1000)
dev930drivers/net/arcnet.carcnet_debug=dev->metric-1000;
dev932drivers/net/arcnet.cdev->metric=1;
dev937drivers/net/arcnet.cirq2dev_map[dev->irq] = dev;
dev942drivers/net/arcnet.cif (arcnet_reset(dev) && arcnet_reset(dev))
dev945drivers/net/arcnet.cdev->tbusy=0;
dev946drivers/net/arcnet.cdev->interrupt=0;
dev951drivers/net/arcnet.clp->adev=dev;
dev958drivers/net/arcnet.cmemcpy(lp->wdev,dev,sizeof(struct device));
dev960drivers/net/arcnet.csprintf(lp->wdev->name,"%sw",dev->name);
dev978drivers/net/arcnet.carcnet_close(struct device *dev)
dev980drivers/net/arcnet.cint ioaddr = dev->base_addr;
dev981drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev1024drivers/net/arcnet.carcnetA_send_packet(struct sk_buff *skb, struct device *dev)
dev1026drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev1027drivers/net/arcnet.cint ioaddr=dev->base_addr;
dev1046drivers/net/arcnet.cint tickssofar = jiffies - dev->trans_start;
dev1073drivers/net/arcnet.cdev->trans_start = jiffies;
dev1101drivers/net/arcnet.cinb(STATUS),lp->intx,jiffies-dev->trans_start);
dev1102drivers/net/arcnet.cdev_tint(dev);
dev1114drivers/net/arcnet.carcnet_inthandler(dev); /* fake an interrupt */
dev1124drivers/net/arcnet.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev1127drivers/net/arcnet.cinb(STATUS),lp->intx,jiffies-dev->trans_start);
dev1154drivers/net/arcnet.carcnetA_go_tx(dev);
dev1167drivers/net/arcnet.carcnetA_prepare_tx(dev,out->hdr,
dev1177drivers/net/arcnet.carcnetA_go_tx(dev);
dev1200drivers/net/arcnet.carcnetA_go_tx(dev);
dev1207drivers/net/arcnet.carcnetA_continue_tx(dev);
dev1210drivers/net/arcnet.carcnetA_go_tx(dev);
dev1211drivers/net/arcnet.carcnetA_continue_tx(dev);
dev1213drivers/net/arcnet.carcnetA_go_tx(dev);
dev1233drivers/net/arcnet.cdev->trans_start=jiffies;
dev1242drivers/net/arcnet.cstatic void arcnetA_continue_tx(struct device *dev)
dev1244drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev1272drivers/net/arcnet.carcnetA_prepare_tx(dev,out->hdr,out->seglen,out->data);
dev1284drivers/net/arcnet.carcnetA_prepare_tx(struct device *dev,struct ClientData *hdr,short length,
dev1287drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev1290drivers/net/arcnet.c(union ArcPacket *)(dev->mem_start+512*(lp->txbuf^1));
dev1305drivers/net/arcnet.cmemset((void *)dev->mem_start+lp->txbuf*512,0x42,512);
dev1385drivers/net/arcnet.carcnetA_go_tx(struct device *dev)
dev1387drivers/net/arcnet.cstruct arcnet_local *lp=(struct arcnet_local *)dev->priv;
dev1388drivers/net/arcnet.cint ioaddr=dev->base_addr;
dev1401drivers/net/arcnet.cdev->trans_start = jiffies;
dev1414drivers/net/arcnet.carcnetW_send_packet(struct sk_buff *skb, struct device *dev)
dev1416drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev1419drivers/net/arcnet.cprintk("%s: in arcnetW_send_packet (skb=%p)\n",dev->name,skb);
dev1425drivers/net/arcnet.cint tickssofar = jiffies - dev->trans_start;
dev1428drivers/net/arcnet.cprintk("%s: transmit timed out\n",dev->name);
dev1432drivers/net/arcnet.cdev->trans_start = jiffies;
dev1441drivers/net/arcnet.cdev_tint(dev);
dev1447drivers/net/arcnet.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev1448drivers/net/arcnet.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev1452drivers/net/arcnet.c(union ArcPacket *)(dev->mem_start+512*(lp->txbuf^1));
dev1475drivers/net/arcnet.cmemset((void *)dev->mem_start+lp->txbuf*512,0x42,512);
dev1539drivers/net/arcnet.carcnetA_go_tx(dev);
dev1540drivers/net/arcnet.cdev->trans_start = jiffies;
dev1564drivers/net/arcnet.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev1566drivers/net/arcnet.cif (dev==NULL || !dev->start)
dev1573drivers/net/arcnet.carcnet_inthandler(dev);
dev1581drivers/net/arcnet.carcnet_inthandler(struct device *dev)
dev1586drivers/net/arcnet.cif (dev->interrupt)
dev1589drivers/net/arcnet.cdev->interrupt = 1;
dev1591drivers/net/arcnet.cioaddr = dev->base_addr;
dev1592drivers/net/arcnet.clp = (struct arcnet_local *)dev->priv;
dev1605drivers/net/arcnet.cif (!dev->start)
dev1613drivers/net/arcnet.cdev->interrupt=0;
dev1651drivers/net/arcnet.carcnet_rx(dev,!recbuf);
dev1692drivers/net/arcnet.carcnetA_go_tx(dev);
dev1724drivers/net/arcnet.carcnetA_continue_tx(dev);
dev1726drivers/net/arcnet.carcnetA_go_tx(dev);
dev1757drivers/net/arcnet.cif (dev->start && lp->sending )
dev1762drivers/net/arcnet.cdev->interrupt=0;
dev1778drivers/net/arcnet.carcnet_rx(struct device *dev,int recbuf)
dev1780drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev1781drivers/net/arcnet.cint ioaddr = dev->base_addr;
dev1783drivers/net/arcnet.c(union ArcPacket *)(dev->mem_start+recbuf*512);
dev1826drivers/net/arcnet.carcnetA_rx(dev,(struct ClientData*)arcsoft,
dev1830drivers/net/arcnet.carcnetW_rx(dev,arcsoft,length,saddr,daddr);
dev1866drivers/net/arcnet.carcnetA_rx(struct device *dev,struct ClientData *arcsoft,
dev1869drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev1920drivers/net/arcnet.cskb->dev = dev;
dev1975drivers/net/arcnet.cskb->protocol=arcnetA_type_trans(skb,dev);
dev2047drivers/net/arcnet.cdev->name);
dev2060drivers/net/arcnet.cskb->dev=dev;
dev2139drivers/net/arcnet.cskb->protocol=arcnetA_type_trans(skb,dev);
dev2151drivers/net/arcnet.carcnetW_rx(struct device *dev,u_char *arcsoft,
dev2154drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev2169drivers/net/arcnet.cskb->dev = lp->wdev;
dev2187drivers/net/arcnet.cskb->protocol=eth_type_trans(skb,dev);
dev2206drivers/net/arcnet.carcnet_get_stats(struct device *dev)
dev2208drivers/net/arcnet.cstruct arcnet_local *lp = (struct arcnet_local *)dev->priv;
dev2220drivers/net/arcnet.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev2223drivers/net/arcnet.cstruct arcnet_local *lp=(struct arcnet_local *)(dev->priv);
dev2225drivers/net/arcnet.cshort ioaddr = dev->base_addr;
dev2238drivers/net/arcnet.cint arcnetA_header(struct sk_buff *skb,struct device *dev,unsigned short type,
dev2242drivers/net/arcnet.cskb_push(skb,dev->hard_header_len);
dev2280drivers/net/arcnet.chead->saddr=((u_char*)(dev->dev_addr))[0];
dev2289drivers/net/arcnet.cif (dev->flags & IFF_LOOPBACK) 
dev2292drivers/net/arcnet.creturn(dev->hard_header_len);
dev2303drivers/net/arcnet.creturn dev->hard_header_len;
dev2308drivers/net/arcnet.creturn -dev->hard_header_len;
dev2316drivers/net/arcnet.cint arcnetA_rebuild_header(void *buff,struct device *dev,unsigned long dst,
dev2338drivers/net/arcnet.creturn arp_find(&(head->daddr), dst, dev, dev->pa_addr, skb)? 1 : 0;
dev2348drivers/net/arcnet.cunsigned short arcnetA_type_trans(struct sk_buff *skb,struct device *dev)
dev2351drivers/net/arcnet.cstruct arcnet_local *lp=(struct arcnet_local *) (dev->priv);
dev2355drivers/net/arcnet.cskb_pull(skb,dev->hard_header_len);
dev2359drivers/net/arcnet.celse if (dev->flags&IFF_PROMISC)
dev2362drivers/net/arcnet.cif (head->daddr != dev->dev_addr[0])
dev55drivers/net/at1700.cextern struct device *init_etherdev(struct device *dev, int sizeof_private,
dev116drivers/net/at1700.cextern int at1700_probe(struct device *dev);
dev118drivers/net/at1700.cstatic int at1700_probe1(struct device *dev, short ioaddr);
dev120drivers/net/at1700.cstatic int net_open(struct device *dev);
dev121drivers/net/at1700.cstatic int  net_send_packet(struct sk_buff *skb, struct device *dev);
dev123drivers/net/at1700.cstatic void net_rx(struct device *dev);
dev124drivers/net/at1700.cstatic int net_close(struct device *dev);
dev125drivers/net/at1700.cstatic struct enet_statistics *net_get_stats(struct device *dev);
dev126drivers/net/at1700.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev142drivers/net/at1700.cat1700_probe(struct device *dev)
dev145drivers/net/at1700.cint base_addr = dev ? dev->base_addr : 0;
dev148drivers/net/at1700.creturn at1700_probe1(dev, base_addr);
dev156drivers/net/at1700.cif (at1700_probe1(dev, ioaddr) == 0)
dev172drivers/net/at1700.cint at1700_probe1(struct device *dev, short ioaddr)
dev204drivers/net/at1700.cif (dev == NULL)
dev205drivers/net/at1700.cdev = init_etherdev(0, sizeof(struct net_local), 0);
dev211drivers/net/at1700.cprintk("%s: AT1700 found at %#3x, IRQ %d, address ", dev->name,
dev214drivers/net/at1700.cdev->base_addr = ioaddr;
dev215drivers/net/at1700.cdev->irq = irq;
dev216drivers/net/at1700.cirq2dev_map[irq] = dev;
dev221drivers/net/at1700.c((unsigned short *)dev->dev_addr)[i] = ntohs(eeprom_val);
dev234drivers/net/at1700.cdev->if_port = setup_value >> 8;
dev235drivers/net/at1700.cprintk(" %s interface.\n", porttype[(dev->if_port>>3) & 3]);
dev241drivers/net/at1700.coutb(dev->dev_addr[i], ioaddr + 8 + i);
dev254drivers/net/at1700.coutb(dev->if_port, MODE13);
dev263drivers/net/at1700.cif (dev->priv == NULL)
dev264drivers/net/at1700.cdev->priv = kmalloc(sizeof(struct net_local), GFP_KERNEL);
dev265drivers/net/at1700.cmemset(dev->priv, 0, sizeof(struct net_local));
dev267drivers/net/at1700.cdev->open    = net_open;
dev268drivers/net/at1700.cdev->stop    = net_close;
dev269drivers/net/at1700.cdev->hard_start_xmit = net_send_packet;
dev270drivers/net/at1700.cdev->get_stats  = net_get_stats;
dev271drivers/net/at1700.cdev->set_multicast_list = &set_multicast_list;
dev275drivers/net/at1700.cether_setup(dev);
dev320drivers/net/at1700.cstatic int net_open(struct device *dev)
dev322drivers/net/at1700.cstruct net_local *lp = (struct net_local *)dev->priv;
dev323drivers/net/at1700.cint ioaddr = dev->base_addr;
dev331drivers/net/at1700.coutb(dev->dev_addr[i], ioaddr + 8 + i);
dev355drivers/net/at1700.cdev->tbusy = 0;
dev356drivers/net/at1700.cdev->interrupt = 0;
dev357drivers/net/at1700.cdev->start = 1;
dev363drivers/net/at1700.cnet_send_packet(struct sk_buff *skb, struct device *dev)
dev365drivers/net/at1700.cstruct net_local *lp = (struct net_local *)dev->priv;
dev366drivers/net/at1700.cint ioaddr = dev->base_addr;
dev368drivers/net/at1700.cif (dev->tbusy) {
dev371drivers/net/at1700.cint tickssofar = jiffies - dev->trans_start;
dev374drivers/net/at1700.cprintk("%s: transmit timed out with status %04x, %s?\n", dev->name,
dev378drivers/net/at1700.cdev->name, inw(ioaddr + 0), inw(ioaddr + 2), inw(ioaddr + 4),
dev387drivers/net/at1700.cdev->tbusy=0;
dev388drivers/net/at1700.cdev->trans_start = jiffies;
dev398drivers/net/at1700.cdev_tint(dev);
dev404drivers/net/at1700.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev405drivers/net/at1700.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev424drivers/net/at1700.cdev->trans_start = jiffies;
dev426drivers/net/at1700.cdev->tbusy = 0;
dev429drivers/net/at1700.cdev->tbusy = 0;
dev444drivers/net/at1700.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev448drivers/net/at1700.cif (dev == NULL) {
dev452drivers/net/at1700.cdev->interrupt = 1;
dev454drivers/net/at1700.cioaddr = dev->base_addr;
dev455drivers/net/at1700.clp = (struct net_local *)dev->priv;
dev460drivers/net/at1700.cprintk("%s: Interrupt with status %04x.\n", dev->name, status);
dev463drivers/net/at1700.cnet_rx(dev);
dev472drivers/net/at1700.cdev->trans_start = jiffies;
dev473drivers/net/at1700.cdev->tbusy = 0;
dev479drivers/net/at1700.cdev->tbusy = 0;
dev485drivers/net/at1700.cdev->interrupt = 0;
dev491drivers/net/at1700.cnet_rx(struct device *dev)
dev493drivers/net/at1700.cstruct net_local *lp = (struct net_local *)dev->priv;
dev494drivers/net/at1700.cint ioaddr = dev->base_addr;
dev503drivers/net/at1700.cdev->name, inb(ioaddr + RX_MODE), status);
dev523drivers/net/at1700.cdev->name, pkt_len);
dev533drivers/net/at1700.cdev->name, pkt_len);
dev540drivers/net/at1700.cskb->dev = dev;
dev544drivers/net/at1700.cskb->protocol=eth_type_trans(skb, dev);
dev566drivers/net/at1700.cdev->name, inb(ioaddr + RX_MODE), i);
dev572drivers/net/at1700.cstatic int net_close(struct device *dev)
dev574drivers/net/at1700.cstruct net_local *lp = (struct net_local *)dev->priv;
dev575drivers/net/at1700.cint ioaddr = dev->base_addr;
dev577drivers/net/at1700.cdev->tbusy = 1;
dev578drivers/net/at1700.cdev->start = 0;
dev594drivers/net/at1700.cnet_get_stats(struct device *dev)
dev596drivers/net/at1700.cstruct net_local *lp = (struct net_local *)dev->priv;
dev612drivers/net/at1700.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev614drivers/net/at1700.cshort ioaddr = dev->base_addr;
dev128drivers/net/atp.cextern int atp_probe(struct device *dev);
dev130drivers/net/atp.cstatic int atp_probe1(struct device *dev, short ioaddr);
dev131drivers/net/atp.cstatic void get_node_ID(struct device *dev);
dev133drivers/net/atp.cstatic int net_open(struct device *dev);
dev134drivers/net/atp.cstatic void hardware_init(struct device *dev);
dev137drivers/net/atp.cstatic int  net_send_packet(struct sk_buff *skb, struct device *dev);
dev139drivers/net/atp.cstatic void net_rx(struct device *dev);
dev141drivers/net/atp.cstatic int net_close(struct device *dev);
dev142drivers/net/atp.cstatic struct enet_statistics *net_get_stats(struct device *dev);
dev143drivers/net/atp.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev153drivers/net/atp.catp_init(struct device *dev)
dev156drivers/net/atp.cint base_addr = dev->base_addr;
dev159drivers/net/atp.creturn atp_probe1(dev, base_addr);
dev168drivers/net/atp.cif (atp_probe1(dev, ioaddr) == 0)
dev175drivers/net/atp.cstatic int atp_probe1(struct device *dev, short ioaddr)
dev205drivers/net/atp.cdev->irq = 7;
dev207drivers/net/atp.cdev->irq = 5;
dev211drivers/net/atp.cdev->base_addr = ioaddr;
dev214drivers/net/atp.cget_node_ID(dev);
dev217drivers/net/atp.c"%02X:%02X:%02X:%02X:%02X:%02X.\n", dev->name, dev->base_addr,
dev218drivers/net/atp.cdev->irq, dev->dev_addr[0], dev->dev_addr[1], dev->dev_addr[2],
dev219drivers/net/atp.cdev->dev_addr[3], dev->dev_addr[4], dev->dev_addr[5]);
dev228drivers/net/atp.cether_setup(dev);
dev229drivers/net/atp.cdev->priv = kmalloc(sizeof(struct net_local), GFP_KERNEL);
dev230drivers/net/atp.cmemset(dev->priv, 0, sizeof(struct net_local));
dev234drivers/net/atp.cstruct net_local *lp = (struct net_local *)dev->priv;
dev239drivers/net/atp.cdev->if_port = (dev->mem_start & 0xf) ? dev->mem_start & 0x7 : 4;
dev240drivers/net/atp.cif (dev->mem_end & 0xf)
dev241drivers/net/atp.cnet_debug = dev->mem_end & 7;
dev243drivers/net/atp.cdev->open    = net_open;
dev244drivers/net/atp.cdev->stop    = net_close;
dev245drivers/net/atp.cdev->hard_start_xmit = net_send_packet;
dev246drivers/net/atp.cdev->get_stats  = net_get_stats;
dev247drivers/net/atp.cdev->set_multicast_list = &set_multicast_list;
dev252drivers/net/atp.catp_timed_dev = dev;
dev259drivers/net/atp.cstatic void get_node_ID(struct device *dev)
dev261drivers/net/atp.cshort ioaddr = dev->base_addr;
dev273drivers/net/atp.c((unsigned short *)dev->dev_addr)[i] =
dev321drivers/net/atp.cstatic int net_open(struct device *dev)
dev327drivers/net/atp.cif (irq2dev_map[dev->irq] != 0
dev328drivers/net/atp.c|| (irq2dev_map[dev->irq] = dev) == 0
dev329drivers/net/atp.c|| request_irq(dev->irq, &net_interrupt, 0, "ATP")) {
dev333drivers/net/atp.chardware_init(dev);
dev334drivers/net/atp.cdev->start = 1;
dev340drivers/net/atp.cstatic void hardware_init(struct device *dev)
dev342drivers/net/atp.cstruct net_local *lp = (struct net_local *)dev->priv;
dev343drivers/net/atp.cint ioaddr = dev->base_addr;
dev349drivers/net/atp.cwrite_reg_byte(ioaddr, PAR0 + i, dev->dev_addr[i]);
dev354drivers/net/atp.cprintk("%s: Reset: current Rx mode %d.\n", dev->name,
dev372drivers/net/atp.cdev->tbusy = 0;
dev373drivers/net/atp.cdev->interrupt = 0;
dev414drivers/net/atp.cnet_send_packet(struct sk_buff *skb, struct device *dev)
dev416drivers/net/atp.cstruct net_local *lp = (struct net_local *)dev->priv;
dev417drivers/net/atp.cint ioaddr = dev->base_addr;
dev419drivers/net/atp.cif (dev->tbusy) {
dev422drivers/net/atp.cint tickssofar = jiffies - dev->trans_start;
dev425drivers/net/atp.cprintk("%s: transmit timed out, %s?\n", dev->name,
dev430drivers/net/atp.chardware_init(dev);
dev431drivers/net/atp.cdev->tbusy=0;
dev432drivers/net/atp.cdev->trans_start = jiffies;
dev439drivers/net/atp.cdev_tint(dev);
dev445drivers/net/atp.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev446drivers/net/atp.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev460drivers/net/atp.cwrite_packet(ioaddr, length, buf, dev->if_port);
dev471drivers/net/atp.cdev->trans_start = jiffies;
dev487drivers/net/atp.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev492drivers/net/atp.cif (dev == NULL) {
dev496drivers/net/atp.cdev->interrupt = 1;
dev498drivers/net/atp.cioaddr = dev->base_addr;
dev499drivers/net/atp.clp = (struct net_local *)dev->priv;
dev508drivers/net/atp.cif (net_debug > 5) printk("%s: In interrupt ", dev->name);
dev525drivers/net/atp.cnet_rx(dev);
dev530drivers/net/atp.cnet_rx(dev);
dev531drivers/net/atp.cdev->last_rx = jiffies;
dev545drivers/net/atp.chardware_init(dev);
dev561drivers/net/atp.cdev->tbusy = 0;
dev566drivers/net/atp.c&& jiffies > dev->last_rx + 100) {
dev569drivers/net/atp.c" status %02x  CMR1 %02x.\n", dev->name,
dev570drivers/net/atp.cnum_tx_since_rx, jiffies - dev->last_rx, status,
dev573drivers/net/atp.chardware_init(dev);
dev585drivers/net/atp.cwrite_reg_byte(ioaddr, PAR0 + i, dev->dev_addr[i]);
dev603drivers/net/atp.cdev->interrupt = 0;
dev644drivers/net/atp.cstatic void net_rx(struct device *dev)
dev646drivers/net/atp.cstruct net_local *lp = (struct net_local *)dev->priv;
dev647drivers/net/atp.cint ioaddr = dev->base_addr;
dev656drivers/net/atp.cread_block(ioaddr, 8, (unsigned char*)&rx_head, dev->if_port);
dev665drivers/net/atp.cdev->name, rx_head.rx_status);
dev666drivers/net/atp.chardware_init(dev);
dev675drivers/net/atp.cprintk("%s: Memory squeeze, dropping packet.\n", dev->name);
dev679drivers/net/atp.cskb->dev = dev;
dev681drivers/net/atp.cread_block(ioaddr, pkt_len, skb_put(skb,pkt_len), dev->if_port);
dev692drivers/net/atp.cskb->protocol=eth_type_trans(skb,dev);
dev723drivers/net/atp.cnet_close(struct device *dev)
dev725drivers/net/atp.cstruct net_local *lp = (struct net_local *)dev->priv;
dev726drivers/net/atp.cint ioaddr = dev->base_addr;
dev728drivers/net/atp.cdev->tbusy = 1;
dev729drivers/net/atp.cdev->start = 0;
dev737drivers/net/atp.cfree_irq(dev->irq);
dev738drivers/net/atp.cirq2dev_map[dev->irq] = 0;
dev749drivers/net/atp.cnet_get_stats(struct device *dev)
dev751drivers/net/atp.cstruct net_local *lp = (struct net_local *)dev->priv;
dev762drivers/net/atp.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev764drivers/net/atp.cstruct net_local *lp = (struct net_local *)dev->priv;
dev765drivers/net/atp.cshort ioaddr = dev->base_addr;
dev404drivers/net/de4x5.cstatic int     de4x5_open(struct device *dev);
dev405drivers/net/de4x5.cstatic int     de4x5_queue_pkt(struct sk_buff *skb, struct device *dev);
dev407drivers/net/de4x5.cstatic int     de4x5_close(struct device *dev);
dev408drivers/net/de4x5.cstatic struct  enet_statistics *de4x5_get_stats(struct device *dev);
dev409drivers/net/de4x5.cstatic void    set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev410drivers/net/de4x5.cstatic int     de4x5_ioctl(struct device *dev, struct ifreq *rq, int cmd);
dev415drivers/net/de4x5.cstatic int     de4x5_hw_init(struct device *dev, u_long iobase);
dev416drivers/net/de4x5.cstatic int     de4x5_init(struct device *dev);
dev417drivers/net/de4x5.cstatic int     de4x5_rx(struct device *dev);
dev418drivers/net/de4x5.cstatic int     de4x5_tx(struct device *dev);
dev419drivers/net/de4x5.cstatic int     de4x5_ast(struct device *dev);
dev421drivers/net/de4x5.cstatic int     autoconf_media(struct device *dev);
dev422drivers/net/de4x5.cstatic void    create_packet(struct device *dev, char *frame, int len);
dev425drivers/net/de4x5.cstatic void    load_packet(struct device *dev, char *buf, u32 flags, struct sk_buff *skb);
dev426drivers/net/de4x5.cstatic void    dc21040_autoconf(struct device *dev);
dev427drivers/net/de4x5.cstatic void    dc21041_autoconf(struct device *dev);
dev428drivers/net/de4x5.cstatic void    dc21140_autoconf(struct device *dev);
dev429drivers/net/de4x5.cstatic int     test_media(struct device *dev, s32 irqs, s32 irq_mask, s32 csr13, s32 csr14, s32 csr15, s32 msec);
dev431drivers/net/de4x5.cstatic int     ping_media(struct device *dev);
dev432drivers/net/de4x5.cstatic void    reset_init_sia(struct device *dev, s32 sicr, s32 strr, s32 sigr);
dev433drivers/net/de4x5.cstatic int     test_ans(struct device *dev, s32 irqs, s32 irq_mask, s32 msec);
dev434drivers/net/de4x5.cstatic void    load_ms_timer(struct device *dev, u32 msec);
dev445drivers/net/de4x5.cstatic void    SetMulticastFilter(struct device *dev, int num_addrs, char *addrs);
dev446drivers/net/de4x5.cstatic int     get_hw_addr(struct device *dev);
dev448drivers/net/de4x5.cstatic void    eisa_probe(struct device *dev, u_long iobase);
dev449drivers/net/de4x5.cstatic void    pci_probe(struct device *dev, u_long iobase);
dev450drivers/net/de4x5.cstatic struct  device *alloc_device(struct device *dev, u_long iobase);
dev451drivers/net/de4x5.cstatic char    *build_setup_frame(struct device *dev, int mode);
dev452drivers/net/de4x5.cstatic void    disable_ast(struct device *dev);
dev453drivers/net/de4x5.cstatic void    enable_ast(struct device *dev, u32 time_out);
dev454drivers/net/de4x5.cstatic void    kick_tx(struct device *dev);
dev499drivers/net/de4x5.cint de4x5_probe(struct device *dev)
dev502drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev508drivers/net/de4x5.ceisa_probe(dev, iobase);
dev509drivers/net/de4x5.cpci_probe(dev, iobase);
dev512drivers/net/de4x5.cprintk("%s: de4x5_probe() cannot find device at 0x%04lx.\n", dev->name, 
dev520drivers/net/de4x5.cfor (; (dev->priv == NULL) && (dev->next != NULL); dev = dev->next);
dev522drivers/net/de4x5.cif (dev->priv) status = 0;
dev530drivers/net/de4x5.cde4x5_hw_init(struct device *dev, u_long iobase)
dev563drivers/net/de4x5.cdev->base_addr = iobase;
dev566drivers/net/de4x5.cdev->name, name, iobase, ((iobase>>12)&0x0f));
dev568drivers/net/de4x5.cprintk("%s: %s at %04lx (PCI bus %d, device %d)", dev->name, name,
dev573drivers/net/de4x5.cstatus = get_hw_addr(dev);
dev575drivers/net/de4x5.cprintk("%2.2x:", dev->dev_addr[i]);
dev577drivers/net/de4x5.cprintk("%2.2x,\n", dev->dev_addr[i]);
dev589drivers/net/de4x5.cdev->priv = (void *) kmalloc(sizeof(struct de4x5_private) + ALIGN, 
dev594drivers/net/de4x5.cdev->priv = (void *)(((u_long)dev->priv + ALIGN) & ~ALIGN);
dev595drivers/net/de4x5.clp = (struct de4x5_private *)dev->priv;
dev596drivers/net/de4x5.cmemset(dev->priv, 0, sizeof(struct de4x5_private));
dev619drivers/net/de4x5.csprintf(lp->adapter_name,"%s (%s)", name, dev->name);
dev661drivers/net/de4x5.cif (dev->irq < 2) {
dev676drivers/net/de4x5.cfor (dev->irq=0,i=0; (i<sizeof(de4x5_irq)) && (!dev->irq); i++) {
dev678drivers/net/de4x5.cdev->irq = irqnum;
dev679drivers/net/de4x5.cprintk("      and uses IRQ%d.\n", dev->irq);
dev683drivers/net/de4x5.cif (!dev->irq) {
dev693drivers/net/de4x5.cprintk("      and requires IRQ%d (not probed).\n", dev->irq);
dev697drivers/net/de4x5.cdev->name);
dev720drivers/net/de4x5.cdev->open = &de4x5_open;
dev721drivers/net/de4x5.cdev->hard_start_xmit = &de4x5_queue_pkt;
dev722drivers/net/de4x5.cdev->stop = &de4x5_close;
dev723drivers/net/de4x5.cdev->get_stats = &de4x5_get_stats;
dev725drivers/net/de4x5.cdev->set_multicast_list = &set_multicast_list;
dev727drivers/net/de4x5.cdev->do_ioctl = &de4x5_ioctl;
dev729drivers/net/de4x5.cdev->mem_start = 0;
dev732drivers/net/de4x5.cether_setup(dev);
dev740drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev745drivers/net/de4x5.cif (dev->priv) {
dev746drivers/net/de4x5.ckfree_s(dev->priv, sizeof(struct de4x5_private) + ALIGN);
dev747drivers/net/de4x5.cdev->priv = NULL;
dev756drivers/net/de4x5.cde4x5_open(struct device *dev)
dev758drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev759drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev771drivers/net/de4x5.cif (request_irq(dev->irq, (void *)de4x5_interrupt, 0, lp->adapter_name)) {
dev772drivers/net/de4x5.cprintk("de4x5_open(): Requested IRQ%d is busy\n",dev->irq);
dev776drivers/net/de4x5.cirq2dev_map[dev->irq] = dev;
dev780drivers/net/de4x5.cstatus = de4x5_init(dev);
dev783drivers/net/de4x5.cprintk("%s: de4x5 open with irq %d\n",dev->name,dev->irq);
dev786drivers/net/de4x5.cprintk("%2.2x:",(short)dev->dev_addr[i]);
dev826drivers/net/de4x5.cdev->tbusy = 0;                         
dev827drivers/net/de4x5.cdev->start = 1;
dev828drivers/net/de4x5.cdev->interrupt = UNMASK_INTERRUPTS;
dev829drivers/net/de4x5.cdev->trans_start = jiffies;
dev869drivers/net/de4x5.cde4x5_init(struct device *dev)
dev871drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev872drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev877drivers/net/de4x5.cset_bit(0, (void *)&dev->tbusy);
dev909drivers/net/de4x5.cSetMulticastFilter(dev, 0, NULL);
dev912drivers/net/de4x5.cload_packet(dev, lp->setup_frame, HASH_F|TD_SET|SETUP_FRAME_LEN, NULL);
dev914drivers/net/de4x5.cload_packet(dev, lp->setup_frame, PERFECT_F|TD_SET|SETUP_FRAME_LEN, NULL);
dev925drivers/net/de4x5.cprintk("%s: Setup frame timed out, status %08x\n", dev->name, 
dev934drivers/net/de4x5.cif (autoconf_media(dev) == 0) {
dev945drivers/net/de4x5.cde4x5_queue_pkt(struct sk_buff *skb, struct device *dev)
dev947drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev948drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev957drivers/net/de4x5.cif (set_bit(0, (void*)&dev->tbusy) == 0) {
dev959drivers/net/de4x5.cde4x5_tx(dev);
dev960drivers/net/de4x5.cdev->tbusy = 0;
dev969drivers/net/de4x5.cif (dev->tbusy || (lp->lostMedia > LOST_MEDIA_THRESHOLD)) {
dev970drivers/net/de4x5.cu_long tickssofar = jiffies - dev->trans_start;
dev976drivers/net/de4x5.cprintk("%s: transmit timed out, status %08x, tbusy:%ld, lostMedia:%d tickssofar:%ld, resetting.\n",dev->name, inl(DE4X5_STS), dev->tbusy, lp->lostMedia, tickssofar);
dev987drivers/net/de4x5.cdev_queue_xmit(lp->skb[i], dev, SOPRI_NORMAL);
dev998drivers/net/de4x5.cdev_queue_xmit(skb, dev, SOPRI_NORMAL);
dev1004drivers/net/de4x5.cstatus = de4x5_init(dev);
dev1009drivers/net/de4x5.cdev->interrupt = UNMASK_INTERRUPTS;
dev1010drivers/net/de4x5.cdev->start = 1;
dev1011drivers/net/de4x5.cdev->tbusy = 0;                         
dev1012drivers/net/de4x5.cdev->trans_start = jiffies;
dev1027drivers/net/de4x5.cdev->name, inl(DE4X5_STS));
dev1031drivers/net/de4x5.cdev_tint(dev);
dev1036drivers/net/de4x5.cif (set_bit(0, (void*)&dev->tbusy) != 0) { 
dev1037drivers/net/de4x5.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev1042drivers/net/de4x5.cload_packet(dev, skb->data, TD_IC | TD_LS | TD_FS | skb->len, skb);
dev1048drivers/net/de4x5.cdev->trans_start = jiffies;
dev1051drivers/net/de4x5.cdev->tbusy = 0;                      /* Another pkt may be queued */
dev1077drivers/net/de4x5.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev1082drivers/net/de4x5.cif (dev == NULL) {
dev1085drivers/net/de4x5.clp = (struct de4x5_private *)dev->priv;
dev1086drivers/net/de4x5.ciobase = dev->base_addr;
dev1088drivers/net/de4x5.cif (dev->interrupt)
dev1089drivers/net/de4x5.cprintk("%s: Re-entering the interrupt handler.\n", dev->name);
dev1092drivers/net/de4x5.cdev->interrupt = MASK_INTERRUPTS;
dev1098drivers/net/de4x5.cde4x5_rx(dev);
dev1101drivers/net/de4x5.cde4x5_tx(dev); 
dev1104drivers/net/de4x5.cde4x5_ast(dev);
dev1109drivers/net/de4x5.ckick_tx(dev);
dev1115drivers/net/de4x5.cdev->name, sts);
dev1119drivers/net/de4x5.cif (TX_BUFFS_AVAIL && dev->tbusy) {/* Any resources available? */
dev1120drivers/net/de4x5.cdev->tbusy = 0;                  /* Clear TX busy flag */
dev1124drivers/net/de4x5.cdev->interrupt = UNMASK_INTERRUPTS;
dev1132drivers/net/de4x5.cde4x5_rx(struct device *dev)
dev1134drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1157drivers/net/de4x5.cskb->dev = dev;
dev1169drivers/net/de4x5.cskb->protocol=eth_type_trans(skb,dev);
dev1187drivers/net/de4x5.c} else if ((*(s32 *)&buf[0] == *(s32 *)&dev->dev_addr[0]) &&
dev1188drivers/net/de4x5.c(*(s16 *)&buf[4] == *(s16 *)&dev->dev_addr[4])) {
dev1197drivers/net/de4x5.cprintk("%s: Insufficient memory; nuking packet.\n", dev->name);
dev1225drivers/net/de4x5.cde4x5_tx(struct device *dev)
dev1227drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1228drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1249drivers/net/de4x5.ckick_tx(dev);
dev1272drivers/net/de4x5.cde4x5_ast(struct device *dev)
dev1274drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1275drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1278drivers/net/de4x5.cdisable_ast(dev);
dev1289drivers/net/de4x5.ckick_tx(dev);
dev1294drivers/net/de4x5.cenable_ast(dev, DE4X5_AUTOSENSE_MS);
dev1299drivers/net/de4x5.cenable_ast(dev, 1500);
dev1304drivers/net/de4x5.cenable_ast(dev, 4000);
dev1310drivers/net/de4x5.cenable_ast(dev, DE4X5_AUTOSENSE_MS);
dev1318drivers/net/de4x5.cde4x5_close(struct device *dev)
dev1320drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1321drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1324drivers/net/de4x5.cdev->start = 0;
dev1325drivers/net/de4x5.cdev->tbusy = 1;
dev1329drivers/net/de4x5.cdev->name, inl(DE4X5_STS));
dev1342drivers/net/de4x5.cfree_irq(dev->irq);
dev1343drivers/net/de4x5.cirq2dev_map[dev->irq] = 0;
dev1357drivers/net/de4x5.cde4x5_get_stats(struct device *dev)
dev1359drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1360drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1367drivers/net/de4x5.cstatic void load_packet(struct device *dev, char *buf, u32 flags, struct sk_buff *skb)
dev1369drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1392drivers/net/de4x5.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev1394drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1395drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1398drivers/net/de4x5.cif (irq2dev_map[dev->irq] != NULL) {
dev1400drivers/net/de4x5.cSetMulticastFilter(dev, num_addrs, (char *)addrs);
dev1402drivers/net/de4x5.cload_packet(dev, lp->setup_frame, TD_IC | HASH_F | TD_SET | 
dev1405drivers/net/de4x5.cload_packet(dev, lp->setup_frame, TD_IC | PERFECT_F | TD_SET | 
dev1411drivers/net/de4x5.cdev->trans_start = jiffies;
dev1423drivers/net/de4x5.cstatic void SetMulticastFilter(struct device *dev, int num_addrs, char *addrs)
dev1425drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1426drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1433drivers/net/de4x5.cpa = build_setup_frame(dev, ALL);          /* Build the basic frame */
dev1484drivers/net/de4x5.cstatic void eisa_probe(struct device *dev, u_long ioaddr)
dev1508drivers/net/de4x5.cfor (status = -ENODEV; (i<maxSlots) && (dev!=NULL); i++, iobase+=EISA_SLOT_INC) {
dev1523drivers/net/de4x5.cif ((dev = alloc_device(dev, iobase)) != NULL) {
dev1524drivers/net/de4x5.cif ((status = de4x5_hw_init(dev, iobase)) == 0) {
dev1530drivers/net/de4x5.cprintk("%s: region already allocated at 0x%04lx.\n", dev->name, iobase);
dev1554drivers/net/de4x5.cstatic void pci_probe(struct device *dev, u_long ioaddr)
dev1610drivers/net/de4x5.cif ((dev = alloc_device(dev, iobase)) != NULL) {
dev1611drivers/net/de4x5.cdev->irq = irq;
dev1612drivers/net/de4x5.cif ((status = de4x5_hw_init(dev, iobase)) == 0) {
dev1618drivers/net/de4x5.cprintk("%s: region already allocated at 0x%04x.\n", dev->name, (u_short)iobase);
dev1635drivers/net/de4x5.cstatic struct device *alloc_device(struct device *dev, u_long iobase)
dev1645drivers/net/de4x5.cwhile (dev->next != NULL) {
dev1646drivers/net/de4x5.cif ((dev->base_addr == DE4X5_NDA) || (dev->base_addr == 0)) break;
dev1647drivers/net/de4x5.cdev = dev->next;                     /* walk through eth device list */
dev1655drivers/net/de4x5.cif ((dev->base_addr == 0) && (num_de4x5s > 0)) {
dev1657drivers/net/de4x5.ctmp = dev->next;                     /* point to the next device */
dev1658drivers/net/de4x5.cinit = dev->init;                    /* remember the probe function */
dev1665drivers/net/de4x5.cif ((dev->next == NULL) &&  
dev1666drivers/net/de4x5.c!((dev->base_addr == DE4X5_NDA) || (dev->base_addr == 0))){
dev1667drivers/net/de4x5.cdev->next = (struct device *)kmalloc(sizeof(struct device) + 8,
dev1670drivers/net/de4x5.cdev = dev->next;                     /* point to the new device */
dev1671drivers/net/de4x5.cif (dev == NULL) {
dev1680drivers/net/de4x5.cdev->name = (char *)(dev + sizeof(struct device));
dev1682drivers/net/de4x5.csprintf(dev->name,"eth????");    /* New device name */
dev1684drivers/net/de4x5.csprintf(dev->name,"eth%d", num_eth);/* New device name */
dev1686drivers/net/de4x5.cdev->base_addr = iobase;           /* assign the io address */
dev1687drivers/net/de4x5.cdev->next = NULL;                  /* mark the end of list */
dev1688drivers/net/de4x5.cdev->init = &de4x5_probe;          /* initialisation routine */
dev1692drivers/net/de4x5.cret = dev;                             /* return current struct, or NULL */
dev1712drivers/net/de4x5.cdev->name);
dev1735drivers/net/de4x5.cret = dev;
dev1747drivers/net/de4x5.cstatic int autoconf_media(struct device *dev)
dev1749drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1750drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1755drivers/net/de4x5.cprintk("%s: Searching for media... ",dev->name);
dev1757drivers/net/de4x5.cprintk("%s: Searching for mode... ",dev->name);
dev1763drivers/net/de4x5.cdc21040_autoconf(dev);
dev1766drivers/net/de4x5.cdc21041_autoconf(dev);
dev1768drivers/net/de4x5.cdisable_ast(dev);
dev1770drivers/net/de4x5.cdc21140_autoconf(dev);
dev1803drivers/net/de4x5.cstatic void dc21040_autoconf(struct device *dev)
dev1805drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1806drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1812drivers/net/de4x5.creset_init_sia(dev, 0x8f01, 0xffff, 0x0000);
dev1819drivers/net/de4x5.cdc21040_autoconf(dev);
dev1826drivers/net/de4x5.creset_init_sia(dev, 0x8f09, 0x0705, 0x0006);
dev1828drivers/net/de4x5.clinkBad = ping_media(dev);
dev1831drivers/net/de4x5.cdc21040_autoconf(dev);
dev1837drivers/net/de4x5.creset_init_sia(dev, 0x8f01, 0xffff, 0x0000);
dev1841drivers/net/de4x5.creset_init_sia(dev, 0x8f09, 0x0705, 0x0006);
dev1854drivers/net/de4x5.cstatic void dc21041_autoconf(struct device *dev)
dev1856drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1857drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1866drivers/net/de4x5.csts = test_media(dev, irqs, irq_mask, 0xef01, 0xffff, 0x0008, 2400);
dev1872drivers/net/de4x5.cdc21041_autoconf(dev);
dev1878drivers/net/de4x5.csts = test_ans(dev, irqs, irq_mask, 3000);
dev1881drivers/net/de4x5.cdc21041_autoconf(dev);
dev1890drivers/net/de4x5.csts = test_media(dev, irqs, irq_mask, 0xef01, 0xff3f, 0x0008, 2400);
dev1897drivers/net/de4x5.cdc21041_autoconf(dev);
dev1906drivers/net/de4x5.csts = test_media(dev, irqs, irq_mask, 0xef09, 0xf7fd, 0x000e, 1000);
dev1909drivers/net/de4x5.cdc21041_autoconf(dev);
dev1918drivers/net/de4x5.csts = test_media(dev, irqs, irq_mask, 0xef09, 0xf7fd, 0x0006, 1000);
dev1922drivers/net/de4x5.cif (ping_media(dev)) lp->media = NC;
dev1929drivers/net/de4x5.creset_init_sia(dev, 0xef01, 0xffff, 0x0008);/* Initialise the SIA */
dev1939drivers/net/de4x5.cstatic void dc21140_autoconf(struct device *dev)
dev1941drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1942drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1965drivers/net/de4x5.ctest_media(struct device *dev, s32 irqs, s32 irq_mask, s32 csr13, s32 csr14, s32 csr15, s32 msec)
dev1967drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev1968drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev1971drivers/net/de4x5.creset_init_sia(dev, csr13, csr14, csr15);
dev1974drivers/net/de4x5.cload_ms_timer(dev, msec);
dev2017drivers/net/de4x5.cstatic int ping_media(struct device *dev)
dev2019drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2020drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2025drivers/net/de4x5.ccreate_packet(dev, frame, sizeof(frame));
dev2028drivers/net/de4x5.cload_packet(dev, frame, TD_LS | TD_FS | sizeof(frame),NULL);
dev2051drivers/net/de4x5.cstatic int test_ans(struct device *dev, s32 irqs, s32 irq_mask, s32 msec)
dev2053drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2054drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2060drivers/net/de4x5.cload_ms_timer(dev, msec);
dev2078drivers/net/de4x5.cstatic void reset_init_sia(struct device *dev, s32 sicr, s32 strr, s32 sigr)
dev2080drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2081drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2094drivers/net/de4x5.cstatic void load_ms_timer(struct device *dev, u32 msec)
dev2096drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2097drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2117drivers/net/de4x5.cstatic void create_packet(struct device *dev, char *frame, int len)
dev2123drivers/net/de4x5.c*buf++ = dev->dev_addr[i];
dev2126drivers/net/de4x5.c*buf++ = dev->dev_addr[i];
dev2214drivers/net/de4x5.c} dev;
dev2220drivers/net/de4x5.cdev.llsig.a = ETH_PROM_SIG;
dev2221drivers/net/de4x5.cdev.llsig.b = ETH_PROM_SIG;
dev2232drivers/net/de4x5.cif (dev.Sig[j] == data) {   /* track signature */
dev2235drivers/net/de4x5.cif (data == dev.Sig[0]) {
dev2257drivers/net/de4x5.cstatic int get_hw_addr(struct device *dev)
dev2259drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2272drivers/net/de4x5.cdev->dev_addr[i++] = (u_char) tmp;
dev2275drivers/net/de4x5.cdev->dev_addr[i++] = (u_char) tmp;
dev2277drivers/net/de4x5.cdev->dev_addr[i] = (u_char) lp->srom.ieee_addr[i]; i++;
dev2278drivers/net/de4x5.cdev->dev_addr[i] = (u_char) lp->srom.ieee_addr[i]; i++;
dev2282drivers/net/de4x5.cdev->dev_addr[i++] = (u_char) tmp;
dev2284drivers/net/de4x5.cdev->dev_addr[i++] = (u_char) tmp;
dev2413drivers/net/de4x5.cstatic char *build_setup_frame(struct device *dev, int mode)
dev2415drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2426drivers/net/de4x5.c*(pa + i) = dev->dev_addr[i];                 /* Host address */
dev2432drivers/net/de4x5.c*(pa + (i&1)) = dev->dev_addr[i];
dev2444drivers/net/de4x5.cstatic void enable_ast(struct device *dev, u32 time_out)
dev2446drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2447drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2451drivers/net/de4x5.cload_ms_timer(dev, time_out);
dev2456drivers/net/de4x5.cstatic void disable_ast(struct device *dev)
dev2458drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2459drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2463drivers/net/de4x5.cload_ms_timer(dev, 0);
dev2468drivers/net/de4x5.cstatic void kick_tx(struct device *dev)
dev2475drivers/net/de4x5.cskb->dev=dev;
dev2476drivers/net/de4x5.cdev_queue_xmit(skb, dev, SOPRI_NORMAL);
dev2486drivers/net/de4x5.cstatic int de4x5_ioctl(struct device *dev, struct ifreq *rq, int cmd)
dev2488drivers/net/de4x5.cstruct de4x5_private *lp = (struct de4x5_private *)dev->priv;
dev2490drivers/net/de4x5.cu_long iobase = dev->base_addr;
dev2506drivers/net/de4x5.ctmp.addr[i] = dev->dev_addr[i];
dev2521drivers/net/de4x5.cdev->dev_addr[i] = tmp.addr[i];
dev2523drivers/net/de4x5.cbuild_setup_frame(dev, PHYS_ADDR_ONLY);
dev2525drivers/net/de4x5.cwhile (set_bit(0, (void *)&dev->tbusy) != 0);/* Wait for lock to free*/
dev2527drivers/net/de4x5.cload_packet(dev, lp->setup_frame, TD_IC | HASH_F | TD_SET | 
dev2530drivers/net/de4x5.cload_packet(dev, lp->setup_frame, TD_IC | PERFECT_F | TD_SET | 
dev2535drivers/net/de4x5.cdev->tbusy = 0;                              /* Unlock the TX ring */
dev2559drivers/net/de4x5.cprintk("%s: Boo!\n", dev->name);
dev2575drivers/net/de4x5.cset_multicast_list(dev, ioc->len, tmp.addr);
dev2578drivers/net/de4x5.cset_multicast_list(dev, ioc->len, NULL);
dev2587drivers/net/de4x5.cset_multicast_list(dev, 0, NULL);
dev2662drivers/net/de4x5.ctmp.addr[j++] = dev->irq;
dev2664drivers/net/de4x5.ctmp.addr[j++] = dev->dev_addr[i];
dev2713drivers/net/de4x5.ctmp.addr[j++] = dev->tbusy;
dev243drivers/net/de600.cstatic byte  de600_read_status(struct device *dev);
dev244drivers/net/de600.cstatic byte  de600_read_byte(unsigned char type, struct device *dev);
dev247drivers/net/de600.cstatic int  de600_open(struct device *dev);
dev248drivers/net/de600.cstatic int  de600_close(struct device *dev);
dev249drivers/net/de600.cstatic struct netstats *get_stats(struct device *dev);
dev250drivers/net/de600.cstatic int  de600_start_xmit(struct sk_buff *skb, struct device *dev);
dev254drivers/net/de600.cstatic int  de600_tx_intr(struct device *dev, int irq_status);
dev255drivers/net/de600.cstatic void  de600_rx_intr(struct device *dev);
dev258drivers/net/de600.cstatic void  trigger_interrupt(struct device *dev);
dev259drivers/net/de600.cint    de600_probe(struct device *dev);
dev260drivers/net/de600.cstatic int  adapter_init(struct device *dev);
dev310drivers/net/de600.cde600_read_status(struct device *dev)
dev322drivers/net/de600.cde600_read_byte(unsigned char type, struct device *dev) { /* dev used by macros */
dev340drivers/net/de600.cde600_open(struct device *dev)
dev343drivers/net/de600.cprintk ("%s: unable to get IRQ %d\n", dev->name, DE600_IRQ);
dev346drivers/net/de600.cirq2dev_map[DE600_IRQ] = dev;
dev351drivers/net/de600.cdev->start = 1;
dev352drivers/net/de600.cif (adapter_init(dev)) {
dev363drivers/net/de600.cde600_close(struct device *dev)
dev372drivers/net/de600.cif (dev->start) {
dev375drivers/net/de600.cdev->start = 0;
dev384drivers/net/de600.cget_stats(struct device *dev)
dev386drivers/net/de600.creturn (struct netstats *)(dev->priv);
dev390drivers/net/de600.ctrigger_interrupt(struct device *dev)
dev404drivers/net/de600.cde600_start_xmit(struct sk_buff *skb, struct device *dev)
dev418drivers/net/de600.cdev_tint(dev);
dev423drivers/net/de600.ctickssofar = jiffies - dev->trans_start;
dev430drivers/net/de600.cdev->name,
dev435drivers/net/de600.cif (adapter_init(dev)) {
dev454drivers/net/de600.cde600_read_byte(READ_DATA, dev);
dev455drivers/net/de600.cif (was_down || (de600_read_byte(READ_DATA, dev) != 0xde)) {
dev456drivers/net/de600.cif (adapter_init(dev)) {
dev468drivers/net/de600.cdev->trans_start = jiffies;
dev469drivers/net/de600.cdev->tbusy = 0;  /* allow more packets into adapter */
dev475drivers/net/de600.cdev->tbusy = !free_tx_pages;
dev500drivers/net/de600.cstruct device  *dev = irq2dev_map[irq];
dev506drivers/net/de600.cif ((dev == NULL) || (dev->start == 0) || (DE600_IRQ != irq)) {
dev507drivers/net/de600.cprintk("%s: bogus interrupt %d\n", dev?dev->name:"DE-600", irq);
dev511drivers/net/de600.cdev->interrupt = 1;
dev513drivers/net/de600.cirq_status = de600_read_status(dev);
dev519drivers/net/de600.cde600_rx_intr(dev);
dev525drivers/net/de600.cretrig = de600_tx_intr(dev, irq_status);
dev529drivers/net/de600.cirq_status = de600_read_status(dev);
dev538drivers/net/de600.cdev->interrupt = 0;
dev542drivers/net/de600.ctrigger_interrupt(dev);
dev549drivers/net/de600.cde600_tx_intr(struct device *dev, int irq_status)
dev565drivers/net/de600.c((struct netstats *)(dev->priv))->tx_packets++;
dev566drivers/net/de600.cdev->tbusy = 0;
dev571drivers/net/de600.cdev->trans_start = jiffies;
dev585drivers/net/de600.cde600_rx_intr(struct device *dev)
dev595drivers/net/de600.csize = de600_read_byte(RX_LEN, dev);  /* low byte */
dev596drivers/net/de600.csize += (de600_read_byte(RX_LEN, dev) << 8);  /* high byte */
dev606drivers/net/de600.cprintk("%s: Bogus packet size %d.\n", dev->name, size);
dev608drivers/net/de600.cadapter_init(dev);
dev616drivers/net/de600.cdev->name, size);
dev621drivers/net/de600.cskb->dev = dev;
dev630drivers/net/de600.c*buffer = de600_read_byte(READ_DATA, dev);
dev632drivers/net/de600.c((struct netstats *)(dev->priv))->rx_packets++; /* count all receives */
dev634drivers/net/de600.cskb->protocol=eth_type_trans(skb,dev);
dev645drivers/net/de600.cde600_probe(struct device *dev)
dev651drivers/net/de600.cprintk("%s: D-Link DE-600 pocket adapter", dev->name);
dev659drivers/net/de600.c(void)de600_read_status(dev);
dev662drivers/net/de600.cif (de600_read_status(dev) & 0xf0) {
dev675drivers/net/de600.cdev->dev_addr[i] = de600_read_byte(READ_DATA, dev);
dev676drivers/net/de600.cdev->broadcast[i] = 0xff;
dev680drivers/net/de600.cif ((dev->dev_addr[1] == 0xde) && (dev->dev_addr[2] == 0x15)) {
dev682drivers/net/de600.cdev->dev_addr[0] = 0x00;
dev683drivers/net/de600.cdev->dev_addr[1] = 0x80;
dev684drivers/net/de600.cdev->dev_addr[2] = 0xc8;
dev685drivers/net/de600.cdev->dev_addr[3] &= 0x0f;
dev686drivers/net/de600.cdev->dev_addr[3] |= 0x70;
dev700drivers/net/de600.cprintk(", Ethernet Address: %02X", dev->dev_addr[0]);
dev702drivers/net/de600.cprintk(":%02X",dev->dev_addr[i]);
dev707drivers/net/de600.cdev->priv = &de600_netstats;
dev709drivers/net/de600.cmemset(dev->priv, 0, sizeof(struct netstats));
dev710drivers/net/de600.cdev->get_stats = get_stats;
dev712drivers/net/de600.cdev->open = de600_open;
dev713drivers/net/de600.cdev->stop = de600_close;
dev714drivers/net/de600.cdev->hard_start_xmit = &de600_start_xmit;
dev716drivers/net/de600.cether_setup(dev);
dev723drivers/net/de600.cadapter_init(struct device *dev)
dev739drivers/net/de600.cde600_read_byte(READ_DATA, dev);
dev740drivers/net/de600.cif ((de600_read_byte(READ_DATA, dev) != 0xde) ||
dev741drivers/net/de600.c(de600_read_byte(READ_DATA, dev) != 0x15)) {
dev750drivers/net/de600.cdev->flags &= ~IFF_UP;
dev751drivers/net/de600.cde600_close(dev);
dev754drivers/net/de600.cdev->tbusy = 1;    /* Transmit busy...  */
dev763drivers/net/de600.cdev->tbusy = 0;    /* Transmit busy...  */
dev764drivers/net/de600.cdev->interrupt = 0;
dev772drivers/net/de600.cde600_put_byte(dev->dev_addr[i]);
dev408drivers/net/de620.cde620_open(struct device *dev)
dev411drivers/net/de620.cprintk ("%s: unable to get IRQ %d\n", dev->name, DE620_IRQ);
dev414drivers/net/de620.cirq2dev_map[DE620_IRQ] = dev;
dev419drivers/net/de620.cif (adapter_init(dev)) {
dev422drivers/net/de620.cdev->start = 1;
dev432drivers/net/de620.cde620_close(struct device *dev)
dev440drivers/net/de620.cdev->start = 0;
dev453drivers/net/de620.cget_stats(struct device *dev)
dev455drivers/net/de620.creturn (struct netstats *)(dev->priv);
dev469drivers/net/de620.cde620_set_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev485drivers/net/de620.cde620_start_xmit(struct sk_buff *skb, struct device *dev)
dev500drivers/net/de620.cdev_tint(dev);
dev505drivers/net/de620.cdev->tbusy = (using_txbuf == (TXBF0 | TXBF1)); /* Boolean! */
dev507drivers/net/de620.cif (dev->tbusy) {  /* Do timeouts, to avoid hangs. */
dev508drivers/net/de620.ctickssofar = jiffies - dev->trans_start;
dev515drivers/net/de620.cdev->name,
dev520drivers/net/de620.cif (adapter_init(dev)) /* maybe close it */
dev557drivers/net/de620.cdev->trans_start = jiffies;
dev558drivers/net/de620.cdev->tbusy = (using_txbuf == (TXBF0 | TXBF1)); /* Boolean! */
dev560drivers/net/de620.c((struct netstats *)(dev->priv))->tx_packets++;
dev577drivers/net/de620.cstruct device *dev = irq2dev_map[irq];
dev583drivers/net/de620.cif ((dev == NULL) || (DE620_IRQ != irq)) {
dev584drivers/net/de620.cprintk("%s: bogus interrupt %d\n", dev?dev->name:"DE620", irq);
dev589drivers/net/de620.cdev->interrupt = 1;
dev598drivers/net/de620.cagain = de620_rx_intr(dev);
dev604drivers/net/de620.cdev->tbusy = (de620_tx_buffs() == (TXBF0 | TXBF1)); /* Boolean! */
dev606drivers/net/de620.cdev->interrupt = 0;
dev619drivers/net/de620.cde620_rx_intr(struct device *dev)
dev648drivers/net/de620.cprintk("%s: Ring overrun? Restoring...\n", dev->name);
dev650drivers/net/de620.cadapter_init(dev);
dev651drivers/net/de620.c((struct netstats *)(dev->priv))->rx_over_errors++;
dev667drivers/net/de620.cprintk("%s: Page link out of sync! Restoring...\n", dev->name);
dev671drivers/net/de620.c((struct netstats *)(dev->priv))->rx_over_errors++;
dev678drivers/net/de620.cprintk("%s: Illegal packet size: %d!\n", dev->name, size);
dev684drivers/net/de620.cdev->name, size);
dev685drivers/net/de620.c((struct netstats *)(dev->priv))->rx_dropped++;
dev689drivers/net/de620.cskb->dev = dev;
dev696drivers/net/de620.cskb->protocol=eth_type_trans(skb,dev);
dev699drivers/net/de620.c((struct netstats *)(dev->priv))->rx_packets++;
dev718drivers/net/de620.cadapter_init(struct device *dev)
dev746drivers/net/de620.cde620_set_register(W_PAR0 + i, dev->dev_addr[i]);
dev779drivers/net/de620.cdev->flags &= ~IFF_UP;
dev780drivers/net/de620.cde620_close(dev);
dev806drivers/net/de620.cde620_probe(struct device *dev)
dev840drivers/net/de620.cdev->dev_addr[0] = nic_data.NodeID[0]);
dev842drivers/net/de620.cprintk(":%2.2X", dev->dev_addr[i] = nic_data.NodeID[i]);
dev843drivers/net/de620.cdev->broadcast[i] = 0xff;
dev856drivers/net/de620.cdev->priv = &de620_netstats;
dev858drivers/net/de620.cmemset(dev->priv, 0, sizeof(struct netstats));
dev859drivers/net/de620.cdev->get_stats = get_stats;
dev860drivers/net/de620.cdev->open = de620_open;
dev861drivers/net/de620.cdev->stop = de620_close;
dev862drivers/net/de620.cdev->hard_start_xmit = &de620_start_xmit;
dev863drivers/net/de620.cdev->set_multicast_list = &de620_set_multicast_list;
dev864drivers/net/de620.cdev->base_addr = DE620_IO;
dev865drivers/net/de620.cdev->irq = DE620_IRQ;
dev867drivers/net/de620.cether_setup(dev);
dev367drivers/net/depca.cstatic int    depca_open(struct device *dev);
dev368drivers/net/depca.cstatic int    depca_start_xmit(struct sk_buff *skb, struct device *dev);
dev370drivers/net/depca.cstatic int    depca_close(struct device *dev);
dev371drivers/net/depca.cstatic int    depca_ioctl(struct device *dev, struct ifreq *rq, int cmd);
dev372drivers/net/depca.cstatic struct enet_statistics *depca_get_stats(struct device *dev);
dev373drivers/net/depca.cstatic void   set_multicast_list(struct device *dev,int num_addrs,void *addrs);
dev378drivers/net/depca.cstatic int    depca_hw_init(struct device *dev, u_long ioaddr);
dev379drivers/net/depca.cstatic void   depca_init_ring(struct device *dev);
dev380drivers/net/depca.cstatic int    depca_rx(struct device *dev);
dev381drivers/net/depca.cstatic int    depca_tx(struct device *dev);
dev383drivers/net/depca.cstatic void   LoadCSRs(struct device *dev);
dev384drivers/net/depca.cstatic int    InitRestartDepca(struct device *dev);
dev387drivers/net/depca.cstatic int    get_hw_addr(struct device *dev);
dev389drivers/net/depca.cstatic void   SetMulticastFilter(struct device *dev,int num_addrs,char *addrs);
dev390drivers/net/depca.cstatic void   isa_probe(struct device *dev, u_long iobase);
dev391drivers/net/depca.cstatic void   eisa_probe(struct device *dev, u_long iobase);
dev392drivers/net/depca.cstatic struct device *alloc_device(struct device *dev, u_long iobase);
dev393drivers/net/depca.cstatic int    load_packet(struct device *dev, struct sk_buff *skb);
dev419drivers/net/depca.cint depca_probe(struct device *dev)
dev422drivers/net/depca.cu_long iobase = dev->base_addr;
dev428drivers/net/depca.cisa_probe(dev, iobase);
dev429drivers/net/depca.ceisa_probe(dev, iobase);
dev432drivers/net/depca.cprintk("%s: depca_probe() cannot find device at 0x%04lx.\n", dev->name, 
dev440drivers/net/depca.cfor (; (dev->priv == NULL) && (dev->next != NULL); dev = dev->next);
dev442drivers/net/depca.cif (dev->priv) status = 0;
dev450drivers/net/depca.cdepca_hw_init(struct device *dev, u_long ioaddr)
dev471drivers/net/depca.cdev->base_addr = ioaddr;
dev475drivers/net/depca.cdev->name, name, ioaddr, (int)((ioaddr>>12)&0x0f));
dev477drivers/net/depca.cprintk("%s: %s at 0x%04lx", dev->name, name, ioaddr);
dev481drivers/net/depca.cstatus = get_hw_addr(dev);
dev483drivers/net/depca.cprintk("%2.2x:", dev->dev_addr[i]);
dev485drivers/net/depca.cprintk("%2.2x", dev->dev_addr[i]);
dev513drivers/net/depca.cdev->priv = (void *) kmalloc(sizeof(struct depca_private), GFP_KERNEL);
dev514drivers/net/depca.clp = (struct depca_private *)dev->priv;
dev515drivers/net/depca.cmemset((char *)dev->priv, 0, sizeof(struct depca_private));
dev517drivers/net/depca.csprintf(lp->adapter_name,"%s (%s)", name, dev->name);
dev552drivers/net/depca.cdepca_init_ring(dev);
dev555drivers/net/depca.cLoadCSRs(dev);
dev563drivers/net/depca.cif (dev->irq < 2) {
dev594drivers/net/depca.cfor (dev->irq=0,i=0; (depca_irq[i]) && (!dev->irq); i++) {
dev596drivers/net/depca.cdev->irq = irqnum;
dev597drivers/net/depca.cprintk("      and uses IRQ%d.\n", dev->irq);
dev601drivers/net/depca.cif (!dev->irq) {
dev608drivers/net/depca.cprintk(" and assigned IRQ%d.\n", dev->irq);
dev627drivers/net/depca.cdev->open = &depca_open;
dev628drivers/net/depca.cdev->hard_start_xmit = &depca_start_xmit;
dev629drivers/net/depca.cdev->stop = &depca_close;
dev630drivers/net/depca.cdev->get_stats = &depca_get_stats;
dev631drivers/net/depca.cdev->set_multicast_list = &set_multicast_list;
dev632drivers/net/depca.cdev->do_ioctl = &depca_ioctl;
dev634drivers/net/depca.cdev->mem_start = 0;
dev637drivers/net/depca.cether_setup(dev);
dev639drivers/net/depca.cif (dev->priv) {
dev640drivers/net/depca.ckfree_s(dev->priv, sizeof(struct depca_private));
dev641drivers/net/depca.cdev->priv = NULL;
dev653drivers/net/depca.cdepca_open(struct device *dev)
dev655drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev657drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev661drivers/net/depca.cif (request_irq(dev->irq, &depca_interrupt, 0, lp->adapter_name)) {
dev662drivers/net/depca.cprintk("depca_open(): Requested IRQ%d is busy\n",dev->irq);
dev666drivers/net/depca.cirq2dev_map[dev->irq] = dev;
dev677drivers/net/depca.cdepca_init_ring(dev);
dev678drivers/net/depca.cLoadCSRs(dev);
dev684drivers/net/depca.cprintk("%s: depca open with irq %d\n",dev->name,dev->irq);
dev750drivers/net/depca.cdev->tbusy = 0;                         
dev751drivers/net/depca.cdev->interrupt = 0;
dev752drivers/net/depca.cdev->start = 1;
dev754drivers/net/depca.cstatus = InitRestartDepca(dev);
dev768drivers/net/depca.cdepca_init_ring(struct device *dev)
dev770drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev775drivers/net/depca.cset_bit(0, (void *)&dev->tbusy);
dev796drivers/net/depca.cSetMulticastFilter(dev, 0, NULL);
dev799drivers/net/depca.clp->init_block.phys_addr[i] = dev->dev_addr[i];
dev811drivers/net/depca.cdepca_start_xmit(struct sk_buff *skb, struct device *dev)
dev813drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev814drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev818drivers/net/depca.cif (dev->tbusy) {
dev819drivers/net/depca.cint tickssofar = jiffies - dev->trans_start;
dev824drivers/net/depca.cdev->name, inw(DEPCA_DATA));
dev827drivers/net/depca.cdepca_init_ring(dev);
dev828drivers/net/depca.cLoadCSRs(dev);
dev829drivers/net/depca.cdev->interrupt = UNMASK_INTERRUPTS;
dev830drivers/net/depca.cdev->start = 1;
dev831drivers/net/depca.cdev->tbusy=0;
dev832drivers/net/depca.cdev->trans_start = jiffies;
dev833drivers/net/depca.cInitRestartDepca(dev);
dev837drivers/net/depca.cdev_tint(dev);
dev840drivers/net/depca.cif (set_bit(0, (void*)&dev->tbusy) != 0) {
dev841drivers/net/depca.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev845drivers/net/depca.cstatus = load_packet(dev, skb);
dev852drivers/net/depca.cdev->trans_start = jiffies;
dev856drivers/net/depca.cdev->tbusy=0;
dev873drivers/net/depca.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev878drivers/net/depca.cif (dev == NULL) {
dev881drivers/net/depca.clp = (struct depca_private *)dev->priv;
dev882drivers/net/depca.cioaddr = dev->base_addr;
dev884drivers/net/depca.cif (dev->interrupt)
dev885drivers/net/depca.cprintk("%s: Re-entering the interrupt handler.\n", dev->name);
dev887drivers/net/depca.cdev->interrupt = MASK_INTERRUPTS;
dev901drivers/net/depca.cdepca_rx(dev);
dev904drivers/net/depca.cdepca_tx(dev);
dev906drivers/net/depca.cif ((TX_BUFFS_AVAIL >= 0) && dev->tbusy) { /* any resources available? */
dev907drivers/net/depca.cdev->tbusy = 0;                  /* clear TX busy flag */
dev915drivers/net/depca.cdev->interrupt = UNMASK_INTERRUPTS;
dev922drivers/net/depca.cdepca_rx(struct device *dev)
dev924drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev951drivers/net/depca.cskb->dev = dev;
dev964drivers/net/depca.cskb->protocol=eth_type_trans(skb,dev);
dev983drivers/net/depca.c} else if ((*(s16 *)&buf[0] == *(s16 *)&dev->dev_addr[0]) &&
dev984drivers/net/depca.c(*(s32 *)&buf[2] == *(s32 *)&dev->dev_addr[2])) {
dev993drivers/net/depca.cprintk("%s: Memory squeeze, deferring packet.\n", dev->name);
dev1019drivers/net/depca.cdepca_tx(struct device *dev)
dev1021drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1024drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev1057drivers/net/depca.cdepca_close(struct device *dev)
dev1059drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1061drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev1063drivers/net/depca.cdev->start = 0;
dev1064drivers/net/depca.cdev->tbusy = 1;
dev1070drivers/net/depca.cdev->name, inw(DEPCA_DATA));
dev1091drivers/net/depca.cfree_irq(dev->irq);
dev1092drivers/net/depca.cirq2dev_map[dev->irq] = NULL;
dev1099drivers/net/depca.cstatic void LoadCSRs(struct device *dev)
dev1101drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1102drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev1116drivers/net/depca.cstatic int InitRestartDepca(struct device *dev)
dev1118drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1119drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev1136drivers/net/depca.cdev->name, i, lp->sh_mem, inw(DEPCA_DATA));
dev1140drivers/net/depca.cdev->name, i, lp->sh_mem, inw(DEPCA_DATA));
dev1148drivers/net/depca.cdepca_get_stats(struct device *dev)
dev1150drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1165drivers/net/depca.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev1167drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1168drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev1170drivers/net/depca.cif (irq2dev_map[dev->irq] != NULL) {
dev1171drivers/net/depca.cwhile(dev->tbusy);                /* Stop ring access */
dev1172drivers/net/depca.cset_bit(0, (void*)&dev->tbusy);
dev1176drivers/net/depca.cdepca_init_ring(dev);             /* Initialize the descriptor rings */
dev1179drivers/net/depca.cSetMulticastFilter(dev, num_addrs, (char *)addrs);
dev1185drivers/net/depca.cLoadCSRs(dev);                    /* Reload CSR3 */
dev1186drivers/net/depca.cInitRestartDepca(dev);            /* Resume normal operation. */
dev1187drivers/net/depca.cdev->tbusy = 0;                   /* Unlock the TX ring */
dev1197drivers/net/depca.cstatic void SetMulticastFilter(struct device *dev, int num_addrs, char *addrs)
dev1199drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1245drivers/net/depca.cstatic void isa_probe(struct device *dev, u_long ioaddr)
dev1261drivers/net/depca.cfor (; (i<maxSlots) && (dev!=NULL) && ports[i]; i++) {
dev1264drivers/net/depca.cif ((dev = alloc_device(dev, ports[i])) != NULL) {
dev1265drivers/net/depca.cif (depca_hw_init(dev, ports[i]) == 0) {
dev1271drivers/net/depca.cprintk("%s: region already allocated at 0x%04x.\n", dev->name,ports[i]);
dev1283drivers/net/depca.cstatic void eisa_probe(struct device *dev, u_long ioaddr)
dev1303drivers/net/depca.cfor (; (i<maxSlots) && (dev!=NULL); i++, iobase+=EISA_SLOT_INC) {
dev1307drivers/net/depca.cif ((dev = alloc_device(dev, iobase)) != NULL) {
dev1308drivers/net/depca.cif (depca_hw_init(dev, iobase) == 0) {
dev1314drivers/net/depca.cprintk("%s: region already allocated at 0x%04lx.\n",dev->name,iobase);
dev1327drivers/net/depca.cstatic struct device *alloc_device(struct device *dev, u_long iobase)
dev1337drivers/net/depca.cwhile (dev->next != NULL) {
dev1338drivers/net/depca.cif ((dev->base_addr == DEPCA_NDA) || (dev->base_addr == 0)) break;
dev1339drivers/net/depca.cdev = dev->next;                     /* walk through eth device list */
dev1347drivers/net/depca.cif ((dev->base_addr == 0) && (num_depcas > 0)) {
dev1349drivers/net/depca.ctmp = dev->next;                     /* point to the next device */
dev1350drivers/net/depca.cinit = dev->init;                    /* remember the probe function */
dev1357drivers/net/depca.cif ((dev->next == NULL) &&  
dev1358drivers/net/depca.c!((dev->base_addr == DEPCA_NDA) || (dev->base_addr == 0))){
dev1359drivers/net/depca.cdev->next = (struct device *)kmalloc(sizeof(struct device) + 8,
dev1362drivers/net/depca.cdev = dev->next;                     /* point to the new device */
dev1363drivers/net/depca.cif (dev == NULL) {
dev1372drivers/net/depca.cdev->name = (char *)(dev + sizeof(struct device));
dev1374drivers/net/depca.csprintf(dev->name,"eth????");    /* New device name */
dev1376drivers/net/depca.csprintf(dev->name,"eth%d", num_eth);/* New device name */
dev1378drivers/net/depca.cdev->base_addr = iobase;           /* assign the io address */
dev1379drivers/net/depca.cdev->next = NULL;                  /* mark the end of list */
dev1380drivers/net/depca.cdev->init = &depca_probe;          /* initialisation routine */
dev1384drivers/net/depca.cret = dev;                             /* return current struct, or NULL */
dev1404drivers/net/depca.cdev->name);
dev1427drivers/net/depca.cret = dev;
dev1490drivers/net/depca.c} dev;
dev1505drivers/net/depca.cdev.llsig.a = ETH_PROM_SIG;
dev1506drivers/net/depca.cdev.llsig.b = ETH_PROM_SIG;
dev1511drivers/net/depca.cif (dev.Sig[j] == data) {    /* track signature */
dev1514drivers/net/depca.cif (data == dev.Sig[0]) {  /* rare case.... */
dev1534drivers/net/depca.cstatic int get_hw_addr(struct device *dev)
dev1536drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev1547drivers/net/depca.cdev->dev_addr[i++] = (u_char) tmp;
dev1549drivers/net/depca.cdev->dev_addr[i++] = (u_char) tmp;
dev1565drivers/net/depca.cstatic int load_packet(struct device *dev, struct sk_buff *skb)
dev1567drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1657drivers/net/depca.cstatic int depca_ioctl(struct device *dev, struct ifreq *rq, int cmd)
dev1659drivers/net/depca.cstruct depca_private *lp = (struct depca_private *)dev->priv;
dev1662drivers/net/depca.cu_long ioaddr = dev->base_addr;
dev1672drivers/net/depca.ctmp.addr[i] = dev->dev_addr[i];
dev1685drivers/net/depca.cdev->dev_addr[i] = tmp.addr[i];
dev1687drivers/net/depca.cwhile(dev->tbusy);              /* Stop ring access */
dev1688drivers/net/depca.cset_bit(0, (void*)&dev->tbusy);
dev1692drivers/net/depca.cdepca_init_ring(dev);           /* Initialize the descriptor rings */
dev1693drivers/net/depca.cLoadCSRs(dev);                  /* Reload CSR3 */
dev1694drivers/net/depca.cInitRestartDepca(dev);          /* Resume normal operation. */
dev1695drivers/net/depca.cdev->tbusy = 0;                 /* Unlock the TX ring */
dev1704drivers/net/depca.cwhile(dev->tbusy);                /* Stop ring access */
dev1705drivers/net/depca.cset_bit(0, (void*)&dev->tbusy);
dev1709drivers/net/depca.cdepca_init_ring(dev);             /* Initialize the descriptor rings */
dev1712drivers/net/depca.cLoadCSRs(dev);                    /* Reload CSR3 */
dev1713drivers/net/depca.cInitRestartDepca(dev);            /* Resume normal operation. */
dev1714drivers/net/depca.cdev->tbusy = 0;                   /* Unlock the TX ring */
dev1722drivers/net/depca.cwhile(dev->tbusy);                /* Stop ring access */
dev1723drivers/net/depca.cset_bit(0, (void*)&dev->tbusy);
dev1727drivers/net/depca.cdepca_init_ring(dev);             /* Initialize the descriptor rings */
dev1730drivers/net/depca.cLoadCSRs(dev);                    /* Reload CSR3 */
dev1731drivers/net/depca.cInitRestartDepca(dev);            /* Resume normal operation. */
dev1732drivers/net/depca.cdev->tbusy = 0;                   /* Unlock the TX ring */
dev1739drivers/net/depca.cprintk("%s: Boo!\n", dev->name);
dev1754drivers/net/depca.cset_multicast_list(dev, ioc->len, tmp.addr);
dev1757drivers/net/depca.cset_multicast_list(dev, ioc->len, NULL);
dev1766drivers/net/depca.cset_multicast_list(dev, 0, NULL);
dev1774drivers/net/depca.cset_multicast_list(dev, HASH_TABLE_LEN, NULL);
dev59drivers/net/dummy.cstatic int dummy_xmit(struct sk_buff *skb, struct device *dev);
dev61drivers/net/dummy.cstatic struct enet_statistics *dummy_get_stats(struct device *dev);
dev65drivers/net/dummy.cstatic int dummy_open(struct device *dev)
dev71drivers/net/dummy.cstatic int dummy_close(struct device *dev)
dev80drivers/net/dummy.cint dummy_init(struct device *dev)
dev87drivers/net/dummy.cdev->hard_start_xmit  = dummy_xmit;
dev90drivers/net/dummy.cdev->priv = kmalloc(sizeof(struct enet_statistics), GFP_KERNEL);
dev91drivers/net/dummy.cmemset(dev->priv, 0, sizeof(struct enet_statistics));
dev92drivers/net/dummy.cdev->get_stats    = dummy_get_stats;
dev95drivers/net/dummy.cdev->open = &dummy_open;
dev96drivers/net/dummy.cdev->stop = &dummy_close;
dev100drivers/net/dummy.cether_setup(dev);
dev101drivers/net/dummy.cdev->flags |= IFF_NOARP;
dev107drivers/net/dummy.cdummy_xmit(struct sk_buff *skb, struct device *dev)
dev113drivers/net/dummy.cif (skb == NULL || dev == NULL)
dev119drivers/net/dummy.cstats = (struct enet_statistics *)dev->priv;
dev128drivers/net/dummy.cdummy_get_stats(struct device *dev)
dev130drivers/net/dummy.cstruct enet_statistics *stats = (struct enet_statistics*) dev->priv;
dev138drivers/net/dummy.cstatic int dummy_probe(struct device *dev)
dev140drivers/net/dummy.cdummy_init(dev);
dev92drivers/net/e2100.cint e2100_probe(struct device *dev);
dev93drivers/net/e2100.cint e21_probe1(struct device *dev, int ioaddr);
dev95drivers/net/e2100.cstatic int e21_open(struct device *dev);
dev96drivers/net/e2100.cstatic void e21_reset_8390(struct device *dev);
dev97drivers/net/e2100.cstatic int e21_block_input(struct device *dev, int count,
dev99drivers/net/e2100.cstatic void e21_block_output(struct device *dev, int count,
dev101drivers/net/e2100.cstatic int e21_close(struct device *dev);
dev111drivers/net/e2100.cint e2100_probe(struct device *dev)
dev114drivers/net/e2100.cint base_addr = dev->base_addr;
dev117drivers/net/e2100.creturn e21_probe1(dev, base_addr);
dev124drivers/net/e2100.cif (e21_probe1(dev, *port) == 0)
dev131drivers/net/e2100.cint e21_probe1(struct device *dev, int ioaddr)
dev134drivers/net/e2100.cunsigned char *station_addr = dev->dev_addr;
dev159drivers/net/e2100.cprintk("%s: E21** at %#3x,", dev->name, ioaddr);
dev163drivers/net/e2100.cif (dev->irq < 2) {
dev167drivers/net/e2100.cdev->irq = irqlist[i];
dev171drivers/net/e2100.cprintk(" unable to get IRQ %d.\n", dev->irq);
dev174drivers/net/e2100.c} else if (dev->irq == 2)  /* Fixup luser bogosity: IRQ2 is really IRQ9 */
dev175drivers/net/e2100.cdev->irq = 9;
dev178drivers/net/e2100.cdev->base_addr = ioaddr;
dev180drivers/net/e2100.cethdev_init(dev);
dev187drivers/net/e2100.cei_status.saved_irq = dev->irq;
dev191drivers/net/e2100.cif (dev->mem_end & 15)
dev192drivers/net/e2100.cdev->if_port = dev->mem_end & 7;
dev194drivers/net/e2100.cdev->if_port = 0;
dev198drivers/net/e2100.cdev->if_port = 1;
dev206drivers/net/e2100.cif (dev->mem_start == 0)
dev207drivers/net/e2100.cdev->mem_start = 0xd0000;
dev212drivers/net/e2100.cdev->rmem_start = dev->mem_start + TX_PAGES*256;
dev213drivers/net/e2100.cdev->mem_end = dev->rmem_end = dev->mem_start + 2*1024;
dev216drivers/net/e2100.cprintk(", IRQ %d, %s media, memory @ %#lx.\n", dev->irq,
dev217drivers/net/e2100.cdev->if_port ? "secondary" : "primary", dev->mem_start);
dev225drivers/net/e2100.cdev->open = &e21_open;
dev226drivers/net/e2100.cdev->stop = &e21_close;
dev227drivers/net/e2100.cNS8390_init(dev, 0);
dev233drivers/net/e2100.ce21_open(struct device *dev)
dev235drivers/net/e2100.cshort ioaddr = dev->base_addr;
dev237drivers/net/e2100.cif (request_irq(dev->irq, ei_interrupt, 0, "e2100")) {
dev240drivers/net/e2100.cirq2dev_map[dev->irq] = dev;
dev244drivers/net/e2100.coutb(0, ioaddr + E21_ASIC + (dev->irq & 7));
dev246drivers/net/e2100.coutb(0, ioaddr + E21_ASIC + (dev->irq > 7 ? 1:0)
dev247drivers/net/e2100.c+ (dev->if_port ? E21_ALT_IFPORT : 0));
dev249drivers/net/e2100.coutb(0, ioaddr + E21_ASIC + ((dev->mem_start >> 17) & 7));
dev251drivers/net/e2100.creturn ei_open(dev);
dev255drivers/net/e2100.ce21_reset_8390(struct device *dev)
dev257drivers/net/e2100.cshort ioaddr = dev->base_addr;
dev273drivers/net/e2100.ce21_block_input(struct device *dev, int count, char *buf, int ring_offset)
dev275drivers/net/e2100.cshort ioaddr = dev->base_addr;
dev276drivers/net/e2100.cchar *shared_mem = (char *)dev->mem_start;
dev294drivers/net/e2100.ce21_block_output(struct device *dev, int count, const unsigned char *buf,
dev297drivers/net/e2100.cshort ioaddr = dev->base_addr;
dev298drivers/net/e2100.cvolatile char *shared_mem = (char *)dev->mem_start;
dev310drivers/net/e2100.ce21_close(struct device *dev)
dev312drivers/net/e2100.cshort ioaddr = dev->base_addr;
dev315drivers/net/e2100.cprintk("%s: Shutting down ethercard.\n", dev->name);
dev317drivers/net/e2100.cfree_irq(dev->irq);
dev318drivers/net/e2100.cdev->irq = ei_status.saved_irq;
dev326drivers/net/e2100.cirq2dev_map[dev->irq] = NULL;
dev328drivers/net/e2100.cNS8390_init(dev, 0);
dev106drivers/net/eepro.cextern struct device *init_etherdev(struct device *dev, int sizeof_private,
dev141drivers/net/eepro.cextern int eepro_probe(struct device *dev);  
dev143drivers/net/eepro.cstatic int  eepro_probe1(struct device *dev, short ioaddr);
dev144drivers/net/eepro.cstatic int  eepro_open(struct device *dev);
dev145drivers/net/eepro.cstatic int  eepro_send_packet(struct sk_buff *skb, struct device *dev);
dev147drivers/net/eepro.cstatic void   eepro_rx(struct device *dev);
dev148drivers/net/eepro.cstatic void   eepro_transmit_interrupt(struct device *dev);
dev149drivers/net/eepro.cstatic int  eepro_close(struct device *dev);
dev150drivers/net/eepro.cstatic struct enet_statistics *eepro_get_stats(struct device *dev);
dev151drivers/net/eepro.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev154drivers/net/eepro.cstatic void hardware_send_packet(struct device *dev, void *buf, short length);
dev155drivers/net/eepro.cstatic int  eepro_grab_irq(struct device *dev);
dev284drivers/net/eepro.ceepro_probe(struct device *dev)
dev287drivers/net/eepro.cint base_addr = dev ? dev->base_addr : 0;
dev290drivers/net/eepro.creturn eepro_probe1(dev, base_addr);
dev298drivers/net/eepro.cif (eepro_probe1(dev, ioaddr) == 0)
dev310drivers/net/eepro.cint eepro_probe1(struct device *dev, short ioaddr)
dev346drivers/net/eepro.cdev->name, ioaddr);
dev351drivers/net/eepro.cdev->name, ioaddr);
dev355drivers/net/eepro.cdev->base_addr = ioaddr;
dev358drivers/net/eepro.cdev->dev_addr[i] = ((unsigned char *) station_addr)[5-i];
dev359drivers/net/eepro.cprintk("%c%02x", i ? ':' : ' ', dev->dev_addr[i]);
dev365drivers/net/eepro.cdev->if_port = TPE;
dev366drivers/net/eepro.celse dev->if_port = BNC;
dev368drivers/net/eepro.cif (dev->irq < 2 && eepro) {
dev371drivers/net/eepro.ccase 0:  dev->irq = 9; break;
dev372drivers/net/eepro.ccase 1:  dev->irq = 3; break;
dev373drivers/net/eepro.ccase 2:  dev->irq = 5; break;
dev374drivers/net/eepro.ccase 3:  dev->irq = 10; break;
dev375drivers/net/eepro.ccase 4:  dev->irq = 11; break;
dev381drivers/net/eepro.celse if (dev->irq == 2)
dev382drivers/net/eepro.cdev->irq = 9;
dev384drivers/net/eepro.cif (dev->irq > 2) {
dev385drivers/net/eepro.cprintk(", IRQ %d, %s.\n", dev->irq,
dev386drivers/net/eepro.cifmap[dev->if_port]);
dev387drivers/net/eepro.cif (request_irq(dev->irq, &eepro_interrupt, 0, "eepro")) {
dev388drivers/net/eepro.cprintk("%s: unable to get IRQ %d.\n", dev->name, dev->irq);
dev392drivers/net/eepro.celse printk(", %s.\n", ifmap[dev->if_port]);
dev394drivers/net/eepro.cif ((dev->mem_start & 0xf) > 0)
dev395drivers/net/eepro.cnet_debug = dev->mem_start & 7;
dev401drivers/net/eepro.cdev->name);
dev411drivers/net/eepro.cif (dev->priv == NULL)
dev412drivers/net/eepro.cdev->priv = kmalloc(sizeof(struct eepro_local), GFP_KERNEL);
dev413drivers/net/eepro.cmemset(dev->priv, 0, sizeof(struct eepro_local));
dev415drivers/net/eepro.cdev->open = eepro_open;
dev416drivers/net/eepro.cdev->stop = eepro_close;
dev417drivers/net/eepro.cdev->hard_start_xmit = eepro_send_packet;
dev418drivers/net/eepro.cdev->get_stats = eepro_get_stats;
dev419drivers/net/eepro.cdev->set_multicast_list = &set_multicast_list;
dev424drivers/net/eepro.cether_setup(dev);
dev446drivers/net/eepro.cstatic int  eepro_grab_irq(struct device *dev)
dev449drivers/net/eepro.cint *irqp = irqlist, temp_reg, ioaddr = dev->base_addr;
dev479drivers/net/eepro.c(request_irq(dev->irq = *irqp, &eepro_interrupt, 0, "eepro") == 0)) 
dev501drivers/net/eepro.creturn dev->irq;
dev505drivers/net/eepro.ceepro_open(struct device *dev)
dev508drivers/net/eepro.cint i, ioaddr = dev->base_addr;
dev509drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev514drivers/net/eepro.cif (dev->dev_addr[0] == SA_ADDR0 &&
dev515drivers/net/eepro.cdev->dev_addr[1] == SA_ADDR1 &&
dev516drivers/net/eepro.cdev->dev_addr[2] == SA_ADDR2)
dev521drivers/net/eepro.cif (dev->irq < 2 && eepro_grab_irq(dev) == 0) {
dev522drivers/net/eepro.cprintk("%s: unable to get IRQ %d.\n", dev->name, dev->irq);
dev526drivers/net/eepro.cif (irq2dev_map[dev->irq] != 0
dev527drivers/net/eepro.c|| (irq2dev_map[dev->irq] = dev) == 0)
dev537drivers/net/eepro.coutb(dev->dev_addr[i] , ioaddr + I_ADD_REG0 + i); 
dev553drivers/net/eepro.coutb((temp_reg & 0xf8) | irqrmap[dev->irq], ioaddr + INT_NO_REG); 
dev588drivers/net/eepro.cdev->tbusy = 0;
dev589drivers/net/eepro.cdev->interrupt = 0;
dev590drivers/net/eepro.cdev->start = 1;
dev604drivers/net/eepro.ceepro_send_packet(struct sk_buff *skb, struct device *dev)
dev606drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev607drivers/net/eepro.cint ioaddr = dev->base_addr;
dev612drivers/net/eepro.cif (dev->tbusy) {
dev615drivers/net/eepro.cint tickssofar = jiffies - dev->trans_start;
dev619drivers/net/eepro.cprintk("%s: transmit timed out, %s?\n", dev->name,
dev632drivers/net/eepro.cdev->tbusy=0;
dev633drivers/net/eepro.cdev->trans_start = jiffies;
dev643drivers/net/eepro.cdev_tint(dev);
dev648drivers/net/eepro.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev649drivers/net/eepro.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev654drivers/net/eepro.chardware_send_packet(dev, buf, length);
dev655drivers/net/eepro.cdev->trans_start = jiffies;
dev675drivers/net/eepro.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev681drivers/net/eepro.cif (dev == NULL) {
dev685drivers/net/eepro.cdev->interrupt = 1;
dev687drivers/net/eepro.cioaddr = dev->base_addr;
dev700drivers/net/eepro.ceepro_rx(dev);
dev710drivers/net/eepro.ceepro_transmit_interrupt(dev);
dev711drivers/net/eepro.cdev->tbusy = 0;
dev716drivers/net/eepro.cdev->interrupt = 0;
dev724drivers/net/eepro.ceepro_close(struct device *dev)
dev726drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev727drivers/net/eepro.cint ioaddr = dev->base_addr;
dev730drivers/net/eepro.cdev->tbusy = 1;
dev731drivers/net/eepro.cdev->start = 0;
dev756drivers/net/eepro.cfree_irq(dev->irq);
dev758drivers/net/eepro.cirq2dev_map[dev->irq] = 0;
dev778drivers/net/eepro.ceepro_get_stats(struct device *dev)
dev780drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev792drivers/net/eepro.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev794drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev795drivers/net/eepro.cshort ioaddr = dev->base_addr;
dev805drivers/net/eepro.cprintk("%s: promiscuous mode enabled.\n", dev->name);
dev840drivers/net/eepro.ceaddrs = (unsigned short *) dev->dev_addr;
dev869drivers/net/eepro.cdev->name);
dev873drivers/net/eepro.cdev->name, num_addrs);
dev934drivers/net/eepro.chardware_send_packet(struct device *dev, void *buf, short length)
dev936drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev937drivers/net/eepro.cshort ioaddr = dev->base_addr;
dev1009drivers/net/eepro.cif (dev->tbusy) {
dev1010drivers/net/eepro.cdev->tbusy = 0;
dev1018drivers/net/eepro.cdev->tbusy = 1;
dev1024drivers/net/eepro.ceepro_rx(struct device *dev)
dev1026drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev1027drivers/net/eepro.cshort ioaddr = dev->base_addr;
dev1051drivers/net/eepro.cprintk("%s: Memory squeeze, dropping packet.\n", dev->name);
dev1055drivers/net/eepro.cskb->dev = dev;
dev1060drivers/net/eepro.cskb->protocol = eth_type_trans(skb,dev);  
dev1074drivers/net/eepro.cdev->name, rcv_event, rcv_status, rcv_next_frame, rcv_size);
dev1096drivers/net/eepro.ceepro_transmit_interrupt(struct device *dev)
dev1098drivers/net/eepro.cstruct eepro_local *lp = (struct eepro_local *)dev->priv;
dev1099drivers/net/eepro.cshort ioaddr = dev->base_addr;
dev1111drivers/net/eepro.cif (dev->tbusy) {
dev1112drivers/net/eepro.cdev->tbusy = 0;
dev1123drivers/net/eepro.cdev->name, xmt_status);
dev288drivers/net/eexpress.cextern int express_probe(struct device *dev);  /* Called from Space.c */
dev290drivers/net/eexpress.cstatic int  eexp_probe1(struct device *dev, short ioaddr);
dev291drivers/net/eexpress.cstatic int  eexp_open(struct device *dev);
dev292drivers/net/eexpress.cstatic int  eexp_send_packet(struct sk_buff *skb, struct device *dev);
dev294drivers/net/eexpress.cstatic void eexp_rx(struct device *dev);
dev295drivers/net/eexpress.cstatic int  eexp_close(struct device *dev);
dev296drivers/net/eexpress.cstatic struct enet_statistics *eexp_get_stats(struct device *dev);
dev297drivers/net/eexpress.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev300drivers/net/eexpress.cstatic void hardware_send_packet(struct device *dev, void *buf, short length);
dev301drivers/net/eexpress.cstatic void init_82586_mem(struct device *dev);
dev302drivers/net/eexpress.cstatic void init_rx_bufs(struct device *dev);
dev312drivers/net/eexpress.cexpress_probe(struct device *dev)
dev316drivers/net/eexpress.cint base_addr = dev->base_addr;
dev319drivers/net/eexpress.creturn eexp_probe1(dev, base_addr);
dev338drivers/net/eexpress.c&& eexp_probe1(dev, *port) == 0)
dev345drivers/net/eexpress.cint eexp_probe1(struct device *dev, short ioaddr)
dev350drivers/net/eexpress.cprintk("%s: EtherExpress at %#x,", dev->name, ioaddr);
dev367drivers/net/eexpress.cdev->base_addr = ioaddr;
dev370drivers/net/eexpress.cdev->dev_addr[i] = ((unsigned char*)station_addr)[5-i];
dev371drivers/net/eexpress.cprintk(" %02x", dev->dev_addr[i]);
dev382drivers/net/eexpress.cdev->irq = irqmap[setupval >> 13];
dev383drivers/net/eexpress.cdev->if_port = (setupval & 0x1000) == 0 ? AUI :
dev385drivers/net/eexpress.cprintk(", IRQ %d, Interface %s.\n", dev->irq, ifmap[dev->if_port]);
dev394drivers/net/eexpress.cif ((dev->mem_start & 0xf) > 0)
dev395drivers/net/eexpress.cnet_debug = dev->mem_start & 7;
dev401drivers/net/eexpress.cdev->priv = kmalloc(sizeof(struct net_local), GFP_KERNEL);
dev402drivers/net/eexpress.cmemset(dev->priv, 0, sizeof(struct net_local));
dev404drivers/net/eexpress.cdev->open    = eexp_open;
dev405drivers/net/eexpress.cdev->stop    = eexp_close;
dev406drivers/net/eexpress.cdev->hard_start_xmit = eexp_send_packet;
dev407drivers/net/eexpress.cdev->get_stats  = eexp_get_stats;
dev408drivers/net/eexpress.cdev->set_multicast_list = &set_multicast_list;
dev412drivers/net/eexpress.cether_setup(dev);
dev422drivers/net/eexpress.ceexp_open(struct device *dev)
dev424drivers/net/eexpress.cint ioaddr = dev->base_addr;
dev426drivers/net/eexpress.cif (dev->irq == 0  ||  irqrmap[dev->irq] == 0)
dev429drivers/net/eexpress.cif (irq2dev_map[dev->irq] != 0
dev431drivers/net/eexpress.c|| (irq2dev_map[dev->irq] = dev) == 0
dev432drivers/net/eexpress.c|| request_irq(dev->irq, &eexp_interrupt, 0, "EExpress")) {
dev437drivers/net/eexpress.cinit_82586_mem(dev);
dev440drivers/net/eexpress.coutb(irqrmap[dev->irq] | 0x08, ioaddr + SET_IRQ);
dev442drivers/net/eexpress.cdev->tbusy = 0;
dev443drivers/net/eexpress.cdev->interrupt = 0;
dev444drivers/net/eexpress.cdev->start = 1;
dev452drivers/net/eexpress.ceexp_send_packet(struct sk_buff *skb, struct device *dev)
dev454drivers/net/eexpress.cstruct net_local *lp = (struct net_local *)dev->priv;
dev455drivers/net/eexpress.cint ioaddr = dev->base_addr;
dev457drivers/net/eexpress.cif (dev->tbusy) {
dev460drivers/net/eexpress.cint tickssofar = jiffies - dev->trans_start;
dev464drivers/net/eexpress.cprintk("%s: transmit timed out, %s?  ", dev->name,
dev472drivers/net/eexpress.cinit_82586_mem(dev);
dev480drivers/net/eexpress.cdev->tbusy=0;
dev481drivers/net/eexpress.cdev->trans_start = jiffies;
dev488drivers/net/eexpress.cdev_tint(dev);
dev493drivers/net/eexpress.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev494drivers/net/eexpress.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev500drivers/net/eexpress.coutb(irqrmap[dev->irq], ioaddr + SET_IRQ);
dev501drivers/net/eexpress.chardware_send_packet(dev, buf, length);
dev502drivers/net/eexpress.cdev->trans_start = jiffies;
dev504drivers/net/eexpress.coutb(0x08 | irqrmap[dev->irq], ioaddr + SET_IRQ);
dev520drivers/net/eexpress.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev525drivers/net/eexpress.cif (dev == NULL) {
dev529drivers/net/eexpress.cdev->interrupt = 1;
dev531drivers/net/eexpress.cioaddr = dev->base_addr;
dev532drivers/net/eexpress.clp = (struct net_local *)dev->priv;
dev537drivers/net/eexpress.cprintk("%s: EExp interrupt, status %4.4x.\n", dev->name, status);
dev541drivers/net/eexpress.coutb(irqrmap[dev->irq], ioaddr + SET_IRQ);
dev555drivers/net/eexpress.cdev->tbusy = 0;
dev576drivers/net/eexpress.ceexp_rx(dev);
dev582drivers/net/eexpress.cif ((status & 0x0700) != 0x0200  &&  dev->start) {
dev586drivers/net/eexpress.cdev->name, status);
dev601drivers/net/eexpress.cif ((status & 0x0070) != 0x0040  &&  dev->start) {
dev609drivers/net/eexpress.cdev->name, status, lp->rx_head, lp->rx_tail);
dev620drivers/net/eexpress.cinit_rx_bufs(dev);
dev630drivers/net/eexpress.cprintk("%s: EExp exiting interrupt, status %4.4x.\n", dev->name,
dev634drivers/net/eexpress.coutb(irqrmap[dev->irq] | 0x08, ioaddr + SET_IRQ);
dev639drivers/net/eexpress.ceexp_close(struct device *dev)
dev641drivers/net/eexpress.cint ioaddr = dev->base_addr;
dev643drivers/net/eexpress.cdev->tbusy = 1;
dev644drivers/net/eexpress.cdev->start = 0;
dev653drivers/net/eexpress.cfree_irq(dev->irq);
dev655drivers/net/eexpress.cirq2dev_map[dev->irq] = 0;
dev671drivers/net/eexpress.ceexp_get_stats(struct device *dev)
dev673drivers/net/eexpress.cstruct net_local *lp = (struct net_local *)dev->priv;
dev687drivers/net/eexpress.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev691drivers/net/eexpress.cshort ioaddr = dev->base_addr;
dev755drivers/net/eexpress.cinit_82586_mem(struct device *dev)
dev757drivers/net/eexpress.cstruct net_local *lp = (struct net_local *)dev->priv;
dev758drivers/net/eexpress.cshort ioaddr = dev->base_addr;
dev773drivers/net/eexpress.coutsw(ioaddr, dev->dev_addr, 3);
dev783drivers/net/eexpress.cinit_rx_bufs(dev);
dev797drivers/net/eexpress.cdev->name, inw(ioaddr + SCB_STATUS), inw(ioaddr + SCB_CMD));
dev807drivers/net/eexpress.cprintk("%s: Initialized 82586, status %04x.\n", dev->name,
dev813drivers/net/eexpress.cstatic void init_rx_bufs(struct device *dev)
dev815drivers/net/eexpress.cstruct net_local *lp = (struct net_local *)dev->priv;
dev816drivers/net/eexpress.cshort ioaddr = dev->base_addr;
dev854drivers/net/eexpress.chardware_send_packet(struct device *dev, void *buf, short length)
dev856drivers/net/eexpress.cstruct net_local *lp = (struct net_local *)dev->priv;
dev857drivers/net/eexpress.cshort ioaddr = dev->base_addr;
dev894drivers/net/eexpress.c"reap %4x status %4.4x.\n", dev->name, ioaddr, length,
dev899drivers/net/eexpress.cdev->tbusy = 0;
dev903drivers/net/eexpress.ceexp_rx(struct device *dev)
dev905drivers/net/eexpress.cstruct net_local *lp = (struct net_local *)dev->priv;
dev906drivers/net/eexpress.cshort ioaddr = dev->base_addr;
dev928drivers/net/eexpress.c"next %04x data-buf @%04x %04x.\n", dev->name, rx_head,
dev946drivers/net/eexpress.cprintk("%s: Memory squeeze, dropping packet.\n", dev->name);
dev950drivers/net/eexpress.cskb->dev = dev;
dev957drivers/net/eexpress.cskb->protocol=eth_type_trans(skb,dev);
dev969drivers/net/eexpress.cprintk("%s: Rx next frame at %#x is %#x instead of %#x.\n", dev->name,
dev983drivers/net/eexpress.cdev->name, rx_tail, (outw(rx_tail+4, ioaddr + READ_PTR),inw(ioaddr)),
dev140drivers/net/eql.cint        eql_init(struct device *dev); /*  */
dev141drivers/net/eql.cstatic int eql_open(struct device *dev); /*  */
dev142drivers/net/eql.cstatic int eql_close(struct device *dev); /*  */
dev143drivers/net/eql.cstatic int eql_ioctl(struct device *dev, struct ifreq *ifr, int cmd); /*  */
dev144drivers/net/eql.cstatic int eql_slave_xmit(struct sk_buff *skb, struct device *dev); /*  */
dev146drivers/net/eql.cstatic struct enet_statistics *eql_get_stats(struct device *dev); /*  */
dev147drivers/net/eql.cstatic int eql_header(struct sk_buff *skb, struct device *dev, 
dev150drivers/net/eql.cstatic int eql_rebuild_header(void *buff, struct device *dev, 
dev155drivers/net/eql.cstatic int eql_enslave(struct device *dev,  slaving_request_t *srq); /*  */
dev156drivers/net/eql.cstatic int eql_emancipate(struct device *dev, slaving_request_t *srq); /*  */
dev158drivers/net/eql.cstatic int eql_g_slave_cfg(struct device *dev, slave_config_t *sc); /*  */
dev159drivers/net/eql.cstatic int eql_s_slave_cfg(struct device *dev, slave_config_t *sc); /*  */
dev161drivers/net/eql.cstatic int eql_g_master_cfg(struct device *dev, master_config_t *mc); /*  */
dev162drivers/net/eql.cstatic int eql_s_master_cfg(struct device *dev, master_config_t *mc); /*  */
dev164drivers/net/eql.cstatic inline int eql_is_slave(struct device *dev); /*  */
dev165drivers/net/eql.cstatic inline int eql_is_master(struct device *dev); /*  */
dev176drivers/net/eql.cstatic slave_queue_t *eql_new_slave_queue(struct device *dev); /*  */
dev183drivers/net/eql.cstatic int eql_remove_slave_dev(slave_queue_t *queue, struct device *dev); /*  */
dev193drivers/net/eql.cstatic slave_t *eql_find_slave_dev(slave_queue_t *queue, struct device *dev); /*  */
dev205drivers/net/eql.ceql_init(struct device *dev)
dev216drivers/net/eql.cdev->priv = kmalloc (sizeof (equalizer_t), GFP_KERNEL);
dev217drivers/net/eql.cmemset (dev->priv, 0, sizeof (equalizer_t));
dev218drivers/net/eql.ceql = (equalizer_t *) dev->priv;
dev224drivers/net/eql.ceql->timer.data     = (unsigned long) dev->priv;
dev229drivers/net/eql.cdev->open    = eql_open;
dev230drivers/net/eql.cdev->stop    = eql_close;
dev231drivers/net/eql.cdev->do_ioctl         = eql_ioctl;
dev232drivers/net/eql.cdev->hard_start_xmit  = eql_slave_xmit;
dev233drivers/net/eql.cdev->get_stats  = eql_get_stats;
dev239drivers/net/eql.cskb_queue_head_init(&dev->buffs[i]);
dev241drivers/net/eql.cdev->hard_header    = eql_header; 
dev242drivers/net/eql.cdev->rebuild_header = eql_rebuild_header;
dev245drivers/net/eql.cdev->mtu        = EQL_DEFAULT_MTU;  /* set to 576 in eql.h */
dev246drivers/net/eql.cdev->flags      = IFF_MASTER;
dev248drivers/net/eql.cdev->family     = AF_INET;
dev249drivers/net/eql.cdev->pa_addr    = 0;
dev250drivers/net/eql.cdev->pa_brdaddr = 0;
dev251drivers/net/eql.cdev->pa_mask    = 0;
dev252drivers/net/eql.cdev->pa_alen    = 4;
dev254drivers/net/eql.cdev->type       = ARPHRD_SLIP;
dev262drivers/net/eql.ceql_open(struct device *dev)
dev264drivers/net/eql.cequalizer_t *eql = (equalizer_t *) dev->priv;
dev269drivers/net/eql.cprintk ("%s: open\n", dev->name);
dev272drivers/net/eql.cnew_queue = eql_new_slave_queue (dev);
dev276drivers/net/eql.cnew_queue->master_dev = dev;
dev282drivers/net/eql.cprintk ("%s: adding timer\n", dev->name);
dev294drivers/net/eql.ceql_close(struct device *dev)
dev296drivers/net/eql.cequalizer_t *eql = (equalizer_t *) dev->priv;
dev300drivers/net/eql.cprintk ("%s: close\n", dev->name);
dev304drivers/net/eql.cprintk ("%s: stopping timer\n", dev->name);
dev316drivers/net/eql.ceql_ioctl(struct device *dev, struct ifreq *ifr, int cmd)
dev323drivers/net/eql.creturn eql_enslave (dev, (slaving_request_t *) ifr->ifr_data);
dev325drivers/net/eql.creturn eql_emancipate (dev, (slaving_request_t *) ifr->ifr_data);
dev328drivers/net/eql.creturn eql_g_slave_cfg (dev, (slave_config_t *) ifr->ifr_data);
dev330drivers/net/eql.creturn eql_s_slave_cfg (dev, (slave_config_t *) ifr->ifr_data);
dev333drivers/net/eql.creturn eql_g_master_cfg (dev, (master_config_t *) ifr->ifr_data);
dev335drivers/net/eql.creturn eql_s_master_cfg (dev, (master_config_t *) ifr->ifr_data);
dev345drivers/net/eql.ceql_slave_xmit(struct sk_buff *skb, struct device *dev)
dev347drivers/net/eql.cequalizer_t *eql = (equalizer_t *) dev->priv;
dev366drivers/net/eql.cdev->name, eql_number_slaves (eql->queue), skb->len,
dev388drivers/net/eql.ceql_get_stats(struct device *dev)
dev390drivers/net/eql.cequalizer_t *eql = (equalizer_t *) dev->priv;
dev398drivers/net/eql.ceql_header(struct sk_buff *skb, struct device *dev, 
dev408drivers/net/eql.ceql_rebuild_header(void *buff, struct device *dev, 
dev422drivers/net/eql.ceql_enslave(struct device *dev, slaving_request_t *srqp)
dev436drivers/net/eql.cprintk ("%s: enslave '%s' %ld bps\n", dev->name, 
dev440drivers/net/eql.cmaster_dev = dev;    /* for "clarity" */
dev451drivers/net/eql.cs->dev = slave_dev;
dev471drivers/net/eql.ceql_emancipate(struct device *dev, slaving_request_t *srqp)
dev485drivers/net/eql.cprintk ("%s: emancipate `%s`\n", dev->name, srq.slave_name);
dev489drivers/net/eql.cmaster_dev = dev;    /* for "clarity" */
dev507drivers/net/eql.ceql_g_slave_cfg(struct device *dev, slave_config_t *scp)
dev522drivers/net/eql.cprintk ("%s: get config for slave `%s'\n", dev->name, sc.slave_name);
dev525drivers/net/eql.ceql = (equalizer_t *) dev->priv;
dev548drivers/net/eql.ceql_s_slave_cfg(struct device *dev, slave_config_t *scp)
dev561drivers/net/eql.cprintk ("%s: set config for slave `%s'\n", dev->name, sc.slave_name);
dev566drivers/net/eql.ceql = (equalizer_t *) dev->priv;
dev586drivers/net/eql.ceql_g_master_cfg(struct device *dev, master_config_t *mcp)
dev593drivers/net/eql.cprintk ("%s: get master config\n", dev->name);
dev596drivers/net/eql.cif ( eql_is_master (dev) )
dev603drivers/net/eql.ceql = (equalizer_t *) dev->priv;
dev615drivers/net/eql.ceql_s_master_cfg(struct device *dev, master_config_t *mcp)
dev626drivers/net/eql.cprintk ("%s: set master config\n", dev->name);
dev631drivers/net/eql.cif ( eql_is_master (dev) )
dev633drivers/net/eql.ceql = (equalizer_t *) dev->priv;
dev647drivers/net/eql.ceql_is_slave(struct device *dev)
dev649drivers/net/eql.cif (dev)
dev651drivers/net/eql.cif ((dev->flags & IFF_SLAVE) == IFF_SLAVE)
dev660drivers/net/eql.ceql_is_master(struct device *dev)
dev662drivers/net/eql.cif (dev)
dev664drivers/net/eql.cif ((dev->flags & IFF_MASTER) == IFF_MASTER)
dev745drivers/net/eql.ceql_new_slave_queue(struct device *dev)
dev764drivers/net/eql.cqueue->master_dev = dev;
dev805drivers/net/eql.cduplicate_slave = eql_find_slave_dev (queue, slave->dev);
dev839drivers/net/eql.ccurrent->dev != 0 )
dev862drivers/net/eql.ceql_insert_slave_dev(slave_queue_t *queue, struct device *dev)
dev871drivers/net/eql.cslave->dev = dev;
dev888drivers/net/eql.ceql_remove_slave_dev(slave_queue_t *queue, struct device *dev)
dev894drivers/net/eql.ctarget = eql_find_slave_dev (queue, dev);
dev925drivers/net/eql.cif (queue->best_slave->dev != 0)
dev926drivers/net/eql.creturn queue->best_slave->dev;
dev988drivers/net/eql.cif ( slave->dev != 0)
dev990drivers/net/eql.cif ((slave->dev->flags & IFF_UP) == IFF_UP )
dev1030drivers/net/eql.ceql_find_slave_dev(slave_queue_t *queue, struct device *dev)
dev1036drivers/net/eql.cwhile (slave != 0 && slave->dev != dev && slave != 0)
dev1039drivers/net/eql.cif (slave->dev != 0)
dev1040drivers/net/eql.cprintk ("eql: find_slave_dev; looked at '%s'...\n", slave->dev->name);
dev1137drivers/net/eql.cif ((slave->dev->flags & IFF_UP) == IFF_UP )
dev291drivers/net/ewrk3.cstatic int ewrk3_open(struct device *dev);
dev292drivers/net/ewrk3.cstatic int ewrk3_queue_pkt(struct sk_buff *skb, struct device *dev);
dev294drivers/net/ewrk3.cstatic int ewrk3_close(struct device *dev);
dev295drivers/net/ewrk3.cstatic struct enet_statistics *ewrk3_get_stats(struct device *dev);
dev296drivers/net/ewrk3.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev297drivers/net/ewrk3.cstatic int ewrk3_ioctl(struct device *dev, struct ifreq *rq, int cmd);
dev302drivers/net/ewrk3.cstatic int  ewrk3_hw_init(struct device *dev, short iobase);
dev303drivers/net/ewrk3.cstatic void ewrk3_init(struct device *dev);
dev304drivers/net/ewrk3.cstatic int  ewrk3_rx(struct device *dev);
dev305drivers/net/ewrk3.cstatic int  ewrk3_tx(struct device *dev);
dev309drivers/net/ewrk3.cstatic void SetMulticastFilter(struct device *dev, int num_addrs, char *addrs, char *multicast_table);
dev313drivers/net/ewrk3.cstatic unsigned char aprom_crc (struct device *dev, unsigned char *eeprom_image, char chipType);
dev316drivers/net/ewrk3.cstatic struct device *isa_probe(struct device *dev);
dev317drivers/net/ewrk3.cstatic struct device *eisa_probe(struct device *dev);
dev318drivers/net/ewrk3.cstatic struct device *alloc_device(struct device *dev, int iobase);
dev343drivers/net/ewrk3.cint ewrk3_probe(struct device *dev)
dev345drivers/net/ewrk3.cint base_addr = dev->base_addr;
dev358drivers/net/ewrk3.cstatus = ewrk3_hw_init(dev, base_addr);
dev365drivers/net/ewrk3.cprintk("%s: ewrk3_probe(): Detected a device already registered at 0x%02x\n", dev->name, base_addr);
dev369drivers/net/ewrk3.cstatus = ewrk3_hw_init(dev, base_addr);
dev381drivers/net/ewrk3.ceth0=isa_probe(dev);
dev383drivers/net/ewrk3.cif (dev->priv) status=0;
dev391drivers/net/ewrk3.cif (status) dev->base_addr = base_addr;
dev397drivers/net/ewrk3.cewrk3_hw_init(struct device *dev, short iobase)
dev439drivers/net/ewrk3.cprintk("%s: Device has a bad on-board EEPROM.\n", dev->name);
dev448drivers/net/ewrk3.cdev->base_addr = iobase;
dev459drivers/net/ewrk3.cprintk("%s: %s at %#3x", dev->name, name, iobase);
dev464drivers/net/ewrk3.cdev->name, name, iobase, ((iobase>>12)&0x0f));
dev466drivers/net/ewrk3.cprintk("%s: %s at %#3x", dev->name, name, iobase);
dev473drivers/net/ewrk3.cprintk("%2.2x:", dev->dev_addr[i] = 
dev477drivers/net/ewrk3.cprintk("%2.2x,\n",dev->dev_addr[i] = eeprom_image[EEPROM_PADDR0 + i]);
dev482drivers/net/ewrk3.cprintk("%2.2x:", dev->dev_addr[i] = inb(EWRK3_APROM));
dev483drivers/net/ewrk3.coutb(dev->dev_addr[i], EWRK3_PAR0 + i);
dev485drivers/net/ewrk3.cprintk("%2.2x,\n", dev->dev_addr[i] = inb(EWRK3_APROM));
dev486drivers/net/ewrk3.coutb(dev->dev_addr[i], EWRK3_PAR0 + i);
dev489drivers/net/ewrk3.cif (aprom_crc(dev, eeprom_image, lemac)) {
dev549drivers/net/ewrk3.cdev->priv = (void *) kmalloc(sizeof(struct ewrk3_private), 
dev551drivers/net/ewrk3.clp = (struct ewrk3_private *)dev->priv;
dev552drivers/net/ewrk3.cmemset(dev->priv, 0, sizeof(struct ewrk3_private));
dev569drivers/net/ewrk3.cdev->dma = 0;
dev573drivers/net/ewrk3.cif (dev->irq < 2) {
dev588drivers/net/ewrk3.cdev->irq = autoirq_report(1);
dev589drivers/net/ewrk3.cif ((dev->irq) && (irqnum == dev->irq)) {
dev590drivers/net/ewrk3.cprintk(" and uses IRQ%d.\n", dev->irq);
dev592drivers/net/ewrk3.cif (!dev->irq) {
dev606drivers/net/ewrk3.cprintk(" and requires IRQ%d.\n", dev->irq);
dev625drivers/net/ewrk3.cdev->open = &ewrk3_open;
dev626drivers/net/ewrk3.cdev->hard_start_xmit = &ewrk3_queue_pkt;
dev627drivers/net/ewrk3.cdev->stop = &ewrk3_close;
dev628drivers/net/ewrk3.cdev->get_stats = &ewrk3_get_stats;
dev630drivers/net/ewrk3.cdev->set_multicast_list = &set_multicast_list;
dev632drivers/net/ewrk3.cdev->do_ioctl = &ewrk3_ioctl;
dev634drivers/net/ewrk3.cdev->mem_start = 0;
dev637drivers/net/ewrk3.cether_setup(dev);
dev648drivers/net/ewrk3.cewrk3_open(struct device *dev)
dev650drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev651drivers/net/ewrk3.cint i, iobase = dev->base_addr;
dev661drivers/net/ewrk3.cif (request_irq(dev->irq, &ewrk3_interrupt, 0, "ewrk3")) {
dev662drivers/net/ewrk3.cprintk("ewrk3_open(): Requested IRQ%d is busy\n",dev->irq);
dev666drivers/net/ewrk3.cirq2dev_map[dev->irq] = dev;
dev671drivers/net/ewrk3.cewrk3_init(dev);
dev674drivers/net/ewrk3.cprintk("%s: ewrk3 open with irq %d\n",dev->name,dev->irq);
dev677drivers/net/ewrk3.cprintk("%2.2x:",(short)dev->dev_addr[i]);
dev695drivers/net/ewrk3.cdev->tbusy = 0;                         
dev696drivers/net/ewrk3.cdev->start = 1;
dev697drivers/net/ewrk3.cdev->interrupt = UNMASK_INTERRUPTS;
dev707drivers/net/ewrk3.cdev->start = 0;
dev708drivers/net/ewrk3.cdev->tbusy = 1;
dev709drivers/net/ewrk3.cprintk("%s: ewrk3 available for hard strapped set up only.\n", dev->name);
dev725drivers/net/ewrk3.cewrk3_init(struct device *dev)
dev727drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev729drivers/net/ewrk3.cshort iobase = dev->base_addr;
dev734drivers/net/ewrk3.cset_multicast_list(dev, HASH_TABLE_LEN, NULL);
dev760drivers/net/ewrk3.cewrk3_queue_pkt(struct sk_buff *skb, struct device *dev)
dev762drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev763drivers/net/ewrk3.cint iobase = dev->base_addr;
dev768drivers/net/ewrk3.cif (dev->tbusy || lp->lock) {
dev769drivers/net/ewrk3.cint tickssofar = jiffies - dev->trans_start;
dev774drivers/net/ewrk3.cdev->name, inb(EWRK3_CSR));
dev786drivers/net/ewrk3.cewrk3_init(dev);
dev793drivers/net/ewrk3.cdev->tbusy=0;
dev794drivers/net/ewrk3.cdev->trans_start = jiffies;
dev797drivers/net/ewrk3.cdev_tint(dev);
dev804drivers/net/ewrk3.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev805drivers/net/ewrk3.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev836drivers/net/ewrk3.cprintk("%s: Oops - your private data area is hosed!\n",dev->name);
dev877drivers/net/ewrk3.cdev->trans_start = jiffies;
dev896drivers/net/ewrk3.cdev->tbusy = 0;
dev911drivers/net/ewrk3.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev916drivers/net/ewrk3.cif (dev == NULL) {
dev919drivers/net/ewrk3.clp = (struct ewrk3_private *)dev->priv;
dev920drivers/net/ewrk3.ciobase = dev->base_addr;
dev922drivers/net/ewrk3.cif (dev->interrupt)
dev923drivers/net/ewrk3.cprintk("%s: Re-entering the interrupt handler.\n", dev->name);
dev925drivers/net/ewrk3.cdev->interrupt = MASK_INTERRUPTS;
dev940drivers/net/ewrk3.cewrk3_rx(dev);
dev943drivers/net/ewrk3.cewrk3_tx(dev);
dev955drivers/net/ewrk3.cdev->tbusy = 0;           /* clear TX busy flag */
dev965drivers/net/ewrk3.cdev->interrupt = UNMASK_INTERRUPTS;
dev974drivers/net/ewrk3.cewrk3_rx(struct device *dev)
dev976drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev977drivers/net/ewrk3.cint i, iobase = dev->base_addr;
dev1013drivers/net/ewrk3.cprintk("%s: Oops - your private data area is hosed!\n",dev->name);
dev1040drivers/net/ewrk3.cskb->dev = dev;
dev1058drivers/net/ewrk3.cskb->protocol=eth_type_trans(skb,dev);
dev1078drivers/net/ewrk3.c} else if ((*(long *)&buf[0] == *(long *)&dev->dev_addr[0]) &&
dev1079drivers/net/ewrk3.c(*(short *)&buf[4] == *(short *)&dev->dev_addr[4])) {
dev1088drivers/net/ewrk3.cprintk("%s: Insufficient memory; nuking packet.\n", dev->name);
dev1119drivers/net/ewrk3.cewrk3_tx(struct device *dev)
dev1121drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev1122drivers/net/ewrk3.cint iobase = dev->base_addr;
dev1154drivers/net/ewrk3.cewrk3_close(struct device *dev)
dev1156drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev1157drivers/net/ewrk3.cint iobase = dev->base_addr;
dev1160drivers/net/ewrk3.cdev->start = 0;
dev1161drivers/net/ewrk3.cdev->tbusy = 1;
dev1165drivers/net/ewrk3.cdev->name, inb(EWRK3_CSR));
dev1186drivers/net/ewrk3.cfree_irq(dev->irq);
dev1188drivers/net/ewrk3.cirq2dev_map[dev->irq] = 0;
dev1199drivers/net/ewrk3.cewrk3_get_stats(struct device *dev)
dev1201drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev1216drivers/net/ewrk3.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev1218drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev1219drivers/net/ewrk3.cint iobase = dev->base_addr;
dev1232drivers/net/ewrk3.cSetMulticastFilter(dev, num_addrs, (char *)addrs, multicast_table);
dev1251drivers/net/ewrk3.cstatic void SetMulticastFilter(struct device *dev, int num_addrs, char *addrs, char *multicast_table)
dev1253drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev1254drivers/net/ewrk3.cint i, iobase = dev->base_addr;
dev1334drivers/net/ewrk3.cstatic struct device *isa_probe(struct device *dev)
dev1352drivers/net/ewrk3.cdev = alloc_device(dev, iobase);
dev1354drivers/net/ewrk3.cif ((status = ewrk3_hw_init(dev, iobase)) == 0) {
dev1363drivers/net/ewrk3.cprintk("%s: ewrk3_probe(): Detected a device already registered at 0x%02x\n", dev->name, iobase);
dev1370drivers/net/ewrk3.creturn dev;
dev1377drivers/net/ewrk3.cstatic struct device *eisa_probe(struct device *dev)
dev1395drivers/net/ewrk3.cdev = alloc_device(dev, iobase);
dev1397drivers/net/ewrk3.cif ((status = ewrk3_hw_init(dev, iobase)) == 0) {
dev1405drivers/net/ewrk3.creturn dev;
dev1412drivers/net/ewrk3.cstatic struct device *alloc_device(struct device *dev, int iobase)
dev1417drivers/net/ewrk3.cwhile (dev->next != NULL) {
dev1418drivers/net/ewrk3.cif (dev->next->base_addr == 0xffe0) break;
dev1419drivers/net/ewrk3.cdev = dev->next;         /* walk through eth device list */
dev1427drivers/net/ewrk3.cif (dev->next == NULL) {
dev1428drivers/net/ewrk3.cdev->next = (struct device *)kmalloc(sizeof(struct device) + 8,
dev1430drivers/net/ewrk3.cif (dev->next == NULL) {
dev1441drivers/net/ewrk3.cif ((dev->next != NULL) &&
dev1443drivers/net/ewrk3.cdev = dev->next;                    /* point to the new device */
dev1444drivers/net/ewrk3.cdev->name = (char *)(dev + sizeof(struct device));
dev1445drivers/net/ewrk3.csprintf(dev->name,"eth%d", num_eth);/* New device name */
dev1446drivers/net/ewrk3.cdev->base_addr = iobase;            /* assign the io address */
dev1447drivers/net/ewrk3.cdev->next = NULL;                   /* mark the end of list */
dev1448drivers/net/ewrk3.cdev->init = &ewrk3_probe;           /* initialisation routine */
dev1452drivers/net/ewrk3.creturn dev;
dev1576drivers/net/ewrk3.cstatic unsigned char aprom_crc(struct device *dev, unsigned char *eeprom_image, char chipType)
dev1581drivers/net/ewrk3.cint iobase = dev->base_addr;
dev1611drivers/net/ewrk3.cstatic int ewrk3_ioctl(struct device *dev, struct ifreq *rq, int cmd)
dev1613drivers/net/ewrk3.cstruct ewrk3_private *lp = (struct ewrk3_private *)dev->priv;
dev1615drivers/net/ewrk3.cint i, j, iobase = dev->base_addr, status = 0;
dev1626drivers/net/ewrk3.ctmp.addr[i] = dev->dev_addr[i];
dev1645drivers/net/ewrk3.cdev->dev_addr[i] = tmp.addr[i];
dev1678drivers/net/ewrk3.cprintk("%s: Boo!\n", dev->name);
dev1709drivers/net/ewrk3.cset_multicast_list(dev, ioc->len, tmp.addr);
dev1717drivers/net/ewrk3.cset_multicast_list(dev, 0, NULL);
dev37drivers/net/hp-plus.cextern struct device *init_etherdev(struct device *dev, int sizeof_private,
dev95drivers/net/hp-plus.cint hpplus_probe(struct device *dev);
dev96drivers/net/hp-plus.cint hpp_probe1(struct device *dev, int ioaddr);
dev98drivers/net/hp-plus.cstatic void hpp_reset_8390(struct device *dev);
dev99drivers/net/hp-plus.cstatic int hpp_open(struct device *dev);
dev100drivers/net/hp-plus.cstatic int hpp_close(struct device *dev);
dev101drivers/net/hp-plus.cstatic int hpp_mem_block_input(struct device *dev, int count,
dev103drivers/net/hp-plus.cstatic void hpp_mem_block_output(struct device *dev, int count,
dev105drivers/net/hp-plus.cstatic int hpp_io_block_input(struct device *dev, int count,
dev107drivers/net/hp-plus.cstatic void hpp_io_block_output(struct device *dev, int count,
dev120drivers/net/hp-plus.cint hp_plus_probe(struct device *dev)
dev123drivers/net/hp-plus.cint base_addr = dev ? dev->base_addr : 0;
dev126drivers/net/hp-plus.creturn hpp_probe1(dev, base_addr);
dev134drivers/net/hp-plus.cif (hpp_probe1(dev, ioaddr) == 0)
dev143drivers/net/hp-plus.cint hpp_probe1(struct device *dev, int ioaddr)
dev155drivers/net/hp-plus.cif (dev == NULL)
dev156drivers/net/hp-plus.cdev = init_etherdev(0, sizeof(struct ei_device), 0);
dev158drivers/net/hp-plus.cprintk("%s: %s at %#3x,", dev->name, name, ioaddr);
dev165drivers/net/hp-plus.cdev->dev_addr[i] = inval;
dev189drivers/net/hp-plus.cdev->irq = irq;
dev205drivers/net/hp-plus.cdev->base_addr = ioaddr + NIC_OFFSET;
dev207drivers/net/hp-plus.cethdev_init(dev);
dev209drivers/net/hp-plus.cdev->open = &hpp_open;
dev210drivers/net/hp-plus.cdev->stop = &hpp_close;
dev226drivers/net/hp-plus.cdev->mem_start = mem_start;
dev227drivers/net/hp-plus.cdev->rmem_start = dev->mem_start + TX_2X_PAGES*256;
dev228drivers/net/hp-plus.cdev->mem_end = dev->rmem_end
dev229drivers/net/hp-plus.c= dev->mem_start + (HP_STOP_PG - HP_START_PG)*256;
dev233drivers/net/hp-plus.cNS8390_init(dev, 0);
dev241drivers/net/hp-plus.chpp_open(struct device *dev)
dev243drivers/net/hp-plus.cint ioaddr = dev->base_addr - NIC_OFFSET;
dev246drivers/net/hp-plus.cif (request_irq(dev->irq, &ei_interrupt, 0, "hp-plus")) {
dev264drivers/net/hp-plus.creturn ei_open(dev);
dev268drivers/net/hp-plus.chpp_close(struct device *dev)
dev270drivers/net/hp-plus.cint ioaddr = dev->base_addr - NIC_OFFSET;
dev273drivers/net/hp-plus.cfree_irq(dev->irq);
dev274drivers/net/hp-plus.cirq2dev_map[dev->irq] = NULL;
dev275drivers/net/hp-plus.cNS8390_init(dev, 0);
dev283drivers/net/hp-plus.chpp_reset_8390(struct device *dev)
dev285drivers/net/hp-plus.cint ioaddr = dev->base_addr - NIC_OFFSET;
dev301drivers/net/hp-plus.cprintk("%s: hp_reset_8390() did not complete.\n", dev->name);
dev311drivers/net/hp-plus.chpp_io_block_input(struct device *dev, int count, char *buf, int ring_offset)
dev313drivers/net/hp-plus.cint ioaddr = dev->base_addr - NIC_OFFSET;
dev323drivers/net/hp-plus.chpp_mem_block_input(struct device *dev, int count, char *buf, int ring_offset)
dev325drivers/net/hp-plus.cint ioaddr = dev->base_addr - NIC_OFFSET;
dev332drivers/net/hp-plus.cmemcpy(buf, (char*)dev->mem_start,  (count + 3) & ~3);
dev341drivers/net/hp-plus.chpp_io_block_output(struct device *dev, int count,
dev344drivers/net/hp-plus.cint ioaddr = dev->base_addr - NIC_OFFSET;
dev351drivers/net/hp-plus.chpp_mem_block_output(struct device *dev, int count,
dev354drivers/net/hp-plus.cint ioaddr = dev->base_addr - NIC_OFFSET;
dev359drivers/net/hp-plus.cmemcpy((char *)dev->mem_start, buf, (count + 3) & ~3);
dev34drivers/net/hp.cextern struct device *init_etherdev(struct device *dev, int sizeof_private,
dev55drivers/net/hp.cint hp_probe(struct device *dev);
dev56drivers/net/hp.cint hp_probe1(struct device *dev, int ioaddr);
dev58drivers/net/hp.cstatic void hp_reset_8390(struct device *dev);
dev59drivers/net/hp.cstatic int hp_block_input(struct device *dev, int count,
dev61drivers/net/hp.cstatic void hp_block_output(struct device *dev, int count,
dev63drivers/net/hp.cstatic void hp_init_card(struct device *dev);
dev78drivers/net/hp.cint hp_probe(struct device *dev)
dev81drivers/net/hp.cint base_addr = dev ? dev->base_addr : 0;
dev84drivers/net/hp.creturn hp_probe1(dev, base_addr);
dev92drivers/net/hp.cif (hp_probe1(dev, ioaddr) == 0)
dev100drivers/net/hp.cint hp_probe1(struct device *dev, int ioaddr)
dev124drivers/net/hp.cif (dev == NULL)
dev125drivers/net/hp.cdev = init_etherdev(0, sizeof(struct ei_device), 0);
dev130drivers/net/hp.cprintk("%s: %s (ID %02x) at %#3x,", dev->name, name, board_id, ioaddr);
dev133drivers/net/hp.cprintk(" %2.2x", dev->dev_addr[i] = inb(ioaddr + i));
dev136drivers/net/hp.cif (dev->irq < 2) {
dev150drivers/net/hp.cdev->irq = *irqp;
dev160drivers/net/hp.cif (dev->irq == 2)
dev161drivers/net/hp.cdev->irq = 9;
dev162drivers/net/hp.cif (request_irq(dev->irq, ei_interrupt, 0, "hp")) {
dev163drivers/net/hp.cprintk (" unable to get IRQ %d.\n", dev->irq);
dev172drivers/net/hp.cdev->base_addr = ioaddr + NIC_OFFSET;
dev174drivers/net/hp.cethdev_init(dev);
dev185drivers/net/hp.chp_init_card(dev);
dev191drivers/net/hp.chp_reset_8390(struct device *dev)
dev193drivers/net/hp.cint hp_base = dev->base_addr - NIC_OFFSET;
dev207drivers/net/hp.cprintk("%s: hp_reset_8390() did not complete.\n", dev->name);
dev219drivers/net/hp.chp_block_input(struct device *dev, int count, char *buf, int ring_offset)
dev221drivers/net/hp.cint nic_base = dev->base_addr;
dev247drivers/net/hp.cdev->name, ring_offset + xfer_count, addr);
dev254drivers/net/hp.chp_block_output(struct device *dev, int count,
dev257drivers/net/hp.cint nic_base = dev->base_addr;
dev304drivers/net/hp.cdev->name, (start_page << 8) + count, addr);
dev312drivers/net/hp.chp_init_card(struct device *dev)
dev314drivers/net/hp.cint irq = dev->irq;
dev315drivers/net/hp.cNS8390_init(dev, 0);
dev317drivers/net/hp.cdev->base_addr - NIC_OFFSET + HP_CONFIGURE);
dev153drivers/net/hp100.cstatic int hp100_probe1( struct device *dev, int ioaddr );
dev154drivers/net/hp100.cstatic int hp100_open( struct device *dev );
dev155drivers/net/hp100.cstatic int hp100_close( struct device *dev );
dev156drivers/net/hp100.cstatic int hp100_start_xmit( struct sk_buff *skb, struct device *dev );
dev157drivers/net/hp100.cstatic void hp100_rx( struct device *dev );
dev158drivers/net/hp100.cstatic struct enet_statistics *hp100_get_stats( struct device *dev );
dev159drivers/net/hp100.cstatic void hp100_update_stats( struct device *dev );
dev161drivers/net/hp100.cstatic void hp100_set_multicast_list( struct device *dev, int num_addrs, void *addrs );
dev169drivers/net/hp100.cstatic void hp100_start_interface( struct device *dev );
dev170drivers/net/hp100.cstatic void hp100_stop_interface( struct device *dev );
dev171drivers/net/hp100.cstatic void hp100_load_eeprom( struct device *dev );
dev172drivers/net/hp100.cstatic int hp100_sense_lan( struct device *dev );
dev173drivers/net/hp100.cstatic int hp100_login_to_vg_hub( struct device *dev );
dev174drivers/net/hp100.cstatic int hp100_down_vg_link( struct device *dev );
dev180drivers/net/hp100.cint hp100_probe( struct device *dev )
dev182drivers/net/hp100.cint base_addr = dev ? dev -> base_addr : 0;
dev186drivers/net/hp100.creturn hp100_probe1(dev, base_addr);
dev195drivers/net/hp100.cif ( hp100_probe1( dev, ioaddr ) == 0 ) return 0;
dev203drivers/net/hp100.cif ( hp100_probe1( dev, ioaddr ) == 0 ) return 0;
dev209drivers/net/hp100.cstatic int hp100_probe1( struct device *dev, int ioaddr )
dev217drivers/net/hp100.cif ( dev == NULL )
dev231drivers/net/hp100.cdev -> base_addr = ioaddr;
dev289drivers/net/hp100.cif ( ( dev -> priv = kmalloc( sizeof( struct hp100_private ), GFP_KERNEL ) ) == NULL )
dev291drivers/net/hp100.cmemset( dev -> priv, 0, sizeof( struct hp100_private ) );
dev293drivers/net/hp100.clp = (struct hp100_private *)dev -> priv;
dev300drivers/net/hp100.cdev -> base_addr = ioaddr;
dev302drivers/net/hp100.cdev -> irq = hp100_inb( IRQ_CHANNEL ) & HP100_IRQ_MASK;
dev303drivers/net/hp100.cif ( dev -> irq == 2 ) dev -> irq = 9;
dev311drivers/net/hp100.cdev -> open = hp100_open;
dev312drivers/net/hp100.cdev -> stop = hp100_close;
dev313drivers/net/hp100.cdev -> hard_start_xmit = hp100_start_xmit;
dev314drivers/net/hp100.cdev -> get_stats = hp100_get_stats;
dev316drivers/net/hp100.cdev -> set_multicast_list = &hp100_set_multicast_list;
dev320drivers/net/hp100.crequest_region( dev -> base_addr, 0x20, eid -> name );
dev325drivers/net/hp100.cdev -> dev_addr[ i ] = hp100_inb( LAN_ADDR + i );
dev327drivers/net/hp100.cether_setup( dev );
dev329drivers/net/hp100.clp -> lan_type = hp100_sense_lan( dev );
dev332drivers/net/hp100.cdev -> name, lp -> id -> name, ioaddr, dev -> irq, 
dev348drivers/net/hp100.cstatic int hp100_open( struct device *dev )
dev351drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev352drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev354drivers/net/hp100.cif ( request_irq( dev -> irq, hp100_interrupt, SA_INTERRUPT, lp -> id -> name ) )
dev356drivers/net/hp100.cprintk( "%s: unable to get IRQ %d\n", dev -> name, dev -> irq );
dev359drivers/net/hp100.cirq2dev_map[ dev -> irq ] = dev;
dev365drivers/net/hp100.cdev -> tbusy = 0;
dev366drivers/net/hp100.cdev -> trans_start = jiffies;
dev367drivers/net/hp100.cdev -> interrupt = 0;
dev368drivers/net/hp100.cdev -> start = 1;
dev370drivers/net/hp100.clp -> lan_type = hp100_sense_lan( dev );
dev377drivers/net/hp100.chp100_stop_interface( dev );
dev379drivers/net/hp100.chp100_load_eeprom( dev );
dev394drivers/net/hp100.chp100_outb( dev -> dev_addr[ i ], MAC_ADDR + i );
dev410drivers/net/hp100.clp -> hub_status = hp100_login_to_vg_hub( dev );
dev412drivers/net/hp100.chp100_start_interface( dev );
dev417drivers/net/hp100.cstatic int hp100_close( struct device *dev )
dev419drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev420drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev425drivers/net/hp100.chp100_stop_interface( dev );
dev428drivers/net/hp100.chp100_login_to_vg_hub( dev );
dev430drivers/net/hp100.cdev -> tbusy = 1;
dev431drivers/net/hp100.cdev -> start = 0;
dev433drivers/net/hp100.cfree_irq( dev -> irq );
dev434drivers/net/hp100.cirq2dev_map[ dev -> irq ] = NULL;
dev445drivers/net/hp100.cstatic int hp100_start_xmit( struct sk_buff *skb, struct device *dev )
dev448drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev450drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev454drivers/net/hp100.chp100_stop_interface( dev );
dev455drivers/net/hp100.cif ( ( lp -> lan_type = hp100_sense_lan( dev ) ) < 0 )
dev457drivers/net/hp100.cprintk( "%s: no connection found - check wire\n", dev -> name );
dev458drivers/net/hp100.chp100_start_interface( dev );  /* 10Mb/s RX packets maybe handled */
dev462drivers/net/hp100.clp -> hub_status = hp100_login_to_vg_hub( dev );
dev463drivers/net/hp100.chp100_start_interface( dev );
dev471drivers/net/hp100.cif ( jiffies - dev -> trans_start < 2 * HZ ) return -EAGAIN;
dev475drivers/net/hp100.cprintk( "%s: login to 100Mb/s hub retry\n", dev -> name );
dev476drivers/net/hp100.chp100_stop_interface( dev );
dev477drivers/net/hp100.clp -> hub_status = hp100_login_to_vg_hub( dev );
dev478drivers/net/hp100.chp100_start_interface( dev );
dev483drivers/net/hp100.ci = hp100_sense_lan( dev );
dev487drivers/net/hp100.cprintk( "%s: link down detected\n", dev -> name );
dev492drivers/net/hp100.cprintk( "%s: cable change 10Mb/s <-> 100Mb/s detected\n", dev -> name );
dev494drivers/net/hp100.chp100_stop_interface( dev );
dev496drivers/net/hp100.clp -> hub_status = hp100_login_to_vg_hub( dev );
dev497drivers/net/hp100.chp100_start_interface( dev );
dev501drivers/net/hp100.cprintk( "%s: interface reset\n", dev -> name );
dev502drivers/net/hp100.chp100_stop_interface( dev );
dev503drivers/net/hp100.chp100_start_interface( dev );
dev506drivers/net/hp100.cdev -> trans_start = jiffies;
dev512drivers/net/hp100.cdev_tint( dev );
dev549drivers/net/hp100.cdev -> trans_start = jiffies;
dev565drivers/net/hp100.cstatic void hp100_rx( struct device *dev )
dev568drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev569drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev576drivers/net/hp100.cif ( ( lp -> lan_type = hp100_sense_lan( dev ) ) == HP100_LAN_100 )
dev577drivers/net/hp100.clp -> hub_status = hp100_login_to_vg_hub( dev );
dev616drivers/net/hp100.cskb -> dev = dev;
dev618drivers/net/hp100.cskb->protocol=eth_type_trans(skb,dev);
dev638drivers/net/hp100.cstatic struct enet_statistics *hp100_get_stats( struct device *dev )
dev640drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev643drivers/net/hp100.chp100_update_stats( dev );
dev645drivers/net/hp100.creturn &((struct hp100_private *)dev -> priv) -> stats;
dev648drivers/net/hp100.cstatic void hp100_update_stats( struct device *dev )
dev650drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev652drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev682drivers/net/hp100.cstatic void hp100_set_multicast_list( struct device *dev, int num_addrs, void *addrs )
dev684drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev685drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev735drivers/net/hp100.cstruct device *dev = (struct device *)irq2dev_map[ irq ];
dev740drivers/net/hp100.cif ( dev == NULL ) return;
dev741drivers/net/hp100.cioaddr = dev -> base_addr;
dev742drivers/net/hp100.cif ( dev -> interrupt )
dev743drivers/net/hp100.cprintk( "%s: re-entering the interrupt handler\n", dev -> name );
dev745drivers/net/hp100.cdev -> interrupt = 1;
dev753drivers/net/hp100.chp100_rx( dev );
dev762drivers/net/hp100.clp = (struct hp100_private *)dev -> priv;
dev763drivers/net/hp100.chp100_update_stats( dev );
dev769drivers/net/hp100.cdev -> interrupt = 0;
dev777drivers/net/hp100.cstatic void hp100_start_interface( struct device *dev )
dev779drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev780drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev796drivers/net/hp100.cstatic void hp100_stop_interface( struct device *dev )
dev798drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev813drivers/net/hp100.cprintk( "%s: hp100_stop_interface - timeout\n", dev -> name );
dev816drivers/net/hp100.cstatic void hp100_load_eeprom( struct device *dev )
dev819drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev826drivers/net/hp100.cprintk( "%s: hp100_load_eeprom - timeout\n", dev -> name );
dev831drivers/net/hp100.cstatic int hp100_sense_lan( struct device *dev )
dev834drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev836drivers/net/hp100.cstruct hp100_private *lp = (struct hp100_private *)dev -> priv;
dev856drivers/net/hp100.cstatic int hp100_down_vg_link( struct device *dev )
dev858drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev880drivers/net/hp100.cstatic int hp100_login_to_vg_hub( struct device *dev )
dev883drivers/net/hp100.cint ioaddr = dev -> base_addr;
dev901drivers/net/hp100.cif ( hp100_down_vg_link( dev ) < 0 )  /* if fail, try reset VG link */
dev926drivers/net/hp100.cprintk( "%s: 100Mb cable training failed, check cable.\n", dev -> name );
dev928drivers/net/hp100.cprintk( "%s: 100Mb node not accepted by hub, check frame type or security.\n", dev -> name );
dev931drivers/net/hp100.chp100_down_vg_link( dev );
dev77drivers/net/ibmtr.c#define DPRINTK(format, args...) printk("%s: " format, dev->name , ## args)
dev78drivers/net/ibmtr.c#define DPRINTD(format, args...) DummyCall("%s: " format, dev->name , ## args)
dev86drivers/net/ibmtr.cvoid (*do_tok_int)(struct device *dev)=NULL;
dev98drivers/net/ibmtr.cint tok_probe(struct device *dev);
dev104drivers/net/ibmtr.cstatic void initial_tok_int(struct device *dev);
dev106drivers/net/ibmtr.cstatic void open_sap(unsigned char type,struct device *dev);
dev108drivers/net/ibmtr.cstatic void tr_rx(struct device *dev);
dev109drivers/net/ibmtr.cstatic void tr_tx(struct device *dev);
dev111drivers/net/ibmtr.cstatic int tok_open(struct device *dev);
dev112drivers/net/ibmtr.cstatic int tok_close(struct device *dev);
dev113drivers/net/ibmtr.cstatic int tok_send_packet(struct sk_buff *skb, struct device *dev);
dev114drivers/net/ibmtr.cstatic struct enet_statistics * tok_get_stats(struct device *dev);
dev142drivers/net/ibmtr.cint tok_probe(struct device *dev) {
dev255drivers/net/ibmtr.cdev->priv = ti;     /* this seems like the logical use of the
dev308drivers/net/ibmtr.cdev->dev_addr[(j/2)]=ti->hw_address[j]+(ti->hw_address[j-1]<<4);
dev419drivers/net/ibmtr.cif (request_irq (dev->irq = irq, &tok_interrupt,0,"IBM TR") != 0) {
dev424drivers/net/ibmtr.cirq2dev_map[irq]=dev;
dev428drivers/net/ibmtr.cdev->base_addr=PIOaddr; /* set the value for device */
dev430drivers/net/ibmtr.cdev->open=tok_open;
dev431drivers/net/ibmtr.cdev->stop=tok_close;
dev432drivers/net/ibmtr.cdev->hard_start_xmit=tok_send_packet;
dev433drivers/net/ibmtr.cdev->get_stats = NULL;
dev434drivers/net/ibmtr.cdev->get_stats = tok_get_stats;
dev435drivers/net/ibmtr.cdev->set_multicast_list = NULL;
dev436drivers/net/ibmtr.ctr_setup(dev);
dev437drivers/net/ibmtr.ctok_init_card((unsigned long)dev);
dev465drivers/net/ibmtr.cstatic int tok_open(struct device *dev) {
dev467drivers/net/ibmtr.cstruct tok_info *ti=(struct tok_info *)dev->priv;
dev470drivers/net/ibmtr.ctok_init_card((unsigned long)dev);
dev478drivers/net/ibmtr.cdev->tbusy=0;
dev479drivers/net/ibmtr.cdev->interrupt=0;
dev480drivers/net/ibmtr.cdev->start=1;
dev490drivers/net/ibmtr.cstatic int tok_close(struct device *dev) {
dev492drivers/net/ibmtr.cstruct tok_info *ti=(struct tok_info *) dev->priv;
dev515drivers/net/ibmtr.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev517drivers/net/ibmtr.cDPRINTK("Int from tok_driver, dev : %p\n",dev);
dev519drivers/net/ibmtr.cti=(struct tok_info *) dev->priv;
dev529drivers/net/ibmtr.cdev->interrupt=1;
dev553drivers/net/ibmtr.cdev->interrupt=0;
dev563drivers/net/ibmtr.cdev->interrupt=0;
dev578drivers/net/ibmtr.cdev->tbusy=0;
dev591drivers/net/ibmtr.cdev->tbusy=0;
dev622drivers/net/ibmtr.copen_sap(EXTENDED_SAP,dev);
dev631drivers/net/ibmtr.ctr_timer.data=(unsigned long)dev;
dev646drivers/net/ibmtr.ctr_timer.data=(unsigned long)dev;
dev682drivers/net/ibmtr.cdev->tbusy=0;
dev717drivers/net/ibmtr.ctr_rx(dev);
dev728drivers/net/ibmtr.ctr_timer.data=(unsigned long)dev;
dev739drivers/net/ibmtr.cdev->tbusy=1; /* really srb busy... */
dev745drivers/net/ibmtr.ctr_tx(dev);
dev777drivers/net/ibmtr.cdev->interrupt=0;
dev784drivers/net/ibmtr.cinitial_tok_int(dev);
dev792drivers/net/ibmtr.cstatic void initial_tok_int(struct device *dev) {
dev798drivers/net/ibmtr.cti=(struct tok_info *) dev->priv;
dev838drivers/net/ibmtr.cprintk("%02X%s",dev->dev_addr[i]=encoded_addr[i],(i==TR_ALEN-1) ? "" : ":" );
dev841drivers/net/ibmtr.ctok_open_adapter((unsigned long)dev);
dev850drivers/net/ibmtr.cstruct  device *dev=(struct device *)dev_addr;
dev851drivers/net/ibmtr.cPIOaddr = dev->base_addr;
dev852drivers/net/ibmtr.cti=(struct tok_info *) dev->priv;
dev859drivers/net/ibmtr.cdev->tbusy=1; /* nothing can be done before reset and open completed */
dev880drivers/net/ibmtr.cstatic void open_sap(unsigned char type,struct device *dev) {
dev882drivers/net/ibmtr.cstruct tok_info *ti=(struct tok_info *) dev->priv;
dev900drivers/net/ibmtr.cstruct device *dev=(struct device *)dev_addr;
dev903drivers/net/ibmtr.cti=(struct tok_info *) dev->priv;
dev929drivers/net/ibmtr.cstatic void tr_tx(struct device *dev) {
dev931drivers/net/ibmtr.cstruct tok_info *ti=(struct tok_info *) dev->priv;
dev1017drivers/net/ibmtr.cdev->tbusy=0;
dev1023drivers/net/ibmtr.cstatic void tr_rx(struct device *dev) {
dev1025drivers/net/ibmtr.cstruct tok_info *ti=(struct tok_info *) dev->priv;
dev1085drivers/net/ibmtr.cskb->dev=dev;
dev1122drivers/net/ibmtr.cskb->protocol=tr_type_trans(skb,dev);
dev1128drivers/net/ibmtr.cstatic int tok_send_packet(struct sk_buff *skb, struct device *dev) {
dev1130drivers/net/ibmtr.cstruct tok_info *ti=(struct tok_info *) dev->priv;
dev1136drivers/net/ibmtr.cif (dev->tbusy) {
dev1137drivers/net/ibmtr.cint ticks_waited=jiffies - dev->trans_start;
dev1143drivers/net/ibmtr.cdev->trans_start+=5; /* we fake the transmission start time... */
dev1150drivers/net/ibmtr.cdev_tint(dev);
dev1154drivers/net/ibmtr.cif(set_bit(0,(void *)&dev->tbusy)!=0)
dev1164drivers/net/ibmtr.cdev->trans_start=jiffies;
dev1175drivers/net/ibmtr.cstatic struct enet_statistics * tok_get_stats(struct device *dev) {
dev1178drivers/net/ibmtr.ctoki=(struct tok_info *) dev->priv;
dev39drivers/net/lance.cstruct device *init_etherdev(struct device *dev, int sizeof_private,
dev256drivers/net/lance.cstatic int lance_open(struct device *dev);
dev257drivers/net/lance.cstatic void lance_init_ring(struct device *dev);
dev258drivers/net/lance.cstatic int lance_start_xmit(struct sk_buff *skb, struct device *dev);
dev259drivers/net/lance.cstatic int lance_rx(struct device *dev);
dev261drivers/net/lance.cstatic int lance_close(struct device *dev);
dev262drivers/net/lance.cstatic struct enet_statistics *lance_get_stats(struct device *dev);
dev264drivers/net/lance.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev336drivers/net/lance.cstruct device *dev;
dev394drivers/net/lance.cdev = init_etherdev(0, 7
dev403drivers/net/lance.cprintk("%s: %s at %#3x,", dev->name, chipname, ioaddr);
dev408drivers/net/lance.cprintk(" %2.2x", dev->dev_addr[i] = inb(ioaddr + i));
dev410drivers/net/lance.cdev->base_addr = ioaddr;
dev414drivers/net/lance.cdev->priv = (void *)(((int)dev->priv + 7) & ~7);
dev415drivers/net/lance.clp = (struct lance_private *)dev->priv;
dev425drivers/net/lance.clp->init_block.phys_addr[i] = dev->dev_addr[i];
dev441drivers/net/lance.cdev->dma = 4;      /* Native bus-master, no DMA channel needed. */
dev442drivers/net/lance.cdev->irq = pci_irq_line;
dev447drivers/net/lance.cdev->dma = dma_tbl[(port_val >> 4) & 3];
dev448drivers/net/lance.cdev->irq = irq_tbl[(port_val >> 2) & 3];
dev449drivers/net/lance.cprintk(" HP Vectra IRQ %d DMA %d.\n", dev->irq, dev->dma);
dev454drivers/net/lance.cdev->dma = dma_tbl[(reset_val >> 2) & 3];
dev455drivers/net/lance.cdev->irq = irq_tbl[(reset_val >> 4) & 7];
dev456drivers/net/lance.cprintk(" HP J2405A IRQ %d DMA %d.\n", dev->irq, dev->dma);
dev461drivers/net/lance.cdev->dma = bus_info & 0x07;
dev462drivers/net/lance.cdev->irq = (bus_info >> 4) & 0x0F;
dev465drivers/net/lance.cif (dev->mem_start & 0x07)
dev466drivers/net/lance.cdev->dma = dev->mem_start & 0x07;
dev469drivers/net/lance.cif (dev->dma == 0) {
dev475drivers/net/lance.cif (dev->irq >= 2)
dev476drivers/net/lance.cprintk(" assigned IRQ %d", dev->irq);
dev486drivers/net/lance.cdev->irq = autoirq_report(1);
dev487drivers/net/lance.cif (dev->irq)
dev488drivers/net/lance.cprintk(", probed IRQ %d", dev->irq);
dev497drivers/net/lance.cdev->dma = 4;
dev500drivers/net/lance.cif (dev->dma == 4) {
dev502drivers/net/lance.c} else if (dev->dma) {
dev503drivers/net/lance.cif (request_dma(dev->dma, chipname)) {
dev504drivers/net/lance.cprintk("DMA %d allocation failed.\n", dev->dma);
dev507drivers/net/lance.cprintk(", assigned DMA %d.\n", dev->dma);
dev530drivers/net/lance.cdev->dma = dma;
dev531drivers/net/lance.cprintk(", DMA %d.\n", dev->dma);
dev555drivers/net/lance.cdev->open = &lance_open;
dev556drivers/net/lance.cdev->hard_start_xmit = &lance_start_xmit;
dev557drivers/net/lance.cdev->stop = &lance_close;
dev558drivers/net/lance.cdev->get_stats = &lance_get_stats;
dev559drivers/net/lance.cdev->set_multicast_list = &set_multicast_list;
dev566drivers/net/lance.clance_open(struct device *dev)
dev568drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev569drivers/net/lance.cint ioaddr = dev->base_addr;
dev572drivers/net/lance.cif (dev->irq == 0 ||
dev573drivers/net/lance.crequest_irq(dev->irq, &lance_interrupt, 0, lp->name)) {
dev580drivers/net/lance.cirq2dev_map[dev->irq] = dev;
dev586drivers/net/lance.cif (dev->dma != 4) {
dev587drivers/net/lance.cenable_dma(dev->dma);
dev588drivers/net/lance.cset_dma_mode(dev->dma, DMA_MODE_CASCADE);
dev603drivers/net/lance.cdev->name, dev->irq, dev->dma, (int) lp->tx_ring, (int) lp->rx_ring,
dev606drivers/net/lance.clance_init_ring(dev);
dev619drivers/net/lance.cdev->tbusy = 0;
dev620drivers/net/lance.cdev->interrupt = 0;
dev621drivers/net/lance.cdev->start = 1;
dev634drivers/net/lance.cdev->name, i, (int) &lp->init_block, inw(ioaddr+LANCE_DATA));
dev652drivers/net/lance.clance_purge_tx_ring(struct device *dev)
dev654drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev668drivers/net/lance.clance_init_ring(struct device *dev)
dev670drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev689drivers/net/lance.clp->init_block.phys_addr[i] = dev->dev_addr[i];
dev697drivers/net/lance.clance_restart(struct device *dev, unsigned int csr0_bits, int must_reinit)
dev699drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev703drivers/net/lance.clance_purge_tx_ring(dev);
dev704drivers/net/lance.clance_init_ring(dev);
dev706drivers/net/lance.coutw(0x0000,    dev->base_addr + LANCE_ADDR);
dev707drivers/net/lance.coutw(csr0_bits, dev->base_addr + LANCE_DATA);
dev711drivers/net/lance.clance_start_xmit(struct sk_buff *skb, struct device *dev)
dev713drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev714drivers/net/lance.cint ioaddr = dev->base_addr;
dev719drivers/net/lance.cif (dev->tbusy) {
dev720drivers/net/lance.cint tickssofar = jiffies - dev->trans_start;
dev725drivers/net/lance.cdev->name, inw(ioaddr+LANCE_DATA));
dev745drivers/net/lance.clance_restart(dev, 0x0043, 1);
dev747drivers/net/lance.cdev->tbusy=0;
dev748drivers/net/lance.cdev->trans_start = jiffies;
dev754drivers/net/lance.cdev_tint(dev);
dev763drivers/net/lance.cprintk("%s: lance_start_xmit() called, csr0 %4.4x.\n", dev->name,
dev770drivers/net/lance.cif (set_bit(0, (void*)&dev->tbusy) != 0) {
dev771drivers/net/lance.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev777drivers/net/lance.cprintk("%s: tx queue lock!.\n", dev->name);
dev804drivers/net/lance.cdev->name, (int)(skb->data));
dev819drivers/net/lance.cdev->trans_start = jiffies;
dev825drivers/net/lance.cdev->tbusy=0;
dev837drivers/net/lance.cstruct device *dev = (struct device *)(irq2dev_map[irq]);
dev842drivers/net/lance.cif (dev == NULL) {
dev847drivers/net/lance.cioaddr = dev->base_addr;
dev848drivers/net/lance.clp = (struct lance_private *)dev->priv;
dev849drivers/net/lance.cif (dev->interrupt)
dev850drivers/net/lance.cprintk("%s: Re-entering the interrupt handler.\n", dev->name);
dev852drivers/net/lance.cdev->interrupt = 1;
dev854drivers/net/lance.coutw(0x00, dev->base_addr + LANCE_ADDR);
dev855drivers/net/lance.cwhile ((csr0 = inw(dev->base_addr + LANCE_DATA)) & 0x8600
dev858drivers/net/lance.coutw(csr0 & ~0x004f, dev->base_addr + LANCE_DATA);
dev864drivers/net/lance.cdev->name, csr0, inw(dev->base_addr + LANCE_DATA));
dev867drivers/net/lance.clance_rx(dev);
dev893drivers/net/lance.cdev->name, csr0);
dev920drivers/net/lance.cif (lp->tx_full && dev->tbusy
dev924drivers/net/lance.cdev->tbusy = 0;
dev936drivers/net/lance.cdev->name, csr0);
dev943drivers/net/lance.coutw(0x0000, dev->base_addr + LANCE_ADDR);
dev944drivers/net/lance.coutw(0x0004, dev->base_addr + LANCE_DATA);
dev945drivers/net/lance.clance_restart(dev, 0x0002, 0);
dev950drivers/net/lance.coutw(0x0000, dev->base_addr + LANCE_ADDR);
dev951drivers/net/lance.coutw(0x7940, dev->base_addr + LANCE_DATA);
dev955drivers/net/lance.cdev->name, inw(ioaddr + LANCE_ADDR),
dev956drivers/net/lance.cinw(dev->base_addr + LANCE_DATA));
dev958drivers/net/lance.cdev->interrupt = 0;
dev963drivers/net/lance.clance_rx(struct device *dev)
dev965drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev992drivers/net/lance.cprintk("%s: Memory squeeze, deferring packet.\n", dev->name);
dev1004drivers/net/lance.cskb->dev = dev;
dev1010drivers/net/lance.cskb->protocol=eth_type_trans(skb,dev);
dev1029drivers/net/lance.clance_close(struct device *dev)
dev1031drivers/net/lance.cint ioaddr = dev->base_addr;
dev1032drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev1034drivers/net/lance.cdev->start = 0;
dev1035drivers/net/lance.cdev->tbusy = 1;
dev1045drivers/net/lance.cdev->name, inw(ioaddr+LANCE_DATA));
dev1051drivers/net/lance.cif (dev->dma != 4)
dev1052drivers/net/lance.cdisable_dma(dev->dma);
dev1054drivers/net/lance.cfree_irq(dev->irq);
dev1056drivers/net/lance.cirq2dev_map[dev->irq] = 0;
dev1062drivers/net/lance.clance_get_stats(struct device *dev)
dev1064drivers/net/lance.cstruct lance_private *lp = (struct lance_private *)dev->priv;
dev1065drivers/net/lance.cshort ioaddr = dev->base_addr;
dev1089drivers/net/lance.cset_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev1091drivers/net/lance.cshort ioaddr = dev->base_addr;
dev1109drivers/net/lance.cprintk("%s: Promiscuous mode enabled.\n", dev->name);
dev1114drivers/net/lance.clance_restart(dev, 0x0142, 0); /*  Resume normal operation */
dev47drivers/net/loopback.cstatic int loopback_xmit(struct sk_buff *skb, struct device *dev)
dev49drivers/net/loopback.cstruct enet_statistics *stats = (struct enet_statistics *)dev->priv;
dev53drivers/net/loopback.cif (skb == NULL || dev == NULL) 
dev58drivers/net/loopback.cif (dev->tbusy != 0) 
dev64drivers/net/loopback.cdev->tbusy = 1;
dev94drivers/net/loopback.cskb->protocol=eth_type_trans(skb,dev);
dev95drivers/net/loopback.cskb->dev=dev;
dev106drivers/net/loopback.cdev->tbusy = 0;
dev111drivers/net/loopback.cstatic struct enet_statistics *get_stats(struct device *dev)
dev113drivers/net/loopback.creturn (struct enet_statistics *)dev->priv;
dev116drivers/net/loopback.cstatic int loopback_open(struct device *dev)
dev118drivers/net/loopback.cdev->flags|=IFF_LOOPBACK;
dev123drivers/net/loopback.cint loopback_init(struct device *dev)
dev127drivers/net/loopback.cdev->mtu    = 2000;      /* MTU      */
dev128drivers/net/loopback.cdev->tbusy    = 0;
dev129drivers/net/loopback.cdev->hard_start_xmit  = loopback_xmit;
dev130drivers/net/loopback.cdev->open    = NULL;
dev131drivers/net/loopback.cdev->hard_header  = eth_header;
dev132drivers/net/loopback.cdev->hard_header_len  = ETH_HLEN;    /* 14      */
dev133drivers/net/loopback.cdev->addr_len    = ETH_ALEN;    /* 6      */
dev134drivers/net/loopback.cdev->type    = ARPHRD_ETHER;    /* 0x0001    */
dev135drivers/net/loopback.cdev->rebuild_header  = eth_rebuild_header;
dev136drivers/net/loopback.cdev->open    = loopback_open;
dev137drivers/net/loopback.cdev->flags    = IFF_LOOPBACK|IFF_BROADCAST;
dev138drivers/net/loopback.cdev->family    = AF_INET;
dev140drivers/net/loopback.cdev->pa_addr    = in_aton("127.0.0.1");
dev141drivers/net/loopback.cdev->pa_brdaddr  = in_aton("127.255.255.255");
dev142drivers/net/loopback.cdev->pa_mask    = in_aton("255.0.0.0");
dev143drivers/net/loopback.cdev->pa_alen    = 4;
dev145drivers/net/loopback.cdev->priv = kmalloc(sizeof(struct enet_statistics), GFP_KERNEL);
dev146drivers/net/loopback.cmemset(dev->priv, 0, sizeof(struct enet_statistics));
dev147drivers/net/loopback.cdev->get_stats = get_stats;
dev154drivers/net/loopback.cskb_queue_head_init(&dev->buffs[i]);
dev54drivers/net/ne.cextern struct device *init_etherdev(struct device *dev, int sizeof_private,
dev77drivers/net/ne.c#define NE_BASE   (dev->base_addr)
dev88drivers/net/ne.cint ne_probe(struct device *dev);
dev89drivers/net/ne.cstatic int ne_probe1(struct device *dev, int ioaddr);
dev91drivers/net/ne.cstatic void ne_reset_8390(struct device *dev);
dev92drivers/net/ne.cstatic int ne_block_input(struct device *dev, int count,
dev94drivers/net/ne.cstatic void ne_block_output(struct device *dev, const int count,
dev124drivers/net/ne.cint ne_probe(struct device *dev)
dev127drivers/net/ne.cint base_addr = dev ? dev->base_addr : 0;
dev130drivers/net/ne.creturn ne_probe1(dev, base_addr);
dev138drivers/net/ne.cif (ne_probe1(dev, ioaddr) == 0)
dev146drivers/net/ne.cstatic int ne_probe1(struct device *dev, int ioaddr)
dev239drivers/net/ne.cdev->dev_addr[i] = SA_prom[i];
dev282drivers/net/ne.cif (dev == NULL)
dev283drivers/net/ne.cdev = init_etherdev(0, sizeof(struct ei_device), 0);
dev285drivers/net/ne.cif (dev->irq < 2) {
dev292drivers/net/ne.cdev->irq = autoirq_report(0);
dev294drivers/net/ne.cprintk(" autoirq is %d\n", dev->irq);
dev295drivers/net/ne.c} else if (dev->irq == 2)
dev298drivers/net/ne.cdev->irq = 9;
dev303drivers/net/ne.cint irqval = request_irq (dev->irq, ei_interrupt, 0, wordlength==2 ? "ne2000":"ne1000");
dev305drivers/net/ne.cprintk (" unable to get IRQ %d (irqval=%d).\n", dev->irq, irqval);
dev310drivers/net/ne.cdev->base_addr = ioaddr;
dev315drivers/net/ne.cdev->dev_addr[i] = SA_prom[i];
dev317drivers/net/ne.cethdev_init(dev);
dev319drivers/net/ne.cdev->name, name, ioaddr, dev->irq);
dev338drivers/net/ne.cNS8390_init(dev, 0);
dev345drivers/net/ne.cne_reset_8390(struct device *dev)
dev360drivers/net/ne.cprintk("%s: ne_reset_8390() did not complete.\n", dev->name);
dev372drivers/net/ne.cne_block_input(struct device *dev, int count, char *buf, int ring_offset)
dev377drivers/net/ne.cint nic_base = dev->base_addr;
dev384drivers/net/ne.cdev->name, ei_status.dmaing, ei_status.irqlock,
dev385drivers/net/ne.cdev->interrupt);
dev426drivers/net/ne.cdev->name, ring_offset + xfer_count, addr);
dev435drivers/net/ne.cne_block_output(struct device *dev, int count,
dev455drivers/net/ne.cdev->name, ei_status.dmaing, ei_status.irqlock,
dev456drivers/net/ne.cdev->interrupt);
dev515drivers/net/ne.cdev->name, (start_page << 8) + count, addr);
dev524drivers/net/ne.cprintk("%s: timeout waiting for Tx RDC.\n", dev->name);
dev525drivers/net/ne.cne_reset_8390(dev);
dev526drivers/net/ne.cNS8390_init(dev,1);
dev93drivers/net/net_init.cinit_etherdev(struct device *dev, int sizeof_priv, unsigned long *mem_startp)
dev99drivers/net/net_init.cif (dev == NULL) {
dev110drivers/net/net_init.cdev = cur_dev;
dev111drivers/net/net_init.cdev->init = NULL;
dev114drivers/net/net_init.cdev->priv = (void*) *mem_startp;
dev117drivers/net/net_init.cdev->priv = kmalloc(sizeof_priv, GFP_KERNEL);
dev118drivers/net/net_init.cmemset(dev->priv, 0, sizeof_priv);
dev126drivers/net/net_init.cdev = (struct device *)*mem_startp;
dev129drivers/net/net_init.cdev = (struct device *)kmalloc(alloc_size, GFP_KERNEL);
dev130drivers/net/net_init.cmemset(dev, 0, alloc_size);
dev132drivers/net/net_init.cdev->priv = (void *) (dev + 1);
dev133drivers/net/net_init.cdev->name = sizeof_priv + (char *)(dev + 1);
dev139drivers/net/net_init.cif (dev->name &&
dev140drivers/net/net_init.c((dev->name[0] == '\0') || (dev->name[0] == ' '))) {
dev143drivers/net/net_init.csprintf(dev->name, "eth%d", i);
dev144drivers/net/net_init.cethdev_index[i] = dev;
dev149drivers/net/net_init.cether_setup(dev);   /* Hmmm, should this be called here? */
dev156drivers/net/net_init.c(*old_devp)->next = dev;
dev157drivers/net/net_init.cdev->next = 0;
dev159drivers/net/net_init.creturn dev;
dev163drivers/net/net_init.cstatic int eth_mac_addr(struct device *dev, void * addr)
dev167drivers/net/net_init.cif(dev->start)
dev169drivers/net/net_init.cmemcpy(dev->dev_addr, ifr->ifr_hwaddr.sa_data,dev->hard_header_len);
dev173drivers/net/net_init.cvoid ether_setup(struct device *dev)
dev179drivers/net/net_init.cskb_queue_head_init(&dev->buffs[i]);
dev182drivers/net/net_init.cif (dev->name && (strncmp(dev->name, "eth", 3) == 0)) {
dev183drivers/net/net_init.ci = simple_strtoul(dev->name + 3, NULL, 0);
dev185drivers/net/net_init.cethdev_index[i] = dev;
dev187drivers/net/net_init.celse if (dev != ethdev_index[i]) {
dev190drivers/net/net_init.cdev->name);
dev194drivers/net/net_init.cdev->hard_header  = eth_header;
dev195drivers/net/net_init.cdev->rebuild_header = eth_rebuild_header;
dev196drivers/net/net_init.cdev->set_mac_address = eth_mac_addr;
dev197drivers/net/net_init.cdev->header_cache = eth_header_cache;
dev199drivers/net/net_init.cdev->type    = ARPHRD_ETHER;
dev200drivers/net/net_init.cdev->hard_header_len = ETH_HLEN;
dev201drivers/net/net_init.cdev->mtu    = 1500; /* eth_mtu */
dev202drivers/net/net_init.cdev->addr_len  = ETH_ALEN;
dev204drivers/net/net_init.cdev->broadcast[i]=0xff;
dev208drivers/net/net_init.cdev->flags    = IFF_BROADCAST|IFF_MULTICAST;
dev209drivers/net/net_init.cdev->family    = AF_INET;
dev210drivers/net/net_init.cdev->pa_addr  = 0;
dev211drivers/net/net_init.cdev->pa_brdaddr = 0;
dev212drivers/net/net_init.cdev->pa_mask  = 0;
dev213drivers/net/net_init.cdev->pa_alen  = 4;
dev218drivers/net/net_init.cvoid tr_setup(struct device *dev)
dev224drivers/net/net_init.cskb_queue_head_init(&dev->buffs[i]);
dev226drivers/net/net_init.cdev->hard_header  = tr_header;
dev227drivers/net/net_init.cdev->rebuild_header = tr_rebuild_header;
dev229drivers/net/net_init.cdev->type    = ARPHRD_IEEE802;
dev230drivers/net/net_init.cdev->hard_header_len = TR_HLEN;
dev231drivers/net/net_init.cdev->mtu    = 2000; /* bug in fragmenter...*/
dev232drivers/net/net_init.cdev->addr_len  = TR_ALEN;
dev234drivers/net/net_init.cdev->broadcast[i]=0xff;
dev238drivers/net/net_init.cdev->flags    = IFF_BROADCAST;
dev239drivers/net/net_init.cdev->family    = AF_INET;
dev240drivers/net/net_init.cdev->pa_addr  = 0;
dev241drivers/net/net_init.cdev->pa_brdaddr = 0;
dev242drivers/net/net_init.cdev->pa_mask  = 0;
dev243drivers/net/net_init.cdev->pa_alen  = 4;
dev248drivers/net/net_init.cint ether_config(struct device *dev, struct ifmap *map)
dev251drivers/net/net_init.cdev->mem_start = map->mem_start;
dev253drivers/net/net_init.cdev->mem_end = map->mem_end;
dev255drivers/net/net_init.cdev->base_addr = map->base_addr;
dev257drivers/net/net_init.cdev->irq = map->irq;
dev259drivers/net/net_init.cdev->dma = map->dma;
dev261drivers/net/net_init.cdev->if_port = map->port;
dev265drivers/net/net_init.cint register_netdev(struct device *dev)
dev274drivers/net/net_init.cif (dev && dev->init) {
dev275drivers/net/net_init.cif (dev->name &&
dev276drivers/net/net_init.c((dev->name[0] == '\0') || (dev->name[0] == ' '))) {
dev279drivers/net/net_init.csprintf(dev->name, "eth%d", i);
dev280drivers/net/net_init.cprintk("loading device '%s'...\n", dev->name);
dev281drivers/net/net_init.cethdev_index[i] = dev;
dev286drivers/net/net_init.cif (dev->init(dev) != 0) {
dev296drivers/net/net_init.cd->next = dev;
dev299drivers/net/net_init.cdev_base = dev;
dev300drivers/net/net_init.cdev->next = NULL;
dev306drivers/net/net_init.cvoid unregister_netdev(struct device *dev)
dev317drivers/net/net_init.cif (dev == NULL) {
dev323drivers/net/net_init.cif (dev->start)
dev324drivers/net/net_init.cprintk("'%s' busy\n", dev->name);
dev326drivers/net/net_init.cif (dev_base == dev)
dev327drivers/net/net_init.cdev_base = dev->next;
dev329drivers/net/net_init.cwhile (d && (d->next != dev))
dev332drivers/net/net_init.cif (d && (d->next == dev)) {
dev333drivers/net/net_init.cd->next = dev->next;
dev334drivers/net/net_init.cprintk("'%s' unlinked\n", dev->name);
dev337drivers/net/net_init.cprintk("'%s' not found\n", dev->name);
dev343drivers/net/net_init.cif (ethdev_index[i] == dev) {
dev100drivers/net/ni52.c#define ni_attn586()  {outb(0,dev->base_addr+NI52_ATTENTION);}
dev101drivers/net/ni52.c#define ni_reset586() {outb(0,dev->base_addr+NI52_RESET);}
dev146drivers/net/ni52.cprintk("%s: scb_cmd timed out .. resetting i82586\n",dev->name); \
dev163drivers/net/ni52.cstatic int     ni52_probe1(struct device *dev,int ioaddr);
dev165drivers/net/ni52.cstatic int     ni52_open(struct device *dev);
dev166drivers/net/ni52.cstatic int     ni52_close(struct device *dev);
dev168drivers/net/ni52.cstatic struct  enet_statistics *ni52_get_stats(struct device *dev);
dev169drivers/net/ni52.cstatic void    set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev172drivers/net/ni52.cstatic int     init586(struct device *dev,int num_addrs,void *addrs);
dev173drivers/net/ni52.cstatic int     check586(struct device *dev,char *where,unsigned size);
dev174drivers/net/ni52.cstatic void    alloc586(struct device *dev);
dev175drivers/net/ni52.cstatic void    startrecv586(struct device *dev);
dev176drivers/net/ni52.cstatic void   *alloc_rfa(struct device *dev,void *ptr);
dev177drivers/net/ni52.cstatic void    ni52_rcv_int(struct device *dev);
dev178drivers/net/ni52.cstatic void    ni52_xmt_int(struct device *dev);
dev179drivers/net/ni52.cstatic void    ni52_rnr_int(struct device *dev);
dev207drivers/net/ni52.cstatic int ni52_close(struct device *dev)
dev209drivers/net/ni52.cfree_irq(dev->irq);
dev210drivers/net/ni52.cirq2dev_map[dev->irq] = 0;
dev214drivers/net/ni52.cdev->start = 0;
dev215drivers/net/ni52.cdev->tbusy = 0;
dev224drivers/net/ni52.cstatic int ni52_open(struct device *dev)
dev226drivers/net/ni52.calloc586(dev);
dev227drivers/net/ni52.cinit586(dev,0,NULL);  
dev228drivers/net/ni52.cstartrecv586(dev);
dev230drivers/net/ni52.cif(request_irq(dev->irq, &ni52_interrupt,0,"ni52")) 
dev235drivers/net/ni52.cirq2dev_map[dev->irq] = dev;
dev237drivers/net/ni52.cdev->interrupt = 0;
dev238drivers/net/ni52.cdev->tbusy = 0;
dev239drivers/net/ni52.cdev->start = 1;
dev248drivers/net/ni52.cstatic int check586(struct device *dev,char *where,unsigned size)
dev250drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev285drivers/net/ni52.cvoid alloc586(struct device *dev)
dev287drivers/net/ni52.cstruct priv *p =  (struct priv *) dev->priv; 
dev293drivers/net/ni52.cp->scb  = (struct scb_struct *)  (dev->mem_start);
dev310drivers/net/ni52.cprintk("%s: Init-Problems (alloc).\n",dev->name);
dev319drivers/net/ni52.cint ni52_probe(struct device *dev)
dev322drivers/net/ni52.cint base_addr = dev->base_addr;
dev327drivers/net/ni52.creturn ni52_probe1(dev, base_addr);
dev339drivers/net/ni52.cdev->base_addr = ioaddr;
dev340drivers/net/ni52.cif (ni52_probe1(dev, ioaddr) == 0)
dev344drivers/net/ni52.cdev->base_addr = base_addr;
dev348drivers/net/ni52.cstatic int ni52_probe1(struct device *dev,int ioaddr)
dev354drivers/net/ni52.cdev->dev_addr[i] = inb(dev->base_addr+i);
dev356drivers/net/ni52.cif(dev->dev_addr[0] != NI52_ADDR0 || dev->dev_addr[1] != NI52_ADDR1
dev357drivers/net/ni52.c|| dev->dev_addr[2] != NI52_ADDR2)
dev360drivers/net/ni52.cprintk("%s: Ni52 found at %#3x, ",dev->name,dev->base_addr);
dev364drivers/net/ni52.cdev->priv = (void *) kmalloc(sizeof(struct priv),GFP_KERNEL); 
dev366drivers/net/ni52.cmemset((char *) dev->priv,0,sizeof(struct priv));
dev371drivers/net/ni52.cif(dev->mem_start != 0) /* no auto-mem-probe */
dev374drivers/net/ni52.cif(!check586(dev,(char *) dev->mem_start,size)) {
dev376drivers/net/ni52.cif(!check586(dev,(char *) dev->mem_start,size)) {
dev377drivers/net/ni52.cprintk("?memprobe, Can't find memory at 0x%lx!\n",dev->mem_start);
dev390drivers/net/ni52.cdev->mem_start = memaddrs[i];
dev392drivers/net/ni52.cif(check586(dev,(char *)dev->mem_start,size)) /* 8K-check */
dev395drivers/net/ni52.cif(check586(dev,(char *)dev->mem_start,size)) /* 16K-check */
dev399drivers/net/ni52.cdev->mem_end = dev->mem_start + size; /* set mem_end showed by 'ifconfig' */
dev401drivers/net/ni52.c((struct priv *) (dev->priv))->base =  dev->mem_start + size - 0x01000000;
dev402drivers/net/ni52.calloc586(dev);
dev406drivers/net/ni52.c((struct priv *) dev->priv)->num_recv_buffs = NUM_RECV_BUFFS_8;
dev408drivers/net/ni52.c((struct priv *) dev->priv)->num_recv_buffs = NUM_RECV_BUFFS_16;
dev410drivers/net/ni52.cprintk("Memaddr: 0x%lx, Memsize: %d, ",dev->mem_start,size);
dev412drivers/net/ni52.cif(dev->irq < 2)
dev417drivers/net/ni52.cif(!(dev->irq = autoirq_report(2)))
dev423drivers/net/ni52.celse if(dev->irq == 2) 
dev424drivers/net/ni52.cdev->irq = 9;
dev426drivers/net/ni52.cprintk("IRQ %d.\n",dev->irq);
dev428drivers/net/ni52.cdev->open            = &ni52_open;
dev429drivers/net/ni52.cdev->stop            = &ni52_close;
dev430drivers/net/ni52.cdev->get_stats       = &ni52_get_stats;
dev431drivers/net/ni52.cdev->hard_start_xmit = &ni52_send_packet;
dev432drivers/net/ni52.cdev->set_multicast_list = &set_multicast_list;
dev434drivers/net/ni52.cdev->if_port          = 0;
dev436drivers/net/ni52.cether_setup(dev);
dev438drivers/net/ni52.cdev->tbusy = 0;
dev439drivers/net/ni52.cdev->interrupt = 0;
dev440drivers/net/ni52.cdev->start = 0;
dev450drivers/net/ni52.cstatic int init586(struct device *dev,int num_addrs,void *addrs)
dev455drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev490drivers/net/ni52.cprintk("%s (ni52): configure command failed: %x\n",dev->name,cfg_cmd->cmd_status);
dev503drivers/net/ni52.cmemcpy((char *)&ias_cmd->iaddr,(char *) dev->dev_addr,ETH_ALEN);
dev515drivers/net/ni52.cprintk("%s (ni52): individual address setup command failed: %04x\n",dev->name,ias_cmd->cmd_status);
dev537drivers/net/ni52.cprintk("%s: Problems while running the TDR.\n",dev->name);
dev551drivers/net/ni52.cprintk("%s: TDR: Transceiver problem!\n",dev->name);
dev553drivers/net/ni52.cprintk("%s: TDR: No correct termination %d clocks away.\n",dev->name,result & TDR_TIMEMASK);
dev557drivers/net/ni52.cprintk("%s: TDR: Detected a short circuit %d clocks away.\n",dev->name,result & TDR_TIMEMASK);
dev560drivers/net/ni52.cprintk("%s: TDR: Unknown status %04x\n",dev->name,result);
dev596drivers/net/ni52.cptr = alloc_rfa(dev,(void *)ptr); /* init receive-frame-area */ 
dev607drivers/net/ni52.cprintk("%s: Ooooops, no memory for MC-Setup!\n",dev->name);
dev614drivers/net/ni52.cprintk("%s: Sorry, can only apply %d MC-Address(es).\n",dev->name,num_addrs);
dev631drivers/net/ni52.cprintk("%s: Can't apply multicast-address-list.\n",dev->name);
dev646drivers/net/ni52.cprintk("%s: not enough shared-mem for your configuration!\n",dev->name);
dev685drivers/net/ni52.cstatic void *alloc_rfa(struct device *dev,void *ptr) 
dev690drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev731drivers/net/ni52.cstruct device *dev = (struct device *) irq2dev_map[irq];
dev735drivers/net/ni52.cif (dev == NULL) {
dev739drivers/net/ni52.cp = (struct priv *) dev->priv;
dev741drivers/net/ni52.cdev->interrupt = 1;
dev749drivers/net/ni52.cni52_xmt_int(dev);
dev752drivers/net/ni52.cni52_rcv_int(dev);
dev757drivers/net/ni52.cif(dev->start)
dev758drivers/net/ni52.cprintk("%s: oops! CU has left active state. stat: %04x/%04x.\n",dev->name,(int) stat,(int) p->scb->status);
dev772drivers/net/ni52.cprintk("%s: Receiver-Unit went 'NOT READY': %04x/%04x.\n",dev->name,(int) stat,(int) p->scb->status);
dev773drivers/net/ni52.cni52_rnr_int(dev); 
dev781drivers/net/ni52.cdev->interrupt = 0;
dev788drivers/net/ni52.cstatic void ni52_rcv_int(struct device *dev)
dev794drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev809drivers/net/ni52.cskb->dev = dev;
dev812drivers/net/ni52.cskb->protocol=eth_type_trans(skb,dev);
dev821drivers/net/ni52.cprintk("%s: received oversized frame.\n",dev->name);
dev827drivers/net/ni52.cprintk("%s: oops! rfd-error-status: %04x\n",dev->name,status);
dev842drivers/net/ni52.cstatic void ni52_rnr_int(struct device *dev)
dev844drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev853drivers/net/ni52.calloc_rfa(dev,(char *)p->rfd_first);
dev854drivers/net/ni52.cstartrecv586(dev); /* restart RU */
dev856drivers/net/ni52.cprintk("%s: Receive-Unit restarted. Status: %04x\n",dev->name,p->scb->status);
dev864drivers/net/ni52.cstatic void ni52_xmt_int(struct device *dev)
dev867drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev871drivers/net/ni52.cprintk("%s: strange .. xmit-int without a 'COMPLETE'\n",dev->name);
dev882drivers/net/ni52.cprintk("%s: late collision detected.\n",dev->name);
dev887drivers/net/ni52.cprintk("%s: no carrier detected.\n",dev->name);
dev890drivers/net/ni52.cprintk("%s: loss of CTS detected.\n",dev->name);
dev893drivers/net/ni52.cprintk("%s: DMA underrun detected.\n",dev->name);
dev896drivers/net/ni52.cprintk("%s: Max. collisions exceeded.\n",dev->name);
dev906drivers/net/ni52.cdev->tbusy = 0;
dev914drivers/net/ni52.cstatic void startrecv586(struct device *dev)
dev916drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev928drivers/net/ni52.cstatic int ni52_send_packet(struct sk_buff *skb, struct device *dev)
dev934drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev936drivers/net/ni52.cif(dev->tbusy)
dev938drivers/net/ni52.cint tickssofar = jiffies - dev->trans_start;
dev944drivers/net/ni52.cdev->tbusy = 0;
dev946drivers/net/ni52.cprintk("%s: strange ... timeout with CU active?!?\n",dev->name);
dev947drivers/net/ni52.cprintk("%s: X0: %04x N0: %04x N1: %04x %d\n",dev->name,(int)p->xmit_cmds[0]->cmd_status,(int)p->nop_cmds[0]->cmd_status,(int)p->nop_cmds[1]->cmd_status,(int)p->nop_point);
dev956drivers/net/ni52.cdev->trans_start = jiffies;
dev962drivers/net/ni52.cprintk("%s: xmitter timed out, try to restart! stat: %04x\n",dev->name,p->scb->status);
dev963drivers/net/ni52.cprintk("%s: command-stats: %04x %04x\n",dev->name,p->xmit_cmds[0]->cmd_status,p->xmit_cmds[1]->cmd_status);
dev965drivers/net/ni52.cni52_close(dev);
dev966drivers/net/ni52.cni52_open(dev);
dev968drivers/net/ni52.cdev->trans_start = jiffies;
dev974drivers/net/ni52.cdev_tint(dev);
dev982drivers/net/ni52.cprintk("%s: Sorry, max. framelength is %d bytes. The length of your frame is %ld bytes.\n",dev->name,XMIT_BUFF_SIZE,skb->len);
dev986drivers/net/ni52.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev987drivers/net/ni52.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev1003drivers/net/ni52.cdev->trans_start = jiffies;
dev1012drivers/net/ni52.cprintk("%s: Can't start transmit-command.\n",dev->name);
dev1023drivers/net/ni52.cdev->trans_start = jiffies;
dev1038drivers/net/ni52.cdev->trans_start = jiffies;
dev1043drivers/net/ni52.cdev->tbusy = 0;
dev1055drivers/net/ni52.cstatic struct enet_statistics *ni52_get_stats(struct device *dev)
dev1057drivers/net/ni52.cstruct priv *p = (struct priv *) dev->priv;
dev1081drivers/net/ni52.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev1083drivers/net/ni52.cif(!dev->start && !num_addrs)
dev1085drivers/net/ni52.cprintk("%s: Can't apply promiscuous/multicastmode to a not running interface.\n",dev->name);
dev1089drivers/net/ni52.cdev->start = 0;
dev1090drivers/net/ni52.calloc586(dev);
dev1091drivers/net/ni52.cinit586(dev,num_addrs,addrs);  
dev1092drivers/net/ni52.cstartrecv586(dev);
dev1093drivers/net/ni52.cdev->start = 1;
dev77drivers/net/ni65.c#define PORT dev->base_addr
dev114drivers/net/ni65.cstatic int   ni65_probe1(struct device *dev,int);
dev116drivers/net/ni65.cstatic void recv_intr(struct device *dev);
dev117drivers/net/ni65.cstatic void xmit_intr(struct device *dev);
dev118drivers/net/ni65.cstatic int   ni65_open(struct device *dev);
dev119drivers/net/ni65.cstatic int am7990_reinit(struct device *dev);
dev120drivers/net/ni65.cstatic int   ni65_send_packet(struct sk_buff *skb, struct device *dev);
dev121drivers/net/ni65.cstatic int   ni65_close(struct device *dev);
dev124drivers/net/ni65.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs);
dev149drivers/net/ni65.cstatic int ni65_open(struct device *dev)
dev151drivers/net/ni65.cif(am7990_reinit(dev))
dev153drivers/net/ni65.cdev->tbusy     = 0;
dev154drivers/net/ni65.cdev->interrupt = 0;
dev155drivers/net/ni65.cdev->start     = 1;
dev160drivers/net/ni65.cdev->start = 0;
dev165drivers/net/ni65.cstatic int ni65_close(struct device *dev)
dev168drivers/net/ni65.cdev->tbusy = 1;
dev169drivers/net/ni65.cdev->start = 0;
dev178drivers/net/ni65.cint ni65_probe(struct device *dev)
dev181drivers/net/ni65.cint base_addr = dev->base_addr;
dev184drivers/net/ni65.creturn ni65_probe1(dev, base_addr);
dev196drivers/net/ni65.cdev->base_addr = ioaddr;
dev197drivers/net/ni65.cif (ni65_probe1(dev, ioaddr) == 0)
dev201drivers/net/ni65.cdev->base_addr = base_addr;
dev206drivers/net/ni65.cstatic int ni65_probe1(struct device *dev,int ioaddr)
dev213drivers/net/ni65.cstation_addr[i] = dev->dev_addr[i] = inb(PORT+L_EBASE+i);
dev217drivers/net/ni65.cprintk("%s: wrong Hardaddress \n",dev->name);
dev221drivers/net/ni65.cif(dev->irq == 0) 
dev222drivers/net/ni65.cdev->irq = irqtab[(inw(PORT+L_CONFIG)>>2)&3];
dev223drivers/net/ni65.cif(dev->dma == 0)  
dev224drivers/net/ni65.cdev->dma = dmatab[inw(PORT+L_CONFIG)&3];
dev226drivers/net/ni65.cprintk("%s: %s found at %#3x, IRQ %d DMA %d.\n", dev->name,
dev227drivers/net/ni65.c"network card", dev->base_addr, dev->irq,dev->dma);
dev230drivers/net/ni65.cint irqval = request_irq(dev->irq, &ni65_interrupt,0,"ni65");
dev233drivers/net/ni65.cdev->name,dev->irq, irqval);
dev236drivers/net/ni65.cif(request_dma(dev->dma, "ni65") != 0)
dev238drivers/net/ni65.cprintk("%s: Can't request dma-channel %d\n",dev->name,(int) dev->dma);
dev239drivers/net/ni65.cfree_irq(dev->irq);
dev243drivers/net/ni65.cirq2dev_map[dev->irq] = dev;
dev248drivers/net/ni65.cp = dev->priv = (void *) kmalloc(sizeof(struct priv),GFP_KERNEL);
dev249drivers/net/ni65.cmemset((char *) dev->priv,0,sizeof(struct priv));
dev251drivers/net/ni65.cdev->open               = ni65_open;
dev252drivers/net/ni65.cdev->stop               = ni65_close;
dev253drivers/net/ni65.cdev->hard_start_xmit    = ni65_send_packet;
dev254drivers/net/ni65.cdev->get_stats          = ni65_get_stats;
dev255drivers/net/ni65.cdev->set_multicast_list = set_multicast_list;
dev257drivers/net/ni65.cether_setup(dev);
dev259drivers/net/ni65.cdev->interrupt      = 0;
dev260drivers/net/ni65.cdev->tbusy          = 0;
dev261drivers/net/ni65.cdev->start          = 0;
dev264drivers/net/ni65.cprintk("%s: Can't alloc TMD/RMD-buffer.\n",dev->name);
dev268drivers/net/ni65.cprintk("%s: Can't alloc TMD/RMD buffer in lower 16MB!\n",dev->name);
dev278drivers/net/ni65.cprintk("%s: Can't alloc Xmit-Mem.\n",dev->name);
dev282drivers/net/ni65.cprintk("%s: Can't alloc Xmit-Mem in lower 16MB!\n",dev->name);
dev291drivers/net/ni65.cprintk("%s: unable to alloc recv-mem\n",dev->name);
dev295drivers/net/ni65.cprintk("%s: unable to alloc receive-memory in lower 16MB!\n",dev->name);
dev307drivers/net/ni65.cstatic int am7990_reinit(struct device *dev)
dev312drivers/net/ni65.cstruct priv *p = (struct priv *) dev->priv;
dev317drivers/net/ni65.cdisable_dma(dev->dma); /* I've never worked with dma, but we do it like the packetdriver */
dev318drivers/net/ni65.cset_dma_mode(dev->dma,DMA_MODE_CASCADE);
dev319drivers/net/ni65.cenable_dma(dev->dma); 
dev324drivers/net/ni65.cprintk("%s: can't RESET ni6510 card: %04x\n",dev->name,(int) inw(PORT+L_DATAREG));
dev325drivers/net/ni65.cdisable_dma(dev->dma);
dev326drivers/net/ni65.cfree_dma(dev->dma);
dev327drivers/net/ni65.cfree_irq(dev->irq);
dev357drivers/net/ni65.cp->ib.eaddr[i] = dev->dev_addr[i];
dev384drivers/net/ni65.cprintk("%s: can't init am7990, status: %04x\n",dev->name,(int) inw(PORT+L_DATAREG));
dev385drivers/net/ni65.cdisable_dma(dev->dma);
dev386drivers/net/ni65.cfree_dma(dev->dma);
dev387drivers/net/ni65.cfree_irq(dev->irq);
dev403drivers/net/ni65.cstruct device *dev = (struct device *) irq2dev_map[irq];
dev405drivers/net/ni65.cif (dev == NULL) {
dev413drivers/net/ni65.cdev->interrupt = 1;
dev417drivers/net/ni65.cstruct priv *p = (struct priv *) dev->priv;
dev427drivers/net/ni65.crecv_intr(dev);
dev431drivers/net/ni65.cxmit_intr(dev);
dev435drivers/net/ni65.cdev->interrupt = 0;
dev445drivers/net/ni65.cstatic void xmit_intr(struct device *dev)
dev449drivers/net/ni65.cstruct priv *p = (struct priv *) dev->priv;
dev468drivers/net/ni65.cprintk("%s: xmit-error: %04x %04x\n",dev->name,(int) tmdstat,(int) tmdp->status2);
dev470drivers/net/ni65.cprintk("%s: tdr-problems (e.g. no resistor)\n",dev->name);
dev488drivers/net/ni65.cdev->tbusy = 0;
dev496drivers/net/ni65.cstatic void recv_intr(struct device *dev)
dev501drivers/net/ni65.cstruct priv *p = (struct priv *) dev->priv;
dev512drivers/net/ni65.cprintk("%s: packet too long\n",dev->name);
dev518drivers/net/ni65.cprintk("%s: receive-error: %04x\n",dev->name,(int) rmdstat );
dev524drivers/net/ni65.cprintk("%s: lance-status: %04x\n",dev->name,(int) inw(PORT+L_DATAREG));
dev543drivers/net/ni65.cskb1->dev = dev;
dev545drivers/net/ni65.cskb1->protocol=eth_type_trans(skb1,dev);
dev551drivers/net/ni65.cprintk("%s: can't alloc new sk_buff\n",dev->name);
dev564drivers/net/ni65.cstatic int ni65_send_packet(struct sk_buff *skb, struct device *dev)
dev566drivers/net/ni65.cstruct priv *p = (struct priv *) dev->priv;
dev569drivers/net/ni65.cif(dev->tbusy)
dev571drivers/net/ni65.cint tickssofar = jiffies - dev->trans_start;
dev575drivers/net/ni65.cprintk("%s: xmitter timed out, try to restart!\n",dev->name);
dev576drivers/net/ni65.cam7990_reinit(dev);
dev577drivers/net/ni65.cdev->tbusy=0;
dev578drivers/net/ni65.cdev->trans_start = jiffies;
dev583drivers/net/ni65.cdev_tint(dev);
dev590drivers/net/ni65.cif (set_bit(0, (void*)&dev->tbusy) != 0)
dev592drivers/net/ni65.cprintk("%s: Transmitter access conflict.\n", dev->name);
dev597drivers/net/ni65.cprintk("%s: Queue was locked!\n",dev->name);
dev622drivers/net/ni65.cdev->tbusy = 0;
dev626drivers/net/ni65.cdev->trans_start = jiffies;
dev633drivers/net/ni65.cstatic struct enet_statistics *ni65_get_stats(struct device *dev)
dev635drivers/net/ni65.creturn &((struct priv *) dev->priv)->stats;
dev638drivers/net/ni65.cstatic void set_multicast_list(struct device *dev, int num_addrs, void *addrs)
dev82drivers/net/pi2.cstruct device *init_etherdev(struct device *dev, int sizeof_private,
dev139drivers/net/pi2.cstatic int pi0_preprobe(struct device *dev){return 0;}  /* Dummy probe function */
dev150drivers/net/pi2.cstatic int pi_probe(struct device *dev, int card_type);
dev151drivers/net/pi2.cstatic int pi_open(struct device *dev);
dev152drivers/net/pi2.cstatic int pi_send_packet(struct sk_buff *skb, struct device *dev);
dev154drivers/net/pi2.cstatic int pi_close(struct device *dev);
dev155drivers/net/pi2.cstatic int pi_ioctl(struct device *dev, struct ifreq *ifr, int cmd);
dev156drivers/net/pi2.cstatic struct enet_statistics *pi_get_stats(struct device *dev);
dev158drivers/net/pi2.cstatic void b_rxint(struct device *dev, struct pi_local *lp);
dev161drivers/net/pi2.cstatic void a_rxint(struct device *dev, struct pi_local *lp);
dev505drivers/net/pi2.cstatic void a_rxint(struct device *dev, struct pi_local *lp)
dev557drivers/net/pi2.cprintk("PI: %s: Memory squeeze, dropping packet.\n", dev->name);
dev562drivers/net/pi2.cskb->dev = dev;
dev581drivers/net/pi2.cstatic void b_rxint(struct device *dev, struct pi_local *lp)
dev646drivers/net/pi2.cprintk("PI: %s: Memory squeeze, dropping packet.\n", dev->name);
dev651drivers/net/pi2.cskb->dev = dev;
dev1077drivers/net/pi2.cstatic int pi_header(struct sk_buff *skb, struct device *dev, unsigned short type,
dev1080drivers/net/pi2.creturn ax25_encapsulate(skb, dev, type, daddr, saddr, len);
dev1084drivers/net/pi2.cstatic int pi_rebuild_header(void *buff, struct device *dev, unsigned long raddr,
dev1087drivers/net/pi2.creturn ax25_rebuild_header(buff, dev, raddr, skb);
dev1090drivers/net/pi2.cstatic void scc_init(struct device *dev)
dev1093drivers/net/pi2.cstruct pi_local *lp = (struct pi_local *) dev->priv;
dev1192drivers/net/pi2.cstatic void chipset_init(struct device *dev)
dev1197drivers/net/pi2.ccardbase = dev->base_addr & 0x3f0;
dev1201drivers/net/pi2.cwrtscc(cardbase, dev->base_addr + CTL, R9, FHWRES);  /* Hardware reset */
dev1203drivers/net/pi2.cwrtscc(cardbase, dev->base_addr + CTL, R9, 0);
dev1282drivers/net/pi2.cstatic int pi_set_mac_address(struct device *dev, void *addr)
dev1284drivers/net/pi2.cmemcpy(dev->dev_addr, addr, 7);  /* addr is an AX.25 shifted ASCII */
dev1304drivers/net/pi2.cstatic int pi_probe(struct device *dev, int card_type)
dev1312drivers/net/pi2.cioaddr = dev->base_addr;
dev1317drivers/net/pi2.cdev->priv = (void *) (((int) dev->priv + 7) & ~7);
dev1318drivers/net/pi2.clp = (struct pi_local *) dev->priv;
dev1320drivers/net/pi2.cmemset(dev->priv, 0, sizeof(struct pi_local));
dev1323drivers/net/pi2.cmem_ptr = (unsigned long) dev->priv + sizeof(struct pi_local);
dev1341drivers/net/pi2.clp->base = dev->base_addr;
dev1342drivers/net/pi2.clp->cardbase = dev->base_addr & 0x3f0;
dev1343drivers/net/pi2.cif (dev->base_addr & CHANA) {
dev1364drivers/net/pi2.cchipset_init(dev);
dev1366drivers/net/pi2.cif (dev->base_addr & CHANA) {  /* Do these things only for the A port */
dev1369drivers/net/pi2.clp->dmachan = dev->dma;
dev1375drivers/net/pi2.cif (dev->irq < 2) {
dev1386drivers/net/pi2.cdev->irq = autoirq_report(20);
dev1387drivers/net/pi2.cif (!dev->irq) {
dev1392drivers/net/pi2.cwrtscc(lp->cardbase, dev->base_addr + CTL, R9, FHWRES);  /* Hardware reset */
dev1394drivers/net/pi2.cwrtscc(lp->cardbase, dev->base_addr + CTL, R9, 0);
dev1399drivers/net/pi2.cdev->irq, dev->dma);
dev1405drivers/net/pi2.cint irqval = request_irq(dev->irq, &pi_interrupt,0, "pi2");
dev1408drivers/net/pi2.cdev->irq, irqval);
dev1418drivers/net/pi2.cdev->open = pi_open;
dev1419drivers/net/pi2.cdev->stop = pi_close;
dev1420drivers/net/pi2.cdev->do_ioctl = pi_ioctl;
dev1421drivers/net/pi2.cdev->hard_start_xmit = pi_send_packet;
dev1422drivers/net/pi2.cdev->get_stats = pi_get_stats;
dev1426drivers/net/pi2.cskb_queue_head_init(&dev->buffs[i]);
dev1429drivers/net/pi2.cdev->hard_header = pi_header;
dev1430drivers/net/pi2.cdev->rebuild_header = pi_rebuild_header;
dev1431drivers/net/pi2.cdev->set_mac_address = pi_set_mac_address;
dev1433drivers/net/pi2.cdev->type = ARPHRD_AX25;      /* AF_AX25 device */
dev1434drivers/net/pi2.cdev->hard_header_len = 73;      /* We do digipeaters now */
dev1435drivers/net/pi2.cdev->mtu = 1500;        /* eth_mtu is the default */
dev1436drivers/net/pi2.cdev->addr_len = 7;        /* sizeof an ax.25 address */
dev1437drivers/net/pi2.cmemcpy(dev->broadcast, ax25_bcast, 7);
dev1438drivers/net/pi2.cmemcpy(dev->dev_addr, ax25_test, 7);
dev1441drivers/net/pi2.cdev->flags = 0;
dev1442drivers/net/pi2.cdev->family = AF_INET;
dev1443drivers/net/pi2.cdev->pa_addr = 0;
dev1444drivers/net/pi2.cdev->pa_brdaddr = 0;
dev1445drivers/net/pi2.cdev->pa_mask = 0;
dev1446drivers/net/pi2.cdev->pa_alen = 4;
dev1458drivers/net/pi2.cstatic int pi_open(struct device *dev)
dev1463drivers/net/pi2.cstruct pi_local *lp = (struct pi_local *) dev->priv;
dev1465drivers/net/pi2.cif (dev->base_addr & 2) {  /* if A channel */
dev1467drivers/net/pi2.cif (request_dma(dev->dma,"pi2")) {
dev1468drivers/net/pi2.cfree_irq(dev->irq);
dev1471drivers/net/pi2.cirq2dev_map[dev->irq] = dev;
dev1474drivers/net/pi2.cchipset_init(dev);
dev1478drivers/net/pi2.cif (dev->base_addr & 2) {  /* if A channel */
dev1479drivers/net/pi2.cscc_init(dev);    /* Called once for each channel */
dev1480drivers/net/pi2.cscc_init(dev->next);
dev1490drivers/net/pi2.cdev->tbusy = 0;
dev1491drivers/net/pi2.cdev->interrupt = 0;
dev1492drivers/net/pi2.cdev->start = 1;
dev1497drivers/net/pi2.cstatic int pi_send_packet(struct sk_buff *skb, struct device *dev)
dev1499drivers/net/pi2.cstruct pi_local *lp = (struct pi_local *) dev->priv;
dev1505drivers/net/pi2.cdev_tint(dev);
dev1509drivers/net/pi2.cdev->trans_start = jiffies;
dev1571drivers/net/pi2.cstatic int pi_close(struct device *dev)
dev1580drivers/net/pi2.clp = (struct pi_local *) dev->priv;
dev1583drivers/net/pi2.cchipset_init(dev);    /* reset the scc */
dev1588drivers/net/pi2.cdev->tbusy = 1;
dev1589drivers/net/pi2.cdev->start = 0;
dev1599drivers/net/pi2.cstatic int pi_ioctl(struct device *dev, struct ifreq *ifr, int cmd)
dev1603drivers/net/pi2.cstruct pi_local *lp = (struct pi_local *) dev->priv;
dev1637drivers/net/pi2.cif (dev->base_addr & 2) {   /* if A channel */
dev1642drivers/net/pi2.cpi_close(dev);
dev1644drivers/net/pi2.cdev->dma = lp->dmachan = rq.dmachan;
dev1647drivers/net/pi2.cpi_open(dev);
dev1667drivers/net/pi2.crq.irq = dev->irq;
dev1681drivers/net/pi2.cpi_get_stats(struct device *dev)
dev1683drivers/net/pi2.cstruct pi_local *lp = (struct pi_local *) dev->priv;
dev118drivers/net/pi2.hint dev;            /* Device number */
dev120drivers/net/plip.c#define PAR_DATA(dev)    ((dev)->base_addr+0)
dev121drivers/net/plip.c#define PAR_STATUS(dev)    ((dev)->base_addr+1)
dev122drivers/net/plip.c#define PAR_CONTROL(dev)  ((dev)->base_addr+2)
dev125drivers/net/plip.cstatic void plip_kick_bh(struct device *dev);
dev126drivers/net/plip.cstatic void plip_bh(struct device *dev);
dev132drivers/net/plip.cstatic int plip_rebuild_header(void *buff, struct device *dev,
dev134drivers/net/plip.cstatic int plip_tx_packet(struct sk_buff *skb, struct device *dev);
dev135drivers/net/plip.cstatic int plip_open(struct device *dev);
dev136drivers/net/plip.cstatic int plip_close(struct device *dev);
dev137drivers/net/plip.cstatic struct enet_statistics *plip_get_stats(struct device *dev);
dev138drivers/net/plip.cstatic int plip_config(struct device *dev, struct ifmap *map);
dev139drivers/net/plip.cstatic int plip_ioctl(struct device *dev, struct ifreq *ifr, int cmd);
dev198drivers/net/plip.cint (*orig_rebuild_header)(void *eth, struct device *dev,
dev205drivers/net/plip.cplip_init(struct device *dev)
dev210drivers/net/plip.cif (check_region(PAR_DATA(dev), 3) < 0)
dev214drivers/net/plip.coutb(0, PAR_DATA(dev));
dev216drivers/net/plip.cif (inb(PAR_DATA(dev)) != 0)
dev220drivers/net/plip.cprintk("%s: Parallel port at %#3lx, ", dev->name, dev->base_addr);
dev221drivers/net/plip.cif (dev->irq) {
dev222drivers/net/plip.cprintk("using assigned IRQ %d.\n", dev->irq);
dev231drivers/net/plip.coutb(0x00, PAR_CONTROL(dev));
dev233drivers/net/plip.coutb(PAR_INTR_OFF, PAR_CONTROL(dev));
dev234drivers/net/plip.coutb(PAR_INTR_ON, PAR_CONTROL(dev));
dev235drivers/net/plip.coutb(PAR_INTR_OFF, PAR_CONTROL(dev));
dev240drivers/net/plip.cdev->irq = irq;
dev241drivers/net/plip.cprintk("using probed IRQ %d.\n", dev->irq);
dev247drivers/net/plip.crequest_region(PAR_DATA(dev), 3, dev->name);
dev250drivers/net/plip.cether_setup(dev);
dev253drivers/net/plip.cdev->hard_start_xmit  = plip_tx_packet;
dev254drivers/net/plip.cdev->open    = plip_open;
dev255drivers/net/plip.cdev->stop    = plip_close;
dev256drivers/net/plip.cdev->get_stats     = plip_get_stats;
dev257drivers/net/plip.cdev->set_config    = plip_config;
dev258drivers/net/plip.cdev->do_ioctl    = plip_ioctl;
dev259drivers/net/plip.cdev->flags          = IFF_POINTOPOINT|IFF_NOARP;
dev262drivers/net/plip.cdev->priv = kmalloc(sizeof (struct net_local), GFP_KERNEL);
dev263drivers/net/plip.cif (dev->priv == NULL)
dev265drivers/net/plip.cmemset(dev->priv, 0, sizeof(struct net_local));
dev266drivers/net/plip.cnl = (struct net_local *) dev->priv;
dev268drivers/net/plip.cnl->orig_rebuild_header = dev->rebuild_header;
dev269drivers/net/plip.cdev->rebuild_header   = plip_rebuild_header;
dev279drivers/net/plip.cnl->immediate.data = dev;
dev284drivers/net/plip.cnl->deferred.data = dev;
dev293drivers/net/plip.cplip_kick_bh(struct device *dev)
dev295drivers/net/plip.cstruct net_local *nl = (struct net_local *)dev->priv;
dev314drivers/net/plip.cstatic int plip_bh_timeout_error(struct device *dev, struct net_local *nl,
dev323drivers/net/plip.ctypedef int (*plip_func)(struct device *dev, struct net_local *nl,
dev337drivers/net/plip.cplip_bh(struct device *dev)
dev339drivers/net/plip.cstruct net_local *nl = (struct net_local *)dev->priv;
dev347drivers/net/plip.cif ((r = (*f)(dev, nl, snd, rcv)) != OK
dev348drivers/net/plip.c&& (r = plip_bh_timeout_error(dev, nl, snd, rcv, r)) != OK) {
dev355drivers/net/plip.cplip_bh_timeou