Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 6 Oct 2003 12:48:01 -0700 (PDT)
From:      Sam Leffler <sam@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 39270 for review
Message-ID:  <200310061948.h96Jm1aB063060@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=39270

Change 39270 by sam@sam_ebb on 2003/10/06 12:47:41

	IFC @ 39269

Affected files ...

.. //depot/projects/netperf/sys/alpha/include/pmap.h#2 integrate
.. //depot/projects/netperf/sys/amd64/amd64/pmap.c#12 integrate
.. //depot/projects/netperf/sys/amd64/include/pmap.h#3 integrate
.. //depot/projects/netperf/sys/cam/scsi/scsi_cd.c#7 integrate
.. //depot/projects/netperf/sys/coda/coda_subr.c#4 integrate
.. //depot/projects/netperf/sys/conf/majors#5 integrate
.. //depot/projects/netperf/sys/dev/ath/if_ath.c#14 integrate
.. //depot/projects/netperf/sys/dev/cardbus/cardbus.c#3 integrate
.. //depot/projects/netperf/sys/dev/cardbus/cardbus_cis.c#4 integrate
.. //depot/projects/netperf/sys/dev/firewire/firewire.c#5 integrate
.. //depot/projects/netperf/sys/dev/firewire/sbp.c#7 integrate
.. //depot/projects/netperf/sys/dev/pccard/card_if.m#2 integrate
.. //depot/projects/netperf/sys/dev/pccard/pccard_cis_quirks.c#3 integrate
.. //depot/projects/netperf/sys/dev/pccard/pccardvar.h#4 integrate
.. //depot/projects/netperf/sys/dev/usb/if_aue.c#4 integrate
.. //depot/projects/netperf/sys/dev/usb/if_auereg.h#2 integrate
.. //depot/projects/netperf/sys/dev/usb/if_cue.c#3 integrate
.. //depot/projects/netperf/sys/dev/usb/if_cuereg.h#2 integrate
.. //depot/projects/netperf/sys/dev/usb/if_kue.c#3 integrate
.. //depot/projects/netperf/sys/dev/usb/if_kuereg.h#2 integrate
.. //depot/projects/netperf/sys/dev/usb/if_rue.c#3 integrate
.. //depot/projects/netperf/sys/dev/usb/if_ruereg.h#2 integrate
.. //depot/projects/netperf/sys/dev/usb/ubsa.c#3 integrate
.. //depot/projects/netperf/sys/dev/usb/ufm.c#4 integrate
.. //depot/projects/netperf/sys/dev/usb/uhid.c#5 integrate
.. //depot/projects/netperf/sys/dev/usb/ukbd.c#3 integrate
.. //depot/projects/netperf/sys/dev/usb/ums.c#5 integrate
.. //depot/projects/netperf/sys/dev/usb/usb.c#4 integrate
.. //depot/projects/netperf/sys/dev/usb/usb_mem.c#3 integrate
.. //depot/projects/netperf/sys/dev/usb/usb_port.h#2 integrate
.. //depot/projects/netperf/sys/dev/usb/usbdevs#5 integrate
.. //depot/projects/netperf/sys/dev/usb/usbdevs.h#5 integrate
.. //depot/projects/netperf/sys/dev/usb/usbdevs_data.h#5 integrate
.. //depot/projects/netperf/sys/fs/hpfs/hpfs_vnops.c#2 integrate
.. //depot/projects/netperf/sys/fs/msdosfs/msdosfs_denode.c#2 integrate
.. //depot/projects/netperf/sys/fs/msdosfs/msdosfs_vfsops.c#6 integrate
.. //depot/projects/netperf/sys/fs/ntfs/ntfs_vnops.c#3 integrate
.. //depot/projects/netperf/sys/fs/nwfs/nwfs_io.c#5 integrate
.. //depot/projects/netperf/sys/fs/nwfs/nwfs_node.c#2 integrate
.. //depot/projects/netperf/sys/fs/pseudofs/pseudofs_vncache.c#2 integrate
.. //depot/projects/netperf/sys/fs/smbfs/smbfs_io.c#5 integrate
.. //depot/projects/netperf/sys/fs/smbfs/smbfs_node.c#2 integrate
.. //depot/projects/netperf/sys/fs/udf/udf_vnops.c#2 integrate
.. //depot/projects/netperf/sys/geom/geom.h#3 integrate
.. //depot/projects/netperf/sys/geom/geom_io.c#5 integrate
.. //depot/projects/netperf/sys/geom/geom_subr.c#3 integrate
.. //depot/projects/netperf/sys/gnu/ext2fs/ext2_inode.c#2 integrate
.. //depot/projects/netperf/sys/gnu/ext2fs/ext2_vfsops.c#5 integrate
.. //depot/projects/netperf/sys/i386/i386/locore.s#5 integrate
.. //depot/projects/netperf/sys/i386/i386/machdep.c#5 integrate
.. //depot/projects/netperf/sys/i386/i386/pmap.c#15 integrate
.. //depot/projects/netperf/sys/i386/include/pmap.h#4 integrate
.. //depot/projects/netperf/sys/ia64/include/pmap.h#2 integrate
.. //depot/projects/netperf/sys/isofs/cd9660/cd9660_node.c#2 integrate
.. //depot/projects/netperf/sys/kern/kern_exec.c#5 integrate
.. //depot/projects/netperf/sys/kern/kern_proc.c#4 integrate
.. //depot/projects/netperf/sys/kern/kern_synch.c#6 integrate
.. //depot/projects/netperf/sys/kern/kern_sysctl.c#2 integrate
.. //depot/projects/netperf/sys/kern/vfs_bio.c#7 integrate
.. //depot/projects/netperf/sys/kern/vfs_cache.c#2 integrate
.. //depot/projects/netperf/sys/kern/vfs_subr.c#5 integrate
.. //depot/projects/netperf/sys/net/route.c#12 integrate
.. //depot/projects/netperf/sys/netinet6/ah_output.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/frag6.c#3 integrate
.. //depot/projects/netperf/sys/netinet6/icmp6.c#4 integrate
.. //depot/projects/netperf/sys/netinet6/in6.c#5 integrate
.. //depot/projects/netperf/sys/netinet6/in6_gif.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/in6_ifattach.c#6 integrate
.. //depot/projects/netperf/sys/netinet6/in6_pcb.c#7 integrate
.. //depot/projects/netperf/sys/netinet6/in6_prefix.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/in6_proto.c#3 integrate
.. //depot/projects/netperf/sys/netinet6/in6_src.c#4 integrate
.. //depot/projects/netperf/sys/netinet6/ip6_fw.c#4 integrate
.. //depot/projects/netperf/sys/netinet6/ip6_input.c#6 integrate
.. //depot/projects/netperf/sys/netinet6/ip6_mroute.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/ip6_output.c#9 integrate
.. //depot/projects/netperf/sys/netinet6/ipsec.c#3 integrate
.. //depot/projects/netperf/sys/netinet6/nd6.c#7 integrate
.. //depot/projects/netperf/sys/netinet6/nd6_rtr.c#5 integrate
.. //depot/projects/netperf/sys/netinet6/raw_ip6.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/route6.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/scope6.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/udp6_output.c#2 integrate
.. //depot/projects/netperf/sys/netinet6/udp6_usrreq.c#2 integrate
.. //depot/projects/netperf/sys/nfsclient/nfs_node.c#3 integrate
.. //depot/projects/netperf/sys/nfsclient/nfs_subs.c#3 integrate
.. //depot/projects/netperf/sys/nfsclient/nfs_vfsops.c#4 integrate
.. //depot/projects/netperf/sys/pc98/i386/machdep.c#4 integrate
.. //depot/projects/netperf/sys/pc98/pc98/clock.c#6 integrate
.. //depot/projects/netperf/sys/pc98/pc98/sio.c#5 integrate
.. //depot/projects/netperf/sys/pci/if_dc.c#7 integrate
.. //depot/projects/netperf/sys/pci/if_dcreg.h#2 integrate
.. //depot/projects/netperf/sys/powerpc/include/pmap.h#2 integrate
.. //depot/projects/netperf/sys/sparc64/include/pmap.h#2 integrate
.. //depot/projects/netperf/sys/sys/proc.h#5 integrate
.. //depot/projects/netperf/sys/sys/sysctl.h#3 integrate
.. //depot/projects/netperf/sys/ufs/ffs/ffs_inode.c#2 integrate
.. //depot/projects/netperf/sys/ufs/ffs/ffs_snapshot.c#3 integrate
.. //depot/projects/netperf/sys/ufs/ffs/ffs_softdep.c#5 integrate
.. //depot/projects/netperf/sys/ufs/ffs/ffs_vfsops.c#5 integrate
.. //depot/projects/netperf/sys/ufs/ffs/ffs_vnops.c#4 integrate
.. //depot/projects/netperf/sys/ufs/ufs/ufs_inode.c#3 integrate
.. //depot/projects/netperf/sys/vm/device_pager.c#4 integrate
.. //depot/projects/netperf/sys/vm/pmap.h#4 integrate
.. //depot/projects/netperf/sys/vm/vm_extern.h#3 integrate
.. //depot/projects/netperf/sys/vm/vm_fault.c#5 integrate
.. //depot/projects/netperf/sys/vm/vm_glue.c#5 integrate
.. //depot/projects/netperf/sys/vm/vm_kern.c#7 integrate
.. //depot/projects/netperf/sys/vm/vm_map.c#8 integrate
.. //depot/projects/netperf/sys/vm/vm_map.h#6 integrate
.. //depot/projects/netperf/sys/vm/vm_mmap.c#6 integrate
.. //depot/projects/netperf/sys/vm/vm_page.c#7 integrate

Differences ...

==== //depot/projects/netperf/sys/alpha/include/pmap.h#2 (text+ko) ====

@@ -43,7 +43,7 @@
  *	from: hp300: @(#)pmap.h	7.2 (Berkeley) 12/16/90
  *	from: @(#)pmap.h	7.4 (Berkeley) 5/12/91
  *	from: i386 pmap.h,v 1.54 1997/11/20 19:30:35 bde Exp
- * $FreeBSD: src/sys/alpha/include/pmap.h,v 1.23 2003/04/10 18:42:06 jhb Exp $
+ * $FreeBSD: src/sys/alpha/include/pmap.h,v 1.24 2003/10/06 01:47:11 bms Exp $
  */
 
 #ifndef _MACHINE_PMAP_H_
@@ -183,7 +183,6 @@
 };
 
 #define	pmap_page_is_mapped(m)	(!TAILQ_EMPTY(&(m)->md.pv_list))
-#define pmap_resident_count(pmap) (pmap)->pm_stats.resident_count
 
 #define PM_FLAG_LOCKED	0x1
 #define PM_FLAG_WANTED	0x2

==== //depot/projects/netperf/sys/amd64/amd64/pmap.c#12 (text+ko) ====

@@ -73,7 +73,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.441 2003/10/03 22:46:52 alc Exp $");
+__FBSDID("$FreeBSD: src/sys/amd64/amd64/pmap.c,v 1.442 2003/10/05 00:12:16 alc Exp $");
 
 /*
  *	Manages physical address maps.
@@ -1022,7 +1022,6 @@
 		VM_WAIT;
 	vm_page_lock_queues();
 	vm_page_flag_clear(pml4pg, PG_BUSY);
-	pml4pg->valid = VM_PAGE_BITS_ALL;
 	vm_page_unlock_queues();
 
 	pmap->pm_pml4 = (pml4_entry_t *)PHYS_TO_DMAP(VM_PAGE_TO_PHYS(pml4pg));
@@ -1196,7 +1195,6 @@
 	}
 
 	vm_page_lock_queues();
-	m->valid = VM_PAGE_BITS_ALL;
 	vm_page_flag_clear(m, PG_ZERO);
 	vm_page_wakeup(m);
 	vm_page_unlock_queues();

==== //depot/projects/netperf/sys/amd64/include/pmap.h#3 (text+ko) ====

@@ -42,7 +42,7 @@
  *
  *	from: hp300: @(#)pmap.h	7.2 (Berkeley) 12/16/90
  *	from: @(#)pmap.h	7.4 (Berkeley) 5/12/91
- * $FreeBSD: src/sys/amd64/include/pmap.h,v 1.106 2003/09/27 20:53:01 alc Exp $
+ * $FreeBSD: src/sys/amd64/include/pmap.h,v 1.107 2003/10/06 01:47:11 bms Exp $
  */
 
 #ifndef _MACHINE_PMAP_H_
@@ -226,7 +226,6 @@
 };
 
 #define	pmap_page_is_mapped(m)	(!TAILQ_EMPTY(&(m)->md.pv_list))
-#define pmap_resident_count(pmap) (pmap)->pm_stats.resident_count
 
 typedef struct pmap	*pmap_t;
 

==== //depot/projects/netperf/sys/cam/scsi/scsi_cd.c#7 (text+ko) ====

@@ -46,7 +46,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/cam/scsi/scsi_cd.c,v 1.84 2003/09/30 07:52:15 phk Exp $");
+__FBSDID("$FreeBSD: src/sys/cam/scsi/scsi_cd.c,v 1.85 2003/10/06 10:39:13 phk Exp $");
 
 #include "opt_cd.h"
 
@@ -496,6 +496,7 @@
 		free(softc->changer, M_DEVBUF);
 		num_changers--;
 	}
+	disk_destroy(&softc->disk);
 	free(softc, M_DEVBUF);
 	splx(s);
 }
@@ -2852,6 +2853,20 @@
              
 	ccb = cdgetccb(periph, /* priority */ 1);
 
+	scsi_test_unit_ready(&ccb->csio, 0, cddone,
+	    MSG_SIMPLE_Q_TAG, SSD_FULL_SIZE, 1000);
+	ccb->ccb_h.ccb_bp = NULL;
+
+	error = cam_periph_runccb(ccb, NULL,
+				  /*cam_flags*/0,
+				  /*sense_flags*/SF_RETRY_UA,
+				  softc->disk.d_devstat);
+
+	if ((ccb->ccb_h.status & CAM_STATUS_MASK) != CAM_REQ_CMP) {
+		xpt_release_ccb(ccb);
+		return (ENXIO);
+	}
+
 	rcap_buf = malloc(sizeof(struct scsi_read_capacity_data), 
 			  M_TEMP, M_WAITOK);
 

==== //depot/projects/netperf/sys/coda/coda_subr.c#4 (text+ko) ====

@@ -52,14 +52,13 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/coda/coda_subr.c,v 1.25 2003/10/04 13:16:54 jeff Exp $");
-
-#include <vcoda.h>
+__FBSDID("$FreeBSD: src/sys/coda/coda_subr.c,v 1.27 2003/10/05 07:44:45 bde Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
 #include <sys/lock.h>
 #include <sys/malloc.h>
+#include <sys/mutex.h>
 #include <sys/mount.h>
 
 #include <coda/coda.h>
@@ -318,6 +317,11 @@
 		nvp = TAILQ_NEXT(vp, v_nmntvnodes);
 		if (vp->v_mount != mp)
 			continue;
+		VI_LOCK(vp);
+		if (vp->v_iflag & VI_XLOCK) {
+			VI_UNLOCK(vp);
+			continue;
+		}
 		cp = VTOC(vp);
 		count++;
 		if (!(cp->c_flags & C_UNMOUNTING)) {
@@ -325,6 +329,7 @@
 			printf("vp %p, cp %p missed\n", vp, cp);
 			cp->c_flags |= C_UNMOUNTING;
 		}
+		VI_UNLOCK(vp);
 	}
 	mtx_unlock(&mntvnode_mtx);
 }

==== //depot/projects/netperf/sys/conf/majors#5 (text+ko) ====

@@ -1,4 +1,4 @@
-# $FreeBSD: src/sys/conf/majors,v 1.179 2003/09/29 14:15:57 scottl Exp $
+# $FreeBSD: src/sys/conf/majors,v 1.180 2003/10/06 09:13:08 phk Exp $
 #
 # This list is semi-obsoleted by DEVFS, but for now it still contains
 # the current allocation of device major numbers.
@@ -28,7 +28,6 @@
 11	*spigot		Video capture?
 12	*sc		syscons/pcvt virtual consoles
 14	*sa		SCSI "sequential access devices"
-15	*cd		SCSI "CDROM type"
 16	*lpt		PC parallel printer port
 17	*ch		SCSI changer
 18	*nmdm		nullmodem back-to-back tty ports

==== //depot/projects/netperf/sys/dev/ath/if_ath.c#14 (text+ko) ====

@@ -35,7 +35,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.18 2003/09/15 22:34:46 sam Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/ath/if_ath.c,v 1.19 2003/10/06 00:45:25 sam Exp $");
 
 /*
  * Driver for the Atheros Wireless LAN controller.
@@ -995,7 +995,7 @@
 	 */
 	rs = &ni->ni_rates;
 	pktlen = sizeof (struct ieee80211_frame)
-	       + 8 + 2 + 2 + 2+ni->ni_esslen + 2+rs->rs_nrates + 6;
+	       + 8 + 2 + 2 + 2+ni->ni_esslen + 2+rs->rs_nrates + 3 + 6;
 	if (rs->rs_nrates > IEEE80211_RATE_SIZE)
 		pktlen += 2;
 	if (pktlen <= MHLEN)
@@ -1052,6 +1052,9 @@
 	memcpy(frm, ni->ni_essid, ni->ni_esslen);
 	frm += ni->ni_esslen;
 	frm = ieee80211_add_rates(frm, rs);
+	*frm++ = IEEE80211_ELEMID_DSPARMS;
+	*frm++ = 1;
+	*frm++ = ieee80211_chan2ieee(ic, ni->ni_chan);
 	if (ic->ic_opmode == IEEE80211_M_IBSS) {
 		*frm++ = IEEE80211_ELEMID_IBSSPARMS;
 		*frm++ = 2;

==== //depot/projects/netperf/sys/dev/cardbus/cardbus.c#3 (text+ko) ====

@@ -28,7 +28,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/cardbus/cardbus.c,v 1.40 2003/08/24 17:46:02 obrien Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/cardbus/cardbus.c,v 1.41 2003/10/06 15:56:29 imp Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -377,8 +377,6 @@
 	/* Card Interface */
 	DEVMETHOD(card_attach_card,	cardbus_attach_card),
 	DEVMETHOD(card_detach_card,	cardbus_detach_card),
-	DEVMETHOD(card_cis_read,	cardbus_cis_read),
-	DEVMETHOD(card_cis_free,	cardbus_cis_free),
 
 	/* Cardbus/PCI interface */
 	DEVMETHOD(pci_read_config,	pci_read_config_method),

==== //depot/projects/netperf/sys/dev/cardbus/cardbus_cis.c#4 (text+ko) ====

@@ -28,7 +28,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/cardbus/cardbus_cis.c,v 1.40 2003/09/02 17:30:35 jhb Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/cardbus/cardbus_cis.c,v 1.41 2003/10/06 15:56:29 imp Exp $");
 
 /*
  * CIS Handling for the Cardbus Bus
@@ -75,9 +75,6 @@
 static int decode_tuple_generic(device_t cbdev, device_t child, int id,
     int len, uint8_t *tupledata, uint32_t start, uint32_t *off,
     struct tuple_callbacks *info);
-static int decode_tuple_nothing(device_t cbdev, device_t child, int id,
-    int len, uint8_t *tupledata, uint32_t start, uint32_t *off,
-    struct tuple_callbacks *info);
 static int decode_tuple_copy(device_t cbdev, device_t child, int id,
     int len, uint8_t *tupledata, uint32_t start, uint32_t *off,
     struct tuple_callbacks *info);
@@ -157,9 +154,6 @@
 	{ 0 }
 };
 
-static struct cis_tupleinfo *cisread_buf;
-static int ncisread_buf;
-
 /*
  * Handler functions for various CIS tuples
  */
@@ -188,38 +182,6 @@
 }
 
 static int
-decode_tuple_nothing(device_t cbdev, device_t child, int id,
-    int len, uint8_t *tupledata, uint32_t start, uint32_t *off,
-    struct tuple_callbacks *info)
-{
-	return (0);
-}
-
-static int
-decode_tuple_copy(device_t cbdev, device_t child, int id,
-    int len, uint8_t *tupledata, uint32_t start, uint32_t *off,
-    struct tuple_callbacks *info)
-{
-	struct cis_tupleinfo *tmpbuf;
-
-	tmpbuf = malloc(sizeof(struct cis_tupleinfo) * (ncisread_buf+1),
-	    M_DEVBUF, M_WAITOK);
-	if (ncisread_buf > 0) {
-		memcpy(tmpbuf, cisread_buf,
-		    sizeof(struct cis_tupleinfo) * ncisread_buf);
-		free(cisread_buf, M_DEVBUF);
-	}
-	cisread_buf = tmpbuf;
-
-	cisread_buf[ncisread_buf].id = id;
-	cisread_buf[ncisread_buf].len = len;
-	cisread_buf[ncisread_buf].data = malloc(len, M_DEVBUF, M_WAITOK);
-	memcpy(cisread_buf[ncisread_buf].data, tupledata, len);
-	ncisread_buf++;
-	return (0);
-}
-
-static int
 decode_tuple_linktarget(device_t cbdev, device_t child, int id,
     int len, uint8_t *tupledata, uint32_t start, uint32_t *off,
     struct tuple_callbacks *info)
@@ -1056,77 +1018,6 @@
 }
 
 int
-cardbus_cis_read(device_t cbdev, device_t child, uint8_t id,
-    struct cis_tupleinfo **buff, int *nret)
-{
-	struct tuple_callbacks cisread_callbacks[] = {
-		MAKETUPLE(NULL,			nothing),
-		/* first entry will be overwritten */
-		MAKETUPLE(NULL,			nothing),
-		MAKETUPLE(DEVICE,		nothing),
-		MAKETUPLE(LONG_LINK_CB,		unhandled),
-		MAKETUPLE(INDIRECT,		unhandled),
-		MAKETUPLE(CONFIG_CB,		nothing),
-		MAKETUPLE(CFTABLE_ENTRY_CB,	nothing),
-		MAKETUPLE(LONGLINK_MFC,		unhandled),
-		MAKETUPLE(BAR,			nothing),
-		MAKETUPLE(PWR_MGMNT,		nothing),
-		MAKETUPLE(EXTDEVICE,		nothing),
-		MAKETUPLE(CHECKSUM,		nothing),
-		MAKETUPLE(LONGLINK_A,		unhandled),
-		MAKETUPLE(LONGLINK_C,		unhandled),
-		MAKETUPLE(LINKTARGET,		nothing),
-		MAKETUPLE(NO_LINK,		nothing),
-		MAKETUPLE(VERS_1,		nothing),
-		MAKETUPLE(ALTSTR,		nothing),
-		MAKETUPLE(DEVICE_A,		nothing),
-		MAKETUPLE(JEDEC_C,		nothing),
-		MAKETUPLE(JEDEC_A,		nothing),
-		MAKETUPLE(CONFIG,		nothing),
-		MAKETUPLE(CFTABLE_ENTRY,	nothing),
-		MAKETUPLE(DEVICE_OC,		nothing),
-		MAKETUPLE(DEVICE_OA,		nothing),
-		MAKETUPLE(DEVICE_GEO,		nothing),
-		MAKETUPLE(DEVICE_GEO_A,		nothing),
-		MAKETUPLE(MANFID,		nothing),
-		MAKETUPLE(FUNCID,		nothing),
-		MAKETUPLE(FUNCE,		nothing),
-		MAKETUPLE(SWIL,			nothing),
-		MAKETUPLE(VERS_2,		nothing),
-		MAKETUPLE(FORMAT,		nothing),
-		MAKETUPLE(GEOMETRY,		nothing),
-		MAKETUPLE(BYTEORDER,		nothing),
-		MAKETUPLE(DATE,			nothing),
-		MAKETUPLE(BATTERY,		nothing),
-		MAKETUPLE(ORG,			nothing),
-		MAKETUPLE(END,			end),
-		MAKETUPLE(GENERIC,		nothing),
-	};
-	int ret;
-
-	cisread_callbacks[0].id = id;
-	cisread_callbacks[0].name = "COPY";
-	cisread_callbacks[0].func = decode_tuple_copy;
-	ncisread_buf = 0;
-	cisread_buf = NULL;
-	ret = cardbus_parse_cis(cbdev, child, cisread_callbacks);
-
-	*buff = cisread_buf;
-	*nret = ncisread_buf;
-	return (ret);
-}
-
-void
-cardbus_cis_free(device_t cbdev, struct cis_tupleinfo *buff, int *nret)
-{
-	int i;
-	for (i = 0; i < *nret; i++)
-		free(buff[i].data, M_DEVBUF);
-	if (*nret > 0)
-		free(buff, M_DEVBUF);
-}
-
-int
 cardbus_do_cis(device_t cbdev, device_t child)
 {
 	int ret;

==== //depot/projects/netperf/sys/dev/firewire/firewire.c#5 (text+ko) ====

@@ -31,7 +31,7 @@
  * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGE.
  * 
- * $FreeBSD: src/sys/dev/firewire/firewire.c,v 1.61 2003/10/02 04:06:55 simokawa Exp $
+ * $FreeBSD: src/sys/dev/firewire/firewire.c,v 1.62 2003/10/06 07:17:43 simokawa Exp $
  *
  */
 
@@ -64,18 +64,19 @@
 	struct crom_chunk hw;
 };
 
-int firewire_debug=0, try_bmr=1;
+int firewire_debug=0, try_bmr=1, hold_count=3;
 SYSCTL_INT(_debug, OID_AUTO, firewire_debug, CTLFLAG_RW, &firewire_debug, 0,
 	"FireWire driver debug flag");
 SYSCTL_NODE(_hw, OID_AUTO, firewire, CTLFLAG_RD, 0, "FireWire Subsystem");
 SYSCTL_INT(_hw_firewire, OID_AUTO, try_bmr, CTLFLAG_RW, &try_bmr, 0,
 	"Try to be a bus manager");
+SYSCTL_INT(_hw_firewire, OID_AUTO, hold_count, CTLFLAG_RW, &hold_count, 0,
+	"Number of count of bus resets for removing lost device information");
 
 MALLOC_DEFINE(M_FW, "firewire", "FireWire");
 MALLOC_DEFINE(M_FWXFER, "fw_xfer", "XFER/FireWire");
 
 #define FW_MAXASYRTY 4
-#define FW_MAXDEVRCNT 4
 
 devclass_t firewire_devclass;
 
@@ -1227,28 +1228,19 @@
 fw_bus_probe(struct firewire_comm *fc)
 {
 	int s;
-	struct fw_device *fwdev, *next;
+	struct fw_device *fwdev;
 
 	s = splfw();
 	fc->status = FWBUSEXPLORE;
 	fc->retry_count = 0;
 
-/*
- * Invalidate all devices, just after bus reset. Devices 
- * to be removed has not been seen longer time.
- */
-	for (fwdev = STAILQ_FIRST(&fc->devices); fwdev != NULL; fwdev = next) {
-		next = STAILQ_NEXT(fwdev, link);
+	/* Invalidate all devices, just after bus reset. */
+	STAILQ_FOREACH(fwdev, &fc->devices, link)
 		if (fwdev->status != FWDEVINVAL) {
 			fwdev->status = FWDEVINVAL;
 			fwdev->rcnt = 0;
-		} else if(fwdev->rcnt < FW_MAXDEVRCNT) {
-			fwdev->rcnt ++;
-		} else {
-			STAILQ_REMOVE(&fc->devices, fwdev, fw_device, link);
-			free(fwdev, M_FW);
 		}
-	}
+
 	fc->ongonode = 0;
 	fc->ongoaddr = CSRROMOFF;
 	fc->ongodev = NULL;
@@ -1592,16 +1584,30 @@
 static void
 fw_attach_dev(struct firewire_comm *fc)
 {
-	struct fw_device *fwdev;
+	struct fw_device *fwdev, *next;
 	struct fw_xfer *xfer;
 	int i, err;
 	device_t *devlistp;
 	int devcnt;
 	struct firewire_dev_comm *fdc;
 
-	STAILQ_FOREACH(fwdev, &fc->devices, link)
-		if (fwdev->status == FWDEVINIT)
+	for (fwdev = STAILQ_FIRST(&fc->devices); fwdev != NULL; fwdev = next) {
+		next = STAILQ_NEXT(fwdev, link);
+		if (fwdev->status == FWDEVINIT) {
 			fwdev->status = FWDEVATTACHED;
+		} else if (fwdev->status == FWDEVINVAL) {
+			fwdev->rcnt ++;
+			if (fwdev->rcnt > hold_count) {
+				/*
+				 * Remove devices which have not been seen
+				 * for a while.
+				 */
+				STAILQ_REMOVE(&fc->devices, fwdev, fw_device,
+				    link);
+				free(fwdev, M_FW);
+			}
+		}
+	}
 
 	err = device_get_children(fc->bdev, &devlistp, &devcnt);
 	if( err != 0 )

==== //depot/projects/netperf/sys/dev/firewire/sbp.c#7 (text+ko) ====

@@ -31,7 +31,7 @@
  * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGE.
  * 
- * $FreeBSD: src/sys/dev/firewire/sbp.c,v 1.62 2003/10/02 04:06:56 simokawa Exp $
+ * $FreeBSD: src/sys/dev/firewire/sbp.c,v 1.64 2003/10/06 05:40:47 simokawa Exp $
  *
  */
 
@@ -157,7 +157,9 @@
 		 timeout:4;
 	u_int8_t type;
 	u_int16_t lun_id;
-	int freeze;
+	u_int16_t freeze;
+#define	ORB_LINK_DEAD 1
+	u_int16_t flags;
 	struct cam_path *path;
 	struct sbp_target *target;
 	struct fwdma_alloc dma;
@@ -194,8 +196,6 @@
 	struct sbp_target targets[SBP_NUM_TARGETS];
 	struct fw_bind fwb;
 	bus_dma_tag_t	dmat;
-#define SBP_RESOURCE_SHORTAGE 0x10
-	unsigned char flags;
 };
 static void sbp_post_explore __P((void *));
 static void sbp_recv __P((struct fw_xfer *));
@@ -811,6 +811,10 @@
 	sbp_show_sdev_info(sdev, 2);
 	printf("sbp_cmd_callback\n");
 END_DEBUG
+	if (xfer->resp != 0) {
+		/* XXX */
+		printf("%s: xfer->resp != 0\n", __FUNCTION__);
+	}
 	sbp_xfer_free(xfer);
 	return;
 }
@@ -1536,6 +1540,7 @@
 		switch(ocb->flags) {
 		case OCB_ACT_MGM:
 			orb_fun = ntohl(ocb->orb[4]) & ORB_FUN_MSK;
+			reset_agent = 0;
 			switch(orb_fun) {
 			case ORB_FUN_LGI:
 				fwdma_sync(&sdev->dma, BUS_DMASYNC_POSTREAD);
@@ -1953,7 +1958,8 @@
 	struct sbp_target *target = sdev->target;
 
 	sbp_show_sdev_info(sdev, 2);
-	printf("management ORB timeout\n");
+	printf("request timeout(mgm orb:0x%08x) ... ",
+	    (u_int32_t)ocb->bus_addr);
 	target->mgm_ocb_cur = NULL;
 	sbp_free_ocb(sdev, ocb);
 #if 0
@@ -1972,7 +1978,8 @@
 	struct sbp_dev *sdev = ocb->sdev;
 
 	sbp_show_sdev_info(sdev, 2);
-	printf("request timeout ... ");
+	printf("request timeout(cmd orb:0x%08x) ... ",
+	    (u_int32_t)ocb->bus_addr);
 
 	sdev->timeout ++;
 	switch(sdev->timeout) {
@@ -2366,16 +2373,26 @@
 			BUS_DMASYNC_PREREAD : BUS_DMASYNC_PREWRITE);
 	prev = sbp_enqueue_ocb(ocb->sdev, ocb);
 	fwdma_sync(&ocb->sdev->dma, BUS_DMASYNC_PREWRITE);
-	if (prev == NULL)
+	if (prev == NULL || (ocb->sdev->flags & ORB_LINK_DEAD) != 0) {
+		ocb->sdev->flags &= ~ORB_LINK_DEAD;
 		sbp_orb_pointer(ocb->sdev, ocb); 
+	}
 }
 
 static void
 sbp_poll(struct cam_sim *sim)
 {       
-	/* should call fwohci_intr? */
+	struct sbp_softc *sbp;
+	struct firewire_comm *fc;
+
+	sbp = (struct sbp_softc *)sim->softc;
+	fc = sbp->fd.fc;
+
+	fc->poll(fc, 0, -1);
+
 	return;
 }
+
 static struct sbp_ocb *
 sbp_dequeue_ocb(struct sbp_dev *sdev, struct sbp_status *sbp_status)
 {
@@ -2413,8 +2430,18 @@
 				bus_dmamap_unload(sdev->target->sbp->dmat,
 					ocb->dmamap);
 			}
-			if (next != NULL && sbp_status->src == 1)
-				sbp_orb_pointer(sdev, next); 
+			if (sbp_status->src == SRC_NO_NEXT) {
+				if (next != NULL)
+					sbp_orb_pointer(sdev, next); 
+				else if (order > 0) {
+					/*
+					 * Unordered execution
+					 * We need to send pointer for
+					 * next ORB
+					 */
+					sdev->flags |= ORB_LINK_DEAD;
+				}
+			}
 			break;
 		} else
 			order ++;
@@ -2451,13 +2478,14 @@
 		ocb->ccb->ccb_h.timeout_ch = timeout(sbp_timeout, (caddr_t)ocb,
 					(ocb->ccb->ccb_h.timeout * hz) / 1000);
 
-	if (prev != NULL ) {
+	if (prev != NULL) {
 SBP_DEBUG(1)
 #if __FreeBSD_version >= 500000
-	printf("linking chain 0x%jx -> 0x%jx\n",
-		(uintmax_t)prev->bus_addr, (uintmax_t)ocb->bus_addr);
+		printf("linking chain 0x%jx -> 0x%jx\n",
+		    (uintmax_t)prev->bus_addr, (uintmax_t)ocb->bus_addr);
 #else
-	printf("linking chain 0x%x -> 0x%x\n", prev->bus_addr, ocb->bus_addr);
+		printf("linking chain 0x%x -> 0x%x\n",
+		    prev->bus_addr, ocb->bus_addr);
 #endif
 END_DEBUG
 		prev->orb[1] = htonl(ocb->bus_addr);

==== //depot/projects/netperf/sys/dev/pccard/card_if.m#2 (text+ko) ====

@@ -23,7 +23,7 @@
 # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 # SUCH DAMAGE.
 #
-# $FreeBSD: src/sys/dev/pccard/card_if.m,v 1.21 2002/11/02 23:00:28 imp Exp $
+# $FreeBSD: src/sys/dev/pccard/card_if.m,v 1.22 2003/10/06 07:10:40 imp Exp $
 #
 
 #include <sys/bus.h>
@@ -200,52 +200,3 @@
 METHOD int compat_match {
 	device_t dev;
 }
-
-#
-# Method for devices to ask its CIS-enabled parent bus for CIS info.
-# Device driver requests all tuples if type 'id', the routine places
-# 'nret' number of tuples in 'buff'.  Returns 0 if all tuples processed,
-# or an error code if processing was aborted.
-# Users of this method will be responsible for freeing the memory allocated
-# by calling the cis_free method.
-#
-
-HEADER {
-	struct cis_tupleinfo {
-		u_int8_t id;
-		int len;
-		char *data;
-	};
-};
-
-CODE  {
-	static int
-	null_cis_read(device_t dev, device_t child, u_int8_t id,
-	    struct cis_tupleinfo **buff, int *nret)
-	{
-		*nret = 0;
-		*buff = NULL;
-		return ENXIO;
-	}
-
-	static void
-	null_cis_free(device_t dev, struct cis_tupleinfo *buff, int *nret)
-	{
-		return;
-	}
-};
-
-METHOD int cis_read {
-	device_t dev;
-	device_t child;
-	u_int8_t id;
-	struct	 cis_tupleinfo **buff;
-	int	 *nret;
-} DEFAULT null_cis_read;
-
-METHOD int cis_free {
-	device_t dev;
-	struct	 cis_tupleinfo *buff;
-	int	 nret;
-} DEFAULT null_cis_free;
-

==== //depot/projects/netperf/sys/dev/pccard/pccard_cis_quirks.c#3 (text+ko) ====

@@ -1,7 +1,7 @@
 /*	$NetBSD: pcmcia_cis_quirks.c,v 1.6 2000/04/12 21:07:55 scw Exp $ */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/pccard/pccard_cis_quirks.c,v 1.8 2003/08/24 17:54:15 obrien Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/pccard/pccard_cis_quirks.c,v 1.9 2003/10/06 07:17:20 imp Exp $");
 
 #define	PCCARDDEBUG
 
@@ -208,6 +208,23 @@
 static int n_pccard_cis_quirks =
 	sizeof(pccard_cis_quirks)/sizeof(pccard_cis_quirks[0]);
 
+static int
+pccard_cis_quirk_match(struct pccard_softc *sc, struct pccard_cis_quirk *q)
+{
+	if ((sc->card.manufacturer == q->manufacturer) &&
+		(sc->card.product == q->product) &&
+		(((sc->card.manufacturer != PCMCIA_VENDOR_INVALID) &&
+		  (sc->card.product != PCMCIA_PRODUCT_INVALID)) ||
+		 ((sc->card.manufacturer == PCMCIA_VENDOR_INVALID) &&
+		  (sc->card.product == PCMCIA_PRODUCT_INVALID) &&
+		  sc->card.cis1_info[0] &&
+		  (strcmp(sc->card.cis1_info[0], q->cis1_info[0]) == 0) &&
+		  sc->card.cis1_info[1] &&
+		  (strcmp(sc->card.cis1_info[1], q->cis1_info[1]) == 0))))
+		return (1);
+	return (0);
+}
+
 void pccard_check_cis_quirks(device_t dev)
 {
 	struct pccard_softc *sc = PCCARD_SOFTC(dev);
@@ -215,69 +232,56 @@
 	int i, j;
 	struct pccard_function *pf, *pf_next, *pf_last;
 	struct pccard_config_entry *cfe, *cfe_next;
+	struct pccard_cis_quirk *q;
 
 	pf = NULL;
 	pf_last = NULL;
 
 	for (i=0; i<n_pccard_cis_quirks; i++) {
-		if ((sc->card.manufacturer == pccard_cis_quirks[i].manufacturer) &&
-			(sc->card.product == pccard_cis_quirks[i].product) &&
-			(((sc->card.manufacturer != PCMCIA_VENDOR_INVALID) &&
-			  (sc->card.product != PCMCIA_PRODUCT_INVALID)) ||
-			 ((sc->card.manufacturer == PCMCIA_VENDOR_INVALID) &&
-			  (sc->card.product == PCMCIA_PRODUCT_INVALID) &&
-			  sc->card.cis1_info[0] &&
-			  (strcmp(sc->card.cis1_info[0],
-					  pccard_cis_quirks[i].cis1_info[0]) == 0) &&
-			  sc->card.cis1_info[1] &&
-			  (strcmp(sc->card.cis1_info[1],
-					  pccard_cis_quirks[i].cis1_info[1]) == 0)))) {
-			if (!wiped) {
-				if (bootverbose) {
-					device_printf(dev, "using CIS quirks for ");
-					for (j = 0; j < 4; j++) {
-						if (sc->card.cis1_info[j] == NULL)
-							break;
-						if (j)
-							printf(", ");
-						printf("%s", sc->card.cis1_info[j]);
-					}
-					printf("\n");
+		q = &pccard_cis_quirks[i];
+		if (!pccard_cis_quirk_match(sc, q))
+			continue;
+		if (!wiped) {
+			if (bootverbose) {
+				device_printf(dev, "using CIS quirks for ");
+				for (j = 0; j < 4; j++) {
+					if (sc->card.cis1_info[j] == NULL)
+						break;
+					if (j)
+						printf(", ");
+					printf("%s", sc->card.cis1_info[j]);
 				}
+				printf("\n");
+			}
 
-				for (pf = STAILQ_FIRST(&sc->card.pf_head); pf != NULL;
-				     pf = pf_next) {
-					for (cfe = STAILQ_FIRST(&pf->cfe_head); cfe != NULL;
-					     cfe = cfe_next) {
-						cfe_next = STAILQ_NEXT(cfe, cfe_list);
-						free(cfe, M_DEVBUF);
-					}
-					pf_next = STAILQ_NEXT(pf, pf_list);
-					free(pf, M_DEVBUF);
+			for (pf = STAILQ_FIRST(&sc->card.pf_head); pf != NULL;
+			     pf = pf_next) {
+				for (cfe = STAILQ_FIRST(&pf->cfe_head); cfe != NULL;
+				     cfe = cfe_next) {
+					cfe_next = STAILQ_NEXT(cfe, cfe_list);
+					free(cfe, M_DEVBUF);
 				}
-
-				STAILQ_INIT(&sc->card.pf_head);
-				wiped = 1;
+				pf_next = STAILQ_NEXT(pf, pf_list);
+				free(pf, M_DEVBUF);
 			}
 
-			if (pf_last == pccard_cis_quirks[i].pf) {
-				cfe = malloc(sizeof(*cfe), M_DEVBUF, M_NOWAIT);
-				*cfe = *pccard_cis_quirks[i].cfe;
+			STAILQ_INIT(&sc->card.pf_head);
+			wiped = 1;
+		}
 
-				STAILQ_INSERT_TAIL(&pf->cfe_head, cfe, cfe_list);
-			} else {
-				pf = malloc(sizeof(*pf), M_DEVBUF, M_NOWAIT);
-				*pf = *pccard_cis_quirks[i].pf;
-				STAILQ_INIT(&pf->cfe_head);
-
-				cfe = malloc(sizeof(*cfe), M_DEVBUF, M_NOWAIT);
-				*cfe = *pccard_cis_quirks[i].cfe;
-
-				STAILQ_INSERT_TAIL(&pf->cfe_head, cfe, cfe_list);
-				STAILQ_INSERT_TAIL(&sc->card.pf_head, pf, pf_list);
-
-				pf_last = pccard_cis_quirks[i].pf;
-			}
+		if (pf_last == q->pf) {
+			cfe = malloc(sizeof(*cfe), M_DEVBUF, M_NOWAIT);
+			*cfe = *q->cfe;
+			STAILQ_INSERT_TAIL(&pf->cfe_head, cfe, cfe_list);
+		} else {
+			pf = malloc(sizeof(*pf), M_DEVBUF, M_NOWAIT);
+			*pf = *q->pf;
+			STAILQ_INIT(&pf->cfe_head);
+			cfe = malloc(sizeof(*cfe), M_DEVBUF, M_NOWAIT);
+			*cfe = *q->cfe;
+			STAILQ_INSERT_TAIL(&pf->cfe_head, cfe, cfe_list);
+			STAILQ_INSERT_TAIL(&sc->card.pf_head, pf, pf_list);
+			pf_last = q->pf;
 		}
 	}
 }

==== //depot/projects/netperf/sys/dev/pccard/pccardvar.h#4 (text+ko) ====

@@ -1,5 +1,5 @@
 /*	$NetBSD: pcmciavar.h,v 1.12 2000/02/08 12:51:31 enami Exp $	*/
-/* $FreeBSD: src/sys/dev/pccard/pccardvar.h,v 1.43 2003/09/20 17:46:39 imp Exp $ */
+/* $FreeBSD: src/sys/dev/pccard/pccardvar.h,v 1.44 2003/10/06 07:17:20 imp Exp $ */
 
 /*
  * Copyright (c) 1997 Marc Horowitz.  All rights reserved.
@@ -203,9 +203,6 @@
 	int		sc_enabled_count;	/* num functions enabled */
 };
 
-void
-pccardbus_if_setup(struct pccard_softc*);
-
 struct pccard_cis_quirk {
 	int32_t manufacturer;
 	int32_t product;
@@ -286,7 +283,8 @@
 #define	PCCARD_SPACE_MEMORY	1
 #define	PCCARD_SPACE_IO		2
 
-#define	pccard_mfc(sc)	(STAILQ_FIRST(&(sc)->card.pf_head) &&		\
+#define	pccard_mfc(sc)							\
+		(STAILQ_FIRST(&(sc)->card.pf_head) &&			\
 		 STAILQ_NEXT(STAILQ_FIRST(&(sc)->card.pf_head),pf_list))
 
 #define	pccard_io_alloc(pf, start, size, align, pciop)			\

==== //depot/projects/netperf/sys/dev/usb/if_aue.c#4 (text+ko) ====

@@ -31,7 +31,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/usb/if_aue.c,v 1.72 2003/09/18 15:41:06 obrien Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/usb/if_aue.c,v 1.73 2003/10/04 21:41:01 joe Exp $");
 
 /*
  * ADMtek AN986 Pegasus and AN8511 Pegasus II USB to ethernet driver.
@@ -63,7 +63,7 @@
  */
 
 #include <sys/cdefs.h>
-__FBSDID("$FreeBSD: src/sys/dev/usb/if_aue.c,v 1.72 2003/09/18 15:41:06 obrien Exp $");
+__FBSDID("$FreeBSD: src/sys/dev/usb/if_aue.c,v 1.73 2003/10/04 21:41:01 joe Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -83,6 +83,9 @@
 
 #include <sys/bus.h>
 #include <machine/bus.h>
+#if __FreeBSD_version < 500000
+#include <machine/clock.h>
+#endif
 
 #include <dev/usb/usb.h>
 #include <dev/usb/usbdi.h>
@@ -558,7 +561,12 @@

>>> TRUNCATED FOR MAIL (1000 lines) <<<



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200310061948.h96Jm1aB063060>