From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 03:36:58 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BB828106566B; Sun, 2 Sep 2012 03:36:58 +0000 (UTC) (envelope-from avatar@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8BFAD8FC0A; Sun, 2 Sep 2012 03:36:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q823aw2F031548; Sun, 2 Sep 2012 03:36:58 GMT (envelope-from avatar@svn.freebsd.org) Received: (from avatar@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q823awhq031546; Sun, 2 Sep 2012 03:36:58 GMT (envelope-from avatar@svn.freebsd.org) Message-Id: <201209020336.q823awhq031546@svn.freebsd.org> From: Tai-hwa Liang Date: Sun, 2 Sep 2012 03:36:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r239999 - stable/9/sys/gnu/fs/reiserfs X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 03:36:58 -0000 Author: avatar Date: Sun Sep 2 03:36:57 2012 New Revision: 239999 URL: http://svn.freebsd.org/changeset/base/239999 Log: MFC r238980: Just like the other file systems found in /sys/fs, g_vfs_open() should be paried with g_vfs_close(). Though g_vfs_close() is a wrapper around g_wither_geom_close(), r206130 added the following test in g_vfs_open(): if (bo->bo_private != vp) return (EBUSY); Which will cause a 'Device busy' error inside reiserfs_mountfs() if the same file system is re-mounted again after umount or mounting failure: (case 1, /dev/ad4s3 is not a valid REISERFS partition) # mount -t reiserfs -o ro /dev/ad4s3 /mnt mount: /dev/ad4s3: Invalid argument # mount -t msdosfs -o ro /dev/ad4s3 /mnt mount: /dev/ad4s3: Device busy (case 2, /dev/ad4s3 is a valid REISERFS partition) # mount -t reiserfs -o ro /dev/ad4s3 /mnt # umount /mnt # mount -t reiserfs -o ro /dev/ad4s3 /mnt mount: /dev/ad4s3: Device busy On the other hand, g_vfs_close() 'fixed' the above cases by doing an extra step to keep 'sc->sc_bo->bo_private' and 'cp->private' pointers synchronised. Reviewed by: kib Modified: stable/9/sys/gnu/fs/reiserfs/reiserfs_vfsops.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/gnu/fs/reiserfs/reiserfs_vfsops.c ============================================================================== --- stable/9/sys/gnu/fs/reiserfs/reiserfs_vfsops.c Sun Sep 2 01:48:47 2012 (r239998) +++ stable/9/sys/gnu/fs/reiserfs/reiserfs_vfsops.c Sun Sep 2 03:36:57 2012 (r239999) @@ -227,7 +227,7 @@ reiserfs_unmount(struct mount *mp, int m DROP_GIANT(); g_topology_lock(); - g_wither_geom_close(rmp->rm_cp->geom, ENXIO); + g_vfs_close(rmp->rm_cp); g_topology_unlock(); PICKUP_GIANT(); vrele(rmp->rm_devvp); @@ -611,7 +611,7 @@ out: if (cp != NULL) { DROP_GIANT(); g_topology_lock(); - g_wither_geom_close(cp->geom, ENXIO); + g_vfs_close(cp); g_topology_unlock(); PICKUP_GIANT(); } From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 11:44:30 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BB891106566C; Sun, 2 Sep 2012 11:44:30 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A612B8FC08; Sun, 2 Sep 2012 11:44:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82BiU0e095157; Sun, 2 Sep 2012 11:44:30 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82BiUm1095154; Sun, 2 Sep 2012 11:44:30 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201209021144.q82BiUm1095154@svn.freebsd.org> From: Dimitry Andric Date: Sun, 2 Sep 2012 11:44:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240006 - stable/9/share/mk X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 11:44:30 -0000 Author: dim Date: Sun Sep 2 11:44:30 2012 New Revision: 240006 URL: http://svn.freebsd.org/changeset/base/240006 Log: MFC r226216 (by das): Pass -std= flags in CFLAGS to mkdep. Without this, preprocessor tests for particular compiler features might be evaluated differently by mkdep than they would be by cc. MFC r226244 (by das): Also pass the -ansi flag through to mkdep (requested by bde), and fix a cut-and-paste-o (noticed by rdivacky). MFC r239613: Make sure bsd.dep.mk does not filter out -stdlib=xxx from CXXFLAGS, since this determines parts of the C++ include path. Modified: stable/9/share/mk/bsd.dep.mk Directory Properties: stable/9/share/mk/ (props changed) Modified: stable/9/share/mk/bsd.dep.mk ============================================================================== --- stable/9/share/mk/bsd.dep.mk Sun Sep 2 11:03:18 2012 (r240005) +++ stable/9/share/mk/bsd.dep.mk Sun Sep 2 11:44:30 2012 (r240006) @@ -125,8 +125,10 @@ depend: beforedepend ${DEPENDFILE} after # Different types of sources are compiled with slightly different flags. # Split up the sources, and filter out headers and non-applicable flags. -MKDEP_CFLAGS= ${CFLAGS:M-nostdinc*} ${CFLAGS:M-[BIDU]*} -MKDEP_CXXFLAGS= ${CXXFLAGS:M-nostdinc*} ${CXXFLAGS:M-[BIDU]*} +MKDEP_CFLAGS= ${CFLAGS:M-nostdinc*} ${CFLAGS:M-[BIDU]*} ${CFLAGS:M-std=*} \ + ${CFLAGS:M-ansi} +MKDEP_CXXFLAGS= ${CXXFLAGS:M-nostdinc*} ${CXXFLAGS:M-[BIDU]*} \ + ${CXXFLAGS:M-std=*} ${CXXFLAGS:M-ansi} ${CXXFLAGS:M-stdlib=*} DPSRCS+= ${SRCS} ${DEPENDFILE}: ${DPSRCS} From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 14:41:30 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 644741065677; Sun, 2 Sep 2012 14:41:30 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4E1E88FC19; Sun, 2 Sep 2012 14:41:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82EfUx2018579; Sun, 2 Sep 2012 14:41:30 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82EfUe3018575; Sun, 2 Sep 2012 14:41:30 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021441.q82EfUe3018575@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 14:41:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240008 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 14:41:30 -0000 Author: mjacob Date: Sun Sep 2 14:41:29 2012 New Revision: 240008 URL: http://svn.freebsd.org/changeset/base/240008 Log: Very belated MFC of 227548 Was chasing down a failure to load f/w on a 2400. It turns out that the card is actually broken, or needs a BIOS upgrade for 64 bit loads, but this uncovered a couple of misplaced opcode definitions and some missing continual mbox command cases, so might as well update them here. Modified: stable/9/sys/dev/isp/isp.c stable/9/sys/dev/isp/isp_pci.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp.c ============================================================================== --- stable/9/sys/dev/isp/isp.c Sun Sep 2 12:37:30 2012 (r240007) +++ stable/9/sys/dev/isp/isp.c Sun Sep 2 14:41:29 2012 (r240008) @@ -748,11 +748,13 @@ isp_reset(ispsoftc_t *isp, int do_load_d if (dodnld && IS_24XX(isp)) { const uint32_t *ptr = isp->isp_mdvec->dv_ispfw; + int wordload; /* * Keep loading until we run out of f/w. */ code_org = ptr[2]; /* 1st load address is our start addr */ + wordload = 0; for (;;) { uint32_t la, wi, wl; @@ -777,6 +779,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d wl--; } MEMORYBARRIER(isp, SYNC_REQUEST, 0, ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)), -1); + again: ISP_MEMZERO(&mbs, sizeof (mbs)); if (la < 0x10000 && nw < 0x10000) { mbs.param[0] = MBOX_LOAD_RISC_RAM_2100; @@ -786,6 +789,23 @@ isp_reset(ispsoftc_t *isp, int do_load_d mbs.param[4] = nw; mbs.param[6] = DMA_WD3(isp->isp_rquest_dma); mbs.param[7] = DMA_WD2(isp->isp_rquest_dma); + isp_prt(isp, ISP_LOGDEBUG0, "LOAD RISC RAM 2100 %u words at load address 0x%x", nw, la); + } else if (wordload) { + union { + const uint32_t *cp; + uint32_t *np; + } ucd; + ucd.cp = (const uint32_t *)cp; + mbs.param[0] = MBOX_WRITE_RAM_WORD_EXTENDED; + mbs.param[1] = la; + mbs.param[2] = (*ucd.np); + mbs.param[3] = (*ucd.np) >> 16; + mbs.param[8] = la >> 16; + isp->isp_mbxwrk0 = nw - 1; + isp->isp_mbxworkp = ucd.np+1; + isp->isp_mbxwrk1 = (la + 1); + isp->isp_mbxwrk8 = (la + 1) >> 16; + isp_prt(isp, ISP_LOGDEBUG0, "WRITE RAM WORD EXTENDED %u words at load address 0x%x", nw, la); } else { mbs.param[0] = MBOX_LOAD_RISC_RAM; mbs.param[1] = la; @@ -796,10 +816,16 @@ isp_reset(ispsoftc_t *isp, int do_load_d mbs.param[6] = DMA_WD3(isp->isp_rquest_dma); mbs.param[7] = DMA_WD2(isp->isp_rquest_dma); mbs.param[8] = la >> 16; + isp_prt(isp, ISP_LOGDEBUG0, "LOAD RISC RAM %u words at load address 0x%x", nw, la); } mbs.logval = MBLOGALL; isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { + if (mbs.param[0] == MBOX_HOST_INTERFACE_ERROR) { + isp_prt(isp, ISP_LOGERR, "switching to word load"); + wordload = 1; + goto again; + } isp_prt(isp, ISP_LOGERR, "F/W Risc Ram Load Failed"); ISP_RESET0(isp); return; @@ -855,6 +881,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d mbs.param[4] = nw; mbs.param[6] = DMA_WD3(isp->isp_rquest_dma); mbs.param[7] = DMA_WD2(isp->isp_rquest_dma); + isp_prt(isp, ISP_LOGDEBUG1, "LOAD RISC RAM 2100 %u words at load address 0x%x\n", nw, la); } else { mbs.param[0] = MBOX_LOAD_RISC_RAM; mbs.param[1] = la; @@ -864,6 +891,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d mbs.param[6] = DMA_WD3(isp->isp_rquest_dma); mbs.param[7] = DMA_WD2(isp->isp_rquest_dma); mbs.param[8] = la >> 16; + isp_prt(isp, ISP_LOGDEBUG1, "LOAD RISC RAM %u words at load address 0x%x\n", nw, la); } mbs.logval = MBLOGALL; isp_mboxcmd(isp, &mbs); @@ -910,6 +938,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d mbs.param[1] = code_org; mbs.param[2] = ucd.np[0]; mbs.logval = MBLOGNONE; + isp_prt(isp, ISP_LOGDEBUG1, "WRITE RAM %u words at load address 0x%x\n", ucd.np[3], code_org); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "F/W download failed at word %d", isp->isp_mbxwrk1 - code_org); @@ -6594,23 +6623,39 @@ isp_mbox_continue(ispsoftc_t *isp) mbs.param[1] = isp->isp_mbxwrk1++; break; case MBOX_WRITE_RAM_WORD_EXTENDED: + if (IS_24XX(isp)) { + uint32_t *lptr = (uint32_t *)ptr; + mbs.param[2] = lptr[0]; + mbs.param[3] = lptr[0] >> 16; + lptr++; + ptr = (uint16_t *)lptr; + } else { + mbs.param[2] = *ptr++; + } offset = isp->isp_mbxwrk1; offset |= isp->isp_mbxwrk8 << 16; - - mbs.param[2] = *ptr++; mbs.param[1] = offset; mbs.param[8] = offset >> 16; - isp->isp_mbxwrk1 = ++offset; + offset++; + isp->isp_mbxwrk1 = offset; isp->isp_mbxwrk8 = offset >> 16; break; case MBOX_READ_RAM_WORD_EXTENDED: + if (IS_24XX(isp)) { + uint32_t *lptr = (uint32_t *)ptr; + uint32_t val = isp->isp_mboxtmp[2]; + val |= (isp->isp_mboxtmp[3]) << 16; + *lptr++ = val; + ptr = (uint16_t *)lptr; + } else { + *ptr++ = isp->isp_mboxtmp[2]; + } offset = isp->isp_mbxwrk1; offset |= isp->isp_mbxwrk8 << 16; - - *ptr++ = isp->isp_mboxtmp[2]; mbs.param[1] = offset; mbs.param[8] = offset >> 16; - isp->isp_mbxwrk1 = ++offset; + offset++; + isp->isp_mbxwrk1 = offset; isp->isp_mbxwrk8 = offset >> 16; break; } @@ -6835,7 +6880,7 @@ static const uint32_t mbpfc[] = { ISPOPMAP(0x00, 0x00), /* 0x0c: */ ISPOPMAP(0x10f, 0x01), /* 0x0d: MBOX_WRITE_RAM_WORD_EXTENDED */ ISPOPMAP(0x01, 0x05), /* 0x0e: MBOX_CHECK_FIRMWARE */ - ISPOPMAP(0x10f, 0x05), /* 0x0f: MBOX_READ_RAM_WORD_EXTENDED */ + ISPOPMAP(0x103, 0x0d), /* 0x0f: MBOX_READ_RAM_WORD_EXTENDED */ ISPOPMAP(0x1f, 0x11), /* 0x10: MBOX_INIT_REQ_QUEUE */ ISPOPMAP(0x2f, 0x21), /* 0x11: MBOX_INIT_RES_QUEUE */ ISPOPMAP(0x0f, 0x01), /* 0x12: MBOX_EXECUTE_IOCB */ @@ -6967,13 +7012,13 @@ static const char *fc_mbcmd_names[] = { "MAILBOX REG TEST", "VERIFY CHECKSUM", "ABOUT FIRMWARE", - "LOAD RAM", + "LOAD RAM (2100)", "DUMP RAM", - "WRITE RAM WORD EXTENDED", + "LOAD RISC RAM", NULL, - "READ RAM WORD EXTENDED", + "WRITE RAM WORD EXTENDED", "CHECK FIRMWARE", - NULL, + "READ RAM WORD EXTENDED", "INIT REQUEST QUEUE", "INIT RESULT QUEUE", "EXECUTE IOCB", Modified: stable/9/sys/dev/isp/isp_pci.c ============================================================================== --- stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 12:37:30 2012 (r240007) +++ stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 14:41:29 2012 (r240008) @@ -1461,6 +1461,7 @@ imc(void *arg, bus_dma_segment_t *segs, imushp->error = EINVAL; return; } + isp_prt(imushp->isp, ISP_LOGDEBUG0, "request/result area @ 0x%jx/0x%jx", (uintmax_t) segs->ds_addr, (uintmax_t) segs->ds_len); imushp->isp->isp_rquest = imushp->vbase; imushp->isp->isp_rquest_dma = segs->ds_addr; segs->ds_addr += ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(imushp->isp)); @@ -1490,6 +1491,7 @@ imc1(void *arg, bus_dma_segment_t *segs, imushp->error = EINVAL; return; } + isp_prt(imushp->isp, ISP_LOGDEBUG0, "scdma @ 0x%jx/0x%jx", (uintmax_t) segs->ds_addr, (uintmax_t) segs->ds_len); FCPARAM(imushp->isp, imushp->chan)->isp_scdma = segs->ds_addr; FCPARAM(imushp->isp, imushp->chan)->isp_scratch = imushp->vbase; } From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 14:44:10 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6C03C106566C; Sun, 2 Sep 2012 14:44:10 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 543848FC12; Sun, 2 Sep 2012 14:44:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82EiA6Y018967; Sun, 2 Sep 2012 14:44:10 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82EiAuC018963; Sun, 2 Sep 2012 14:44:10 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021444.q82EiAuC018963@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 14:44:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240009 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 14:44:10 -0000 Author: mjacob Date: Sun Sep 2 14:44:09 2012 New Revision: 240009 URL: http://svn.freebsd.org/changeset/base/240009 Log: MFC of 237210 Prepare for FC-Tape support. Modified: stable/9/sys/dev/isp/isp.c stable/9/sys/dev/isp/isp_freebsd.h stable/9/sys/dev/isp/isp_pci.c stable/9/sys/dev/isp/ispmbox.h stable/9/sys/dev/isp/ispreg.h stable/9/sys/dev/isp/ispvar.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp.c ============================================================================== --- stable/9/sys/dev/isp/isp.c Sun Sep 2 14:41:29 2012 (r240008) +++ stable/9/sys/dev/isp/isp.c Sun Sep 2 14:44:09 2012 (r240009) @@ -159,6 +159,8 @@ void isp_reset(ispsoftc_t *isp, int do_load_defaults) { mbreg_t mbs; + char *buf; + uint64_t fwt; uint32_t code_org, val; int loops, i, dodnld = 1; const char *btype = "????"; @@ -685,9 +687,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d * Do some sanity checking by running a NOP command. * If it succeeds, the ROM firmware is now running. */ - ISP_MEMZERO(&mbs, sizeof (mbs)); - mbs.param[0] = MBOX_NO_OP; - mbs.logval = MBLOGALL; + MBSINIT(&mbs, MBOX_NO_OP, MBLOGALL, 0); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "NOP command failed (%x)", mbs.param[0]); @@ -700,29 +700,32 @@ isp_reset(ispsoftc_t *isp, int do_load_d */ if (IS_SCSI(isp) || IS_24XX(isp)) { - ISP_MEMZERO(&mbs, sizeof (mbs)); - mbs.param[0] = MBOX_MAILBOX_REG_TEST; - mbs.param[1] = 0xdead; - mbs.param[2] = 0xbeef; - mbs.param[3] = 0xffff; - mbs.param[4] = 0x1111; - mbs.param[5] = 0xa5a5; - mbs.param[6] = 0x0000; - mbs.param[7] = 0x0000; - mbs.logval = MBLOGALL; + static const uint16_t patterns[MAX_MAILBOX] = { + 0x0000, 0xdead, 0xbeef, 0xffff, + 0xa5a5, 0x5a5a, 0x7f7f, 0x7ff7, + 0x3421, 0xabcd, 0xdcba, 0xfeef, + 0xbead, 0xdebe, 0x2222, 0x3333, + 0x5555, 0x6666, 0x7777, 0xaaaa, + 0xffff, 0xdddd, 0x9999, 0x1fbc, + 0x6666, 0x6677, 0x1122, 0x33ff, + 0x0000, 0x0001, 0x1000, 0x1010, + }; + MBSINIT(&mbs, MBOX_MAILBOX_REG_TEST, MBLOGALL, 0); + for (i = 1; i < ISP_NMBOX(isp); i++) { + mbs.param[i] = patterns[i]; + } isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { ISP_RESET0(isp); return; } - if (mbs.param[1] != 0xdead || mbs.param[2] != 0xbeef || - mbs.param[3] != 0xffff || mbs.param[4] != 0x1111 || - mbs.param[5] != 0xa5a5) { - ISP_RESET0(isp); - isp_prt(isp, ISP_LOGERR, "Register Test Failed (0x%x 0x%x 0x%x 0x%x 0x%x)", mbs.param[1], mbs.param[2], mbs.param[3], mbs.param[4], mbs.param[5]); - return; + for (i = 1; i < ISP_NMBOX(isp); i++) { + if (mbs.param[i] != patterns[i]) { + ISP_RESET0(isp); + isp_prt(isp, ISP_LOGERR, "Register Test Failed at Register %d: should have 0x%04x but got 0x%04x", i, patterns[i], mbs.param[i]); + return; + } } - } /* @@ -780,7 +783,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d } MEMORYBARRIER(isp, SYNC_REQUEST, 0, ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)), -1); again: - ISP_MEMZERO(&mbs, sizeof (mbs)); + MBSINIT(&mbs, 0, MBLOGALL, 0); if (la < 0x10000 && nw < 0x10000) { mbs.param[0] = MBOX_LOAD_RISC_RAM_2100; mbs.param[1] = la; @@ -818,7 +821,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d mbs.param[8] = la >> 16; isp_prt(isp, ISP_LOGDEBUG0, "LOAD RISC RAM %u words at load address 0x%x", nw, la); } - mbs.logval = MBLOGALL; isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { if (mbs.param[0] == MBOX_HOST_INTERFACE_ERROR) { @@ -872,7 +874,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d wl--; } MEMORYBARRIER(isp, SYNC_REQUEST, 0, ISP_QUEUE_SIZE(RQUEST_QUEUE_LEN(isp)), -1); - ISP_MEMZERO(&mbs, sizeof (mbs)); + MBSINIT(&mbs, 0, MBLOGALL, 0); if (la < 0x10000) { mbs.param[0] = MBOX_LOAD_RISC_RAM_2100; mbs.param[1] = la; @@ -893,7 +895,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d mbs.param[8] = la >> 16; isp_prt(isp, ISP_LOGDEBUG1, "LOAD RISC RAM %u words at load address 0x%x\n", nw, la); } - mbs.logval = MBLOGALL; isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "F/W Risc Ram Load Failed"); @@ -933,11 +934,9 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp->isp_mbxworkp = &ucd.np[1]; isp->isp_mbxwrk0 = ucd.np[3] - 1; isp->isp_mbxwrk1 = code_org + 1; - ISP_MEMZERO(&mbs, sizeof (mbs)); - mbs.param[0] = MBOX_WRITE_RAM_WORD; + MBSINIT(&mbs, MBOX_WRITE_RAM_WORD, MBLOGNONE, 0); mbs.param[1] = code_org; mbs.param[2] = ucd.np[0]; - mbs.logval = MBLOGNONE; isp_prt(isp, ISP_LOGDEBUG1, "WRITE RAM %u words at load address 0x%x\n", ucd.np[3], code_org); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { @@ -954,7 +953,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d * If we loaded firmware, verify its checksum */ if (isp->isp_loaded_fw) { - ISP_MEMZERO(&mbs, sizeof (mbs)); + MBSINIT(&mbs, MBOX_VERIFY_CHECKSUM, MBLOGNONE, 0); mbs.param[0] = MBOX_VERIFY_CHECKSUM; if (IS_24XX(isp)) { mbs.param[1] = code_org >> 16; @@ -978,7 +977,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d */ - MBSINIT(&mbs, MBOX_EXEC_FIRMWARE, MBLOGALL, 1000000); + MBSINIT(&mbs, MBOX_EXEC_FIRMWARE, MBLOGALL, 5000000); if (IS_24XX(isp)) { mbs.param[1] = code_org >> 16; mbs.param[2] = code_org; @@ -1071,9 +1070,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp->isp_fwrev[2] = mbs.param[3]; } - isp_prt(isp, ISP_LOGCONFIG, "Board Type %s, Chip Revision 0x%x, %s F/W Revision %d.%d.%d", - btype, isp->isp_revision, dodnld? "loaded" : "resident", isp->isp_fwrev[0], isp->isp_fwrev[1], isp->isp_fwrev[2]); - if (IS_FC(isp)) { /* * We do not believe firmware attributes for 2100 code less @@ -1090,9 +1086,12 @@ isp_reset(ispsoftc_t *isp, int do_load_d #endif } else { isp->isp_fwattr = mbs.param[6]; - isp_prt(isp, ISP_LOGDEBUG0, "Firmware Attributes = 0x%x", mbs.param[6]); } - } else { + if (IS_24XX(isp) && (isp->isp_fwattr & ISP2400_FW_ATTR_EXTNDED)) { + isp->isp_fwattr ^= ISP2400_FW_ATTR_EXTNDED; + isp->isp_fwattr |= (((uint64_t) mbs.param[15]) << 16) | (((uint64_t) mbs.param[16]) << 32) | (((uint64_t) mbs.param[17]) << 48); + } + } else if (IS_SCSI(isp)) { #ifndef ISP_TARGET_MODE isp->isp_fwattr = ISP_FW_ATTR_TMODE; #else @@ -1100,6 +1099,95 @@ isp_reset(ispsoftc_t *isp, int do_load_d #endif } + isp_prt(isp, ISP_LOGCONFIG, "Board Type %s, Chip Revision 0x%x, %s F/W Revision %d.%d.%d", + btype, isp->isp_revision, dodnld? "loaded" : "resident", isp->isp_fwrev[0], isp->isp_fwrev[1], isp->isp_fwrev[2]); + + fwt = isp->isp_fwattr; + if (IS_24XX(isp)) { + buf = FCPARAM(isp, 0)->isp_scratch; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN, "Attributes:"); + if (fwt & ISP2400_FW_ATTR_CLASS2) { + fwt ^=ISP2400_FW_ATTR_CLASS2; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s Class2", buf); + } + if (fwt & ISP2400_FW_ATTR_IP) { + fwt ^=ISP2400_FW_ATTR_IP; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s IP", buf); + } + if (fwt & ISP2400_FW_ATTR_MULTIID) { + fwt ^=ISP2400_FW_ATTR_MULTIID; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s MultiID", buf); + } + if (fwt & ISP2400_FW_ATTR_SB2) { + fwt ^=ISP2400_FW_ATTR_SB2; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s SB2", buf); + } + if (fwt & ISP2400_FW_ATTR_T10CRC) { + fwt ^=ISP2400_FW_ATTR_T10CRC; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s T10CRC", buf); + } + if (fwt & ISP2400_FW_ATTR_VI) { + fwt ^=ISP2400_FW_ATTR_VI; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s VI", buf); + } + if (fwt & ISP2400_FW_ATTR_VP0) { + fwt ^= ISP2400_FW_ATTR_VP0; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s VP0_Decoupling", buf); + } + if (fwt & ISP2400_FW_ATTR_EXPFW) { + fwt ^= ISP2400_FW_ATTR_EXPFW; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s (Experimental)", buf); + } + fwt &= ~ISP2400_FW_ATTR_EXTNDED; + if (fwt) { + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s (unknown 0x%jx)", buf, (uintmax_t)fwt); + } + isp_prt(isp, ISP_LOGCONFIG, "%s", buf); + } else if (IS_FC(isp)) { + buf = FCPARAM(isp, 0)->isp_scratch; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN, "Attributes:"); + if (fwt & ISP_FW_ATTR_TMODE) { + fwt ^=ISP_FW_ATTR_TMODE; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s TargetMode", buf); + } + if (fwt & ISP_FW_ATTR_SCCLUN) { + fwt ^=ISP_FW_ATTR_SCCLUN; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s SCC-Lun", buf); + } + if (fwt & ISP_FW_ATTR_FABRIC) { + fwt ^=ISP_FW_ATTR_FABRIC; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s Fabric", buf); + } + if (fwt & ISP_FW_ATTR_CLASS2) { + fwt ^=ISP_FW_ATTR_CLASS2; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s Class2", buf); + } + if (fwt & ISP_FW_ATTR_FCTAPE) { + fwt ^=ISP_FW_ATTR_FCTAPE; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s FC-Tape", buf); + } + if (fwt & ISP_FW_ATTR_IP) { + fwt ^=ISP_FW_ATTR_IP; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s IP", buf); + } + if (fwt & ISP_FW_ATTR_VI) { + fwt ^=ISP_FW_ATTR_VI; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s VI", buf); + } + if (fwt & ISP_FW_ATTR_VI_SOLARIS) { + fwt ^=ISP_FW_ATTR_VI_SOLARIS; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s VI_SOLARIS", buf); + } + if (fwt & ISP_FW_ATTR_2KLOGINS) { + fwt ^=ISP_FW_ATTR_2KLOGINS; + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s 2K-Login", buf); + } + if (fwt != 0) { + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s (unknown 0x%jx)", buf, (uintmax_t)fwt); + } + isp_prt(isp, ISP_LOGCONFIG, "%s", buf); + } + if (!IS_24XX(isp)) { MBSINIT(&mbs, MBOX_GET_FIRMWARE_STATUS, MBLOGALL, 0); isp_mboxcmd(isp, &mbs); @@ -1768,6 +1856,7 @@ isp_fibre_init_2400(ispsoftc_t *isp) isp_icb_2400_t local, *icbp = &local; mbreg_t mbs; int chan; + int ownloopid = 0; /* * Check to see whether all channels have *some* kind of role @@ -1831,7 +1920,6 @@ isp_fibre_init_2400(ispsoftc_t *isp) * Get current resource count */ MBSINIT(&mbs, MBOX_GET_RESOURCE_COUNT, MBLOGALL, 0); - mbs.obits = 0x4cf; isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { return; @@ -1840,27 +1928,18 @@ isp_fibre_init_2400(ispsoftc_t *isp) } + ownloopid = (isp->isp_confopts & ISP_CFG_OWNLOOPID) != 0; icbp->icb_hardaddr = fcp->isp_loopid; if (icbp->icb_hardaddr >= LOCAL_LOOP_LIM) { icbp->icb_hardaddr = 0; + ownloopid = 0; } - /* - * Force this on. - */ - icbp->icb_fwoptions1 |= ICB2400_OPT1_HARD_ADDRESS; + if (ownloopid) + icbp->icb_fwoptions1 |= ICB2400_OPT1_HARD_ADDRESS; icbp->icb_fwoptions2 = fcp->isp_xfwoptions; switch (isp->isp_confopts & ISP_CFG_PORT_PREF) { -#if 0 - case ISP_CFG_NPORT: - /* - * XXX: This causes the f/w to crash. - */ - icbp->icb_fwoptions2 &= ~ICB2400_OPT2_TOPO_MASK; - icbp->icb_fwoptions2 |= ICB2400_OPT2_PTP_2_LOOP; - break; -#endif case ISP_CFG_NPORT_ONLY: icbp->icb_fwoptions2 &= ~ICB2400_OPT2_TOPO_MASK; icbp->icb_fwoptions2 |= ICB2400_OPT2_PTP_ONLY; @@ -1870,14 +1949,12 @@ isp_fibre_init_2400(ispsoftc_t *isp) icbp->icb_fwoptions2 |= ICB2400_OPT2_LOOP_ONLY; break; default: + /* ISP_CFG_PTP_2_LOOP not available in 24XX/25XX */ icbp->icb_fwoptions2 &= ~ICB2400_OPT2_TOPO_MASK; icbp->icb_fwoptions2 |= ICB2400_OPT2_LOOP_2_PTP; break; } - /* force this on for now */ - icbp->icb_fwoptions2 |= ICB2400_OPT2_ZIO; - switch (icbp->icb_fwoptions2 & ICB2400_OPT2_TIMER_MASK) { case ICB2400_OPT2_ZIO: case ICB2400_OPT2_ZIO1: @@ -1891,12 +1968,10 @@ isp_fibre_init_2400(ispsoftc_t *isp) break; } - /* - * We don't support FCTAPE, so clear it. - */ - icbp->icb_fwoptions2 &= ~ICB2400_OPT2_FCTAPE; - icbp->icb_fwoptions3 = fcp->isp_zfwoptions; + if ((icbp->icb_fwoptions3 & ICB2400_OPT3_RSPSZ_MASK) == 0) { + icbp->icb_fwoptions3 |= ICB2400_OPT3_RSPSZ_24; + } icbp->icb_fwoptions3 &= ~ICB2400_OPT3_RATE_AUTO; if (isp->isp_confopts & ISP_CFG_ONEGB) { icbp->icb_fwoptions3 |= ICB2400_OPT3_RATE_ONEGB; @@ -1904,11 +1979,12 @@ isp_fibre_init_2400(ispsoftc_t *isp) icbp->icb_fwoptions3 |= ICB2400_OPT3_RATE_TWOGB; } else if (isp->isp_confopts & ISP_CFG_FOURGB) { icbp->icb_fwoptions3 |= ICB2400_OPT3_RATE_FOURGB; + } else if (IS_25XX(isp) && (isp->isp_confopts & ISP_CFG_EIGHTGB)) { + icbp->icb_fwoptions3 |= ICB2400_OPT3_RATE_EIGHTGB; } else { icbp->icb_fwoptions3 |= ICB2400_OPT3_RATE_AUTO; } - - if ((isp->isp_confopts & ISP_CFG_OWNLOOPID) == 0) { + if (ownloopid == 0) { icbp->icb_fwoptions3 |= ICB2400_OPT3_SOFTID; } icbp->icb_logintime = ICB_LOGIN_TOV; @@ -2569,11 +2645,7 @@ isp_fclink_test(ispsoftc_t *isp, int cha * Get our Loop ID and Port ID. */ MBSINIT(&mbs, MBOX_GET_LOOP_ID, MBLOGALL, 0); - if (ISP_CAP_MULTI_ID(isp)) { - mbs.param[9] = chan; - mbs.ibits = (1 << 9); - mbs.obits = (1 << 7); - } + mbs.param[9] = chan; isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { return (-1); @@ -2676,12 +2748,14 @@ isp_fclink_test(ispsoftc_t *isp, int cha lp->new_portid = lp->portid; lp->new_roles = lp->roles; if (IS_24XX(isp)) { - fcp->inorder = (mbs.param[7] & ISP24XX_INORDER) != 0; - if (ISP_FW_NEWER_THAN(isp, 4, 0, 27)) { - fcp->npiv_fabric = (mbs.param[7] & ISP24XX_NPIV_SAN) != 0; - if (fcp->npiv_fabric) { - isp_prt(isp, ISP_LOGCONFIG, "fabric supports NP-IV"); - } + if (check_for_fabric) { + /* + * The mbs is still hanging out from the MBOX_GET_LOOP_ID above. + */ + fcp->isp_fabric_params = mbs.param[7]; + isp_prt(isp, ISP_LOGCONFIG, "fabric params 0x%x", mbs.param[7]); + } else { + fcp->isp_fabric_params = 0; } if (chan) { fcp->isp_sns_hdl = NPH_SNS_HDLBASE + chan; @@ -4427,6 +4501,7 @@ isp_start(XS_T *xs) t7->req_lun[0] |= 0x40; } t7->req_lun[1] = XS_LUN(xs); + FCP_NEXT_CRN(isp, xs, t7->req_crn, XS_CHANNEL(xs), XS_TGT(xs), XS_LUN(xs)); tptr = &t7->req_time; cdbp = t7->req_cdb; cdblen = ISP_MIN(cdblen, sizeof (t7->req_cdb)); @@ -4907,7 +4982,7 @@ again: if (isp->isp_mboxbsy) { int obits = isp->isp_obits; isp->isp_mboxtmp[0] = mbox; - for (i = 1; i < MAX_MAILBOX(isp); i++) { + for (i = 1; i < ISP_NMBOX(isp); i++) { if ((obits & (1 << i)) == 0) { continue; } @@ -6667,105 +6742,106 @@ isp_mbox_continue(ispsoftc_t *isp) return (0); } -#define HIWRD(x) ((x) >> 16) -#define LOWRD(x) ((x) & 0xffff) -#define ISPOPMAP(a, b) (((a) << 16) | (b)) -static const uint32_t mbpscsi[] = { - ISPOPMAP(0x01, 0x01), /* 0x00: MBOX_NO_OP */ - ISPOPMAP(0x1f, 0x01), /* 0x01: MBOX_LOAD_RAM */ - ISPOPMAP(0x03, 0x01), /* 0x02: MBOX_EXEC_FIRMWARE */ - ISPOPMAP(0x1f, 0x01), /* 0x03: MBOX_DUMP_RAM */ - ISPOPMAP(0x07, 0x07), /* 0x04: MBOX_WRITE_RAM_WORD */ - ISPOPMAP(0x03, 0x07), /* 0x05: MBOX_READ_RAM_WORD */ - ISPOPMAP(0x3f, 0x3f), /* 0x06: MBOX_MAILBOX_REG_TEST */ - ISPOPMAP(0x07, 0x07), /* 0x07: MBOX_VERIFY_CHECKSUM */ - ISPOPMAP(0x01, 0x0f), /* 0x08: MBOX_ABOUT_FIRMWARE */ - ISPOPMAP(0x00, 0x00), /* 0x09: */ - ISPOPMAP(0x00, 0x00), /* 0x0a: */ - ISPOPMAP(0x00, 0x00), /* 0x0b: */ - ISPOPMAP(0x00, 0x00), /* 0x0c: */ - ISPOPMAP(0x00, 0x00), /* 0x0d: */ - ISPOPMAP(0x01, 0x05), /* 0x0e: MBOX_CHECK_FIRMWARE */ - ISPOPMAP(0x00, 0x00), /* 0x0f: */ - ISPOPMAP(0x1f, 0x1f), /* 0x10: MBOX_INIT_REQ_QUEUE */ - ISPOPMAP(0x3f, 0x3f), /* 0x11: MBOX_INIT_RES_QUEUE */ - ISPOPMAP(0x0f, 0x0f), /* 0x12: MBOX_EXECUTE_IOCB */ - ISPOPMAP(0x03, 0x03), /* 0x13: MBOX_WAKE_UP */ - ISPOPMAP(0x01, 0x3f), /* 0x14: MBOX_STOP_FIRMWARE */ - ISPOPMAP(0x0f, 0x0f), /* 0x15: MBOX_ABORT */ - ISPOPMAP(0x03, 0x03), /* 0x16: MBOX_ABORT_DEVICE */ - ISPOPMAP(0x07, 0x07), /* 0x17: MBOX_ABORT_TARGET */ - ISPOPMAP(0x07, 0x07), /* 0x18: MBOX_BUS_RESET */ - ISPOPMAP(0x03, 0x07), /* 0x19: MBOX_STOP_QUEUE */ - ISPOPMAP(0x03, 0x07), /* 0x1a: MBOX_START_QUEUE */ - ISPOPMAP(0x03, 0x07), /* 0x1b: MBOX_SINGLE_STEP_QUEUE */ - ISPOPMAP(0x03, 0x07), /* 0x1c: MBOX_ABORT_QUEUE */ - ISPOPMAP(0x03, 0x4f), /* 0x1d: MBOX_GET_DEV_QUEUE_STATUS */ - ISPOPMAP(0x00, 0x00), /* 0x1e: */ - ISPOPMAP(0x01, 0x07), /* 0x1f: MBOX_GET_FIRMWARE_STATUS */ - ISPOPMAP(0x01, 0x07), /* 0x20: MBOX_GET_INIT_SCSI_ID */ - ISPOPMAP(0x01, 0x07), /* 0x21: MBOX_GET_SELECT_TIMEOUT */ - ISPOPMAP(0x01, 0xc7), /* 0x22: MBOX_GET_RETRY_COUNT */ - ISPOPMAP(0x01, 0x07), /* 0x23: MBOX_GET_TAG_AGE_LIMIT */ - ISPOPMAP(0x01, 0x03), /* 0x24: MBOX_GET_CLOCK_RATE */ - ISPOPMAP(0x01, 0x07), /* 0x25: MBOX_GET_ACT_NEG_STATE */ - ISPOPMAP(0x01, 0x07), /* 0x26: MBOX_GET_ASYNC_DATA_SETUP_TIME */ - ISPOPMAP(0x01, 0x07), /* 0x27: MBOX_GET_PCI_PARAMS */ - ISPOPMAP(0x03, 0x4f), /* 0x28: MBOX_GET_TARGET_PARAMS */ - ISPOPMAP(0x03, 0x0f), /* 0x29: MBOX_GET_DEV_QUEUE_PARAMS */ - ISPOPMAP(0x01, 0x07), /* 0x2a: MBOX_GET_RESET_DELAY_PARAMS */ - ISPOPMAP(0x00, 0x00), /* 0x2b: */ - ISPOPMAP(0x00, 0x00), /* 0x2c: */ - ISPOPMAP(0x00, 0x00), /* 0x2d: */ - ISPOPMAP(0x00, 0x00), /* 0x2e: */ - ISPOPMAP(0x00, 0x00), /* 0x2f: */ - ISPOPMAP(0x03, 0x03), /* 0x30: MBOX_SET_INIT_SCSI_ID */ - ISPOPMAP(0x07, 0x07), /* 0x31: MBOX_SET_SELECT_TIMEOUT */ - ISPOPMAP(0xc7, 0xc7), /* 0x32: MBOX_SET_RETRY_COUNT */ - ISPOPMAP(0x07, 0x07), /* 0x33: MBOX_SET_TAG_AGE_LIMIT */ - ISPOPMAP(0x03, 0x03), /* 0x34: MBOX_SET_CLOCK_RATE */ - ISPOPMAP(0x07, 0x07), /* 0x35: MBOX_SET_ACT_NEG_STATE */ - ISPOPMAP(0x07, 0x07), /* 0x36: MBOX_SET_ASYNC_DATA_SETUP_TIME */ - ISPOPMAP(0x07, 0x07), /* 0x37: MBOX_SET_PCI_CONTROL_PARAMS */ - ISPOPMAP(0x4f, 0x4f), /* 0x38: MBOX_SET_TARGET_PARAMS */ - ISPOPMAP(0x0f, 0x0f), /* 0x39: MBOX_SET_DEV_QUEUE_PARAMS */ - ISPOPMAP(0x07, 0x07), /* 0x3a: MBOX_SET_RESET_DELAY_PARAMS */ - ISPOPMAP(0x00, 0x00), /* 0x3b: */ - ISPOPMAP(0x00, 0x00), /* 0x3c: */ - ISPOPMAP(0x00, 0x00), /* 0x3d: */ - ISPOPMAP(0x00, 0x00), /* 0x3e: */ - ISPOPMAP(0x00, 0x00), /* 0x3f: */ - ISPOPMAP(0x01, 0x03), /* 0x40: MBOX_RETURN_BIOS_BLOCK_ADDR */ - ISPOPMAP(0x3f, 0x01), /* 0x41: MBOX_WRITE_FOUR_RAM_WORDS */ - ISPOPMAP(0x03, 0x07), /* 0x42: MBOX_EXEC_BIOS_IOCB */ - ISPOPMAP(0x00, 0x00), /* 0x43: */ - ISPOPMAP(0x00, 0x00), /* 0x44: */ - ISPOPMAP(0x03, 0x03), /* 0x45: SET SYSTEM PARAMETER */ - ISPOPMAP(0x01, 0x03), /* 0x46: GET SYSTEM PARAMETER */ - ISPOPMAP(0x00, 0x00), /* 0x47: */ - ISPOPMAP(0x01, 0xcf), /* 0x48: GET SCAM CONFIGURATION */ - ISPOPMAP(0xcf, 0xcf), /* 0x49: SET SCAM CONFIGURATION */ - ISPOPMAP(0x03, 0x03), /* 0x4a: MBOX_SET_FIRMWARE_FEATURES */ - ISPOPMAP(0x01, 0x03), /* 0x4b: MBOX_GET_FIRMWARE_FEATURES */ - ISPOPMAP(0x00, 0x00), /* 0x4c: */ - ISPOPMAP(0x00, 0x00), /* 0x4d: */ - ISPOPMAP(0x00, 0x00), /* 0x4e: */ - ISPOPMAP(0x00, 0x00), /* 0x4f: */ - ISPOPMAP(0xdf, 0xdf), /* 0x50: LOAD RAM A64 */ - ISPOPMAP(0xdf, 0xdf), /* 0x51: DUMP RAM A64 */ - ISPOPMAP(0xdf, 0xff), /* 0x52: INITIALIZE REQUEST QUEUE A64 */ - ISPOPMAP(0xef, 0xff), /* 0x53: INITIALIZE RESPONSE QUEUE A64 */ - ISPOPMAP(0xcf, 0x01), /* 0x54: EXECUCUTE COMMAND IOCB A64 */ - ISPOPMAP(0x07, 0x01), /* 0x55: ENABLE TARGET MODE */ - ISPOPMAP(0x03, 0x0f), /* 0x56: GET TARGET STATUS */ - ISPOPMAP(0x00, 0x00), /* 0x57: */ - ISPOPMAP(0x00, 0x00), /* 0x58: */ - ISPOPMAP(0x00, 0x00), /* 0x59: */ - ISPOPMAP(0x03, 0x03), /* 0x5a: SET DATA OVERRUN RECOVERY MODE */ - ISPOPMAP(0x01, 0x03), /* 0x5b: GET DATA OVERRUN RECOVERY MODE */ - ISPOPMAP(0x0f, 0x0f), /* 0x5c: SET HOST DATA */ - ISPOPMAP(0x01, 0x01) /* 0x5d: GET NOST DATA */ +#define ISP_SCSI_IBITS(op) (mbpscsi[((op)<<1)]) +#define ISP_SCSI_OBITS(op) (mbpscsi[((op)<<1) + 1]) +#define ISP_SCSI_OPMAP(in, out) in, out +static const uint8_t mbpscsi[] = { + ISP_SCSI_OPMAP(0x01, 0x01), /* 0x00: MBOX_NO_OP */ + ISP_SCSI_OPMAP(0x1f, 0x01), /* 0x01: MBOX_LOAD_RAM */ + ISP_SCSI_OPMAP(0x03, 0x01), /* 0x02: MBOX_EXEC_FIRMWARE */ + ISP_SCSI_OPMAP(0x1f, 0x01), /* 0x03: MBOX_DUMP_RAM */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x04: MBOX_WRITE_RAM_WORD */ + ISP_SCSI_OPMAP(0x03, 0x07), /* 0x05: MBOX_READ_RAM_WORD */ + ISP_SCSI_OPMAP(0x3f, 0x3f), /* 0x06: MBOX_MAILBOX_REG_TEST */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x07: MBOX_VERIFY_CHECKSUM */ + ISP_SCSI_OPMAP(0x01, 0x0f), /* 0x08: MBOX_ABOUT_FIRMWARE */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x09: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x0a: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x0b: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x0c: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x0d: */ + ISP_SCSI_OPMAP(0x01, 0x05), /* 0x0e: MBOX_CHECK_FIRMWARE */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x0f: */ + ISP_SCSI_OPMAP(0x1f, 0x1f), /* 0x10: MBOX_INIT_REQ_QUEUE */ + ISP_SCSI_OPMAP(0x3f, 0x3f), /* 0x11: MBOX_INIT_RES_QUEUE */ + ISP_SCSI_OPMAP(0x0f, 0x0f), /* 0x12: MBOX_EXECUTE_IOCB */ + ISP_SCSI_OPMAP(0x03, 0x03), /* 0x13: MBOX_WAKE_UP */ + ISP_SCSI_OPMAP(0x01, 0x3f), /* 0x14: MBOX_STOP_FIRMWARE */ + ISP_SCSI_OPMAP(0x0f, 0x0f), /* 0x15: MBOX_ABORT */ + ISP_SCSI_OPMAP(0x03, 0x03), /* 0x16: MBOX_ABORT_DEVICE */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x17: MBOX_ABORT_TARGET */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x18: MBOX_BUS_RESET */ + ISP_SCSI_OPMAP(0x03, 0x07), /* 0x19: MBOX_STOP_QUEUE */ + ISP_SCSI_OPMAP(0x03, 0x07), /* 0x1a: MBOX_START_QUEUE */ + ISP_SCSI_OPMAP(0x03, 0x07), /* 0x1b: MBOX_SINGLE_STEP_QUEUE */ + ISP_SCSI_OPMAP(0x03, 0x07), /* 0x1c: MBOX_ABORT_QUEUE */ + ISP_SCSI_OPMAP(0x03, 0x4f), /* 0x1d: MBOX_GET_DEV_QUEUE_STATUS */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x1e: */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x1f: MBOX_GET_FIRMWARE_STATUS */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x20: MBOX_GET_INIT_SCSI_ID */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x21: MBOX_GET_SELECT_TIMEOUT */ + ISP_SCSI_OPMAP(0x01, 0xc7), /* 0x22: MBOX_GET_RETRY_COUNT */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x23: MBOX_GET_TAG_AGE_LIMIT */ + ISP_SCSI_OPMAP(0x01, 0x03), /* 0x24: MBOX_GET_CLOCK_RATE */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x25: MBOX_GET_ACT_NEG_STATE */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x26: MBOX_GET_ASYNC_DATA_SETUP_TIME */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x27: MBOX_GET_PCI_PARAMS */ + ISP_SCSI_OPMAP(0x03, 0x4f), /* 0x28: MBOX_GET_TARGET_PARAMS */ + ISP_SCSI_OPMAP(0x03, 0x0f), /* 0x29: MBOX_GET_DEV_QUEUE_PARAMS */ + ISP_SCSI_OPMAP(0x01, 0x07), /* 0x2a: MBOX_GET_RESET_DELAY_PARAMS */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x2b: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x2c: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x2d: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x2e: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x2f: */ + ISP_SCSI_OPMAP(0x03, 0x03), /* 0x30: MBOX_SET_INIT_SCSI_ID */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x31: MBOX_SET_SELECT_TIMEOUT */ + ISP_SCSI_OPMAP(0xc7, 0xc7), /* 0x32: MBOX_SET_RETRY_COUNT */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x33: MBOX_SET_TAG_AGE_LIMIT */ + ISP_SCSI_OPMAP(0x03, 0x03), /* 0x34: MBOX_SET_CLOCK_RATE */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x35: MBOX_SET_ACT_NEG_STATE */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x36: MBOX_SET_ASYNC_DATA_SETUP_TIME */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x37: MBOX_SET_PCI_CONTROL_PARAMS */ + ISP_SCSI_OPMAP(0x4f, 0x4f), /* 0x38: MBOX_SET_TARGET_PARAMS */ + ISP_SCSI_OPMAP(0x0f, 0x0f), /* 0x39: MBOX_SET_DEV_QUEUE_PARAMS */ + ISP_SCSI_OPMAP(0x07, 0x07), /* 0x3a: MBOX_SET_RESET_DELAY_PARAMS */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x3b: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x3c: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x3d: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x3e: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x3f: */ + ISP_SCSI_OPMAP(0x01, 0x03), /* 0x40: MBOX_RETURN_BIOS_BLOCK_ADDR */ + ISP_SCSI_OPMAP(0x3f, 0x01), /* 0x41: MBOX_WRITE_FOUR_RAM_WORDS */ + ISP_SCSI_OPMAP(0x03, 0x07), /* 0x42: MBOX_EXEC_BIOS_IOCB */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x43: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x44: */ + ISP_SCSI_OPMAP(0x03, 0x03), /* 0x45: SET SYSTEM PARAMETER */ + ISP_SCSI_OPMAP(0x01, 0x03), /* 0x46: GET SYSTEM PARAMETER */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x47: */ + ISP_SCSI_OPMAP(0x01, 0xcf), /* 0x48: GET SCAM CONFIGURATION */ + ISP_SCSI_OPMAP(0xcf, 0xcf), /* 0x49: SET SCAM CONFIGURATION */ + ISP_SCSI_OPMAP(0x03, 0x03), /* 0x4a: MBOX_SET_FIRMWARE_FEATURES */ + ISP_SCSI_OPMAP(0x01, 0x03), /* 0x4b: MBOX_GET_FIRMWARE_FEATURES */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x4c: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x4d: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x4e: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x4f: */ + ISP_SCSI_OPMAP(0xdf, 0xdf), /* 0x50: LOAD RAM A64 */ + ISP_SCSI_OPMAP(0xdf, 0xdf), /* 0x51: DUMP RAM A64 */ + ISP_SCSI_OPMAP(0xdf, 0xff), /* 0x52: INITIALIZE REQUEST QUEUE A64 */ + ISP_SCSI_OPMAP(0xef, 0xff), /* 0x53: INITIALIZE RESPONSE QUEUE A64 */ + ISP_SCSI_OPMAP(0xcf, 0x01), /* 0x54: EXECUCUTE COMMAND IOCB A64 */ + ISP_SCSI_OPMAP(0x07, 0x01), /* 0x55: ENABLE TARGET MODE */ + ISP_SCSI_OPMAP(0x03, 0x0f), /* 0x56: GET TARGET STATUS */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x57: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x58: */ + ISP_SCSI_OPMAP(0x00, 0x00), /* 0x59: */ + ISP_SCSI_OPMAP(0x03, 0x03), /* 0x5a: SET DATA OVERRUN RECOVERY MODE */ + ISP_SCSI_OPMAP(0x01, 0x03), /* 0x5b: GET DATA OVERRUN RECOVERY MODE */ + ISP_SCSI_OPMAP(0x0f, 0x0f), /* 0x5c: SET HOST DATA */ + ISP_SCSI_OPMAP(0x01, 0x01) /* 0x5d: GET NOST DATA */ }; +#define MAX_SCSI_OPCODE 0x5d static const char *scsi_mbcmd_names[] = { "NO-OP", @@ -6864,135 +6940,142 @@ static const char *scsi_mbcmd_names[] = "GET NOST DATA", }; +#define ISP_FC_IBITS(op) ((mbpfc[((op)<<3) + 0] << 24) | (mbpfc[((op)<<3) + 1] << 16) | (mbpfc[((op)<<3) + 2] << 8) | (mbpfc[((op)<<3) + 3])) +#define ISP_FC_OBITS(op) ((mbpfc[((op)<<3) + 4] << 24) | (mbpfc[((op)<<3) + 5] << 16) | (mbpfc[((op)<<3) + 6] << 8) | (mbpfc[((op)<<3) + 7])) + +#define ISP_FC_OPMAP(in0, out0) 0, 0, 0, in0, 0, 0, 0, out0 +#define ISP_FC_OPMAP_HALF(in1, in0, out1, out0) 0, 0, in1, in0, 0, 0, out1, out0 +#define ISP_FC_OPMAP_FULL(in3, in2, in1, in0, out3, out2, out1, out0) in3, in2, in1, in0, out3, out2, out1, out0 static const uint32_t mbpfc[] = { - ISPOPMAP(0x01, 0x01), /* 0x00: MBOX_NO_OP */ - ISPOPMAP(0x1f, 0x01), /* 0x01: MBOX_LOAD_RAM */ - ISPOPMAP(0x0f, 0x01), /* 0x02: MBOX_EXEC_FIRMWARE */ - ISPOPMAP(0xdf, 0x01), /* 0x03: MBOX_DUMP_RAM */ - ISPOPMAP(0x07, 0x07), /* 0x04: MBOX_WRITE_RAM_WORD */ - ISPOPMAP(0x03, 0x07), /* 0x05: MBOX_READ_RAM_WORD */ - ISPOPMAP(0xff, 0xff), /* 0x06: MBOX_MAILBOX_REG_TEST */ - ISPOPMAP(0x07, 0x07), /* 0x07: MBOX_VERIFY_CHECKSUM */ - ISPOPMAP(0x01, 0x4f), /* 0x08: MBOX_ABOUT_FIRMWARE */ - ISPOPMAP(0xdf, 0x01), /* 0x09: MBOX_LOAD_RISC_RAM_2100 */ - ISPOPMAP(0xdf, 0x01), /* 0x0a: DUMP RAM */ - ISPOPMAP(0x1ff, 0x01), /* 0x0b: MBOX_LOAD_RISC_RAM */ - ISPOPMAP(0x00, 0x00), /* 0x0c: */ - ISPOPMAP(0x10f, 0x01), /* 0x0d: MBOX_WRITE_RAM_WORD_EXTENDED */ - ISPOPMAP(0x01, 0x05), /* 0x0e: MBOX_CHECK_FIRMWARE */ - ISPOPMAP(0x103, 0x0d), /* 0x0f: MBOX_READ_RAM_WORD_EXTENDED */ - ISPOPMAP(0x1f, 0x11), /* 0x10: MBOX_INIT_REQ_QUEUE */ - ISPOPMAP(0x2f, 0x21), /* 0x11: MBOX_INIT_RES_QUEUE */ - ISPOPMAP(0x0f, 0x01), /* 0x12: MBOX_EXECUTE_IOCB */ - ISPOPMAP(0x03, 0x03), /* 0x13: MBOX_WAKE_UP */ - ISPOPMAP(0x01, 0xff), /* 0x14: MBOX_STOP_FIRMWARE */ - ISPOPMAP(0x4f, 0x01), /* 0x15: MBOX_ABORT */ - ISPOPMAP(0x07, 0x01), /* 0x16: MBOX_ABORT_DEVICE */ - ISPOPMAP(0x07, 0x01), /* 0x17: MBOX_ABORT_TARGET */ - ISPOPMAP(0x03, 0x03), /* 0x18: MBOX_BUS_RESET */ - ISPOPMAP(0x07, 0x05), /* 0x19: MBOX_STOP_QUEUE */ - ISPOPMAP(0x07, 0x05), /* 0x1a: MBOX_START_QUEUE */ - ISPOPMAP(0x07, 0x05), /* 0x1b: MBOX_SINGLE_STEP_QUEUE */ - ISPOPMAP(0x07, 0x05), /* 0x1c: MBOX_ABORT_QUEUE */ - ISPOPMAP(0x07, 0x03), /* 0x1d: MBOX_GET_DEV_QUEUE_STATUS */ - ISPOPMAP(0x00, 0x00), /* 0x1e: */ - ISPOPMAP(0x01, 0x07), /* 0x1f: MBOX_GET_FIRMWARE_STATUS */ - ISPOPMAP(0x01, 0x4f), /* 0x20: MBOX_GET_LOOP_ID */ - ISPOPMAP(0x00, 0x00), /* 0x21: */ - ISPOPMAP(0x01, 0x07), /* 0x22: MBOX_GET_RETRY_COUNT */ - ISPOPMAP(0x00, 0x00), /* 0x23: */ - ISPOPMAP(0x00, 0x00), /* 0x24: */ - ISPOPMAP(0x00, 0x00), /* 0x25: */ - ISPOPMAP(0x00, 0x00), /* 0x26: */ - ISPOPMAP(0x00, 0x00), /* 0x27: */ - ISPOPMAP(0x01, 0x03), /* 0x28: MBOX_GET_FIRMWARE_OPTIONS */ - ISPOPMAP(0x03, 0x07), /* 0x29: MBOX_GET_PORT_QUEUE_PARAMS */ - ISPOPMAP(0x00, 0x00), /* 0x2a: */ - ISPOPMAP(0x00, 0x00), /* 0x2b: */ - ISPOPMAP(0x00, 0x00), /* 0x2c: */ - ISPOPMAP(0x00, 0x00), /* 0x2d: */ - ISPOPMAP(0x00, 0x00), /* 0x2e: */ - ISPOPMAP(0x00, 0x00), /* 0x2f: */ - ISPOPMAP(0x00, 0x00), /* 0x30: */ - ISPOPMAP(0x00, 0x00), /* 0x31: */ - ISPOPMAP(0x07, 0x07), /* 0x32: MBOX_SET_RETRY_COUNT */ - ISPOPMAP(0x00, 0x00), /* 0x33: */ - ISPOPMAP(0x00, 0x00), /* 0x34: */ - ISPOPMAP(0x00, 0x00), /* 0x35: */ - ISPOPMAP(0x00, 0x00), /* 0x36: */ - ISPOPMAP(0x00, 0x00), /* 0x37: */ - ISPOPMAP(0x0f, 0x01), /* 0x38: MBOX_SET_FIRMWARE_OPTIONS */ - ISPOPMAP(0x0f, 0x07), /* 0x39: MBOX_SET_PORT_QUEUE_PARAMS */ - ISPOPMAP(0x00, 0x00), /* 0x3a: */ - ISPOPMAP(0x00, 0x00), /* 0x3b: */ - ISPOPMAP(0x00, 0x00), /* 0x3c: */ - ISPOPMAP(0x00, 0x00), /* 0x3d: */ - ISPOPMAP(0x00, 0x00), /* 0x3e: */ - ISPOPMAP(0x00, 0x00), /* 0x3f: */ - ISPOPMAP(0x03, 0x01), /* 0x40: MBOX_LOOP_PORT_BYPASS */ - ISPOPMAP(0x03, 0x01), /* 0x41: MBOX_LOOP_PORT_ENABLE */ - ISPOPMAP(0x03, 0x07), /* 0x42: MBOX_GET_RESOURCE_COUNT */ - ISPOPMAP(0x01, 0x01), /* 0x43: MBOX_REQUEST_OFFLINE_MODE */ - ISPOPMAP(0x00, 0x00), /* 0x44: */ - ISPOPMAP(0x00, 0x00), /* 0x45: */ - ISPOPMAP(0x00, 0x00), /* 0x46: */ - ISPOPMAP(0xcf, 0x03), /* 0x47: GET PORT_DATABASE ENHANCED */ - ISPOPMAP(0xcd, 0x01), /* 0x48: MBOX_INIT_FIRMWARE_MULTI_ID */ - ISPOPMAP(0xcd, 0x01), /* 0x49: MBOX_GET_VP_DATABASE */ - ISPOPMAP(0x2cd, 0x01), /* 0x4a: MBOX_GET_VP_DATABASE_ENTRY */ - ISPOPMAP(0x00, 0x00), /* 0x4b: */ - ISPOPMAP(0x00, 0x00), /* 0x4c: */ - ISPOPMAP(0x00, 0x00), /* 0x4d: */ - ISPOPMAP(0x00, 0x00), /* 0x4e: */ - ISPOPMAP(0x00, 0x00), /* 0x4f: */ - ISPOPMAP(0x00, 0x00), /* 0x50: */ - ISPOPMAP(0x00, 0x00), /* 0x51: */ - ISPOPMAP(0x00, 0x00), /* 0x52: */ - ISPOPMAP(0x00, 0x00), /* 0x53: */ - ISPOPMAP(0xcf, 0x01), /* 0x54: EXECUTE IOCB A64 */ - ISPOPMAP(0x00, 0x00), /* 0x55: */ - ISPOPMAP(0x00, 0x00), /* 0x56: */ - ISPOPMAP(0x00, 0x00), /* 0x57: */ - ISPOPMAP(0x00, 0x00), /* 0x58: */ - ISPOPMAP(0x00, 0x00), /* 0x59: */ - ISPOPMAP(0x00, 0x00), /* 0x5a: */ - ISPOPMAP(0x03, 0x01), /* 0x5b: MBOX_DRIVER_HEARTBEAT */ - ISPOPMAP(0xcf, 0x01), /* 0x5c: MBOX_FW_HEARTBEAT */ - ISPOPMAP(0x07, 0x03), /* 0x5d: MBOX_GET_SET_DATA_RATE */ - ISPOPMAP(0x00, 0x00), /* 0x5e: */ - ISPOPMAP(0x00, 0x00), /* 0x5f: */ - ISPOPMAP(0xcd, 0x01), /* 0x60: MBOX_INIT_FIRMWARE */ - ISPOPMAP(0x00, 0x00), /* 0x61: */ - ISPOPMAP(0x01, 0x01), /* 0x62: MBOX_INIT_LIP */ - ISPOPMAP(0xcd, 0x03), /* 0x63: MBOX_GET_FC_AL_POSITION_MAP */ - ISPOPMAP(0xcf, 0x01), /* 0x64: MBOX_GET_PORT_DB */ - ISPOPMAP(0x07, 0x01), /* 0x65: MBOX_CLEAR_ACA */ - ISPOPMAP(0x07, 0x01), /* 0x66: MBOX_TARGET_RESET */ - ISPOPMAP(0x07, 0x01), /* 0x67: MBOX_CLEAR_TASK_SET */ - ISPOPMAP(0x07, 0x01), /* 0x68: MBOX_ABORT_TASK_SET */ - ISPOPMAP(0x01, 0x07), /* 0x69: MBOX_GET_FW_STATE */ - ISPOPMAP(0x03, 0xcf), /* 0x6a: MBOX_GET_PORT_NAME */ - ISPOPMAP(0xcf, 0x01), /* 0x6b: MBOX_GET_LINK_STATUS */ - ISPOPMAP(0x0f, 0x01), /* 0x6c: MBOX_INIT_LIP_RESET */ - ISPOPMAP(0x00, 0x00), /* 0x6d: */ - ISPOPMAP(0xcf, 0x03), /* 0x6e: MBOX_SEND_SNS */ - ISPOPMAP(0x0f, 0x07), /* 0x6f: MBOX_FABRIC_LOGIN */ - ISPOPMAP(0x03, 0x01), /* 0x70: MBOX_SEND_CHANGE_REQUEST */ - ISPOPMAP(0x03, 0x03), /* 0x71: MBOX_FABRIC_LOGOUT */ - ISPOPMAP(0x0f, 0x0f), /* 0x72: MBOX_INIT_LIP_LOGIN */ - ISPOPMAP(0x00, 0x00), /* 0x73: */ - ISPOPMAP(0x07, 0x01), /* 0x74: LOGIN LOOP PORT */ - ISPOPMAP(0xcf, 0x03), /* 0x75: GET PORT/NODE NAME LIST */ - ISPOPMAP(0x4f, 0x01), /* 0x76: SET VENDOR ID */ - ISPOPMAP(0xcd, 0x01), /* 0x77: INITIALIZE IP MAILBOX */ - ISPOPMAP(0x00, 0x00), /* 0x78: */ - ISPOPMAP(0x00, 0x00), /* 0x79: */ - ISPOPMAP(0x00, 0x00), /* 0x7a: */ - ISPOPMAP(0x00, 0x00), /* 0x7b: */ - ISPOPMAP(0x4f, 0x03), /* 0x7c: Get ID List */ - ISPOPMAP(0xcf, 0x01), /* 0x7d: SEND LFA */ - ISPOPMAP(0x0f, 0x01) /* 0x7e: LUN RESET */ + ISP_FC_OPMAP(0x01, 0x01), /* 0x00: MBOX_NO_OP */ + ISP_FC_OPMAP(0x1f, 0x01), /* 0x01: MBOX_LOAD_RAM */ + ISP_FC_OPMAP(0x0f, 0x01), /* 0x02: MBOX_EXEC_FIRMWARE */ + ISP_FC_OPMAP(0xdf, 0x01), /* 0x03: MBOX_DUMP_RAM */ + ISP_FC_OPMAP(0x07, 0x07), /* 0x04: MBOX_WRITE_RAM_WORD */ + ISP_FC_OPMAP(0x03, 0x07), /* 0x05: MBOX_READ_RAM_WORD */ + ISP_FC_OPMAP_FULL(0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff), /* 0x06: MBOX_MAILBOX_REG_TEST */ + ISP_FC_OPMAP(0x07, 0x07), /* 0x07: MBOX_VERIFY_CHECKSUM */ + ISP_FC_OPMAP_FULL(0x0, 0x0, 0x0, 0x01, 0x0, 0x3, 0x80, 0x4f), /* 0x08: MBOX_ABOUT_FIRMWARE */ + ISP_FC_OPMAP(0xdf, 0x01), /* 0x09: MBOX_LOAD_RISC_RAM_2100 */ + ISP_FC_OPMAP(0xdf, 0x01), /* 0x0a: DUMP RAM */ + ISP_FC_OPMAP_HALF(0x1, 0xff, 0x0, 0x01), /* 0x0b: MBOX_LOAD_RISC_RAM */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x0c: */ + ISP_FC_OPMAP_HALF(0x1, 0x0f, 0x0, 0x01), /* 0x0d: MBOX_WRITE_RAM_WORD_EXTENDED */ + ISP_FC_OPMAP(0x01, 0x05), /* 0x0e: MBOX_CHECK_FIRMWARE */ + ISP_FC_OPMAP_HALF(0x1, 0x03, 0x0, 0x0d), /* 0x0f: MBOX_READ_RAM_WORD_EXTENDED */ + ISP_FC_OPMAP(0x1f, 0x11), /* 0x10: MBOX_INIT_REQ_QUEUE */ + ISP_FC_OPMAP(0x2f, 0x21), /* 0x11: MBOX_INIT_RES_QUEUE */ + ISP_FC_OPMAP(0x0f, 0x01), /* 0x12: MBOX_EXECUTE_IOCB */ + ISP_FC_OPMAP(0x03, 0x03), /* 0x13: MBOX_WAKE_UP */ + ISP_FC_OPMAP(0x01, 0xff), /* 0x14: MBOX_STOP_FIRMWARE */ + ISP_FC_OPMAP(0x4f, 0x01), /* 0x15: MBOX_ABORT */ + ISP_FC_OPMAP(0x07, 0x01), /* 0x16: MBOX_ABORT_DEVICE */ + ISP_FC_OPMAP(0x07, 0x01), /* 0x17: MBOX_ABORT_TARGET */ + ISP_FC_OPMAP(0x03, 0x03), /* 0x18: MBOX_BUS_RESET */ + ISP_FC_OPMAP(0x07, 0x05), /* 0x19: MBOX_STOP_QUEUE */ + ISP_FC_OPMAP(0x07, 0x05), /* 0x1a: MBOX_START_QUEUE */ + ISP_FC_OPMAP(0x07, 0x05), /* 0x1b: MBOX_SINGLE_STEP_QUEUE */ + ISP_FC_OPMAP(0x07, 0x05), /* 0x1c: MBOX_ABORT_QUEUE */ + ISP_FC_OPMAP(0x07, 0x03), /* 0x1d: MBOX_GET_DEV_QUEUE_STATUS */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x1e: */ + ISP_FC_OPMAP(0x01, 0x07), /* 0x1f: MBOX_GET_FIRMWARE_STATUS */ + ISP_FC_OPMAP_HALF(0x2, 0x01, 0x0, 0xcf), /* 0x20: MBOX_GET_LOOP_ID */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x21: */ + ISP_FC_OPMAP(0x01, 0x07), /* 0x22: MBOX_GET_RETRY_COUNT */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x23: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x24: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x25: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x26: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x27: */ + ISP_FC_OPMAP(0x01, 0x03), /* 0x28: MBOX_GET_FIRMWARE_OPTIONS */ + ISP_FC_OPMAP(0x03, 0x07), /* 0x29: MBOX_GET_PORT_QUEUE_PARAMS */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x2a: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x2b: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x2c: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x2d: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x2e: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x2f: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x30: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x31: */ + ISP_FC_OPMAP(0x07, 0x07), /* 0x32: MBOX_SET_RETRY_COUNT */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x33: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x34: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x35: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x36: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x37: */ + ISP_FC_OPMAP(0x0f, 0x01), /* 0x38: MBOX_SET_FIRMWARE_OPTIONS */ + ISP_FC_OPMAP(0x0f, 0x07), /* 0x39: MBOX_SET_PORT_QUEUE_PARAMS */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x3a: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x3b: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x3c: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x3d: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x3e: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x3f: */ + ISP_FC_OPMAP(0x03, 0x01), /* 0x40: MBOX_LOOP_PORT_BYPASS */ + ISP_FC_OPMAP(0x03, 0x01), /* 0x41: MBOX_LOOP_PORT_ENABLE */ + ISP_FC_OPMAP_HALF(0x3, 0xcf, 0x0, 0x07), /* 0x42: MBOX_GET_RESOURCE_COUNT */ + ISP_FC_OPMAP(0x01, 0x01), /* 0x43: MBOX_REQUEST_OFFLINE_MODE */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x44: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x45: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x46: */ + ISP_FC_OPMAP(0xcf, 0x03), /* 0x47: GET PORT_DATABASE ENHANCED */ + ISP_FC_OPMAP(0xcd, 0x01), /* 0x48: MBOX_INIT_FIRMWARE_MULTI_ID */ + ISP_FC_OPMAP(0xcd, 0x01), /* 0x49: MBOX_GET_VP_DATABASE */ + ISP_FC_OPMAP_HALF(0x2, 0xcd, 0x0, 0x01), /* 0x4a: MBOX_GET_VP_DATABASE_ENTRY */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x4b: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x4c: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x4d: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x4e: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x4f: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x50: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x51: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x52: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x53: */ + ISP_FC_OPMAP(0xcf, 0x01), /* 0x54: EXECUTE IOCB A64 */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x55: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x56: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x57: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x58: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x59: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x5a: */ + ISP_FC_OPMAP(0x03, 0x01), /* 0x5b: MBOX_DRIVER_HEARTBEAT */ + ISP_FC_OPMAP(0xcf, 0x01), /* 0x5c: MBOX_FW_HEARTBEAT */ + ISP_FC_OPMAP(0x07, 0x03), /* 0x5d: MBOX_GET_SET_DATA_RATE */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x5e: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x5f: */ + ISP_FC_OPMAP(0xcd, 0x01), /* 0x60: MBOX_INIT_FIRMWARE */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x61: */ + ISP_FC_OPMAP(0x01, 0x01), /* 0x62: MBOX_INIT_LIP */ + ISP_FC_OPMAP(0xcd, 0x03), /* 0x63: MBOX_GET_FC_AL_POSITION_MAP */ + ISP_FC_OPMAP(0xcf, 0x01), /* 0x64: MBOX_GET_PORT_DB */ + ISP_FC_OPMAP(0x07, 0x01), /* 0x65: MBOX_CLEAR_ACA */ + ISP_FC_OPMAP(0x07, 0x01), /* 0x66: MBOX_TARGET_RESET */ + ISP_FC_OPMAP(0x07, 0x01), /* 0x67: MBOX_CLEAR_TASK_SET */ + ISP_FC_OPMAP(0x07, 0x01), /* 0x68: MBOX_ABORT_TASK_SET */ + ISP_FC_OPMAP(0x01, 0x07), /* 0x69: MBOX_GET_FW_STATE */ + ISP_FC_OPMAP(0x03, 0xcf), /* 0x6a: MBOX_GET_PORT_NAME */ + ISP_FC_OPMAP(0xcf, 0x01), /* 0x6b: MBOX_GET_LINK_STATUS */ + ISP_FC_OPMAP(0x0f, 0x01), /* 0x6c: MBOX_INIT_LIP_RESET */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x6d: */ + ISP_FC_OPMAP(0xcf, 0x03), /* 0x6e: MBOX_SEND_SNS */ + ISP_FC_OPMAP(0x0f, 0x07), /* 0x6f: MBOX_FABRIC_LOGIN */ + ISP_FC_OPMAP(0x03, 0x01), /* 0x70: MBOX_SEND_CHANGE_REQUEST */ + ISP_FC_OPMAP(0x03, 0x03), /* 0x71: MBOX_FABRIC_LOGOUT */ + ISP_FC_OPMAP(0x0f, 0x0f), /* 0x72: MBOX_INIT_LIP_LOGIN */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x73: */ + ISP_FC_OPMAP(0x07, 0x01), /* 0x74: LOGIN LOOP PORT */ + ISP_FC_OPMAP(0xcf, 0x03), /* 0x75: GET PORT/NODE NAME LIST */ + ISP_FC_OPMAP(0x4f, 0x01), /* 0x76: SET VENDOR ID */ + ISP_FC_OPMAP(0xcd, 0x01), /* 0x77: INITIALIZE IP MAILBOX */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x78: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x79: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x7a: */ + ISP_FC_OPMAP(0x00, 0x00), /* 0x7b: */ + ISP_FC_OPMAP(0x4f, 0x03), /* 0x7c: Get ID List */ + ISP_FC_OPMAP(0xcf, 0x01), /* 0x7d: SEND LFA */ + ISP_FC_OPMAP(0x0f, 0x01) /* 0x7e: LUN RESET */ }; +#define MAX_FC_OPCODE 0x7e /* * Footnotes * @@ -7136,19 +7219,18 @@ static void isp_mboxcmd_qnw(ispsoftc_t *isp, mbreg_t *mbp, int nodelay) { unsigned int ibits, obits, box, opcode; - const uint32_t *mcp; + opcode = mbp->param[0]; if (IS_FC(isp)) { - mcp = mbpfc; + ibits = ISP_FC_IBITS(opcode); + obits = ISP_FC_OBITS(opcode); } else { - mcp = mbpscsi; + ibits = ISP_SCSI_IBITS(opcode); + obits = ISP_SCSI_OBITS(opcode); } - opcode = mbp->param[0]; - ibits = HIWRD(mcp[opcode]) & NMBOX_BMASK(isp); - obits = LOWRD(mcp[opcode]) & NMBOX_BMASK(isp); ibits |= mbp->ibits; obits |= mbp->obits; - for (box = 0; box < MAX_MAILBOX(isp); box++) { + for (box = 0; box < ISP_NMBOX(isp); box++) { if (ibits & (1 << box)) { ISP_WRITE(isp, MBOX_OFF(box), mbp->param[box]); } @@ -7181,26 +7263,27 @@ isp_mboxcmd(ispsoftc_t *isp, mbreg_t *mb { const char *cname, *xname; char tname[16], mname[16]; - unsigned int lim, ibits, obits, box, opcode; - const uint32_t *mcp; + unsigned int ibits, obits, box, opcode; + opcode = mbp->param[0]; if (IS_FC(isp)) { - mcp = mbpfc; - lim = (sizeof (mbpfc) / sizeof (mbpfc[0])); + if (opcode > MAX_FC_OPCODE) { + mbp->param[0] = MBOX_INVALID_COMMAND; + isp_prt(isp, ISP_LOGERR, "Unknown Command 0x%x", opcode); + return; + } + ibits = ISP_FC_IBITS(opcode); + obits = ISP_FC_OBITS(opcode); } else { - mcp = mbpscsi; - lim = (sizeof (mbpscsi) / sizeof (mbpscsi[0])); - } - - if ((opcode = mbp->param[0]) >= lim) { - mbp->param[0] = MBOX_INVALID_COMMAND; - isp_prt(isp, ISP_LOGERR, "Unknown Command 0x%x", opcode); - return; + if (opcode > MAX_SCSI_OPCODE) { + mbp->param[0] = MBOX_INVALID_COMMAND; + isp_prt(isp, ISP_LOGERR, "Unknown Command 0x%x", opcode); + return; + } + ibits = ISP_SCSI_IBITS(opcode); + obits = ISP_SCSI_OBITS(opcode); } - ibits = HIWRD(mcp[opcode]) & NMBOX_BMASK(isp); - obits = LOWRD(mcp[opcode]) & NMBOX_BMASK(isp); - /* * Pick up any additional bits that the caller might have set. */ @@ -7221,7 +7304,7 @@ isp_mboxcmd(ispsoftc_t *isp, mbreg_t *mb goto out; } - for (box = 0; box < MAX_MAILBOX(isp); box++) { + for (box = 0; box < ISP_NMBOX(isp); box++) { if (ibits & (1 << box)) { isp_prt(isp, ISP_LOGDEBUG3, "IN mbox %d = 0x%04x", box, mbp->param[box]); @@ -7264,7 +7347,7 @@ isp_mboxcmd(ispsoftc_t *isp, mbreg_t *mb /* * Copy back output registers. */ - for (box = 0; box < MAX_MAILBOX(isp); box++) { + for (box = 0; box < ISP_NMBOX(isp); box++) { if (obits & (1 << box)) { mbp->param[box] = isp->isp_mboxtmp[box]; isp_prt(isp, ISP_LOGDEBUG3, "OUT mbox %d = 0x%04x", box, @@ -7964,8 +8047,7 @@ isp_parse_nvram_1020(ispsoftc_t *isp, ui (ISP_NVRAM_FIFO_THRESHOLD_128(nvram_data) << 2); if ((isp->isp_confopts & ISP_CFG_OWNLOOPID) == 0) - sdp->isp_initiator_id = - ISP_NVRAM_INITIATOR_ID(nvram_data); + sdp->isp_initiator_id = ISP_NVRAM_INITIATOR_ID(nvram_data); sdp->isp_bus_reset_delay = ISP_NVRAM_BUS_RESET_DELAY(nvram_data); @@ -8076,8 +8158,7 @@ isp_parse_nvram_1080(ispsoftc_t *isp, in ISP1080_NVRAM_FIFO_THRESHOLD(nvram_data); if ((isp->isp_confopts & ISP_CFG_OWNLOOPID) == 0) - sdp->isp_initiator_id = - ISP1080_NVRAM_INITIATOR_ID(nvram_data, bus); + sdp->isp_initiator_id = ISP1080_NVRAM_INITIATOR_ID(nvram_data, bus); sdp->isp_bus_reset_delay = ISP1080_NVRAM_BUS_RESET_DELAY(nvram_data, bus); @@ -8152,8 +8233,7 @@ isp_parse_nvram_12160(ispsoftc_t *isp, i ISP12160_NVRAM_FIFO_THRESHOLD(nvram_data); if ((isp->isp_confopts & ISP_CFG_OWNLOOPID) == 0) - sdp->isp_initiator_id = - ISP12160_NVRAM_INITIATOR_ID(nvram_data, bus); + sdp->isp_initiator_id = ISP12160_NVRAM_INITIATOR_ID(nvram_data, bus); sdp->isp_bus_reset_delay = ISP12160_NVRAM_BUS_RESET_DELAY(nvram_data, bus); Modified: stable/9/sys/dev/isp/isp_freebsd.h ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 14:41:29 2012 (r240008) +++ stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 14:44:09 2012 (r240009) @@ -145,6 +145,7 @@ struct isp_pcmd { bus_dmamap_t dmap; /* dma map for this command */ *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 14:45:37 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 162C1106566B; Sun, 2 Sep 2012 14:45:37 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 001508FC15; Sun, 2 Sep 2012 14:45:36 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82EjaTY019262; Sun, 2 Sep 2012 14:45:36 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82EjaDP019255; Sun, 2 Sep 2012 14:45:36 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021445.q82EjaDP019255@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 14:45:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240010 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 14:45:37 -0000 Author: mjacob Date: Sun Sep 2 14:45:36 2012 New Revision: 240010 URL: http://svn.freebsd.org/changeset/base/240010 Log: MFC of 237537 Clean up multi-id mode so it's driven by the f/w loaded,... Modified: stable/9/sys/dev/isp/isp.c stable/9/sys/dev/isp/isp_freebsd.c stable/9/sys/dev/isp/isp_freebsd.h stable/9/sys/dev/isp/isp_pci.c stable/9/sys/dev/isp/ispmbox.h stable/9/sys/dev/isp/ispvar.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp.c ============================================================================== --- stable/9/sys/dev/isp/isp.c Sun Sep 2 14:44:09 2012 (r240009) +++ stable/9/sys/dev/isp/isp.c Sun Sep 2 14:45:36 2012 (r240010) @@ -1088,7 +1088,6 @@ isp_reset(ispsoftc_t *isp, int do_load_d isp->isp_fwattr = mbs.param[6]; } if (IS_24XX(isp) && (isp->isp_fwattr & ISP2400_FW_ATTR_EXTNDED)) { - isp->isp_fwattr ^= ISP2400_FW_ATTR_EXTNDED; isp->isp_fwattr |= (((uint64_t) mbs.param[15]) << 16) | (((uint64_t) mbs.param[16]) << 32) | (((uint64_t) mbs.param[17]) << 48); } } else if (IS_SCSI(isp)) { @@ -1140,7 +1139,8 @@ isp_reset(ispsoftc_t *isp, int do_load_d } fwt &= ~ISP2400_FW_ATTR_EXTNDED; if (fwt) { - ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s (unknown 0x%jx)", buf, (uintmax_t)fwt); + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s (unknown 0x%08x%08x)", buf, + (uint32_t) (fwt >> 32), (uint32_t) fwt); } isp_prt(isp, ISP_LOGCONFIG, "%s", buf); } else if (IS_FC(isp)) { @@ -1183,12 +1183,23 @@ isp_reset(ispsoftc_t *isp, int do_load_d ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s 2K-Login", buf); } if (fwt != 0) { - ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s (unknown 0x%jx)", buf, (uintmax_t)fwt); + ISP_SNPRINTF(buf, ISP_FC_SCRLEN - strlen(buf), "%s (unknown 0x%08x%08x)", buf, + (uint32_t) (fwt >> 32), (uint32_t) fwt); } isp_prt(isp, ISP_LOGCONFIG, "%s", buf); } - if (!IS_24XX(isp)) { + if (IS_24XX(isp)) { + MBSINIT(&mbs, MBOX_GET_RESOURCE_COUNT, MBLOGALL, 0); + isp_mboxcmd(isp, &mbs); + if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { + ISP_RESET0(isp); + return; + } + if (isp->isp_maxcmds >= mbs.param[3]) { + isp->isp_maxcmds = mbs.param[3]; + } + } else { MBSINIT(&mbs, MBOX_GET_FIRMWARE_STATUS, MBLOGALL, 0); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { @@ -1206,11 +1217,12 @@ isp_reset(ispsoftc_t *isp, int do_load_d * Only make this check for non-SCSI cards (I'm not sure firmware attributes * work for them). */ - if (IS_FC(isp) && ISP_CAP_MULTI_ID(isp) == 0 && isp->isp_nchan > 1) { - isp_prt(isp, ISP_LOGWARN, "non-MULTIID f/w loaded, only can enable 1 of %d channels", isp->isp_nchan); - isp->isp_nchan = 1; + if (IS_FC(isp) && isp->isp_nchan > 1) { + if (!IS_24XX(isp) || (fwt & ISP2400_FW_ATTR_MULTIID) == 0) { + isp_prt(isp, ISP_LOGWARN, "non-MULTIID f/w loaded, only can enable 1 of %d channels", isp->isp_nchan); + isp->isp_nchan = 1; + } } - for (i = 0; i < isp->isp_nchan; i++) { isp_fw_state(isp, i); } @@ -1697,21 +1709,39 @@ isp_fibre_init(ispsoftc_t *isp) */ if (IS_2200(isp) || IS_23XX(isp)) { icbp->icb_fwoptions |= ICBOPT_EXTENDED; + + icbp->icb_xfwoptions = fcp->isp_xfwoptions; + /* * Prefer or force Point-To-Point instead Loop? */ switch (isp->isp_confopts & ISP_CFG_PORT_PREF) { case ISP_CFG_NPORT: + icbp->icb_xfwoptions &= ~ICBXOPT_TOPO_MASK; icbp->icb_xfwoptions |= ICBXOPT_PTP_2_LOOP; break; case ISP_CFG_NPORT_ONLY: + icbp->icb_xfwoptions &= ~ICBXOPT_TOPO_MASK; icbp->icb_xfwoptions |= ICBXOPT_PTP_ONLY; break; case ISP_CFG_LPORT_ONLY: + icbp->icb_xfwoptions &= ~ICBXOPT_TOPO_MASK; icbp->icb_xfwoptions |= ICBXOPT_LOOP_ONLY; break; default: - icbp->icb_xfwoptions |= ICBXOPT_LOOP_2_PTP; + /* + * Let NVRAM settings define it if they are sane + */ + switch (icbp->icb_xfwoptions & ICBXOPT_TOPO_MASK) { + case ICBXOPT_PTP_2_LOOP: + case ICBXOPT_PTP_ONLY: + case ICBXOPT_LOOP_ONLY: + case ICBXOPT_LOOP_2_PTP: + break; + default: + icbp->icb_xfwoptions &= ~ICBXOPT_TOPO_MASK; + icbp->icb_xfwoptions |= ICBXOPT_LOOP_2_PTP; + } break; } if (IS_2200(isp)) { @@ -1737,15 +1767,24 @@ isp_fibre_init(ispsoftc_t *isp) icbp->icb_xfwoptions |= ICBXOPT_ZIO; icbp->icb_idelaytimer = 10; } + icbp->icb_zfwoptions = fcp->isp_zfwoptions; if (isp->isp_confopts & ISP_CFG_ONEGB) { + icbp->icb_zfwoptions &= ~ICBZOPT_RATE_MASK; icbp->icb_zfwoptions |= ICBZOPT_RATE_ONEGB; } else if (isp->isp_confopts & ISP_CFG_TWOGB) { + icbp->icb_zfwoptions &= ~ICBZOPT_RATE_MASK; icbp->icb_zfwoptions |= ICBZOPT_RATE_TWOGB; } else { - icbp->icb_zfwoptions |= ICBZOPT_RATE_AUTO; - } - if (fcp->isp_zfwoptions & ICBZOPT_50_OHM) { - icbp->icb_zfwoptions |= ICBZOPT_50_OHM; + switch (icbp->icb_zfwoptions & ICBZOPT_RATE_MASK) { + case ICBZOPT_RATE_ONEGB: + case ICBZOPT_RATE_TWOGB: + case ICBZOPT_RATE_AUTO: + break; + default: + icbp->icb_zfwoptions &= ~ICBZOPT_RATE_MASK; + icbp->icb_zfwoptions |= ICBZOPT_RATE_AUTO; + break; + } } } } @@ -1915,16 +1954,13 @@ isp_fibre_init_2400(ispsoftc_t *isp) icbp->icb_execthrottle = ICB_DFLT_THROTTLE; } + /* + * Set target exchange count. Take half if we are supporting both roles. + */ if (icbp->icb_fwoptions1 & ICB2400_OPT1_TGT_ENABLE) { - /* - * Get current resource count - */ - MBSINIT(&mbs, MBOX_GET_RESOURCE_COUNT, MBLOGALL, 0); - isp_mboxcmd(isp, &mbs); - if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { - return; - } - icbp->icb_xchgcnt = mbs.param[3]; + icbp->icb_xchgcnt = isp->isp_maxcmds; + if ((icbp->icb_fwoptions1 & ICB2400_OPT1_INI_DISABLE) == 0) + icbp->icb_xchgcnt >>= 1; } @@ -2511,15 +2547,12 @@ isp_get_wwn(ispsoftc_t *isp, int chan, i MBSINIT(&mbs, MBOX_GET_PORT_NAME, MBLOGALL & ~MBOX_COMMAND_PARAM_ERROR, 500000); if (ISP_CAP_2KLOGIN(isp)) { mbs.param[1] = loopid; - mbs.ibits = (1 << 10); if (nodename) { mbs.param[10] = 1; } - if (ISP_CAP_MULTI_ID(isp)) { - mbs.ibits |= (1 << 9); - mbs.param[9] = chan; - } + mbs.param[9] = chan; } else { + mbs.ibits = 3; mbs.param[1] = loopid << 8; if (nodename) { mbs.param[1] |= 1; @@ -7013,7 +7046,7 @@ static const uint32_t mbpfc[] = { ISP_FC_OPMAP(0x00, 0x00), /* 0x3f: */ ISP_FC_OPMAP(0x03, 0x01), /* 0x40: MBOX_LOOP_PORT_BYPASS */ ISP_FC_OPMAP(0x03, 0x01), /* 0x41: MBOX_LOOP_PORT_ENABLE */ - ISP_FC_OPMAP_HALF(0x3, 0xcf, 0x0, 0x07), /* 0x42: MBOX_GET_RESOURCE_COUNT */ + ISP_FC_OPMAP_HALF(0x0, 0x01, 0x3, 0xcf), /* 0x42: MBOX_GET_RESOURCE_COUNT */ ISP_FC_OPMAP(0x01, 0x01), /* 0x43: MBOX_REQUEST_OFFLINE_MODE */ ISP_FC_OPMAP(0x00, 0x00), /* 0x44: */ ISP_FC_OPMAP(0x00, 0x00), /* 0x45: */ @@ -7053,7 +7086,7 @@ static const uint32_t mbpfc[] = { ISP_FC_OPMAP(0x07, 0x01), /* 0x67: MBOX_CLEAR_TASK_SET */ ISP_FC_OPMAP(0x07, 0x01), /* 0x68: MBOX_ABORT_TASK_SET */ ISP_FC_OPMAP(0x01, 0x07), /* 0x69: MBOX_GET_FW_STATE */ - ISP_FC_OPMAP(0x03, 0xcf), /* 0x6a: MBOX_GET_PORT_NAME */ + ISP_FC_OPMAP_HALF(0x6, 0x03, 0x0, 0xcf), /* 0x6a: MBOX_GET_PORT_NAME */ ISP_FC_OPMAP(0xcf, 0x01), /* 0x6b: MBOX_GET_LINK_STATUS */ ISP_FC_OPMAP(0x0f, 0x01), /* 0x6c: MBOX_INIT_LIP_RESET */ ISP_FC_OPMAP(0x00, 0x00), /* 0x6d: */ Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 14:44:09 2012 (r240009) +++ stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 14:45:36 2012 (r240010) @@ -2202,6 +2202,7 @@ isp_handle_platform_atio7(ispsoftc_t *is tstate_t *tptr; struct ccb_accept_tio *atiop; atio_private_data_t *atp = NULL; + atio_private_data_t *oatp; inot_private_data_t *ntp; did = (aep->at_hdr.d_id[0] << 16) | (aep->at_hdr.d_id[1] << 8) | aep->at_hdr.d_id[2]; @@ -2296,6 +2297,7 @@ isp_handle_platform_atio7(ispsoftc_t *is * it and go to noresrc. */ if (tptr->restart_queue) { + isp_prt(isp, ISP_LOGTDEBUG0, "%s: restart queue refilling", __func__); if (restart_queue) { ntp = tptr->restart_queue; tptr->restart_queue = restart_queue; @@ -2332,15 +2334,15 @@ isp_handle_platform_atio7(ispsoftc_t *is isp_prt(isp, ISP_LOGTDEBUG0, "[0x%x] out of atps", aep->at_rxid); goto noresrc; } - if (isp_get_atpd(isp, tptr, aep->at_rxid)) { - isp_prt(isp, ISP_LOGTDEBUG0, "[0x%x] tag wraparound in isp_handle_platforms_atio7 (N-Port Handle 0x%04x S_ID 0x%04x OX_ID 0x%04x)\n", - aep->at_rxid, nphdl, sid, aep->at_hdr.ox_id); + oatp = isp_get_atpd(isp, tptr, aep->at_rxid); + if (oatp) { + isp_prt(isp, ISP_LOGTDEBUG0, "[0x%x] tag wraparound in isp_handle_platforms_atio7 (N-Port Handle 0x%04x S_ID 0x%04x OX_ID 0x%04x) oatp state %d\n", + aep->at_rxid, nphdl, sid, aep->at_hdr.ox_id, oatp->state); /* * It's not a "no resource" condition- but we can treat it like one */ goto noresrc; } - atp->tag = aep->at_rxid; atp->state = ATPD_STATE_ATIO; SLIST_REMOVE_HEAD(&tptr->atios, sim_links.sle); @@ -2386,6 +2388,7 @@ isp_handle_platform_atio7(ispsoftc_t *is atp->nphdl = nphdl; atp->portid = sid; atp->oxid = aep->at_hdr.ox_id; + atp->rxid = aep->at_hdr.rx_id; atp->cdb0 = atiop->cdb_io.cdb_bytes[0]; atp->tattr = aep->at_cmnd.fcp_cmnd_task_attribute & FCP_CMND_TASK_ATTR_MASK; atp->state = ATPD_STATE_CAM; Modified: stable/9/sys/dev/isp/isp_freebsd.h ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 14:44:09 2012 (r240009) +++ stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 14:45:36 2012 (r240010) @@ -61,7 +61,7 @@ #include "opt_isp.h" #define ISP_PLATFORM_VERSION_MAJOR 7 -#define ISP_PLATFORM_VERSION_MINOR 0 +#define ISP_PLATFORM_VERSION_MINOR 10 /* * Efficiency- get rid of SBus code && tests unless we need them. @@ -85,13 +85,14 @@ typedef struct { uint32_t orig_datalen; uint32_t bytes_xfered; uint32_t last_xframt; - uint32_t tag; + uint32_t tag; /* typically f/w RX_ID */ uint32_t lun; uint32_t nphdl; uint32_t sid; uint32_t portid; + uint16_t rxid; /* wire rxid */ + uint16_t oxid; /* wire oxid */ uint32_t - oxid : 16, cdb0 : 8, : 1, dead : 1, Modified: stable/9/sys/dev/isp/isp_pci.c ============================================================================== --- stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 14:44:09 2012 (r240009) +++ stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 14:45:36 2012 (r240010) @@ -374,6 +374,7 @@ static devclass_t isp_devclass; DRIVER_MODULE(isp, pci, isp_pci_driver, isp_devclass, 0, 0); MODULE_DEPEND(isp, cam, 1, 1, 1); MODULE_DEPEND(isp, firmware, 1, 1, 1); +static int isp_nvports = 0; static int isp_pci_probe(device_t dev) @@ -451,7 +452,7 @@ isp_pci_probe(device_t dev) } static void -isp_get_generic_options(device_t dev, ispsoftc_t *isp, int *nvp) +isp_get_generic_options(device_t dev, ispsoftc_t *isp) { int tval; @@ -483,12 +484,10 @@ isp_get_generic_options(device_t dev, is if (bootverbose) { isp->isp_dblev |= ISP_LOGCONFIG|ISP_LOGINFO; } - tval = 0; + tval = -1; (void) resource_int_value(device_get_name(dev), device_get_unit(dev), "vports", &tval); if (tval > 0 && tval < 127) { - *nvp = tval; - } else { - *nvp = 0; + isp_nvports = tval; } tval = 1; (void) resource_int_value(device_get_name(dev), device_get_unit(dev), "autoconfig", &tval); @@ -527,7 +526,7 @@ static void isp_get_specific_options(device_t dev, int chan, ispsoftc_t *isp) { const char *sptr; - int tval; + int tval = 0; if (resource_int_value(device_get_name(dev), device_get_unit(dev), "iid", &tval)) { if (IS_FC(isp)) { @@ -648,7 +647,6 @@ static int isp_pci_attach(device_t dev) { int i, m1, m2, locksetup = 0; - int isp_nvports = 0; uint32_t data, cmd, linesz, did; struct isp_pcisoftc *pcs; ispsoftc_t *isp; @@ -670,7 +668,8 @@ isp_pci_attach(device_t dev) /* * Get Generic Options */ - isp_get_generic_options(dev, isp, &isp_nvports); + isp_nvports = 0; + isp_get_generic_options(dev, isp); /* * Check to see if options have us disabled @@ -876,21 +875,16 @@ isp_pci_attach(device_t dev) /* * Make sure that SERR, PERR, WRITE INVALIDATE and BUSMASTER are set. */ - cmd |= PCIM_CMD_SEREN | PCIM_CMD_PERRESPEN | - PCIM_CMD_BUSMASTEREN | PCIM_CMD_INVEN; - + cmd |= PCIM_CMD_SEREN | PCIM_CMD_PERRESPEN | PCIM_CMD_BUSMASTEREN | PCIM_CMD_INVEN; if (IS_2300(isp)) { /* per QLogic errata */ cmd &= ~PCIM_CMD_INVEN; } - if (IS_2322(isp) || pci_get_devid(dev) == PCI_QLOGIC_ISP6312) { cmd &= ~PCIM_CMD_INTX_DISABLE; } - if (IS_24XX(isp)) { cmd &= ~PCIM_CMD_INTX_DISABLE; } - pci_write_config(dev, PCIR_COMMAND, cmd, 2); /* Modified: stable/9/sys/dev/isp/ispmbox.h ============================================================================== --- stable/9/sys/dev/isp/ispmbox.h Sun Sep 2 14:44:09 2012 (r240009) +++ stable/9/sys/dev/isp/ispmbox.h Sun Sep 2 14:45:36 2012 (r240010) @@ -851,21 +851,36 @@ typedef struct { #define ISP2400_FW_ATTR_EXPFW 0x2000 #define ISP2400_FW_ATTR_EXTNDED 0x8000 -#define ISP_CAP_FCTAPE(isp) \ - (IS_24XX(isp)? 1 : (isp->isp_fwattr & ISP_FW_ATTR_FCTAPE)) +/* + * These are either manifestly true or are dependent on f/w attributes + */ #define ISP_CAP_TMODE(isp) \ (IS_24XX(isp)? 1 : (isp->isp_fwattr & ISP_FW_ATTR_TMODE)) #define ISP_CAP_SCCFW(isp) \ (IS_24XX(isp)? 1 : (isp->isp_fwattr & ISP_FW_ATTR_SCCLUN)) #define ISP_CAP_2KLOGIN(isp) \ (IS_24XX(isp)? 1 : (isp->isp_fwattr & ISP_FW_ATTR_2KLOGINS)) + +/* + * This is only true for 24XX cards with this f/w attribute + */ #define ISP_CAP_MULTI_ID(isp) \ (IS_24XX(isp)? (isp->isp_fwattr & ISP2400_FW_ATTR_MULTIID) : 0) - #define ISP_GET_VPIDX(isp, tag) \ (ISP_CAP_MULTI_ID(isp) ? tag : 0) /* + * This is true manifestly or is dependent on a f/w attribute + * but may or may not actually be *enabled*. In any case, it + * is enabled on a per-channel basis. + */ +#define ISP_CAP_FCTAPE(isp) \ + (IS_24XX(isp)? 1 : (isp->isp_fwattr & ISP_FW_ATTR_FCTAPE)) + +#define ISP_FCTAPE_ENABLED(isp, chan) \ + (IS_24XX(isp)? (FCPARAM(isp, chan)->isp_xfwoptions & ICB2400_OPT2_FCTAPE) != 0 : (FCPARAM(isp, chan)->isp_xfwoptions & ICBXOPT_FCTAPE) != 0) + +/* * Reduced Interrupt Operation Response Queue Entries */ Modified: stable/9/sys/dev/isp/ispvar.h ============================================================================== --- stable/9/sys/dev/isp/ispvar.h Sun Sep 2 14:44:09 2012 (r240009) +++ stable/9/sys/dev/isp/ispvar.h Sun Sep 2 14:45:36 2012 (r240010) @@ -678,7 +678,7 @@ struct ispsoftc { #define ISP_RUNSTATE 4 /* - * ISP Configuration Options + * ISP Runtime Configuration Options */ #define ISP_CFG_NORELOAD 0x80 /* don't download f/w */ #define ISP_CFG_NONVRAM 0x40 /* ignore NVRAM */ From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 14:46:30 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E4D7F1065789; Sun, 2 Sep 2012 14:46:30 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CFAD28FC0C; Sun, 2 Sep 2012 14:46:30 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82EkUsG019477; Sun, 2 Sep 2012 14:46:30 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82EkULL019475; Sun, 2 Sep 2012 14:46:30 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021446.q82EkULL019475@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 14:46:30 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240012 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 14:46:31 -0000 Author: mjacob Date: Sun Sep 2 14:46:30 2012 New Revision: 240012 URL: http://svn.freebsd.org/changeset/base/240012 Log: MFC of 237544 Unbreak register tests for parallel SCSI. Modified: stable/9/sys/dev/isp/isp.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp.c ============================================================================== --- stable/9/sys/dev/isp/isp.c Sun Sep 2 14:46:18 2012 (r240011) +++ stable/9/sys/dev/isp/isp.c Sun Sep 2 14:46:30 2012 (r240012) @@ -710,8 +710,11 @@ isp_reset(ispsoftc_t *isp, int do_load_d 0x6666, 0x6677, 0x1122, 0x33ff, 0x0000, 0x0001, 0x1000, 0x1010, }; + int nmbox = ISP_NMBOX(isp); + if (IS_SCSI(isp)) + nmbox = 6; MBSINIT(&mbs, MBOX_MAILBOX_REG_TEST, MBLOGALL, 0); - for (i = 1; i < ISP_NMBOX(isp); i++) { + for (i = 1; i < nmbox; i++) { mbs.param[i] = patterns[i]; } isp_mboxcmd(isp, &mbs); @@ -719,7 +722,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d ISP_RESET0(isp); return; } - for (i = 1; i < ISP_NMBOX(isp); i++) { + for (i = 1; i < nmbox; i++) { if (mbs.param[i] != patterns[i]) { ISP_RESET0(isp); isp_prt(isp, ISP_LOGERR, "Register Test Failed at Register %d: should have 0x%04x but got 0x%04x", i, patterns[i], mbs.param[i]); From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 14:56:05 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 336BA106566B; Sun, 2 Sep 2012 14:56:05 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0466A8FC08; Sun, 2 Sep 2012 14:56:05 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82Eu4jT020969; Sun, 2 Sep 2012 14:56:04 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82Eu4SD020966; Sun, 2 Sep 2012 14:56:04 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021456.q82Eu4SD020966@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 14:56:04 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240013 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 14:56:05 -0000 Author: mjacob Date: Sun Sep 2 14:56:04 2012 New Revision: 240013 URL: http://svn.freebsd.org/changeset/base/240013 Log: A belated MFC of 227126 Implement the sysctl's for fibre channel that are listed in the man page. Modified: stable/9/sys/dev/isp/isp_freebsd.c stable/9/sys/dev/isp/isp_freebsd.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 14:46:30 2012 (r240012) +++ stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 14:56:04 2012 (r240013) @@ -175,6 +175,14 @@ isp_attach_chan(ispsoftc_t *isp, struct isp_prt(isp, ISP_LOGERR, "cannot create test target thread"); } #endif + if (chan == 0) { + struct sysctl_ctx_list *ctx = device_get_sysctl_ctx(isp->isp_osinfo.dev); + struct sysctl_oid *tree = device_get_sysctl_tree(isp->isp_osinfo.dev); + SYSCTL_ADD_QUAD(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, "wwnn", CTLFLAG_RD, &FCPARAM(isp, 0)->isp_wwnn, "World Wide Node Name"); + SYSCTL_ADD_QUAD(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, "wwpn", CTLFLAG_RD, &FCPARAM(isp, 0)->isp_wwpn, "World Wide Port Name"); + SYSCTL_ADD_UINT(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, "loop_down_limit", CTLFLAG_RW, &ISP_FC_PC(isp, 0)->loop_down_limit, 0, "Loop Down Limit"); + SYSCTL_ADD_UINT(ctx, SYSCTL_CHILDREN(tree), OID_AUTO, "gone_device_time", CTLFLAG_RW, &ISP_FC_PC(isp, 0)->gone_device_time, 0, "Gone Device Time"); + } } return (0); } Modified: stable/9/sys/dev/isp/isp_freebsd.h ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 14:46:30 2012 (r240012) +++ stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 14:56:04 2012 (r240013) @@ -38,6 +38,7 @@ #include #include #include +#include #include #include From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:00:35 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C41FF106566B; Sun, 2 Sep 2012 15:00:35 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id AE2488FC12; Sun, 2 Sep 2012 15:00:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82F0Z8P021538; Sun, 2 Sep 2012 15:00:35 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82F0Z0W021535; Sun, 2 Sep 2012 15:00:35 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021500.q82F0Z0W021535@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:00:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240014 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:00:35 -0000 Author: mjacob Date: Sun Sep 2 15:00:35 2012 New Revision: 240014 URL: http://svn.freebsd.org/changeset/base/240014 Log: MFC of 228914 Fix target mode compilation issues that arose after a change in the sense data structures. Modified: stable/9/sys/dev/isp/isp_freebsd.c stable/9/sys/dev/isp/isp_freebsd.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 14:56:04 2012 (r240013) +++ stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 15:00:35 2012 (r240014) @@ -3248,10 +3248,10 @@ isptargstart(struct cam_periph *periph, xpt_print(atio->ccb_h.path, "[0x%x] Non-Zero Lun %d: cdb0=0x%x\n", atio->tag_id, return_lun, cdb[0]); if (cdb[0] != INQUIRY && cdb[0] != REPORT_LUNS && cdb[0] != REQUEST_SENSE) { status = SCSI_STATUS_CHECK_COND; - atio->sense_data.error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_ILLEGAL_REQUEST; - atio->sense_data.add_sense_code = 0x25; - atio->sense_data.add_sense_code_qual = 0x0; - atio->sense_len = sizeof (atio->sense_data); + SDFIXED(atio->sense_data)->error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_ILLEGAL_REQUEST; + SDFIXED(atio->sense_data)->add_sense_code = 0x25; + SDFIXED(atio->sense_data)->add_sense_code_qual = 0x0; + atio->sense_len = SSD_MIN_SIZE; } return_lun = CAM_LUN_WILDCARD; } @@ -3275,10 +3275,10 @@ isptargstart(struct cam_periph *periph, case READ_16: if (isptarg_rwparm(cdb, disk_data, disk_size, atio->ccb_h.ccb_data_offset, &data_ptr, &data_len, &last)) { status = SCSI_STATUS_CHECK_COND; - atio->sense_data.error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; - atio->sense_data.add_sense_code = 0x5; - atio->sense_data.add_sense_code_qual = 0x24; - atio->sense_len = sizeof (atio->sense_data); + SDFIXED(atio->sense_data)->error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; + SDFIXED(atio->sense_data)->add_sense_code = 0x5; + SDFIXED(atio->sense_data)->add_sense_code_qual = 0x24; + atio->sense_len = SSD_MIN_SIZE; } else { #ifdef ISP_FORCE_TIMEOUT { @@ -3314,10 +3314,10 @@ isptargstart(struct cam_periph *periph, case WRITE_16: if (isptarg_rwparm(cdb, disk_data, disk_size, atio->ccb_h.ccb_data_offset, &data_ptr, &data_len, &last)) { status = SCSI_STATUS_CHECK_COND; - atio->sense_data.error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; - atio->sense_data.add_sense_code = 0x5; - atio->sense_data.add_sense_code_qual = 0x24; - atio->sense_len = sizeof (atio->sense_data); + SDFIXED(atio->sense_data)->error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; + SDFIXED(atio->sense_data)->add_sense_code = 0x5; + SDFIXED(atio->sense_data)->add_sense_code_qual = 0x24; + atio->sense_len = SSD_MIN_SIZE; } else { #ifdef ISP_FORCE_TIMEOUT { @@ -3351,10 +3351,10 @@ isptargstart(struct cam_periph *periph, flags |= CAM_DIR_IN; if (cdb[1] || cdb[2] || cdb[3]) { status = SCSI_STATUS_CHECK_COND; - atio->sense_data.error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; - atio->sense_data.add_sense_code = 0x5; - atio->sense_data.add_sense_code_qual = 0x20; - atio->sense_len = sizeof (atio->sense_data); + SDFIXED(atio->sense_data)->error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; + SDFIXED(atio->sense_data)->add_sense_code = 0x5; + SDFIXED(atio->sense_data)->add_sense_code_qual = 0x20; + atio->sense_len = SSD_MIN_SIZE; break; } data_len = sizeof (iqd); @@ -3375,10 +3375,10 @@ isptargstart(struct cam_periph *periph, if (ca) { ca = 0; status = SCSI_STATUS_CHECK_COND; - atio->sense_data.error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; - atio->sense_data.add_sense_code = 0x28; - atio->sense_data.add_sense_code_qual = 0x0; - atio->sense_len = sizeof (atio->sense_data); + SDFIXED(atio->sense_data)->error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; + SDFIXED(atio->sense_data)->add_sense_code = 0x28; + SDFIXED(atio->sense_data)->add_sense_code_qual = 0x0; + atio->sense_len = SSD_MIN_SIZE; } break; case SYNCHRONIZE_CACHE: @@ -3393,10 +3393,10 @@ isptargstart(struct cam_periph *periph, flags |= CAM_DIR_IN; if (cdb[2] || cdb[3] || cdb[4] || cdb[5]) { status = SCSI_STATUS_CHECK_COND; - atio->sense_data.error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; - atio->sense_data.add_sense_code = 0x5; - atio->sense_data.add_sense_code_qual = 0x24; - atio->sense_len = sizeof (atio->sense_data); + SDFIXED(atio->sense_data)->error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; + SDFIXED(atio->sense_data)->add_sense_code = 0x5; + SDFIXED(atio->sense_data)->add_sense_code_qual = 0x24; + atio->sense_len = SSD_MIN_SIZE; break; } if (cdb[8] & 0x1) { /* PMI */ @@ -3447,10 +3447,10 @@ isptargstart(struct cam_periph *periph, default: flags |= CAM_DIR_NONE; status = SCSI_STATUS_CHECK_COND; - atio->sense_data.error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; - atio->sense_data.add_sense_code = 0x5; - atio->sense_data.add_sense_code_qual = 0x20; - atio->sense_len = sizeof (atio->sense_data); + SDFIXED(atio->sense_data)->error_code = SSD_ERRCODE_VALID|SSD_CURRENT_ERROR|SSD_KEY_UNIT_ATTENTION; + SDFIXED(atio->sense_data)->add_sense_code = 0x5; + SDFIXED(atio->sense_data)->add_sense_code_qual = 0x20; + atio->sense_len = SSD_MIN_SIZE; break; } Modified: stable/9/sys/dev/isp/isp_freebsd.h ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 14:56:04 2012 (r240013) +++ stable/9/sys/dev/isp/isp_freebsd.h Sun Sep 2 15:00:35 2012 (r240014) @@ -76,6 +76,13 @@ #define ISP_IFLAGS INTR_TYPE_CAM | INTR_ENTROPY | INTR_MPSAFE #ifdef ISP_TARGET_MODE +/* Not quite right, but there was no bump for this change */ +#if __FreeBSD_version < 225469 +#define SDFIXED(x) (&x) +#else +#define SDFIXED(x) ((struct scsi_sense_data_fixed *)(&x)) +#endif + #define ISP_TARGET_FUNCTIONS 1 #define ATPDPSIZE 4096 From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:03:41 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 18F2D106566B; Sun, 2 Sep 2012 15:03:41 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0149E8FC08; Sun, 2 Sep 2012 15:03:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82F3eDB021989; Sun, 2 Sep 2012 15:03:40 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82F3emK021986; Sun, 2 Sep 2012 15:03:40 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021503.q82F3emK021986@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:03:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240015 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:03:41 -0000 Author: mjacob Date: Sun Sep 2 15:03:40 2012 New Revision: 240015 URL: http://svn.freebsd.org/changeset/base/240015 Log: MFC of 238859 Mega change for FC-Tape. Modified: stable/9/sys/dev/isp/isp.c stable/9/sys/dev/isp/isp_freebsd.c stable/9/sys/dev/isp/isp_freebsd.h stable/9/sys/dev/isp/isp_library.c stable/9/sys/dev/isp/isp_library.h stable/9/sys/dev/isp/isp_pci.c stable/9/sys/dev/isp/isp_stds.h stable/9/sys/dev/isp/isp_target.c stable/9/sys/dev/isp/isp_target.h stable/9/sys/dev/isp/ispmbox.h stable/9/sys/dev/isp/ispvar.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp.c ============================================================================== --- stable/9/sys/dev/isp/isp.c Sun Sep 2 15:00:35 2012 (r240014) +++ stable/9/sys/dev/isp/isp.c Sun Sep 2 15:03:40 2012 (r240015) @@ -65,7 +65,7 @@ __FBSDID("$FreeBSD$"); */ #define MBOX_DELAY_COUNT 1000000 / 100 #define ISP_MARK_PORTDB(a, b, c) \ - isp_prt(isp, ISP_LOGSANCFG, \ + isp_prt(isp, ISP_LOG_SANCFG, \ "Chan %d ISP_MARK_PORTDB@LINE %d", b, __LINE__); \ isp_mark_portdb(a, b, c) @@ -670,8 +670,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d ISP_DELAY(100); if (--loops < 0) { ISP_RESET0(isp); - isp_prt(isp, ISP_LOGERR, - "MBOX_BUSY never cleared on reset"); + isp_prt(isp, ISP_LOGERR, "MBOX_BUSY never cleared on reset"); return; } } @@ -1715,6 +1714,25 @@ isp_fibre_init(ispsoftc_t *isp) icbp->icb_xfwoptions = fcp->isp_xfwoptions; + if (ISP_CAP_FCTAPE(isp)) { + if (isp->isp_confopts & ISP_CFG_NOFCTAPE) + icbp->icb_xfwoptions &= ~ICBXOPT_FCTAPE; + + if (isp->isp_confopts & ISP_CFG_FCTAPE) + icbp->icb_xfwoptions |= ICBXOPT_FCTAPE; + + if (icbp->icb_xfwoptions & ICBXOPT_FCTAPE) { + icbp->icb_fwoptions &= ~ICBOPT_FULL_LOGIN; /* per documents */ + icbp->icb_xfwoptions |= ICBXOPT_FCTAPE_CCQ|ICBXOPT_FCTAPE_CONFIRM; + FCPARAM(isp, 0)->fctape_enabled = 1; + } else { + FCPARAM(isp, 0)->fctape_enabled = 0; + } + } else { + icbp->icb_xfwoptions &= ~ICBXOPT_FCTAPE; + FCPARAM(isp, 0)->fctape_enabled = 0; + } + /* * Prefer or force Point-To-Point instead Loop? */ @@ -1804,6 +1822,9 @@ isp_fibre_init(ispsoftc_t *isp) if (ISP_FW_NEWER_THAN(isp, 3, 16, 0)) { mbs.param[1] |= IFCOPT1_EQFQASYNC|IFCOPT1_CTIO_RETRY; if (fcp->role & ISP_ROLE_TARGET) { + if (ISP_FW_NEWER_THAN(isp, 3, 25, 0)) { + mbs.param[1] |= IFCOPT1_ENAPURE; + } mbs.param[3] = IFCOPT3_NOPRLI; } } @@ -1813,8 +1834,15 @@ isp_fibre_init(ispsoftc_t *isp) } } icbp->icb_logintime = ICB_LOGIN_TOV; - icbp->icb_lunetimeout = ICB_LUN_ENABLE_TOV; +#ifdef ISP_TARGET_MODE + if (ISP_FW_NEWER_THAN(isp, 3, 25, 0) && (icbp->icb_fwoptions & ICBOPT_TGT_ENABLE)) { + icbp->icb_lunenables = 0xffff; + icbp->icb_ccnt = DFLT_CMND_CNT; + icbp->icb_icnt = DFLT_INOT_CNT; + icbp->icb_lunetimeout = ICB_LUN_ENABLE_TOV; + } +#endif if (fcp->isp_wwnn && fcp->isp_wwpn && (fcp->isp_wwnn >> 60) != 2) { icbp->icb_fwoptions |= ICBOPT_BOTH_WWNS; MAKE_NODE_NAME_FROM_WWN(icbp->icb_nodename, fcp->isp_wwnn); @@ -1910,7 +1938,7 @@ isp_fibre_init_2400(ispsoftc_t *isp) } } if (chan == isp->isp_nchan) { - isp_prt(isp, ISP_LOGDEBUG0, "all %d channels with role 'none'", chan); + isp_prt(isp, ISP_LOG_WARN1, "all %d channels with role 'none'", chan); isp->isp_state = ISP_INITSTATE; return; } @@ -1978,6 +2006,19 @@ isp_fibre_init_2400(ispsoftc_t *isp) icbp->icb_fwoptions1 |= ICB2400_OPT1_HARD_ADDRESS; icbp->icb_fwoptions2 = fcp->isp_xfwoptions; + if (isp->isp_confopts & ISP_CFG_NOFCTAPE) { + icbp->icb_fwoptions2 &= ~ICB2400_OPT2_FCTAPE; + } + if (isp->isp_confopts & ISP_CFG_FCTAPE) { + icbp->icb_fwoptions2 |= ICB2400_OPT2_FCTAPE; + } + + if (icbp->icb_fwoptions2 & ICB2400_OPT2_FCTAPE) { + FCPARAM(isp, chan)->fctape_enabled = 1; + } else { + FCPARAM(isp, chan)->fctape_enabled = 0; + } + switch (isp->isp_confopts & ISP_CFG_PORT_PREF) { case ISP_CFG_NPORT_ONLY: icbp->icb_fwoptions2 &= ~ICB2400_OPT2_TOPO_MASK; @@ -2336,13 +2377,13 @@ isp_plogx(ispsoftc_t *isp, int chan, uin msg = buf; break; case PLOGX_IOCBERR_PORTUSED: - lev = ISP_LOGSANCFG|ISP_LOGDEBUG0; + lev = ISP_LOG_SANCFG|ISP_LOG_WARN1; ISP_SNPRINTF(buf, sizeof (buf), "already logged in with N-Port handle 0x%x", parm1); msg = buf; rval = MBOX_PORT_ID_USED | (parm1 << 16); break; case PLOGX_IOCBERR_HNDLUSED: - lev = ISP_LOGSANCFG|ISP_LOGDEBUG0; + lev = ISP_LOG_SANCFG|ISP_LOG_WARN1; ISP_SNPRINTF(buf, sizeof (buf), "handle already used for PortID 0x%06x", parm1); msg = buf; rval = MBOX_LOOP_ID_USED; @@ -2388,35 +2429,26 @@ isp_port_login(ispsoftc_t *isp, uint16_t switch (mbs.param[0]) { case MBOX_PORT_ID_USED: - isp_prt(isp, ISP_LOGDEBUG0, - "isp_port_login: portid 0x%06x already logged in as %u", - portid, mbs.param[1]); + isp_prt(isp, ISP_LOG_SANCFG|ISP_LOG_WARN1, "isp_port_login: portid 0x%06x already logged in as %u", portid, mbs.param[1]); return (MBOX_PORT_ID_USED | (mbs.param[1] << 16)); case MBOX_LOOP_ID_USED: - isp_prt(isp, ISP_LOGDEBUG0, - "isp_port_login: handle 0x%04x in use for port id 0x%02xXXXX", - handle, mbs.param[1] & 0xff); + isp_prt(isp, ISP_LOG_SANCFG|ISP_LOG_WARN1, "isp_port_login: handle 0x%04x in use for port id 0x%02xXXXX", handle, mbs.param[1] & 0xff); return (MBOX_LOOP_ID_USED); case MBOX_COMMAND_COMPLETE: return (0); case MBOX_COMMAND_ERROR: - isp_prt(isp, ISP_LOGINFO, - "isp_port_login: error 0x%x in PLOGI to port 0x%06x", - mbs.param[1], portid); + isp_prt(isp, ISP_LOG_SANCFG|ISP_LOG_WARN1, "isp_port_login: error 0x%x in PLOGI to port 0x%06x", mbs.param[1], portid); return (MBOX_COMMAND_ERROR); case MBOX_ALL_IDS_USED: - isp_prt(isp, ISP_LOGINFO, - "isp_port_login: all IDs used for fabric login"); + isp_prt(isp, ISP_LOG_SANCFG|ISP_LOG_WARN1, "isp_port_login: all IDs used for fabric login"); return (MBOX_ALL_IDS_USED); default: - isp_prt(isp, ISP_LOGINFO, - "isp_port_login: error 0x%x on port login of 0x%06x@0x%0x", - mbs.param[0], portid, handle); + isp_prt(isp, ISP_LOG_SANCFG, "isp_port_login: error 0x%x on port login of 0x%06x@0x%0x", mbs.param[0], portid, handle); return (mbs.param[0]); } } @@ -2483,16 +2515,12 @@ isp_getpdb(ispsoftc_t *isp, int chan, ui if (IS_24XX(isp)) { isp_get_pdb_24xx(isp, fcp->isp_scratch, &un.bill); pdb->handle = un.bill.pdb_handle; - pdb->s3_role = un.bill.pdb_prli_svc3; + pdb->prli_word3 = un.bill.pdb_prli_svc3; pdb->portid = BITS2WORD_24XX(un.bill.pdb_portid_bits); ISP_MEMCPY(pdb->portname, un.bill.pdb_portname, 8); ISP_MEMCPY(pdb->nodename, un.bill.pdb_nodename, 8); - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Port 0x%06x flags 0x%x curstate %x", - chan, pdb->portid, un.bill.pdb_flags, - un.bill.pdb_curstate); - if (un.bill.pdb_curstate < PDB2400_STATE_PLOGI_DONE || - un.bill.pdb_curstate > PDB2400_STATE_LOGGED_IN) { + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Port 0x%06x flags 0x%x curstate %x", chan, pdb->portid, un.bill.pdb_flags, un.bill.pdb_curstate); + if (un.bill.pdb_curstate < PDB2400_STATE_PLOGI_DONE || un.bill.pdb_curstate > PDB2400_STATE_LOGGED_IN) { mbs.param[0] = MBOX_NOT_LOGGED_IN; if (dolock) { FC_SCRATCH_RELEASE(isp, chan); @@ -2502,7 +2530,7 @@ isp_getpdb(ispsoftc_t *isp, int chan, ui } else { isp_get_pdb_21xx(isp, fcp->isp_scratch, &un.fred); pdb->handle = un.fred.pdb_loopid; - pdb->s3_role = un.fred.pdb_prli_svc3; + pdb->prli_word3 = un.fred.pdb_prli_svc3; pdb->portid = BITS2WORD(un.fred.pdb_portid_bits); ISP_MEMCPY(pdb->portname, un.fred.pdb_portname, 8); ISP_MEMCPY(pdb->nodename, un.fred.pdb_nodename, 8); @@ -2528,7 +2556,7 @@ isp_dump_chip_portdb(ispsoftc_t *isp, in if (isp_getpdb(isp, chan, loopid, &pdb, dolock)) { continue; } - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGINFO, "Chan %d Loopid 0x%04x " + isp_prt(isp, ISP_LOG_SANCFG|ISP_LOGINFO, "Chan %d Loopid 0x%04x " "PortID 0x%06x WWPN 0x%02x%02x%02x%02x%02x%02x%02x%02x", chan, loopid, pdb.portid, pdb.portname[0], pdb.portname[1], pdb.portname[2], pdb.portname[3], pdb.portname[4], @@ -2606,7 +2634,7 @@ isp_fclink_test(ispsoftc_t *isp, int cha fcp = FCPARAM(isp, chan); - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, "Chan %d FC Link Test Entry", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC Link Test Entry", chan); ISP_MARK_PORTDB(isp, chan, 1); /* @@ -2622,7 +2650,7 @@ isp_fclink_test(ispsoftc_t *isp, int cha GET_NANOTIME(&hra); isp_fw_state(isp, chan); if (lwfs != fcp->isp_fwstate) { - isp_prt(isp, ISP_LOGCONFIG|ISP_LOGSANCFG, "Chan %d Firmware State <%s->%s>", chan, isp_fc_fw_statename((int)lwfs), isp_fc_fw_statename((int)fcp->isp_fwstate)); + isp_prt(isp, ISP_LOGCONFIG|ISP_LOG_SANCFG, "Chan %d Firmware State <%s->%s>", chan, isp_fc_fw_statename((int)lwfs), isp_fc_fw_statename((int)fcp->isp_fwstate)); lwfs = fcp->isp_fwstate; } if (fcp->isp_fwstate == FW_READY) { @@ -2673,7 +2701,7 @@ isp_fclink_test(ispsoftc_t *isp, int cha * If we haven't gone to 'ready' state, return. */ if (fcp->isp_fwstate != FW_READY) { - isp_prt(isp, ISP_LOGSANCFG, "%s: chan %d not at FW_READY state", __func__, chan); + isp_prt(isp, ISP_LOG_SANCFG, "%s: chan %d not at FW_READY state", __func__, chan); return (-1); } @@ -2738,7 +2766,9 @@ isp_fclink_test(ispsoftc_t *isp, int cha } } if (alpa_map[i] && fcp->isp_loopid != i) { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, "Chan %d deriving loopid %d from AL_PA map (AL_PA 0x%x) and ignoring returned value %d (AL_PA 0x%x)", chan, i, alpa_map[i], fcp->isp_loopid, alpa); + isp_prt(isp, ISP_LOG_SANCFG, + "Chan %d deriving loopid %d from AL_PA map (AL_PA 0x%x) and ignoring returned value %d (AL_PA 0x%x)", + chan, i, alpa_map[i], fcp->isp_loopid, alpa); fcp->isp_loopid = i; } } @@ -2778,18 +2808,17 @@ isp_fclink_test(ispsoftc_t *isp, int cha lp->state = FC_PORTDB_STATE_PENDING_VALID; MAKE_WWN_FROM_NODE_NAME(lp->node_wwn, pdb.nodename); MAKE_WWN_FROM_NODE_NAME(lp->port_wwn, pdb.portname); - lp->roles = (pdb.s3_role & SVC3_ROLE_MASK) >> SVC3_ROLE_SHIFT; + lp->prli_word3 = pdb.prli_word3; lp->portid = pdb.portid; lp->handle = pdb.handle; lp->new_portid = lp->portid; - lp->new_roles = lp->roles; + lp->new_prli_word3 = lp->prli_word3; if (IS_24XX(isp)) { if (check_for_fabric) { /* * The mbs is still hanging out from the MBOX_GET_LOOP_ID above. */ fcp->isp_fabric_params = mbs.param[7]; - isp_prt(isp, ISP_LOGCONFIG, "fabric params 0x%x", mbs.param[7]); } else { fcp->isp_fabric_params = 0; } @@ -2809,7 +2838,7 @@ isp_fclink_test(ispsoftc_t *isp, int cha r = isp_register_fc4_type(isp, chan); } if (r) { - isp_prt(isp, ISP_LOGWARN|ISP_LOGSANCFG, "%s: register fc4 type failed", __func__); + isp_prt(isp, ISP_LOGWARN|ISP_LOG_SANCFG, "%s: register fc4 type failed", __func__); return (-1); } } else { @@ -2843,8 +2872,8 @@ not_on_fabric: /* * Announce ourselves, too. */ - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGCONFIG, topology, chan, (uint32_t) (fcp->isp_wwpn >> 32), (uint32_t) fcp->isp_wwpn, fcp->isp_portid, fcp->isp_loopid, isp_fc_toponame(fcp)); - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, "Chan %d FC Link Test Complete", chan); + isp_prt(isp, ISP_LOG_SANCFG|ISP_LOGCONFIG, topology, chan, (uint32_t) (fcp->isp_wwpn >> 32), (uint32_t) fcp->isp_wwpn, fcp->isp_portid, fcp->isp_loopid, isp_fc_toponame(fcp)); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC Link Test Complete", chan); return (0); } @@ -2912,8 +2941,7 @@ isp_pdb_sync(ispsoftc_t *isp, int chan) } } - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Synchronizing PDBs", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Synchronizing PDBs", chan); fcp->isp_loopstate = LOOP_SYNCING_PDB; @@ -2950,7 +2978,7 @@ isp_pdb_sync(ispsoftc_t *isp, int chan) } else { lp->autologin = 0; } - lp->new_roles = 0; + lp->new_prli_word3 = 0; lp->new_portid = 0; /* * Note that we might come out of this with our state @@ -2963,13 +2991,12 @@ isp_pdb_sync(ispsoftc_t *isp, int chan) * target id in isp_dev_map (if any). */ lp->portid = lp->new_portid; - lp->roles = lp->new_roles; + lp->prli_word3 = lp->new_prli_word3; lp->state = FC_PORTDB_STATE_VALID; isp_async(isp, ISPASYNC_DEV_ARRIVED, chan, lp); - lp->new_roles = 0; + lp->new_prli_word3 = 0; lp->new_portid = 0; - lp->reserved = 0; - lp->new_reserved = 0; + lp->announced = 0; break; case FC_PORTDB_STATE_CHANGED: /* @@ -2977,14 +3004,13 @@ isp_pdb_sync(ispsoftc_t *isp, int chan) */ lp->state = FC_PORTDB_STATE_VALID; isp_async(isp, ISPASYNC_DEV_CHANGED, chan, lp); - lp->new_roles = 0; + lp->new_prli_word3 = 0; lp->new_portid = 0; - lp->reserved = 0; - lp->new_reserved = 0; + lp->announced = 0; break; case FC_PORTDB_STATE_PENDING_VALID: lp->portid = lp->new_portid; - lp->roles = lp->new_roles; + lp->prli_word3 = lp->new_prli_word3; if (lp->dev_map_idx) { int t = lp->dev_map_idx - 1; fcp->isp_dev_map[t] = dbidx + 1; @@ -2992,11 +3018,10 @@ isp_pdb_sync(ispsoftc_t *isp, int chan) lp->state = FC_PORTDB_STATE_VALID; isp_async(isp, ISPASYNC_DEV_STAYED, chan, lp); if (dbidx != FL_ID) { - lp->new_roles = 0; + lp->new_prli_word3 = 0; lp->new_portid = 0; } - lp->reserved = 0; - lp->new_reserved = 0; + lp->announced = 0; break; case FC_PORTDB_STATE_ZOMBIE: break; @@ -3054,8 +3079,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) break; case TOPO_FL_PORT: if (IS_24XX(isp) && isp->isp_nchan > 1) { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Skipping Local Loop Scan", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Skipping Local Loop Scan", chan); fcp->isp_loopstate = LOOP_LSCAN_DONE; return (0); } @@ -3065,16 +3089,14 @@ isp_scan_loop(ispsoftc_t *isp, int chan) lim = 2; break; default: - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d no loop topology to scan", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d no loop topology to scan", chan); fcp->isp_loopstate = LOOP_LSCAN_DONE; return (0); } fcp->isp_loopstate = LOOP_SCANNING_LOOP; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC scan loop 0..%d", chan, lim-1); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC scan loop 0..%d", chan, lim-1); /* @@ -3100,8 +3122,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) if (IS_2100(isp) || IS_2200(isp)) { uint64_t node_wwn = isp_get_wwn(isp, chan, handle, 1); if (fcp->isp_loopstate < LOOP_SCANNING_LOOP) { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC scan loop DONE (bad)", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC scan loop DONE (bad)", chan); return (-1); } if (node_wwn == INI_NONE) { @@ -3119,8 +3140,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) chan, handle, r); if (fcp->isp_loopstate < LOOP_SCANNING_LOOP) { ISP_MARK_PORTDB(isp, chan, 1); - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC scan loop DONE (bad)", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC scan loop DONE (bad)", chan); return (-1); } continue; @@ -3128,8 +3148,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) if (fcp->isp_loopstate < LOOP_SCANNING_LOOP) { ISP_MARK_PORTDB(isp, chan, 1); - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC scan loop DONE (bad)", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC scan loop DONE (bad)", chan); return (-1); } @@ -3143,8 +3162,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) isp_prt(isp, ISP_LOGWARN, "Chan %d cannot synchronize port database", chan); ISP_MARK_PORTDB(isp, chan, 1); - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC scan loop DONE (bad)", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC scan loop DONE (bad)", chan); return (-1); } @@ -3153,7 +3171,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) */ MAKE_WWN_FROM_NODE_NAME(tmp.node_wwn, pdb.nodename); MAKE_WWN_FROM_NODE_NAME(tmp.port_wwn, pdb.portname); - tmp.roles = (pdb.s3_role & SVC3_ROLE_MASK) >> SVC3_ROLE_SHIFT; + tmp.prli_word3 = pdb.prli_word3; tmp.portid = pdb.portid; tmp.handle = pdb.handle; @@ -3192,8 +3210,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) for (i = 0; i < MAX_FC_TARG; i++) { lp = &fcp->portdb[i]; - if (lp->state == FC_PORTDB_STATE_NIL || - lp->target_mode) { + if (lp->state == FC_PORTDB_STATE_NIL || lp->target_mode) { continue; } if (lp->node_wwn != tmp.node_wwn) { @@ -3214,8 +3231,7 @@ isp_scan_loop(ispsoftc_t *isp, int chan) chan, i, lp->state); isp_dump_portdb(isp, chan); ISP_MARK_PORTDB(isp, chan, 1); - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC scan loop DONE (bad)", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC scan loop DONE (bad)", chan); return (-1); } @@ -3229,15 +3245,11 @@ isp_scan_loop(ispsoftc_t *isp, int chan) * Check to make see if really still the same * device. If it is, we mark it pending valid. */ - if (lp->portid == tmp.portid && - lp->handle == tmp.handle && - lp->roles == tmp.roles) { + if (lp->portid == tmp.portid && lp->handle == tmp.handle && lp->prli_word3 == tmp.prli_word3) { lp->new_portid = tmp.portid; - lp->new_roles = tmp.roles; + lp->new_prli_word3 = tmp.prli_word3; lp->state = FC_PORTDB_STATE_PENDING_VALID; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Loop Port 0x%06x@0x%04x Pending " - "Valid", chan, tmp.portid, tmp.handle); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Loop Port 0x%06x@0x%04x Pending Valid", chan, tmp.portid, tmp.handle); break; } @@ -3251,12 +3263,10 @@ isp_scan_loop(ispsoftc_t *isp, int chan) * Claim that this has changed and let somebody else * decide what to do. */ - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Loop Port 0x%06x@0x%04x changed", - chan, tmp.portid, tmp.handle); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Loop Port 0x%06x@0x%04x changed", chan, tmp.portid, tmp.handle); lp->state = FC_PORTDB_STATE_CHANGED; lp->new_portid = tmp.portid; - lp->new_roles = tmp.roles; + lp->new_prli_word3 = tmp.prli_word3; break; } @@ -3290,17 +3300,14 @@ isp_scan_loop(ispsoftc_t *isp, int chan) lp->autologin = 1; lp->state = FC_PORTDB_STATE_NEW; lp->new_portid = tmp.portid; - lp->new_roles = tmp.roles; + lp->new_prli_word3 = tmp.prli_word3; lp->handle = tmp.handle; lp->port_wwn = tmp.port_wwn; lp->node_wwn = tmp.node_wwn; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Loop Port 0x%06x@0x%04x is New Entry", - chan, tmp.portid, tmp.handle); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Loop Port 0x%06x@0x%04x is New Entry", chan, tmp.portid, tmp.handle); } fcp->isp_loopstate = LOOP_LSCAN_DONE; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC scan loop DONE", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC scan loop DONE", chan); return (0); } @@ -3343,8 +3350,7 @@ isp_gid_ft_sns(ispsoftc_t *isp, int chan sns_gid_ft_req_t *rq = &un._x; mbreg_t mbs; - isp_prt(isp, ISP_LOGDEBUG0, - "Chan %d scanning fabric (GID_FT) via SNS", chan); + isp_prt(isp, ISP_LOGDEBUG0, "Chan %d scanning fabric (GID_FT) via SNS", chan); ISP_MEMZERO(rq, SNS_GID_FT_REQ_SIZE); rq->snscb_rblen = GIDLEN >> 1; @@ -3393,8 +3399,7 @@ isp_gid_ft_ct_passthru(ispsoftc_t *isp, uint32_t *rp; uint8_t *scp = fcp->isp_scratch; - isp_prt(isp, ISP_LOGDEBUG0, - "Chan %d scanning fabric (GID_FT) via CT", chan); + isp_prt(isp, ISP_LOGDEBUG0, "Chan %d scanning fabric (GID_FT) via CT", chan); if (!IS_24XX(isp)) { return (1); @@ -3488,10 +3493,8 @@ isp_scan_fabric(ispsoftc_t *isp, int cha int portidx, portlim, r; sns_gid_ft_rsp_t *rs0, *rs1; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC Scan Fabric", chan); - if (fcp->isp_fwstate != FW_READY || - fcp->isp_loopstate < LOOP_LSCAN_DONE) { + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC Scan Fabric", chan); + if (fcp->isp_fwstate != FW_READY || fcp->isp_loopstate < LOOP_LSCAN_DONE) { return (-1); } if (fcp->isp_loopstate > LOOP_SCANNING_FABRIC) { @@ -3499,8 +3502,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha } if (fcp->isp_topo != TOPO_FL_PORT && fcp->isp_topo != TOPO_F_PORT) { fcp->isp_loopstate = LOOP_FSCAN_DONE; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC Scan Fabric Done (no fabric)", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC Scan Fabric Done (no fabric)", chan); return (0); } @@ -3568,9 +3570,8 @@ isp_scan_fabric(ispsoftc_t *isp, int cha } if (rs1->snscb_cthdr.ct_cmd_resp != LS_ACC) { int level; - if (rs1->snscb_cthdr.ct_reason == 9 && - rs1->snscb_cthdr.ct_explanation == 7) { - level = ISP_LOGSANCFG|ISP_LOGDEBUG0; + if (rs1->snscb_cthdr.ct_reason == 9 && rs1->snscb_cthdr.ct_explanation == 7) { + level = ISP_LOG_SANCFG; } else { level = ISP_LOGWARN; } @@ -3614,7 +3615,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha "fabric too big for scratch area: increase ISP_FC_SCRLEN"); } portlim = portidx + 1; - isp_prt(isp, ISP_LOGSANCFG, + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d got %d ports back from name server", chan, portlim); for (portidx = 0; portidx < portlim; portidx++) { @@ -3639,9 +3640,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha rs1->snscb_ports[npidx].portid[0] = 0; rs1->snscb_ports[npidx].portid[1] = 0; rs1->snscb_ports[npidx].portid[2] = 0; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d removing duplicate PortID 0x%06x" - " entry from list", chan, portid); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d removing duplicate PortID 0x%06x entry from list", chan, portid); } } @@ -3671,7 +3670,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha ((rs1->snscb_ports[portidx].portid[2])); if (portid == 0) { - isp_prt(isp, ISP_LOGSANCFG, + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d skipping null PortID at idx %d", chan, portidx); continue; @@ -3687,19 +3686,19 @@ isp_scan_fabric(ispsoftc_t *isp, int cha */ if (ISP_CAP_MULTI_ID(isp)) { if ((portid >> 8) == (fcp->isp_portid >> 8)) { - isp_prt(isp, ISP_LOGSANCFG, + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d skip PortID 0x%06x", chan, portid); continue; } } else if (portid == fcp->isp_portid) { - isp_prt(isp, ISP_LOGSANCFG, + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d skip ourselves on @ PortID 0x%06x", chan, portid); continue; } - isp_prt(isp, ISP_LOGSANCFG, + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Checking Fabric Port 0x%06x", chan, portid); /* @@ -3711,8 +3710,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha for (dbidx = 0; dbidx < MAX_FC_TARG; dbidx++) { lp = &fcp->portdb[dbidx]; - if (lp->state != FC_PORTDB_STATE_PROBATIONAL || - lp->target_mode) { + if (lp->state != FC_PORTDB_STATE_PROBATIONAL || lp->target_mode) { continue; } if (lp->portid == portid) { @@ -3754,9 +3752,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha if (r != 0) { lp->new_portid = portid; lp->state = FC_PORTDB_STATE_DEAD; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Fabric Port 0x%06x is dead", - chan, portid); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Fabric Port 0x%06x is dead", chan, portid); continue; } @@ -3773,7 +3769,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha pdb.portid != portid || wwpn != lp->port_wwn || wwnn != lp->node_wwn) { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, + isp_prt(isp, ISP_LOG_SANCFG, fconf, chan, dbidx, pdb.handle, pdb.portid, (uint32_t) (wwnn >> 32), (uint32_t) wwnn, (uint32_t) (wwpn >> 32), (uint32_t) wwpn, @@ -3824,7 +3820,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha handle_changed++; } - nr = (pdb.s3_role & SVC3_ROLE_MASK) >> SVC3_ROLE_SHIFT; + nr = pdb.prli_word3; /* * Check to see whether the portid and roles have @@ -3839,17 +3835,12 @@ isp_scan_fabric(ispsoftc_t *isp, int cha */ lp->new_portid = portid; - lp->new_roles = nr; - if (pdb.portid != lp->portid || nr != lp->roles || - handle_changed) { - isp_prt(isp, ISP_LOGSANCFG, - "Chan %d Fabric Port 0x%06x changed", - chan, portid); + lp->new_prli_word3 = nr; + if (pdb.portid != lp->portid || nr != lp->prli_word3 || handle_changed) { + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Fabric Port 0x%06x changed", chan, portid); lp->state = FC_PORTDB_STATE_CHANGED; } else { - isp_prt(isp, ISP_LOGSANCFG, - "Chan %d Fabric Port 0x%06x " - "Now Pending Valid", chan, portid); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Fabric Port 0x%06x Now Pending Valid", chan, portid); lp->state = FC_PORTDB_STATE_PENDING_VALID; } continue; @@ -3935,7 +3926,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha handle = pdb.handle; MAKE_WWN_FROM_NODE_NAME(wwnn, pdb.nodename); MAKE_WWN_FROM_NODE_NAME(wwpn, pdb.portname); - nr = (pdb.s3_role & SVC3_ROLE_MASK) >> SVC3_ROLE_SHIFT; + nr = pdb.prli_word3; /* * And go through the database *one* more time to make sure @@ -3949,8 +3940,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha if (fcp->portdb[dbidx].target_mode) { continue; } - if (fcp->portdb[dbidx].node_wwn == wwnn && - fcp->portdb[dbidx].port_wwn == wwpn) { + if (fcp->portdb[dbidx].node_wwn == wwnn && fcp->portdb[dbidx].port_wwn == wwpn) { break; } } @@ -3961,11 +3951,9 @@ isp_scan_fabric(ispsoftc_t *isp, int cha lp->node_wwn = wwnn; lp->port_wwn = wwpn; lp->new_portid = portid; - lp->new_roles = nr; + lp->new_prli_word3 = nr; lp->state = FC_PORTDB_STATE_NEW; - isp_prt(isp, ISP_LOGSANCFG, - "Chan %d Fabric Port 0x%06x is a New Entry", - chan, portid); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Fabric Port 0x%06x is a New Entry", chan, portid); continue; } @@ -3991,16 +3979,12 @@ isp_scan_fabric(ispsoftc_t *isp, int cha lp = &fcp->portdb[dbidx]; lp->handle = handle; lp->new_portid = portid; - lp->new_roles = nr; - if (lp->portid != portid || lp->roles != nr) { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Zombie Fabric Port 0x%06x Now Changed", - chan, portid); + lp->new_prli_word3 = nr; + if (lp->portid != portid || lp->prli_word3 != nr) { + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Zombie Fabric Port 0x%06x Now Changed", chan, portid); lp->state = FC_PORTDB_STATE_CHANGED; } else { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Zombie Fabric Port 0x%06x " - "Now Pending Valid", chan, portid); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Zombie Fabric Port 0x%06x Now Pending Valid", chan, portid); lp->state = FC_PORTDB_STATE_PENDING_VALID; } } @@ -4011,8 +3995,7 @@ isp_scan_fabric(ispsoftc_t *isp, int cha return (-1); } fcp->isp_loopstate = LOOP_FSCAN_DONE; - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d FC Scan Fabric Done", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d FC Scan Fabric Done", chan); return (0); } @@ -4261,17 +4244,13 @@ isp_register_fc4_type_24xx(ispsoftc_t *i FC_SCRATCH_RELEASE(isp, chan); if (ct->ct_cmd_resp == LS_RJT) { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Register FC4 Type rejected", chan); + isp_prt(isp, ISP_LOG_SANCFG|ISP_LOG_WARN1, "Chan %d Register FC4 Type rejected", chan); return (-1); } else if (ct->ct_cmd_resp == LS_ACC) { - isp_prt(isp, ISP_LOGSANCFG|ISP_LOGDEBUG0, - "Chan %d Register FC4 Type accepted", chan); + isp_prt(isp, ISP_LOG_SANCFG, "Chan %d Register FC4 Type accepted", chan); return (0); } else { - isp_prt(isp, ISP_LOGWARN, - "Chan %d Register FC4 Type: 0x%x", - chan, ct->ct_cmd_resp); + isp_prt(isp, ISP_LOGWARN, "Chan %d Register FC4 Type: 0x%x", chan, ct->ct_cmd_resp); return (-1); } } @@ -4369,6 +4348,7 @@ isp_start(XS_T *xs) fcparam *fcp = FCPARAM(isp, XS_CHANNEL(xs)); if ((fcp->role & ISP_ROLE_INITIATOR) == 0) { + isp_prt(isp, ISP_LOG_WARN1, "%d.%d.%d I am not an initiator", XS_CHANNEL(xs), target, XS_LUN(xs)); XS_SETERR(xs, HBA_SELTIMEOUT); return (CMD_COMPLETE); } @@ -4381,6 +4361,7 @@ isp_start(XS_T *xs) } if (XS_TGT(xs) >= MAX_FC_TARG) { + isp_prt(isp, ISP_LOG_WARN1, "%d.%d.%d target too big", XS_CHANNEL(xs), target, XS_LUN(xs)); XS_SETERR(xs, HBA_SELTIMEOUT); return (CMD_COMPLETE); } @@ -4392,9 +4373,11 @@ isp_start(XS_T *xs) return (CMD_COMPLETE); } if (fcp->portdb[hdlidx].state == FC_PORTDB_STATE_ZOMBIE) { + isp_prt(isp, ISP_LOGDEBUG1, "%d.%d.%d target zombie", XS_CHANNEL(xs), target, XS_LUN(xs)); return (CMD_RQLATER); } if (fcp->portdb[hdlidx].state != FC_PORTDB_STATE_VALID) { + isp_prt(isp, ISP_LOGDEBUG1, "%d.%d.%d bad db port state 0x%x", XS_CHANNEL(xs), target, XS_LUN(xs), fcp->portdb[hdlidx].state); XS_SETERR(xs, HBA_SELTIMEOUT); return (CMD_COMPLETE); } @@ -4403,6 +4386,7 @@ isp_start(XS_T *xs) } else { sdparam *sdp = SDPARAM(isp, XS_CHANNEL(xs)); if ((sdp->role & ISP_ROLE_INITIATOR) == 0) { + isp_prt(isp, ISP_LOGDEBUG1, "%d.%d.%d I am not an initiator", XS_CHANNEL(xs), target, XS_LUN(xs)); XS_SETERR(xs, HBA_SELTIMEOUT); return (CMD_COMPLETE); } @@ -4415,7 +4399,7 @@ isp_start(XS_T *xs) qep = isp_getrqentry(isp); if (qep == NULL) { - isp_prt(isp, ISP_LOGDEBUG0, "Request Queue Overflow"); + isp_prt(isp, ISP_LOG_WARN1, "Request Queue Overflow"); XS_SETERR(xs, HBA_BOTCH); return (CMD_EAGAIN); } @@ -4449,6 +4433,14 @@ isp_start(XS_T *xs) } reqp->req_header.rqs_entry_count = 1; + + /* + * Select and install Header Code. + * Note that it might be overridden before going out + * if we're on a 64 bit platform. The lower level + * code (isp_send_cmd) will select the appropriate + * 64 bit variant if it needs to. + */ if (IS_24XX(isp)) { reqp->req_header.rqs_entry_type = RQSTYPE_T7RQS; } else if (IS_FC(isp)) { @@ -4461,6 +4453,9 @@ isp_start(XS_T *xs) } } + /* + * Set task attributes + */ if (IS_24XX(isp)) { int ttype; if (XS_TAG_P(xs)) { @@ -4513,20 +4508,30 @@ isp_start(XS_T *xs) tptr = &reqp->req_time; /* - * NB: we do not support long CDBs + * NB: we do not support long CDBs (yet) */ cdblen = XS_CDBLEN(xs); if (IS_SCSI(isp)) { + if (cdblen > sizeof (reqp->req_cdb)) { + isp_prt(isp, ISP_LOGERR, "Command Length %u too long for this chip", cdblen); + XS_SETERR(xs, HBA_BOTCH); + return (CMD_COMPLETE); + } reqp->req_target = target | (XS_CHANNEL(xs) << 7); reqp->req_lun_trn = XS_LUN(xs); - cdblen = ISP_MIN(cdblen, sizeof (reqp->req_cdb)); cdbp = reqp->req_cdb; reqp->req_cdblen = cdblen; } else if (IS_24XX(isp)) { ispreqt7_t *t7 = (ispreqt7_t *)local; fcportdb_t *lp; + if (cdblen > sizeof (t7->req_cdb)) { + isp_prt(isp, ISP_LOGERR, "Command Length %u too long for this chip", cdblen); + XS_SETERR(xs, HBA_BOTCH); + return (CMD_COMPLETE); + } + lp = &FCPARAM(isp, XS_CHANNEL(xs))->portdb[hdlidx]; t7->req_nphdl = target; t7->req_tidlo = lp->portid; @@ -4537,28 +4542,47 @@ isp_start(XS_T *xs) t7->req_lun[0] |= 0x40; } t7->req_lun[1] = XS_LUN(xs); - FCP_NEXT_CRN(isp, xs, t7->req_crn, XS_CHANNEL(xs), XS_TGT(xs), XS_LUN(xs)); + if (FCPARAM(isp, XS_CHANNEL(xs))->fctape_enabled && (lp->prli_word3 & PRLI_WD3_RETRY)) { + if (FCP_NEXT_CRN(isp, &t7->req_crn, xs)) { + isp_prt(isp, ISP_LOG_WARN1, "%d.%d.%d cannot generate next CRN", XS_CHANNEL(xs), target, XS_LUN(xs)); + XS_SETERR(xs, HBA_BOTCH); + return (CMD_EAGAIN); + } + } tptr = &t7->req_time; cdbp = t7->req_cdb; - cdblen = ISP_MIN(cdblen, sizeof (t7->req_cdb)); - } else if (ISP_CAP_2KLOGIN(isp)) { - ispreqt2e_t *t2e = (ispreqt2e_t *)local; - t2e->req_target = target; - t2e->req_scclun = XS_LUN(xs); - cdbp = t2e->req_cdb; - cdblen = ISP_MIN(cdblen, sizeof (t2e->req_cdb)); - } else if (ISP_CAP_SCCFW(isp)) { - ispreqt2_t *t2 = (ispreqt2_t *)local; - t2->req_target = target; - t2->req_scclun = XS_LUN(xs); - cdbp = t2->req_cdb; - cdblen = ISP_MIN(cdblen, sizeof (t2->req_cdb)); } else { ispreqt2_t *t2 = (ispreqt2_t *)local; - t2->req_target = target; - t2->req_lun_trn = XS_LUN(xs); - cdbp = t2->req_cdb; - cdblen = ISP_MIN(cdblen, sizeof (t2->req_cdb)); + fcportdb_t *lp; + + if (cdblen > sizeof t2->req_cdb) { + isp_prt(isp, ISP_LOGERR, "Command Length %u too long for this chip", cdblen); + XS_SETERR(xs, HBA_BOTCH); + return (CMD_COMPLETE); + } + lp = &FCPARAM(isp, XS_CHANNEL(xs))->portdb[hdlidx]; + if (FCPARAM(isp, XS_CHANNEL(xs))->fctape_enabled && (lp->prli_word3 & PRLI_WD3_RETRY)) { + if (FCP_NEXT_CRN(isp, &t2->req_crn, xs)) { + isp_prt(isp, ISP_LOG_WARN1, "%d.%d.%d cannot generate next CRN", XS_CHANNEL(xs), target, XS_LUN(xs)); + XS_SETERR(xs, HBA_BOTCH); + return (CMD_EAGAIN); + } + } + if (ISP_CAP_2KLOGIN(isp)) { + ispreqt2e_t *t2e = (ispreqt2e_t *)local; + t2e->req_target = target; + t2e->req_scclun = XS_LUN(xs); + cdbp = t2e->req_cdb; + } else if (ISP_CAP_SCCFW(isp)) { + ispreqt2_t *t2 = (ispreqt2_t *)local; + t2->req_target = target; + t2->req_scclun = XS_LUN(xs); + cdbp = t2->req_cdb; + } else { + t2->req_target = target; + t2->req_lun_trn = XS_LUN(xs); + cdbp = t2->req_cdb; + } } ISP_MEMCPY(cdbp, XS_CDBP(xs), cdblen); @@ -4571,7 +4595,7 @@ isp_start(XS_T *xs) } if (isp_allocate_xs(isp, xs, &handle)) { - isp_prt(isp, ISP_LOGDEBUG0, "out of xflist pointers"); + isp_prt(isp, ISP_LOG_WARN1, "out of xflist pointers"); XS_SETERR(xs, HBA_BOTCH); return (CMD_EAGAIN); } @@ -4618,7 +4642,7 @@ isp_control(ispsoftc_t *isp, ispctl_t ct * Issue a bus reset. */ if (IS_24XX(isp)) { - isp_prt(isp, ISP_LOGWARN, "RESET BUS NOT IMPLEMENTED"); + isp_prt(isp, ISP_LOGERR, "BUS RESET NOT IMPLEMENTED"); break; } else if (IS_FC(isp)) { mbs.param[1] = 10; @@ -4639,8 +4663,7 @@ isp_control(ispsoftc_t *isp, ispctl_t ct if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { break; } - isp_prt(isp, ISP_LOGINFO, - "driver initiated bus reset of bus %d", chan); + isp_prt(isp, ISP_LOGINFO, "driver initiated bus reset of bus %d", chan); return (0); case ISPCTL_RESET_DEV: @@ -4658,17 +4681,12 @@ isp_control(ispsoftc_t *isp, ispctl_t ct hdlidx = fcp->isp_dev_map[tgt] - 1; if (hdlidx < 0 || hdlidx >= MAX_FC_TARG) { - isp_prt(isp, ISP_LOGWARN, - "Chan %d bad handle %d trying to reset" - "target %d", chan, hdlidx, tgt); + isp_prt(isp, ISP_LOGWARN, "Chan %d bad handle %d trying to reset target %d", chan, hdlidx, tgt); break; } lp = &fcp->portdb[hdlidx]; if (lp->state != FC_PORTDB_STATE_VALID) { - isp_prt(isp, ISP_LOGWARN, - "Chan %d handle %d for abort of target %d " - "no longer valid", chan, - hdlidx, tgt); + isp_prt(isp, ISP_LOGWARN, "Chan %d handle %d for abort of target %d no longer valid", chan, hdlidx, tgt); break; } @@ -4703,18 +4721,14 @@ isp_control(ispsoftc_t *isp, ispctl_t ct FC_SCRATCH_RELEASE(isp, chan); break; } - MEMORYBARRIER(isp, SYNC_SFORCPU, QENTRY_LEN, - QENTRY_LEN, chan); + MEMORYBARRIER(isp, SYNC_SFORCPU, QENTRY_LEN, QENTRY_LEN, chan); sp = (isp24xx_statusreq_t *) local; - isp_get_24xx_response(isp, - &((isp24xx_statusreq_t *)fcp->isp_scratch)[1], sp); + isp_get_24xx_response(isp, &((isp24xx_statusreq_t *)fcp->isp_scratch)[1], sp); FC_SCRATCH_RELEASE(isp, chan); if (sp->req_completion_status == 0) { return (0); } - isp_prt(isp, ISP_LOGWARN, - "Chan %d reset of target %d returned 0x%x", - chan, tgt, sp->req_completion_status); + isp_prt(isp, ISP_LOGWARN, "Chan %d reset of target %d returned 0x%x", chan, tgt, sp->req_completion_status); break; } else if (IS_FC(isp)) { if (ISP_CAP_2KLOGIN(isp)) { @@ -4732,8 +4746,7 @@ isp_control(ispsoftc_t *isp, ispctl_t ct if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { break; } - isp_prt(isp, ISP_LOGINFO, - "Target %d on Bus %d Reset Succeeded", tgt, chan); + isp_prt(isp, ISP_LOGINFO, "Target %d on Bus %d Reset Succeeded", tgt, chan); ISP_SET_SENDMARKER(isp, chan, 1); return (0); *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:04:40 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 29785106566C; Sun, 2 Sep 2012 15:04:40 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 10F7E8FC25; Sun, 2 Sep 2012 15:04:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82F4esp022169; Sun, 2 Sep 2012 15:04:40 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82F4dSe022166; Sun, 2 Sep 2012 15:04:39 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021504.q82F4dSe022166@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:04:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240016 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:04:40 -0000 Author: mjacob Date: Sun Sep 2 15:04:39 2012 New Revision: 240016 URL: http://svn.freebsd.org/changeset/base/240016 Log: MFC of 239143 More rototilling with target mode in an attemp to get multiple... Modified: stable/9/sys/dev/isp/isp_freebsd.c stable/9/sys/dev/isp/isp_freebsd.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 15:03:40 2012 (r240015) +++ stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 15:04:39 2012 (r240016) @@ -74,6 +74,7 @@ static void isp_action(struct cam_sim *, static void isp_target_thread_pi(void *); static void isp_target_thread_fc(void *); #endif +static int isp_timer_count; static void isp_timer(void *); static struct cdevsw isp_cdevsw = { @@ -225,7 +226,8 @@ isp_attach(ispsoftc_t *isp) } callout_init_mtx(&isp->isp_osinfo.tmo, &isp->isp_osinfo.lock, 0); - callout_reset(&isp->isp_osinfo.tmo, hz, isp_timer, isp); + isp_timer_count = hz >> 2; + callout_reset(&isp->isp_osinfo.tmo, isp_timer_count, isp_timer, isp); isp->isp_osinfo.timer_active = 1; isp->isp_osinfo.cdev = make_dev(&isp_cdevsw, du, UID_ROOT, GID_OPERATOR, 0600, "%s", nu); @@ -777,6 +779,7 @@ static ISP_INLINE void isp_free_pcmd(ispsoftc_t *isp, union ccb *ccb) { if (ISP_PCMD(ccb)) { + memset(ISP_PCMD(ccb), 0, sizeof (struct isp_pcmd)); ((struct isp_pcmd *)ISP_PCMD(ccb))->next = isp->isp_osinfo.pcmd_free; isp->isp_osinfo.pcmd_free = ISP_PCMD(ccb); ISP_PCMD(ccb) = NULL; @@ -813,7 +816,7 @@ static timeout_t isp_refire_putback_atio static timeout_t isp_refire_notify_ack; static void isp_complete_ctio(union ccb *); static void isp_target_putback_atio(union ccb *); -enum Start_Ctio_How { FROM_CAM, FROM_SRR, FROM_CTIO_DONE }; +enum Start_Ctio_How { FROM_CAM, FROM_TIMER, FROM_SRR, FROM_CTIO_DONE }; static void isp_target_start_ctio(ispsoftc_t *, union ccb *, enum Start_Ctio_How); static void isp_handle_platform_atio(ispsoftc_t *, at_entry_t *); static void isp_handle_platform_atio2(ispsoftc_t *, at2_entry_t *); @@ -975,7 +978,9 @@ static void isp_tmcmd_restart(ispsoftc_t *isp) { inot_private_data_t *ntp; + inot_private_data_t *restart_queue; tstate_t *tptr; + union ccb *ccb; struct tslist *lhp; int bus, i; @@ -983,8 +988,8 @@ isp_tmcmd_restart(ispsoftc_t *isp) for (i = 0; i < LUN_HASH_SIZE; i++) { ISP_GET_PC_ADDR(isp, bus, lun_hash[i], lhp); SLIST_FOREACH(tptr, lhp, next) { - inot_private_data_t *restart_queue = tptr->restart_queue; - tptr->restart_queue = NULL; + if ((restart_queue = tptr->restart_queue) != NULL) + tptr->restart_queue = NULL; while (restart_queue) { ntp = restart_queue; restart_queue = ntp->rd.nt.nt_hba; @@ -1006,6 +1011,14 @@ isp_tmcmd_restart(ispsoftc_t *isp) break; } } + /* + * We only need to do this once per tptr + */ + if (!TAILQ_EMPTY(&tptr->waitq)) { + ccb = (union ccb *)TAILQ_LAST(&tptr->waitq, isp_ccbq); + TAILQ_REMOVE(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + isp_target_start_ctio(isp, ccb, FROM_TIMER); + } } } } @@ -1052,8 +1065,8 @@ isp_dump_atpd(ispsoftc_t *isp, tstate_t if (atp->tag == 0) { continue; } - xpt_print(tptr->owner, "ATP: [0x%x] origdlen %u bytes_xfrd %u last_xfr %u lun %u nphdl 0x%04x s_id 0x%06x d_id 0x%06x oxid 0x%04x state %s\n", - atp->tag, atp->orig_datalen, atp->bytes_xfered, atp->last_xframt, atp->lun, atp->nphdl, atp->sid, atp->portid, atp->oxid, states[atp->state & 0x7]); + xpt_print(tptr->owner, "ATP: [0x%x] origdlen %u bytes_xfrd %u lun %u nphdl 0x%04x s_id 0x%06x d_id 0x%06x oxid 0x%04x state %s\n", + atp->tag, atp->orig_datalen, atp->bytes_xfered, atp->lun, atp->nphdl, atp->sid, atp->portid, atp->oxid, states[atp->state & 0x7]); } } @@ -1118,6 +1131,7 @@ create_lun_state(ispsoftc_t *isp, int bu } SLIST_INIT(&tptr->atios); SLIST_INIT(&tptr->inots); + TAILQ_INIT(&tptr->waitq); for (i = 0; i < ATPDPSIZE-1; i++) { tptr->atpool[i].next = &tptr->atpool[i+1]; tptr->ntpool[i].next = &tptr->ntpool[i+1]; @@ -1534,533 +1548,544 @@ isp_ledone(ispsoftc_t *isp, lun_entry_t static void isp_target_start_ctio(ispsoftc_t *isp, union ccb *ccb, enum Start_Ctio_How how) { - - void *qe; - int fctape, sendstatus, resid, repval = ISP_LOGTDEBUG0; + int fctape, sendstatus, resid; tstate_t *tptr; fcparam *fcp; atio_private_data_t *atp; - struct ccb_scsiio *cso = &ccb->csio; - uint32_t dmaresult, handle, xfrlen, sense_length; + struct ccb_scsiio *cso; + uint32_t dmaresult, handle, xfrlen, sense_length, tmp; uint8_t local[QENTRY_LEN]; - /* - * Do some sanity checks. - */ - xfrlen = cso->dxfer_len; - if (xfrlen == 0) { - if ((ccb->ccb_h.flags & CAM_SEND_STATUS) == 0) { - ISP_PATH_PRT(isp, ISP_LOGERR, ccb->ccb_h.path, "a data transfer length of zero but no status to send is wrong\n"); - ccb->ccb_h.status = CAM_REQ_INVALID; - xpt_done(ccb); - return; - } - } - tptr = get_lun_statep(isp, XS_CHANNEL(ccb), XS_LUN(ccb)); if (tptr == NULL) { tptr = get_lun_statep(isp, XS_CHANNEL(ccb), CAM_LUN_WILDCARD); if (tptr == NULL) { - ISP_PATH_PRT(isp, ISP_LOGERR, ccb->ccb_h.path, "%s: [0x%x] cannot find tstate pointer in %s\n", __func__, cso->tag_id); + isp_prt(isp, ISP_LOGERR, "%s: [0x%x] cannot find tstate pointer", __func__, ccb->csio.tag_id); ccb->ccb_h.status = CAM_DEV_NOT_THERE; xpt_done(ccb); return; } } + isp_prt(isp, ISP_LOGTDEBUG0, "%s: ENTRY[0x%x] how %u xfrlen %u sendstatus %d sense_len %u", __func__, ccb->csio.tag_id, how, ccb->csio.dxfer_len, + (ccb->ccb_h.flags & CAM_SEND_STATUS) != 0, ((ccb->ccb_h.flags & CAM_SEND_SENSE)? ccb->csio.sense_len : 0)); - atp = isp_get_atpd(isp, tptr, cso->tag_id); - if (atp == NULL) { - ISP_PATH_PRT(isp, ISP_LOGERR, ccb->ccb_h.path, "%s: [0x%x] cannot find private data adjunct\n", __func__, cso->tag_id); - isp_dump_atpd(isp, tptr); - ccb->ccb_h.status = CAM_REQ_CMP_ERR; - xpt_done(ccb); - return; - } - - /* - * Is this command a dead duck? - */ - if (atp->dead) { - ISP_PATH_PRT(isp, ISP_LOGERR, ccb->ccb_h.path, "%s: [0x%x] not sending a CTIO for a dead command\n", __func__, cso->tag_id); - ccb->ccb_h.status = CAM_REQ_ABORTED; - xpt_done(ccb); - return; + switch (how) { + case FROM_TIMER: + case FROM_CAM: + /* + * Insert at the tail of the list, if any, waiting CTIO CCBs + */ + TAILQ_INSERT_TAIL(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + break; + case FROM_SRR: + case FROM_CTIO_DONE: + TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + break; } - /* - * Check to make sure we're still in target mode. - */ - fcp = FCPARAM(isp, XS_CHANNEL(ccb)); - if ((fcp->role & ISP_ROLE_TARGET) == 0) { - ISP_PATH_PRT(isp, ISP_LOGERR, ccb->ccb_h.path, "%s: [0x%x] stopping sending a CTIO because we're no longer in target mode\n", __func__, cso->tag_id); - ccb->ccb_h.status = CAM_PROVIDE_FAIL; - xpt_done(ccb); - return; - } + while (TAILQ_FIRST(&tptr->waitq) != NULL) { + ccb = (union ccb *) TAILQ_FIRST(&tptr->waitq); + TAILQ_REMOVE(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); - /* - * We're only handling one outstanding CTIO at a time (which - * could be split into two to split data and status) - */ - if (atp->ctcnt) { - ISP_PATH_PRT(isp, ISP_LOGINFO, ccb->ccb_h.path, "sending only one CTIO at a time\n"); - goto restart_delay; - } + cso = &ccb->csio; + xfrlen = cso->dxfer_len; + if (xfrlen == 0) { + if ((ccb->ccb_h.flags & CAM_SEND_STATUS) == 0) { + ISP_PATH_PRT(isp, ISP_LOGERR, ccb->ccb_h.path, "a data transfer length of zero but no status to send is wrong\n"); + ccb->ccb_h.status = CAM_REQ_INVALID; + xpt_done(ccb); + continue; + } + } + atp = isp_get_atpd(isp, tptr, cso->tag_id); + if (atp == NULL) { + isp_prt(isp, ISP_LOGERR, "%s: [0x%x] cannot find private data adjunct in %s", __func__, cso->tag_id, __func__); + isp_dump_atpd(isp, tptr); + ccb->ccb_h.status = CAM_REQ_CMP_ERR; + xpt_done(ccb); + continue; + } - /* - * Get some resources - */ - if (isp_get_pcmd(isp, ccb)) { - ISP_PATH_PRT(isp, ISP_LOGWARN, ccb->ccb_h.path, "out of PCMDs\n"); - goto restart_delay; - } - qe = isp_getrqentry(isp); - if (qe == NULL) { - ISP_PATH_PRT(isp, ISP_LOGWARN, ccb->ccb_h.path, rqo, __func__); - goto restart_delay; - } - memset(local, 0, QENTRY_LEN); + /* + * Is this command a dead duck? + */ + if (atp->dead) { + isp_prt(isp, ISP_LOGERR, "%s: [0x%x] not sending a CTIO for a dead command", __func__, cso->tag_id); + ccb->ccb_h.status = CAM_REQ_ABORTED; + xpt_done(ccb); + continue; + } - /* - * Does the initiator expect FC-Tape style responses? - * Can we provide them? - */ - if ((atp->word3 & PRLI_WD3_RETRY) && fcp->fctape_enabled) { - fctape = 1; - } else { - fctape = 0; - } + /* + * Check to make sure we're still in target mode. + */ + fcp = FCPARAM(isp, XS_CHANNEL(ccb)); + if ((fcp->role & ISP_ROLE_TARGET) == 0) { + isp_prt(isp, ISP_LOGERR, "%s: [0x%x] stopping sending a CTIO because we're no longer in target mode", __func__, cso->tag_id); + ccb->ccb_h.status = CAM_PROVIDE_FAIL; + xpt_done(ccb); + continue; + } - /* - * If we already did the data xfer portion of a CTIO that sends data - * and status, don't do it again and do the status portion now. - */ - if (atp->sendst) { - xfrlen = 0; /* we already did the data transfer */ - atp->sendst = 0; - } - if (ccb->ccb_h.flags & CAM_SEND_STATUS) { - sendstatus = 1; - } else { - sendstatus = 0; - } + /* + * We're only handling ATPD_CCB_OUTSTANDING outstanding CCB at a time (one of which + * could be split into two CTIOs to split data and status). + */ + if (atp->ctcnt >= ATPD_CCB_OUTSTANDING) { + isp_prt(isp, ISP_LOGTINFO, "[0x%x] handling only %d CCBs at a time (flags for this ccb: 0x%x)", cso->tag_id, ATPD_CCB_OUTSTANDING, ccb->ccb_h.flags); + TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + break; + } - if (ccb->ccb_h.flags & CAM_SEND_SENSE) { /* - * Sense length is not the entire sense data structure size. Periph - * drivers don't seem to be setting sense_len to reflect the actual - * size. We'll peek inside to get the right amount. + * Does the initiator expect FC-Tape style responses? */ - sense_length = cso->sense_len; + if ((atp->word3 & PRLI_WD3_RETRY) && fcp->fctape_enabled) { + fctape = 1; + } else { + fctape = 0; + } /* - * This 'cannot' happen + * If we already did the data xfer portion of a CTIO that sends data + * and status, don't do it again and do the status portion now. */ - if (sense_length > (XCMD_SIZE - MIN_FCP_RESPONSE_SIZE)) { - sense_length = XCMD_SIZE - MIN_FCP_RESPONSE_SIZE; + if (atp->sendst) { + isp_prt(isp, ISP_LOGTINFO, "[0x%x] now sending synthesized status orig_dl=%u xfered=%u bit=%u", + cso->tag_id, atp->orig_datalen, atp->bytes_xfered, atp->bytes_in_transit); + xfrlen = 0; /* we already did the data transfer */ + atp->sendst = 0; + } + if (ccb->ccb_h.flags & CAM_SEND_STATUS) { + sendstatus = 1; + } else { + sendstatus = 0; } - } else { - sense_length = 0; - } - if (how == FROM_SRR || atp->nsrr) - repval = ISP_LOGINFO; + if (ccb->ccb_h.flags & CAM_SEND_SENSE) { + KASSERT((sendstatus != 0), ("how can you have CAM_SEND_SENSE w/o CAM_SEND_STATUS?")); + /* + * Sense length is not the entire sense data structure size. Periph + * drivers don't seem to be setting sense_len to reflect the actual + * size. We'll peek inside to get the right amount. + */ + sense_length = cso->sense_len; - if (IS_24XX(isp)) { - ct7_entry_t *cto = (ct7_entry_t *) local; + /* + * This 'cannot' happen + */ + if (sense_length > (XCMD_SIZE - MIN_FCP_RESPONSE_SIZE)) { + sense_length = XCMD_SIZE - MIN_FCP_RESPONSE_SIZE; + } + } else { + sense_length = 0; + } - cto->ct_header.rqs_entry_type = RQSTYPE_CTIO7; - cto->ct_header.rqs_entry_count = 1; - cto->ct_header.rqs_seqno = 1; - cto->ct_nphdl = atp->nphdl; - cto->ct_rxid = atp->tag; - cto->ct_iid_lo = atp->portid; - cto->ct_iid_hi = atp->portid >> 16; - cto->ct_oxid = atp->oxid; - cto->ct_vpidx = ISP_GET_VPIDX(isp, XS_CHANNEL(ccb)); - cto->ct_timeout = 120; - cto->ct_flags = atp->tattr << CT7_TASK_ATTR_SHIFT; + memset(local, 0, QENTRY_LEN); /* - * Mode 1, status, no data. Only possible when we are sending status, have - * no data to transfer, and any sense length can fit in the ct7_entry. - * - * Mode 2, status, no data. We have to use this in the case sense data - * won't fit into a ct7_entry_t. - * + * Check for overflow */ - if (sendstatus && xfrlen == 0) { - cto->ct_flags |= CT7_SENDSTATUS | CT7_NO_DATA; - resid = atp->orig_datalen - atp->bytes_xfered; - if (sense_length <= MAXRESPLEN_24XX) { - if (resid < 0) { - cto->ct_resid = -resid; - } else if (resid > 0) { - cto->ct_resid = resid; - } - cto->ct_flags |= CT7_FLAG_MODE1; - cto->ct_scsi_status = cso->scsi_status; - if (resid < 0) { - cto->ct_scsi_status |= (FCP_RESID_OVERFLOW << 8); - } else if (resid > 0) { - cto->ct_scsi_status |= (FCP_RESID_UNDERFLOW << 8); - } - if (fctape) { - cto->ct_flags |= CT7_CONFIRM|CT7_EXPLCT_CONF; - } - if (sense_length) { - cto->ct_scsi_status |= (FCP_SNSLEN_VALID << 8); - cto->rsp.m1.ct_resplen = cto->ct_senselen = sense_length; - memcpy(cto->rsp.m1.ct_resp, &cso->sense_data, sense_length); - } - } else { - bus_addr_t addr; - char buf[XCMD_SIZE]; - fcp_rsp_iu_t *rp; + tmp = atp->bytes_xfered + atp->bytes_in_transit + xfrlen; + if (tmp > atp->orig_datalen) { + isp_prt(isp, ISP_LOGERR, "%s: [0x%x] data overflow by %u bytes", __func__, cso->tag_id, tmp - atp->orig_datalen); + ccb->ccb_h.status = CAM_DATA_RUN_ERR; + xpt_done(ccb); + continue; + } + + if (IS_24XX(isp)) { + ct7_entry_t *cto = (ct7_entry_t *) local; + + cto->ct_header.rqs_entry_type = RQSTYPE_CTIO7; + cto->ct_header.rqs_entry_count = 1; + cto->ct_header.rqs_seqno |= ATPD_SEQ_NOTIFY_CAM; + ATPD_SET_SEQNO(cto, atp); + cto->ct_nphdl = atp->nphdl; + cto->ct_rxid = atp->tag; + cto->ct_iid_lo = atp->portid; + cto->ct_iid_hi = atp->portid >> 16; + cto->ct_oxid = atp->oxid; + cto->ct_vpidx = ISP_GET_VPIDX(isp, XS_CHANNEL(ccb)); + cto->ct_timeout = 120; + cto->ct_flags = atp->tattr << CT7_TASK_ATTR_SHIFT; + + /* + * Mode 1, status, no data. Only possible when we are sending status, have + * no data to transfer, and any sense length can fit in the ct7_entry. + * + * Mode 2, status, no data. We have to use this in the case sense data + * won't fit into a ct7_entry_t. + * + */ + if (sendstatus && xfrlen == 0) { + cto->ct_flags |= CT7_SENDSTATUS | CT7_NO_DATA; + resid = atp->orig_datalen - atp->bytes_xfered - atp->bytes_in_transit; + if (sense_length <= MAXRESPLEN_24XX) { + if (resid < 0) { + cto->ct_resid = -resid; + } else if (resid > 0) { + cto->ct_resid = resid; + } + cto->ct_flags |= CT7_FLAG_MODE1; + cto->ct_scsi_status = cso->scsi_status; + if (resid < 0) { + cto->ct_scsi_status |= (FCP_RESID_OVERFLOW << 8); + } else if (resid > 0) { + cto->ct_scsi_status |= (FCP_RESID_UNDERFLOW << 8); + } + if (fctape) { + cto->ct_flags |= CT7_CONFIRM|CT7_EXPLCT_CONF; + } + if (sense_length) { + cto->ct_scsi_status |= (FCP_SNSLEN_VALID << 8); + cto->rsp.m1.ct_resplen = cto->ct_senselen = sense_length; + memcpy(cto->rsp.m1.ct_resp, &cso->sense_data, sense_length); + } + } else { + bus_addr_t addr; + char buf[XCMD_SIZE]; + fcp_rsp_iu_t *rp; - if (atp->ests == NULL) { - atp->ests = isp_get_ecmd(isp); if (atp->ests == NULL) { - goto restart_delay; + atp->ests = isp_get_ecmd(isp); + if (atp->ests == NULL) { + TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + break; + } } - } - memset(buf, 0, sizeof (buf)); - rp = (fcp_rsp_iu_t *)buf; - if (fctape) { - cto->ct_flags |= CT7_CONFIRM|CT7_EXPLCT_CONF; - rp->fcp_rsp_bits |= FCP_CONF_REQ; - } - cto->ct_flags |= CT7_FLAG_MODE2; - rp->fcp_rsp_scsi_status = cso->scsi_status; - if (resid < 0) { - rp->fcp_rsp_resid = -resid; - rp->fcp_rsp_bits |= FCP_RESID_OVERFLOW; - } else if (resid > 0) { - rp->fcp_rsp_resid = resid; - rp->fcp_rsp_bits |= FCP_RESID_UNDERFLOW; + memset(buf, 0, sizeof (buf)); + rp = (fcp_rsp_iu_t *)buf; + if (fctape) { + cto->ct_flags |= CT7_CONFIRM|CT7_EXPLCT_CONF; + rp->fcp_rsp_bits |= FCP_CONF_REQ; + } + cto->ct_flags |= CT7_FLAG_MODE2; + rp->fcp_rsp_scsi_status = cso->scsi_status; + if (resid < 0) { + rp->fcp_rsp_resid = -resid; + rp->fcp_rsp_bits |= FCP_RESID_OVERFLOW; + } else if (resid > 0) { + rp->fcp_rsp_resid = resid; + rp->fcp_rsp_bits |= FCP_RESID_UNDERFLOW; + } + if (sense_length) { + rp->fcp_rsp_snslen = sense_length; + cto->ct_senselen = sense_length; + rp->fcp_rsp_bits |= FCP_SNSLEN_VALID; + isp_put_fcp_rsp_iu(isp, rp, atp->ests); + memcpy(((fcp_rsp_iu_t *)atp->ests)->fcp_rsp_extra, &cso->sense_data, sense_length); + } else { + isp_put_fcp_rsp_iu(isp, rp, atp->ests); + } + if (isp->isp_dblev & ISP_LOGTDEBUG1) { + isp_print_bytes(isp, "FCP Response Frame After Swizzling", MIN_FCP_RESPONSE_SIZE + sense_length, atp->ests); + } + addr = isp->isp_osinfo.ecmd_dma; + addr += ((((isp_ecmd_t *)atp->ests) - isp->isp_osinfo.ecmd_base) * XCMD_SIZE); + isp_prt(isp, ISP_LOGTDEBUG0, "%s: ests base %p vaddr %p ecmd_dma %jx addr %jx len %u", __func__, isp->isp_osinfo.ecmd_base, atp->ests, + (uintmax_t) isp->isp_osinfo.ecmd_dma, (uintmax_t)addr, MIN_FCP_RESPONSE_SIZE + sense_length); + cto->rsp.m2.ct_datalen = MIN_FCP_RESPONSE_SIZE + sense_length; + cto->rsp.m2.ct_fcp_rsp_iudata.ds_base = DMA_LO32(addr); + cto->rsp.m2.ct_fcp_rsp_iudata.ds_basehi = DMA_HI32(addr); + cto->rsp.m2.ct_fcp_rsp_iudata.ds_count = MIN_FCP_RESPONSE_SIZE + sense_length; } if (sense_length) { - rp->fcp_rsp_snslen = sense_length; - cto->ct_senselen = sense_length; - rp->fcp_rsp_bits |= FCP_SNSLEN_VALID; - isp_put_fcp_rsp_iu(isp, rp, atp->ests); - memcpy(((fcp_rsp_iu_t *)atp->ests)->fcp_rsp_extra, &cso->sense_data, sense_length); + isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO7[0x%x] seq %u nc %d CDB0=%x sstatus=0x%x flags=0x%x resid=%d slen %u sense: %x %x/%x/%x", __func__, + cto->ct_rxid, ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cto->ct_scsi_status, cto->ct_flags, cto->ct_resid, sense_length, + cso->sense_data.error_code, cso->sense_data.sense_buf[1], cso->sense_data.sense_buf[11], cso->sense_data.sense_buf[12]); } else { - isp_put_fcp_rsp_iu(isp, rp, atp->ests); - } - if (isp->isp_dblev & ISP_LOGTDEBUG1) { - isp_print_bytes(isp, "FCP Response Frame After Swizzling", MIN_FCP_RESPONSE_SIZE + sense_length, atp->ests); + isp_prt(isp, ISP_LOGDEBUG0, "%s: CTIO7[0x%x] seq %u nc %d CDB0=%x sstatus=0x%x flags=0x%x resid=%d", __func__, + cto->ct_rxid, ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cto->ct_scsi_status, cto->ct_flags, cto->ct_resid); } - addr = isp->isp_osinfo.ecmd_dma; - addr += ((((isp_ecmd_t *)atp->ests) - isp->isp_osinfo.ecmd_base) * XCMD_SIZE); - isp_prt(isp, repval, "%s: ests base %p vaddr %p ecmd_dma %jx addr %jx len %u", __func__, isp->isp_osinfo.ecmd_base, atp->ests, - (uintmax_t) isp->isp_osinfo.ecmd_dma, (uintmax_t)addr, MIN_FCP_RESPONSE_SIZE + sense_length); - cto->rsp.m2.ct_datalen = MIN_FCP_RESPONSE_SIZE + sense_length; - cto->rsp.m2.ct_fcp_rsp_iudata.ds_base = DMA_LO32(addr); - cto->rsp.m2.ct_fcp_rsp_iudata.ds_basehi = DMA_HI32(addr); - cto->rsp.m2.ct_fcp_rsp_iudata.ds_count = MIN_FCP_RESPONSE_SIZE + sense_length; - } - if (sense_length) { - isp_prt(isp, repval, "%s: CTIO7[0x%x] CDB0=%x sstatus=0x%x flags=0x%x resid=%d slen %u sense: %x %x/%x/%x", __func__, - cto->ct_rxid, atp->cdb0, cto->ct_scsi_status, cto->ct_flags, cto->ct_resid, sense_length, cso->sense_data.error_code, - cso->sense_data.sense_buf[1], cso->sense_data.sense_buf[11], cso->sense_data.sense_buf[12]); - } else { - isp_prt(isp, repval, "%s: CTIO7[0x%x] CDB0=%x sstatus=0x%x flags=0x%x resid=%d", __func__, - cto->ct_rxid, atp->cdb0, cto->ct_scsi_status, cto->ct_flags, cto->ct_resid); - } - atp->state = ATPD_STATE_LAST_CTIO; - } - - /* - * Mode 0 data transfers, *possibly* with status. - */ - if (xfrlen != 0) { - cto->ct_flags |= CT7_FLAG_MODE0; - if ((cso->ccb_h.flags & CAM_DIR_MASK) == CAM_DIR_IN) { - cto->ct_flags |= CT7_DATA_IN; - } else { - cto->ct_flags |= CT7_DATA_OUT; + atp->state = ATPD_STATE_LAST_CTIO; } /* - * Don't overrun the limits placed on us, but record it as - * if we had so that we can set an overflow bit later. + * Mode 0 data transfers, *possibly* with status. */ - atp->last_xframt = xfrlen; - if (atp->bytes_xfered >= atp->orig_datalen) { - resid = atp->orig_datalen - (atp->bytes_xfered + xfrlen); - } else if (atp->bytes_xfered + xfrlen > atp->orig_datalen) { - resid = atp->orig_datalen - (atp->bytes_xfered + xfrlen); - xfrlen = atp->orig_datalen - atp->bytes_xfered; - } else { - resid = atp->orig_datalen - xfrlen; - } - cto->rsp.m0.reloff = atp->bytes_xfered; - cto->rsp.m0.ct_xfrlen = xfrlen; + if (xfrlen != 0) { + cto->ct_flags |= CT7_FLAG_MODE0; + if ((cso->ccb_h.flags & CAM_DIR_MASK) == CAM_DIR_IN) { + cto->ct_flags |= CT7_DATA_IN; + } else { + cto->ct_flags |= CT7_DATA_OUT; + } + + cto->rsp.m0.reloff = atp->bytes_xfered + atp->bytes_in_transit; + cto->rsp.m0.ct_xfrlen = xfrlen; #ifdef DEBUG - if (ISP_FC_PC(isp, XS_CHANNEL(ccb))->inject_lost_data_frame && xfrlen > ISP_FC_PC(isp, XS_CHANNEL(ccb))->inject_lost_data_frame) { - isp_prt(isp, ISP_LOGWARN, "%s: truncating data frame with xfrlen %d to %d", __func__, xfrlen, xfrlen - (xfrlen >> 2)); - ISP_FC_PC(isp, XS_CHANNEL(ccb))->inject_lost_data_frame = 0; - cto->rsp.m0.ct_xfrlen -= xfrlen >> 2; - } + if (ISP_FC_PC(isp, XS_CHANNEL(ccb))->inject_lost_data_frame && xfrlen > ISP_FC_PC(isp, XS_CHANNEL(ccb))->inject_lost_data_frame) { + isp_prt(isp, ISP_LOGWARN, "%s: truncating data frame with xfrlen %d to %d", __func__, xfrlen, xfrlen - (xfrlen >> 2)); + ISP_FC_PC(isp, XS_CHANNEL(ccb))->inject_lost_data_frame = 0; + cto->rsp.m0.ct_xfrlen -= xfrlen >> 2; + } #endif - if (sendstatus) { - if (cso->scsi_status == SCSI_STATUS_OK && resid == 0 && fctape == 0) { - cto->ct_flags |= CT7_SENDSTATUS; - atp->state = ATPD_STATE_LAST_CTIO; + if (sendstatus) { + resid = atp->orig_datalen - atp->bytes_xfered - xfrlen; + if (cso->scsi_status == SCSI_STATUS_OK && resid == 0 /* && fctape == 0 */) { + cto->ct_flags |= CT7_SENDSTATUS; + atp->state = ATPD_STATE_LAST_CTIO; + if (fctape) { + cto->ct_flags |= CT7_CONFIRM|CT7_EXPLCT_CONF; + } + } else { + atp->sendst = 1; /* send status later */ + cto->ct_header.rqs_seqno &= ~ATPD_SEQ_NOTIFY_CAM; + atp->state = ATPD_STATE_CTIO; + } } else { - atp->sendst = 1; /* send status later */ - cto->ct_header.rqs_seqno = 0; atp->state = ATPD_STATE_CTIO; } - } else { - atp->state = ATPD_STATE_CTIO; + isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO7[0x%x] seq %u nc %d CDB0=%x sstatus=0x%x flags=0x%x xfrlen=%u off=%u", __func__, + cto->ct_rxid, ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cto->ct_scsi_status, cto->ct_flags, xfrlen, atp->bytes_xfered); } - isp_prt(isp, repval, "%s: CTIO7[0x%x] CDB0=%x sstatus=0x%x flags=0x%x xfrlen=%u off=%u", __func__, - cto->ct_rxid, atp->cdb0, cto->ct_scsi_status, cto->ct_flags, xfrlen, atp->bytes_xfered); - } - } else if (IS_FC(isp)) { - ct2_entry_t *cto = (ct2_entry_t *) local; + } else if (IS_FC(isp)) { + ct2_entry_t *cto = (ct2_entry_t *) local; - if (isp->isp_osinfo.sixtyfourbit) - cto->ct_header.rqs_entry_type = RQSTYPE_CTIO3; - else - cto->ct_header.rqs_entry_type = RQSTYPE_CTIO2; - cto->ct_header.rqs_entry_count = 1; - cto->ct_header.rqs_seqno = 1; - if (ISP_CAP_2KLOGIN(isp) == 0) { - ((ct2e_entry_t *)cto)->ct_iid = cso->init_id; - } else { - cto->ct_iid = cso->init_id; - if (ISP_CAP_SCCFW(isp) == 0) { - cto->ct_lun = ccb->ccb_h.target_lun; + if (isp->isp_osinfo.sixtyfourbit) + cto->ct_header.rqs_entry_type = RQSTYPE_CTIO3; + else + cto->ct_header.rqs_entry_type = RQSTYPE_CTIO2; + cto->ct_header.rqs_entry_count = 1; + cto->ct_header.rqs_seqno |= ATPD_SEQ_NOTIFY_CAM; + ATPD_SET_SEQNO(cto, atp); + if (ISP_CAP_2KLOGIN(isp) == 0) { + ((ct2e_entry_t *)cto)->ct_iid = cso->init_id; + } else { + cto->ct_iid = cso->init_id; + if (ISP_CAP_SCCFW(isp) == 0) { + cto->ct_lun = ccb->ccb_h.target_lun; + } } - } - cto->ct_timeout = 10; - cto->ct_rxid = cso->tag_id; + cto->ct_timeout = 10; + cto->ct_rxid = cso->tag_id; - /* - * Mode 1, status, no data. Only possible when we are sending status, have - * no data to transfer, and the sense length can fit in the ct7_entry. - * - * Mode 2, status, no data. We have to use this in the case the the response - * length won't fit into a ct2_entry_t. - * - * We'll fill out this structure with information as if this were a - * Mode 1. The hardware layer will create the Mode 2 FCP RSP IU as - * needed based upon this. - */ - if (sendstatus && xfrlen == 0) { - cto->ct_flags |= CT2_SENDSTATUS | CT2_NO_DATA; - resid = atp->orig_datalen - atp->bytes_xfered; - if (sense_length <= MAXRESPLEN) { - if (resid < 0) { - cto->ct_resid = -resid; - } else if (resid > 0) { - cto->ct_resid = resid; - } - cto->ct_flags |= CT2_FLAG_MODE1; - cto->rsp.m1.ct_scsi_status = cso->scsi_status; - if (resid < 0) { - cto->rsp.m1.ct_scsi_status |= CT2_DATA_OVER; - } else if (resid > 0) { - cto->rsp.m1.ct_scsi_status |= CT2_DATA_UNDER; - } - if (fctape) { - cto->ct_flags |= CT2_CONFIRM; - } - if (sense_length) { - cto->rsp.m1.ct_scsi_status |= CT2_SNSLEN_VALID; - cto->rsp.m1.ct_resplen = cto->rsp.m1.ct_senselen = sense_length; - memcpy(cto->rsp.m1.ct_resp, &cso->sense_data, sense_length); - } - } else { - bus_addr_t addr; - char buf[XCMD_SIZE]; - fcp_rsp_iu_t *rp; + /* + * Mode 1, status, no data. Only possible when we are sending status, have + * no data to transfer, and the sense length can fit in the ct7_entry. + * + * Mode 2, status, no data. We have to use this in the case the the response + * length won't fit into a ct2_entry_t. + * + * We'll fill out this structure with information as if this were a + * Mode 1. The hardware layer will create the Mode 2 FCP RSP IU as + * needed based upon this. + */ + if (sendstatus && xfrlen == 0) { + cto->ct_flags |= CT2_SENDSTATUS | CT2_NO_DATA; + resid = atp->orig_datalen - atp->bytes_xfered - atp->bytes_in_transit; + if (sense_length <= MAXRESPLEN) { + if (resid < 0) { + cto->ct_resid = -resid; + } else if (resid > 0) { + cto->ct_resid = resid; + } + cto->ct_flags |= CT2_FLAG_MODE1; + cto->rsp.m1.ct_scsi_status = cso->scsi_status; + if (resid < 0) { + cto->rsp.m1.ct_scsi_status |= CT2_DATA_OVER; + } else if (resid > 0) { + cto->rsp.m1.ct_scsi_status |= CT2_DATA_UNDER; + } + if (fctape) { + cto->ct_flags |= CT2_CONFIRM; + } + if (sense_length) { + cto->rsp.m1.ct_scsi_status |= CT2_SNSLEN_VALID; + cto->rsp.m1.ct_resplen = cto->rsp.m1.ct_senselen = sense_length; + memcpy(cto->rsp.m1.ct_resp, &cso->sense_data, sense_length); + } + } else { + bus_addr_t addr; + char buf[XCMD_SIZE]; + fcp_rsp_iu_t *rp; - if (atp->ests == NULL) { - atp->ests = isp_get_ecmd(isp); if (atp->ests == NULL) { - goto restart_delay; + atp->ests = isp_get_ecmd(isp); + if (atp->ests == NULL) { + TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + break; + } + } + memset(buf, 0, sizeof (buf)); + rp = (fcp_rsp_iu_t *)buf; + if (fctape) { + cto->ct_flags |= CT2_CONFIRM; + rp->fcp_rsp_bits |= FCP_CONF_REQ; + } + cto->ct_flags |= CT2_FLAG_MODE2; + rp->fcp_rsp_scsi_status = cso->scsi_status; + if (resid < 0) { + rp->fcp_rsp_resid = -resid; + rp->fcp_rsp_bits |= FCP_RESID_OVERFLOW; + } else if (resid > 0) { + rp->fcp_rsp_resid = resid; + rp->fcp_rsp_bits |= FCP_RESID_UNDERFLOW; + } + if (sense_length) { + rp->fcp_rsp_snslen = sense_length; + rp->fcp_rsp_bits |= FCP_SNSLEN_VALID; + isp_put_fcp_rsp_iu(isp, rp, atp->ests); + memcpy(((fcp_rsp_iu_t *)atp->ests)->fcp_rsp_extra, &cso->sense_data, sense_length); + } else { + isp_put_fcp_rsp_iu(isp, rp, atp->ests); + } + if (isp->isp_dblev & ISP_LOGTDEBUG1) { + isp_print_bytes(isp, "FCP Response Frame After Swizzling", MIN_FCP_RESPONSE_SIZE + sense_length, atp->ests); + } + addr = isp->isp_osinfo.ecmd_dma; + addr += ((((isp_ecmd_t *)atp->ests) - isp->isp_osinfo.ecmd_base) * XCMD_SIZE); + isp_prt(isp, ISP_LOGTDEBUG0, "%s: ests base %p vaddr %p ecmd_dma %jx addr %jx len %u", __func__, isp->isp_osinfo.ecmd_base, atp->ests, + (uintmax_t) isp->isp_osinfo.ecmd_dma, (uintmax_t)addr, MIN_FCP_RESPONSE_SIZE + sense_length); + cto->rsp.m2.ct_datalen = MIN_FCP_RESPONSE_SIZE + sense_length; + if (isp->isp_osinfo.sixtyfourbit) { + cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_base = DMA_LO32(addr); + cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_basehi = DMA_HI32(addr); + cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_count = MIN_FCP_RESPONSE_SIZE + sense_length; + } else { + cto->rsp.m2.u.ct_fcp_rsp_iudata_32.ds_base = DMA_LO32(addr); + cto->rsp.m2.u.ct_fcp_rsp_iudata_32.ds_count = MIN_FCP_RESPONSE_SIZE + sense_length; } - } - memset(buf, 0, sizeof (buf)); - rp = (fcp_rsp_iu_t *)buf; - if (fctape) { - cto->ct_flags |= CT2_CONFIRM; - rp->fcp_rsp_bits |= FCP_CONF_REQ; - } - cto->ct_flags |= CT2_FLAG_MODE2; - rp->fcp_rsp_scsi_status = cso->scsi_status; - if (resid < 0) { - rp->fcp_rsp_resid = -resid; - rp->fcp_rsp_bits |= FCP_RESID_OVERFLOW; - } else if (resid > 0) { - rp->fcp_rsp_resid = resid; - rp->fcp_rsp_bits |= FCP_RESID_UNDERFLOW; } if (sense_length) { - rp->fcp_rsp_snslen = sense_length; - rp->fcp_rsp_bits |= FCP_SNSLEN_VALID; - isp_put_fcp_rsp_iu(isp, rp, atp->ests); - memcpy(((fcp_rsp_iu_t *)atp->ests)->fcp_rsp_extra, &cso->sense_data, sense_length); + isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO2[0x%x] seq %u nc %d CDB0=%x sstatus=0x%x flags=0x%x resid=%d sense: %x %x/%x/%x", __func__, + cto->ct_rxid, ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cso->scsi_status, cto->ct_flags, cto->ct_resid, + cso->sense_data.error_code, cso->sense_data.sense_buf[1], cso->sense_data.sense_buf[11], cso->sense_data.sense_buf[12]); } else { - isp_put_fcp_rsp_iu(isp, rp, atp->ests); - } - if (isp->isp_dblev & ISP_LOGTDEBUG1) { - isp_print_bytes(isp, "FCP Response Frame After Swizzling", MIN_FCP_RESPONSE_SIZE + sense_length, atp->ests); + isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO2[0x%x] seq %u nc %d CDB0=%x sstatus=0x%x flags=0x%x resid=%d", __func__, cto->ct_rxid, + ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cso->scsi_status, cto->ct_flags, cto->ct_resid); } - addr = isp->isp_osinfo.ecmd_dma; - addr += ((((isp_ecmd_t *)atp->ests) - isp->isp_osinfo.ecmd_base) * XCMD_SIZE); - isp_prt(isp, repval, "%s: ests base %p vaddr %p ecmd_dma %jx addr %jx len %u", __func__, isp->isp_osinfo.ecmd_base, atp->ests, - (uintmax_t) isp->isp_osinfo.ecmd_dma, (uintmax_t)addr, MIN_FCP_RESPONSE_SIZE + sense_length); - cto->rsp.m2.ct_datalen = MIN_FCP_RESPONSE_SIZE + sense_length; - if (isp->isp_osinfo.sixtyfourbit) { - cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_base = DMA_LO32(addr); - cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_basehi = DMA_HI32(addr); - cto->rsp.m2.u.ct_fcp_rsp_iudata_64.ds_count = MIN_FCP_RESPONSE_SIZE + sense_length; + atp->state = ATPD_STATE_LAST_CTIO; + } + + if (xfrlen != 0) { + cto->ct_flags |= CT2_FLAG_MODE0; + if ((cso->ccb_h.flags & CAM_DIR_MASK) == CAM_DIR_IN) { + cto->ct_flags |= CT2_DATA_IN; } else { - cto->rsp.m2.u.ct_fcp_rsp_iudata_32.ds_base = DMA_LO32(addr); - cto->rsp.m2.u.ct_fcp_rsp_iudata_32.ds_count = MIN_FCP_RESPONSE_SIZE + sense_length; + cto->ct_flags |= CT2_DATA_OUT; } - } - if (sense_length) { - isp_prt(isp, repval, "%s: CTIO2[0x%x] CDB0=%x sstatus=0x%x flags=0x%x resid=%d sense: %x %x/%x/%x", __func__, - cto->ct_rxid, atp->cdb0, cso->scsi_status, cto->ct_flags, cto->ct_resid, cso->sense_data.error_code, - cso->sense_data.sense_buf[1], cso->sense_data.sense_buf[11], cso->sense_data.sense_buf[12]); - } else { - isp_prt(isp, repval, "%s: CTIO2[0x%x] CDB0=%x sstatus=0x%x flags=0x%x resid=%d", __func__, - cto->ct_rxid, atp->cdb0, cso->scsi_status, cto->ct_flags, cto->ct_resid); - } - atp->state = ATPD_STATE_LAST_CTIO; - } - if (xfrlen != 0) { - int resid = 0; - cto->ct_flags |= CT2_FLAG_MODE0; - if ((cso->ccb_h.flags & CAM_DIR_MASK) == CAM_DIR_IN) { - cto->ct_flags |= CT2_DATA_IN; - } else { - cto->ct_flags |= CT2_DATA_OUT; - } + cto->ct_reloff = atp->bytes_xfered + atp->bytes_in_transit; + cto->rsp.m0.ct_xfrlen = xfrlen; - /* - * Don't overrun the limits placed on us, but record it as - * if we had so that we can set an overflow bit later. - */ - atp->last_xframt = xfrlen; - if (atp->bytes_xfered + xfrlen > atp->orig_datalen) { - resid = 1; - xfrlen = atp->orig_datalen - atp->bytes_xfered; - } - cto->ct_reloff = atp->bytes_xfered; - cto->rsp.m0.ct_xfrlen = xfrlen; - - if (sendstatus) { - if (cso->scsi_status == SCSI_STATUS_OK && resid == 0 && fctape == 0) { - cto->ct_flags |= CT2_SENDSTATUS; - atp->state = ATPD_STATE_LAST_CTIO; + if (sendstatus) { + resid = atp->orig_datalen - atp->bytes_xfered - xfrlen; + if (cso->scsi_status == SCSI_STATUS_OK && resid == 0 /*&& fctape == 0*/) { + cto->ct_flags |= CT2_SENDSTATUS; + atp->state = ATPD_STATE_LAST_CTIO; + if (fctape) { + cto->ct_flags |= CT2_CONFIRM; + } + } else { + atp->sendst = 1; /* send status later */ + cto->ct_header.rqs_seqno &= ~ATPD_SEQ_NOTIFY_CAM; + atp->state = ATPD_STATE_CTIO; + } } else { - atp->sendst = 1; /* send status later */ - cto->ct_header.rqs_seqno = 0; atp->state = ATPD_STATE_CTIO; } + } + isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO2[%x] seq %u nc %d CDB0=%x scsi status %x flags %x resid %d xfrlen %u offset %u", __func__, cto->ct_rxid, + ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), atp->cdb0, cso->scsi_status, cto->ct_flags, cto->ct_resid, cso->dxfer_len, atp->bytes_xfered); + } else { + ct_entry_t *cto = (ct_entry_t *) local; + + cto->ct_header.rqs_entry_type = RQSTYPE_CTIO; + cto->ct_header.rqs_entry_count = 1; + cto->ct_header.rqs_seqno |= ATPD_SEQ_NOTIFY_CAM; + ATPD_SET_SEQNO(cto, atp); + cto->ct_iid = cso->init_id; + cto->ct_iid |= XS_CHANNEL(ccb) << 7; + cto->ct_tgt = ccb->ccb_h.target_id; + cto->ct_lun = ccb->ccb_h.target_lun; + cto->ct_fwhandle = cso->tag_id; + if (atp->rxid) { + cto->ct_tag_val = atp->rxid; + cto->ct_flags |= CT_TQAE; + } + if (ccb->ccb_h.flags & CAM_DIS_DISCONNECT) { + cto->ct_flags |= CT_NODISC; + } + if (cso->dxfer_len == 0) { + cto->ct_flags |= CT_NO_DATA; + } else if ((cso->ccb_h.flags & CAM_DIR_MASK) == CAM_DIR_IN) { + cto->ct_flags |= CT_DATA_IN; } else { - atp->state = ATPD_STATE_CTIO; + cto->ct_flags |= CT_DATA_OUT; + } + if (ccb->ccb_h.flags & CAM_SEND_STATUS) { + cto->ct_flags |= CT_SENDSTATUS|CT_CCINCR; + cto->ct_scsi_status = cso->scsi_status; + cto->ct_resid = atp->orig_datalen - atp->bytes_xfered - atp->bytes_in_transit - xfrlen; + isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO[%x] seq %u nc %d scsi status %x resid %d tag_id %x", __func__, + cto->ct_fwhandle, ATPD_GET_SEQNO(cto), ATPD_GET_NCAM(cto), cso->scsi_status, cso->resid, cso->tag_id); } + ccb->ccb_h.flags &= ~CAM_SEND_SENSE; + cto->ct_timeout = 10; } - isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO2[%x] CDB0=%x scsi status %x flags %x resid %d xfrlen %u offset %u", __func__, cto->ct_rxid, - atp->cdb0, cso->scsi_status, cto->ct_flags, cto->ct_resid, cso->dxfer_len, atp->bytes_xfered); - } else { - ct_entry_t *cto = (ct_entry_t *) local; - cto->ct_header.rqs_entry_type = RQSTYPE_CTIO; - cto->ct_header.rqs_entry_count = 1; - cto->ct_header.rqs_seqno = 1; - cto->ct_iid = cso->init_id; - cto->ct_iid |= XS_CHANNEL(ccb) << 7; - cto->ct_tgt = ccb->ccb_h.target_id; - cto->ct_lun = ccb->ccb_h.target_lun; - cto->ct_fwhandle = cso->tag_id; - if (atp->rxid) { - cto->ct_tag_val = atp->rxid; - cto->ct_flags |= CT_TQAE; - } - if (ccb->ccb_h.flags & CAM_DIS_DISCONNECT) { - cto->ct_flags |= CT_NODISC; - } - if (cso->dxfer_len == 0) { - cto->ct_flags |= CT_NO_DATA; - } else if ((cso->ccb_h.flags & CAM_DIR_MASK) == CAM_DIR_IN) { - cto->ct_flags |= CT_DATA_IN; - } else { - cto->ct_flags |= CT_DATA_OUT; + if (isp_get_pcmd(isp, ccb)) { + ISP_PATH_PRT(isp, ISP_LOGWARN, ccb->ccb_h.path, "out of PCMDs\n"); + TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + break; } - if (ccb->ccb_h.flags & CAM_SEND_STATUS) { - cto->ct_flags |= CT_SENDSTATUS|CT_CCINCR; - cto->ct_scsi_status = cso->scsi_status; - cto->ct_resid = cso->resid; - isp_prt(isp, ISP_LOGTDEBUG0, "%s: CTIO[%x] scsi status %x resid %d tag_id %x", __func__, - cto->ct_fwhandle, cso->scsi_status, cso->resid, cso->tag_id); + if (isp_allocate_xs_tgt(isp, ccb, &handle)) { + ISP_PATH_PRT(isp, ISP_LOGWARN, ccb->ccb_h.path, "No XFLIST pointers for %s\n", __func__); + TAILQ_INSERT_HEAD(&tptr->waitq, &ccb->ccb_h, periph_links.tqe); + isp_free_pcmd(isp, ccb); + break; } - ccb->ccb_h.flags &= ~CAM_SEND_SENSE; - cto->ct_timeout = 10; - } + atp->bytes_in_transit += xfrlen; + PISP_PCMD(ccb)->datalen = xfrlen; - if (isp_allocate_xs_tgt(isp, ccb, &handle)) { - ISP_PATH_PRT(isp, ISP_LOGWARN, ccb->ccb_h.path, "No XFLIST pointers for %s\n", __func__); - goto restart_delay; - } - /* - * Call the dma setup routines for this entry (and any subsequent - * CTIOs) if there's data to move, and then tell the f/w it's got - * new things to play with. As with isp_start's usage of DMA setup, - * any swizzling is done in the machine dependent layer. Because - * of this, we put the request onto the queue area first in native *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:05:40 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 5C8B71065678; Sun, 2 Sep 2012 15:05:40 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3E10E8FC1D; Sun, 2 Sep 2012 15:05:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82F5egj022379; Sun, 2 Sep 2012 15:05:40 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82F5ebg022376; Sun, 2 Sep 2012 15:05:40 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021505.q82F5ebg022376@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:05:40 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240017 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:05:40 -0000 Author: mjacob Date: Sun Sep 2 15:05:39 2012 New Revision: 240017 URL: http://svn.freebsd.org/changeset/base/240017 Log: MFC of 239218 Fix an oops where we wiped out DMA maps... Modified: stable/9/sys/dev/isp/isp_freebsd.c stable/9/sys/dev/isp/isp_pci.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 15:04:39 2012 (r240016) +++ stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 15:05:39 2012 (r240017) @@ -779,8 +779,13 @@ static ISP_INLINE void isp_free_pcmd(ispsoftc_t *isp, union ccb *ccb) { if (ISP_PCMD(ccb)) { - memset(ISP_PCMD(ccb), 0, sizeof (struct isp_pcmd)); - ((struct isp_pcmd *)ISP_PCMD(ccb))->next = isp->isp_osinfo.pcmd_free; +#ifdef ISP_TARGET_MODE + PISP_PCMD(ccb)->datalen = 0; + PISP_PCMD(ccb)->totslen = 0; + PISP_PCMD(ccb)->cumslen = 0; + PISP_PCMD(ccb)->crn = 0; +#endif + PISP_PCMD(ccb)->next = isp->isp_osinfo.pcmd_free; isp->isp_osinfo.pcmd_free = ISP_PCMD(ccb); ISP_PCMD(ccb) = NULL; } @@ -6326,12 +6331,20 @@ isp_common_dmateardown(ispsoftc_t *isp, int isp_fcp_next_crn(ispsoftc_t *isp, uint8_t *crnp, XS_T *cmd) { - uint32_t chan = XS_CHANNEL(cmd); - uint32_t tgt = XS_TGT(cmd); - uint32_t lun = XS_LUN(cmd); - struct isp_fc *fc = &isp->isp_osinfo.pc.fc[chan]; - int idx = NEXUS_HASH(tgt, lun); - struct isp_nexus *nxp = fc->nexus_hash[idx]; + uint32_t chan, tgt, lun; + struct isp_fc *fc; + struct isp_nexus *nxp; + int idx; + + if (isp->isp_type < ISP_HA_FC_2300) + return (0); + + chan = XS_CHANNEL(cmd); + tgt = XS_TGT(cmd); + lun = XS_LUN(cmd); + fc = &isp->isp_osinfo.pc.fc[chan]; + idx = NEXUS_HASH(tgt, lun); + nxp = fc->nexus_hash[idx]; while (nxp) { if (nxp->tgt == tgt && nxp->lun == lun) Modified: stable/9/sys/dev/isp/isp_pci.c ============================================================================== --- stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 15:04:39 2012 (r240016) +++ stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 15:05:39 2012 (r240017) @@ -1688,18 +1688,20 @@ isp_pci_mbxdma(ispsoftc_t *isp) bus_dma_tag_destroy(fc->tdmat); goto bad; } - for (i = 0; i < INITIAL_NEXUS_COUNT; i++) { - struct isp_nexus *n = malloc(sizeof (struct isp_nexus), M_DEVBUF, M_NOWAIT | M_ZERO); - if (n == NULL) { - while (fc->nexus_free_list) { - n = fc->nexus_free_list; - fc->nexus_free_list = n->next; - free(n, M_DEVBUF); + if (isp->isp_type >= ISP_HA_FC_2300) { + for (i = 0; i < INITIAL_NEXUS_COUNT; i++) { + struct isp_nexus *n = malloc(sizeof (struct isp_nexus), M_DEVBUF, M_NOWAIT | M_ZERO); + if (n == NULL) { + while (fc->nexus_free_list) { + n = fc->nexus_free_list; + fc->nexus_free_list = n->next; + free(n, M_DEVBUF); + } + goto bad; } - goto bad; + n->next = fc->nexus_free_list; + fc->nexus_free_list = n; } - n->next = fc->nexus_free_list; - fc->nexus_free_list = n; } } } From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:06:55 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A218E106564A; Sun, 2 Sep 2012 15:06:55 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8C8438FC0C; Sun, 2 Sep 2012 15:06:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82F6tJM022581; Sun, 2 Sep 2012 15:06:55 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82F6tmx022579; Sun, 2 Sep 2012 15:06:55 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021506.q82F6tmx022579@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:06:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240018 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:06:55 -0000 Author: mjacob Date: Sun Sep 2 15:06:55 2012 New Revision: 240018 URL: http://svn.freebsd.org/changeset/base/240018 Log: MFC of 239219 Remove extraneous newline. Modified: stable/9/sys/dev/isp/isp.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp.c ============================================================================== --- stable/9/sys/dev/isp/isp.c Sun Sep 2 15:05:39 2012 (r240017) +++ stable/9/sys/dev/isp/isp.c Sun Sep 2 15:06:55 2012 (r240018) @@ -939,7 +939,7 @@ isp_reset(ispsoftc_t *isp, int do_load_d MBSINIT(&mbs, MBOX_WRITE_RAM_WORD, MBLOGNONE, 0); mbs.param[1] = code_org; mbs.param[2] = ucd.np[0]; - isp_prt(isp, ISP_LOGDEBUG1, "WRITE RAM %u words at load address 0x%x\n", ucd.np[3], code_org); + isp_prt(isp, ISP_LOGDEBUG1, "WRITE RAM %u words at load address 0x%x", ucd.np[3], code_org); isp_mboxcmd(isp, &mbs); if (mbs.param[0] != MBOX_COMMAND_COMPLETE) { isp_prt(isp, ISP_LOGERR, "F/W download failed at word %d", isp->isp_mbxwrk1 - code_org); From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:07:51 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 95166106566B; Sun, 2 Sep 2012 15:07:51 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7E9618FC08; Sun, 2 Sep 2012 15:07:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82F7pH4022752; Sun, 2 Sep 2012 15:07:51 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82F7pk0022750; Sun, 2 Sep 2012 15:07:51 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021507.q82F7pk0022750@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:07:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240019 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:07:51 -0000 Author: mjacob Date: Sun Sep 2 15:07:51 2012 New Revision: 240019 URL: http://svn.freebsd.org/changeset/base/240019 Log: MFC of 239330 On lun disable, complete all INOTs and ATIOs with CAM_REQ_ABORTED. Modified: stable/9/sys/dev/isp/isp_freebsd.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_freebsd.c ============================================================================== --- stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 15:06:55 2012 (r240018) +++ stable/9/sys/dev/isp/isp_freebsd.c Sun Sep 2 15:07:51 2012 (r240019) @@ -1154,10 +1154,27 @@ create_lun_state(ispsoftc_t *isp, int bu static ISP_INLINE void destroy_lun_state(ispsoftc_t *isp, tstate_t *tptr) { + union ccb *ccb; struct tslist *lhp; KASSERT((tptr->hold != 0), ("tptr is not held")); KASSERT((tptr->hold == 1), ("tptr still held (%d)", tptr->hold)); + do { + ccb = (union ccb *)SLIST_FIRST(&tptr->atios); + if (ccb) { + SLIST_REMOVE_HEAD(&tptr->atios, sim_links.sle); + ccb->ccb_h.status = CAM_REQ_ABORTED; + xpt_done(ccb); + } + } while (ccb); + do { + ccb = (union ccb *)SLIST_FIRST(&tptr->inots); + if (ccb) { + SLIST_REMOVE_HEAD(&tptr->inots, sim_links.sle); + ccb->ccb_h.status = CAM_REQ_ABORTED; + xpt_done(ccb); + } + } while (ccb); ISP_GET_PC_ADDR(isp, cam_sim_bus(xpt_path_sim(tptr->owner)), lun_hash[LUN_HASH_FUNC(xpt_path_lun_id(tptr->owner))], lhp); SLIST_REMOVE(lhp, tptr, tstate, next); ISP_PATH_PRT(isp, ISP_LOGTDEBUG0, tptr->owner, "destroyed tstate\n"); @@ -1472,8 +1489,8 @@ done: } ccb->ccb_h.status = status; if (status == CAM_REQ_CMP) { - xpt_print(ccb->ccb_h.path, "lun now disabled for target mode\n"); destroy_lun_state(isp, tptr); + xpt_print(ccb->ccb_h.path, "lun now disabled for target mode\n"); } else { if (tptr) rls_lun_statep(isp, tptr); From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:18:09 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6C2B21065678; Sun, 2 Sep 2012 15:18:09 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 5361F8FC1F; Sun, 2 Sep 2012 15:18:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82FI9QE024220; Sun, 2 Sep 2012 15:18:09 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82FI90r024218; Sun, 2 Sep 2012 15:18:09 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021518.q82FI90r024218@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:18:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240020 - stable/9/sys/dev/ispfw X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:18:09 -0000 Author: mjacob Date: Sun Sep 2 15:18:08 2012 New Revision: 240020 URL: http://svn.freebsd.org/changeset/base/240020 Log: MFC of 238806 Switch to FC-Tape f/w for the 23XX cards. Modified: stable/9/sys/dev/ispfw/asm_2300.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/ispfw/asm_2300.h ============================================================================== --- stable/9/sys/dev/ispfw/asm_2300.h Sun Sep 2 15:07:51 2012 (r240019) +++ stable/9/sys/dev/ispfw/asm_2300.h Sun Sep 2 15:18:08 2012 (r240020) @@ -27,17 +27,17 @@ /************************************************************************ * * - * --- ISP2300 Initiator/Target Firmware --- * - * with Fabric support (Public Loop), with expanded LUN * - * addressing and 2K port logins. * + * --- ISP2300 Initiator/Target Firmware --- * + * with Fabric (Public Loop), Point-point, * + * expanded LUN addressing for FCTAPE, and 2K port logins * * * ************************************************************************/ /* - * Firmware Version 3.03.26 (16:54 Aug 14, 2007) + * Firmware Version 3.03.26 (16:58 Aug 14, 2007) */ static const uint16_t isp_2300_risc_code[] = { - 0x0470, 0x0000, 0x0000, 0xd048, 0x0000, 0x0003, 0x0003, 0x001a, - 0x0107, 0x2043, 0x4f50, 0x5952, 0x4947, 0x4854, 0x2032, 0x3030, + 0x0470, 0x0000, 0x0000, 0xddef, 0x0000, 0x0003, 0x0003, 0x001a, + 0x0117, 0x2043, 0x4f50, 0x5952, 0x4947, 0x4854, 0x2032, 0x3030, 0x3120, 0x514c, 0x4f47, 0x4943, 0x2043, 0x4f52, 0x504f, 0x5241, 0x5449, 0x4f4e, 0x2049, 0x5350, 0x3233, 0x3030, 0x2046, 0x6972, 0x6d77, 0x6172, 0x6520, 0x2056, 0x6572, 0x7369, 0x6f6e, 0x2030, @@ -50,487 +50,496 @@ static const uint16_t isp_2300_risc_code 0x2c00, 0x20a9, 0x000f, 0x2001, 0x0000, 0x400f, 0x2091, 0x2e00, 0x20a9, 0x000f, 0x2001, 0x0000, 0x400f, 0x2091, 0x2000, 0x2001, 0x0000, 0x20c1, 0x0004, 0x20c9, 0x1bff, 0x2059, 0x0000, 0x2b78, - 0x7883, 0x0004, 0x2089, 0x2bf2, 0x2051, 0x1800, 0x2a70, 0x20e1, - 0x0001, 0x20e9, 0x0001, 0x2009, 0x0000, 0x080c, 0x0e53, 0x2029, - 0x3500, 0x2031, 0xffff, 0x2039, 0x34c8, 0x2021, 0x0200, 0x20e9, + 0x7883, 0x0004, 0x2089, 0x2c69, 0x2051, 0x1800, 0x2a70, 0x20e1, + 0x0001, 0x20e9, 0x0001, 0x2009, 0x0000, 0x080c, 0x0e51, 0x2029, + 0x4d00, 0x2031, 0xffff, 0x2039, 0x4cd0, 0x2021, 0x0200, 0x20e9, 0x0001, 0x20a1, 0x0000, 0x20a9, 0x0800, 0x900e, 0x4104, 0x20e9, 0x0001, 0x20a1, 0x1000, 0x900e, 0x2001, 0x0cc0, 0x9084, 0x0fff, 0x20a8, 0x4104, 0x2001, 0x0000, 0x9086, 0x0000, 0x0120, 0x21a8, 0x4104, 0x8001, 0x1de0, 0x756a, 0x766e, 0x7766, 0x7472, 0x7476, - 0x00e6, 0x2071, 0x1aa0, 0x2472, 0x00ee, 0x20a1, 0x1cc8, 0x716c, + 0x00e6, 0x2071, 0x1aac, 0x2472, 0x00ee, 0x20a1, 0x1cd0, 0x716c, 0x810d, 0x810d, 0x810d, 0x810d, 0x918c, 0x000f, 0x2001, 0x0001, 0x9112, 0x900e, 0x21a8, 0x4104, 0x8211, 0x1de0, 0x716c, 0x3400, 0x8001, 0x9102, 0x0120, 0x0218, 0x20a8, 0x900e, 0x4104, 0x2009, 0x1800, 0x810d, 0x810d, 0x810d, 0x810d, 0x810d, 0x918c, 0x001f, 0x2001, 0x0001, 0x9112, 0x20e9, 0x0001, 0x20a1, 0x0800, 0x900e, - 0x20a9, 0x0800, 0x4104, 0x8211, 0x1dd8, 0x080c, 0x0f19, 0x080c, - 0x5f04, 0x080c, 0x9eae, 0x080c, 0x10d0, 0x080c, 0x12b8, 0x080c, - 0x1a99, 0x080c, 0x0d58, 0x080c, 0x1055, 0x080c, 0x32cc, 0x080c, - 0x75f0, 0x080c, 0x6836, 0x080c, 0x8273, 0x080c, 0x235c, 0x080c, - 0x857b, 0x080c, 0x7c59, 0x080c, 0x2191, 0x080c, 0x22c5, 0x080c, - 0x2351, 0x2091, 0x3009, 0x7883, 0x0000, 0x1004, 0x091d, 0x7880, + 0x20a9, 0x0800, 0x4104, 0x8211, 0x1dd8, 0x080c, 0x0f25, 0x080c, + 0x5fc1, 0x080c, 0xa333, 0x080c, 0x10dc, 0x080c, 0x12c4, 0x080c, + 0x1ae1, 0x080c, 0x0d55, 0x080c, 0x1061, 0x080c, 0x3368, 0x080c, + 0x7660, 0x080c, 0x695d, 0x080c, 0x83d5, 0x080c, 0x23a4, 0x080c, + 0x874c, 0x080c, 0x7cf9, 0x080c, 0x21d9, 0x080c, 0x230d, 0x080c, + 0x2399, 0x2091, 0x3009, 0x7883, 0x0000, 0x1004, 0x091d, 0x7880, 0x9086, 0x0002, 0x1190, 0x7883, 0x4000, 0x7837, 0x4000, 0x7833, 0x0010, 0x0e04, 0x0911, 0x2091, 0x5000, 0x2091, 0x4080, 0x2001, - 0x0089, 0x2004, 0xd084, 0x190c, 0x119d, 0x2071, 0x1800, 0x7003, + 0x0089, 0x2004, 0xd084, 0x190c, 0x11a9, 0x2071, 0x1800, 0x7003, 0x0000, 0x2071, 0x1800, 0x7000, 0x908e, 0x0003, 0x1168, 0x080c, - 0x4b82, 0x080c, 0x32f3, 0x080c, 0x7661, 0x080c, 0x6d5c, 0x080c, - 0x829f, 0x080c, 0x2b09, 0x0c68, 0x000b, 0x0c88, 0x0940, 0x0941, - 0x0ade, 0x093e, 0x0b9e, 0x0d57, 0x0d57, 0x0d57, 0x080c, 0x0dc4, + 0x4c32, 0x080c, 0x338f, 0x080c, 0x76d1, 0x080c, 0x6e62, 0x080c, + 0x8401, 0x080c, 0x2b72, 0x0c68, 0x000b, 0x0c88, 0x0940, 0x0941, + 0x0ade, 0x093e, 0x0b9e, 0x0d54, 0x0d54, 0x0d54, 0x080c, 0x0dc3, 0x0005, 0x0126, 0x00f6, 0x2091, 0x8000, 0x7000, 0x9086, 0x0001, - 0x1904, 0x0ab1, 0x080c, 0x0ecd, 0x080c, 0x72e5, 0x0150, 0x080c, - 0x7308, 0x15b0, 0x2079, 0x0100, 0x7828, 0x9085, 0x1800, 0x782a, - 0x0478, 0x080c, 0x7212, 0x7000, 0x9086, 0x0001, 0x1904, 0x0ab1, - 0x7094, 0x9086, 0x0029, 0x1904, 0x0ab1, 0x080c, 0x8253, 0x080c, - 0x8245, 0x2079, 0x0100, 0x782f, 0x0008, 0x2001, 0x0161, 0x2003, + 0x1904, 0x0ab1, 0x080c, 0x0e93, 0x080c, 0x7351, 0x0150, 0x080c, + 0x7374, 0x15b0, 0x2079, 0x0100, 0x7828, 0x9085, 0x1800, 0x782a, + 0x0478, 0x080c, 0x727e, 0x7000, 0x9086, 0x0001, 0x1904, 0x0ab1, + 0x7094, 0x9086, 0x0029, 0x1904, 0x0ab1, 0x080c, 0x83b5, 0x080c, + 0x83a7, 0x2079, 0x0100, 0x782f, 0x0008, 0x2001, 0x0161, 0x2003, 0x0001, 0x7827, 0xffff, 0x7a28, 0x9295, 0x5e2f, 0x7a2a, 0x2011, - 0x7176, 0x080c, 0x835e, 0x2011, 0x7169, 0x080c, 0x8474, 0x2011, - 0x5d5f, 0x080c, 0x835e, 0x2011, 0x8030, 0x901e, 0x7392, 0x04d0, - 0x080c, 0x5607, 0x2079, 0x0100, 0x7844, 0x9005, 0x1904, 0x0ab1, - 0x2011, 0x5d5f, 0x080c, 0x835e, 0x2011, 0x7176, 0x080c, 0x835e, - 0x2011, 0x7169, 0x080c, 0x8474, 0x2001, 0x0265, 0x2001, 0x0205, + 0x71cd, 0x080c, 0x84c2, 0x2011, 0x71c0, 0x080c, 0x85e0, 0x2011, + 0x5e1c, 0x080c, 0x84c2, 0x2011, 0x8030, 0x901e, 0x7392, 0x04d0, + 0x080c, 0x56c4, 0x2079, 0x0100, 0x7844, 0x9005, 0x1904, 0x0ab1, + 0x2011, 0x5e1c, 0x080c, 0x84c2, 0x2011, 0x71cd, 0x080c, 0x84c2, + 0x2011, 0x71c0, 0x080c, 0x85e0, 0x2001, 0x0265, 0x2001, 0x0205, 0x2003, 0x0000, 0x7840, 0x9084, 0xfffb, 0x7842, 0x2001, 0x1983, - 0x2004, 0x9005, 0x1140, 0x00c6, 0x2061, 0x0100, 0x080c, 0x5eac, - 0x00ce, 0x0804, 0x0ab1, 0x780f, 0x006b, 0x7a28, 0x080c, 0x72ed, + 0x2004, 0x9005, 0x1140, 0x00c6, 0x2061, 0x0100, 0x080c, 0x5f69, + 0x00ce, 0x0804, 0x0ab1, 0x780f, 0x006b, 0x7a28, 0x080c, 0x7359, 0x0118, 0x9295, 0x5e2f, 0x0010, 0x9295, 0x402f, 0x7a2a, 0x2011, - 0x8010, 0x73d4, 0x2001, 0x1984, 0x2003, 0x0001, 0x080c, 0x29ae, - 0x080c, 0x4abd, 0x7244, 0xc284, 0x7246, 0x2001, 0x180c, 0x200c, - 0xc1ac, 0xc1cc, 0x2102, 0x080c, 0x98cb, 0x2011, 0x0004, 0x080c, - 0xb965, 0x080c, 0x664c, 0x080c, 0x72e5, 0x1120, 0x080c, 0x29f2, - 0x02e0, 0x0400, 0x080c, 0x5eb3, 0x0140, 0x7093, 0x0001, 0x70cf, - 0x0000, 0x080c, 0x57d9, 0x0804, 0x0ab1, 0x080c, 0x55a7, 0xd094, - 0x0188, 0x2011, 0x180c, 0x2204, 0xc0cd, 0x2012, 0x080c, 0x55ab, - 0xd0d4, 0x1118, 0x080c, 0x29f2, 0x1270, 0x2011, 0x180c, 0x2204, - 0xc0bc, 0x00a8, 0x080c, 0x55ab, 0xd0d4, 0x1db8, 0x2011, 0x180c, + 0x8010, 0x73d4, 0x2001, 0x1984, 0x2003, 0x0001, 0x080c, 0x2a17, + 0x080c, 0x4b6d, 0x7244, 0xc284, 0x7246, 0x2001, 0x180c, 0x200c, + 0xc1ac, 0xc1cc, 0x2102, 0x080c, 0x9b9c, 0x2011, 0x0004, 0x080c, + 0xc1dd, 0x080c, 0x6758, 0x080c, 0x7351, 0x1120, 0x080c, 0x2a5b, + 0x02e0, 0x0400, 0x080c, 0x5f70, 0x0140, 0x7093, 0x0001, 0x70cf, + 0x0000, 0x080c, 0x5896, 0x0804, 0x0ab1, 0x080c, 0x5664, 0xd094, + 0x0188, 0x2011, 0x180c, 0x2204, 0xc0cd, 0x2012, 0x080c, 0x5668, + 0xd0d4, 0x1118, 0x080c, 0x2a5b, 0x1270, 0x2011, 0x180c, 0x2204, + 0xc0bc, 0x00a8, 0x080c, 0x5668, 0xd0d4, 0x1db8, 0x2011, 0x180c, 0x2204, 0xc0bd, 0x0060, 0x2011, 0x180c, 0x2204, 0xc0bd, 0x2012, - 0x080c, 0x673e, 0x1128, 0xd0a4, 0x0118, 0x2204, 0xc0fd, 0x2012, - 0x080c, 0x6704, 0x0120, 0x7a0c, 0xc2b4, 0x7a0e, 0x00a8, 0x707b, - 0x0000, 0x080c, 0x72e5, 0x1130, 0x70ac, 0x9005, 0x1168, 0x080c, - 0xbc7a, 0x0050, 0x080c, 0xbc7a, 0x70d8, 0xd09c, 0x1128, 0x70ac, - 0x9005, 0x0110, 0x080c, 0x5e89, 0x70e3, 0x0000, 0x70df, 0x0000, - 0x70a3, 0x0000, 0x080c, 0x29fa, 0x0228, 0x2011, 0x0101, 0x2204, - 0xc0c4, 0x2012, 0x72d8, 0x080c, 0x72e5, 0x1178, 0x9016, 0x0016, - 0x080c, 0x27b7, 0x2019, 0x194a, 0x211a, 0x001e, 0x705b, 0xffff, - 0x705f, 0x00ef, 0x707f, 0x0000, 0x0020, 0x2019, 0x194a, 0x201b, + 0x080c, 0x6865, 0x1128, 0xd0a4, 0x0118, 0x2204, 0xc0fd, 0x2012, + 0x080c, 0x682b, 0x0120, 0x7a0c, 0xc2b4, 0x7a0e, 0x00a8, 0x707b, + 0x0000, 0x080c, 0x7351, 0x1130, 0x70ac, 0x9005, 0x1168, 0x080c, + 0xc617, 0x0050, 0x080c, 0xc617, 0x70d8, 0xd09c, 0x1128, 0x70ac, + 0x9005, 0x0110, 0x080c, 0x5f46, 0x70e3, 0x0000, 0x70df, 0x0000, + 0x70a3, 0x0000, 0x080c, 0x2a63, 0x0228, 0x2011, 0x0101, 0x2204, + 0xc0c4, 0x2012, 0x72d8, 0x080c, 0x7351, 0x1178, 0x9016, 0x0016, + 0x080c, 0x2820, 0x2019, 0x1949, 0x211a, 0x001e, 0x705b, 0xffff, + 0x705f, 0x00ef, 0x707f, 0x0000, 0x0020, 0x2019, 0x1949, 0x201b, 0x0000, 0x2079, 0x185e, 0x7804, 0xd0ac, 0x0108, 0xc295, 0x72da, - 0x080c, 0x72e5, 0x0118, 0x9296, 0x0004, 0x0548, 0x2011, 0x0001, - 0x080c, 0xb965, 0x70a7, 0x0000, 0x70ab, 0xffff, 0x7003, 0x0002, + 0x080c, 0x7351, 0x0118, 0x9296, 0x0004, 0x0548, 0x2011, 0x0001, + 0x080c, 0xc1dd, 0x70a7, 0x0000, 0x70ab, 0xffff, 0x7003, 0x0002, 0x2079, 0x0100, 0x7827, 0x0003, 0x7828, 0x9085, 0x0003, 0x782a, - 0x00fe, 0x080c, 0x2e5f, 0x2011, 0x0005, 0x080c, 0x99d6, 0x080c, - 0x8c37, 0x080c, 0x72e5, 0x0148, 0x00c6, 0x2061, 0x0100, 0x0016, - 0x080c, 0x27b7, 0x61e2, 0x001e, 0x00ce, 0x012e, 0x0420, 0x70a7, + 0x00fe, 0x080c, 0x2ed6, 0x2011, 0x0005, 0x080c, 0x9ca7, 0x080c, + 0x8e38, 0x080c, 0x7351, 0x0148, 0x00c6, 0x2061, 0x0100, 0x0016, + 0x080c, 0x2820, 0x61e2, 0x001e, 0x00ce, 0x012e, 0x0420, 0x70a7, 0x0000, 0x70ab, 0xffff, 0x7003, 0x0002, 0x00f6, 0x2079, 0x0100, 0x7827, 0x0003, 0x7828, 0x9085, 0x0003, 0x782a, 0x00fe, 0x2011, - 0x0005, 0x080c, 0x99d6, 0x080c, 0x8c37, 0x080c, 0x72e5, 0x0148, - 0x00c6, 0x2061, 0x0100, 0x0016, 0x080c, 0x27b7, 0x61e2, 0x001e, - 0x00ce, 0x00fe, 0x012e, 0x0005, 0x00c6, 0x00b6, 0x080c, 0x72e5, - 0x1118, 0x20a9, 0x0800, 0x0010, 0x20a9, 0x0782, 0x080c, 0x72e5, + 0x0005, 0x080c, 0x9ca7, 0x080c, 0x8e38, 0x080c, 0x7351, 0x0148, + 0x00c6, 0x2061, 0x0100, 0x0016, 0x080c, 0x2820, 0x61e2, 0x001e, + 0x00ce, 0x00fe, 0x012e, 0x0005, 0x00c6, 0x00b6, 0x080c, 0x7351, + 0x1118, 0x20a9, 0x0800, 0x0010, 0x20a9, 0x0782, 0x080c, 0x7351, 0x1110, 0x900e, 0x0010, 0x2009, 0x007e, 0x86ff, 0x0138, 0x9180, - 0x1000, 0x2004, 0x905d, 0x0110, 0xb800, 0xd0bc, 0x090c, 0x3162, + 0x1000, 0x2004, 0x905d, 0x0110, 0xb800, 0xd0bc, 0x090c, 0x31fe, 0x8108, 0x1f04, 0x0ac5, 0x707b, 0x0000, 0x707c, 0x9084, 0x00ff, 0x707e, 0x70af, 0x0000, 0x00be, 0x00ce, 0x0005, 0x00b6, 0x0126, 0x2091, 0x8000, 0x7000, 0x9086, 0x0002, 0x1904, 0x0b9b, 0x70a8, - 0x9086, 0xffff, 0x0130, 0x080c, 0x2e5f, 0x080c, 0x8c37, 0x0804, + 0x9086, 0xffff, 0x0130, 0x080c, 0x2ed6, 0x080c, 0x8e38, 0x0804, 0x0b9b, 0x70d8, 0xd0ac, 0x1110, 0xd09c, 0x0558, 0xd084, 0x0548, 0x0006, 0x2001, 0x0103, 0x2003, 0x002b, 0x000e, 0xd08c, 0x0508, - 0x080c, 0x31c5, 0x11d0, 0x70dc, 0x9086, 0xffff, 0x01b0, 0x080c, - 0x2fd8, 0x080c, 0x8c37, 0x70d8, 0xd094, 0x1904, 0x0b9b, 0x2011, - 0x0001, 0x080c, 0xbef8, 0x0110, 0x2011, 0x0003, 0x901e, 0x080c, - 0x3012, 0x080c, 0x8c37, 0x0804, 0x0b9b, 0x70e0, 0x9005, 0x1904, + 0x080c, 0x3261, 0x11d0, 0x70dc, 0x9086, 0xffff, 0x01b0, 0x080c, + 0x306e, 0x080c, 0x8e38, 0x70d8, 0xd094, 0x1904, 0x0b9b, 0x2011, + 0x0001, 0x080c, 0xc8ce, 0x0110, 0x2011, 0x0003, 0x901e, 0x080c, + 0x30a8, 0x080c, 0x8e38, 0x0804, 0x0b9b, 0x70e0, 0x9005, 0x1904, 0x0b9b, 0x70a4, 0x9005, 0x1904, 0x0b9b, 0x70d8, 0xd0a4, 0x0118, - 0xd0b4, 0x0904, 0x0b9b, 0x080c, 0x6704, 0x1904, 0x0b9b, 0x080c, - 0x6757, 0x1904, 0x0b9b, 0x080c, 0x673e, 0x01c0, 0x0156, 0x00c6, - 0x20a9, 0x007f, 0x900e, 0x0016, 0x080c, 0x6411, 0x1118, 0xb800, + 0xd0b4, 0x0904, 0x0b9b, 0x080c, 0x682b, 0x1904, 0x0b9b, 0x080c, + 0x687e, 0x1904, 0x0b9b, 0x080c, 0x6865, 0x01c0, 0x0156, 0x00c6, + 0x20a9, 0x007f, 0x900e, 0x0016, 0x080c, 0x64fc, 0x1118, 0xb800, 0xd0ec, 0x1138, 0x001e, 0x8108, 0x1f04, 0x0b3b, 0x00ce, 0x015e, 0x0028, 0x001e, 0x00ce, 0x015e, 0x0804, 0x0b9b, 0x0006, 0x2001, - 0x0103, 0x2003, 0x006b, 0x000e, 0x2011, 0x1990, 0x080c, 0x0f89, - 0x2011, 0x19aa, 0x080c, 0x0f89, 0x7030, 0xc08c, 0x7032, 0x7003, - 0x0003, 0x70ab, 0xffff, 0x080c, 0x0ecd, 0x9006, 0x080c, 0x264c, - 0x080c, 0x31c5, 0x0118, 0x080c, 0x4c5a, 0x0050, 0x0036, 0x0046, - 0x2019, 0xffff, 0x2021, 0x0006, 0x080c, 0x4c74, 0x004e, 0x003e, - 0x00f6, 0x2079, 0x0100, 0x080c, 0x7308, 0x0150, 0x080c, 0x72e5, + 0x0103, 0x2003, 0x006b, 0x000e, 0x2011, 0x1990, 0x080c, 0x0f95, + 0x2011, 0x19aa, 0x080c, 0x0f95, 0x7030, 0xc08c, 0x7032, 0x7003, + 0x0003, 0x70ab, 0xffff, 0x080c, 0x0e75, 0x9006, 0x080c, 0x26b1, + 0x080c, 0x3261, 0x0118, 0x080c, 0x4d0a, 0x0050, 0x0036, 0x0046, + 0x2019, 0xffff, 0x2021, 0x0006, 0x080c, 0x4d24, 0x004e, 0x003e, + 0x00f6, 0x2079, 0x0100, 0x080c, 0x7374, 0x0150, 0x080c, 0x7351, 0x7828, 0x0118, 0x9084, 0xe1ff, 0x0010, 0x9084, 0xffdf, 0x782a, 0x00fe, 0x2001, 0x19c5, 0x2004, 0x9086, 0x0005, 0x1120, 0x2011, - 0x0000, 0x080c, 0x99d6, 0x2011, 0x0000, 0x080c, 0x99e0, 0x080c, - 0x8c37, 0x080c, 0x8d06, 0x012e, 0x00be, 0x0005, 0x0016, 0x0046, + 0x0000, 0x080c, 0x9ca7, 0x2011, 0x0000, 0x080c, 0x9cb1, 0x080c, + 0x8e38, 0x080c, 0x8f0e, 0x012e, 0x00be, 0x0005, 0x0016, 0x0046, 0x00f6, 0x0126, 0x2091, 0x8000, 0x2079, 0x0100, 0x7904, 0x918c, - 0xfffd, 0x7906, 0x2009, 0x00f7, 0x080c, 0x5e72, 0x7940, 0x918c, + 0xfffd, 0x7906, 0x2009, 0x00f7, 0x080c, 0x5f2f, 0x7940, 0x918c, 0x0010, 0x7942, 0x7924, 0xd1b4, 0x0110, 0x7827, 0x0040, 0xd19c, 0x0110, 0x7827, 0x0008, 0x0006, 0x0036, 0x0156, 0x7954, 0xd1ac, 0x1904, 0x0c2b, 0x2001, 0x1984, 0x2004, 0x9005, 0x1518, 0x080c, - 0x2a75, 0x1148, 0x2001, 0x0001, 0x080c, 0x29dd, 0x2001, 0x0001, - 0x080c, 0x29c0, 0x00b8, 0x080c, 0x2a7d, 0x1138, 0x9006, 0x080c, - 0x29dd, 0x9006, 0x080c, 0x29c0, 0x0068, 0x080c, 0x2a85, 0x1d50, - 0x2001, 0x1974, 0x2004, 0xd0fc, 0x0108, 0x0020, 0x080c, 0x27eb, - 0x0804, 0x0d0a, 0x080c, 0x72f6, 0x0148, 0x080c, 0x7308, 0x1118, - 0x080c, 0x75eb, 0x0050, 0x080c, 0x72ed, 0x0dd0, 0x080c, 0x75e6, - 0x080c, 0x75dc, 0x080c, 0x7212, 0x0058, 0x080c, 0x72e5, 0x0140, - 0x2009, 0x00f8, 0x080c, 0x5e72, 0x7843, 0x0090, 0x7843, 0x0010, - 0x20a9, 0x09c4, 0x7820, 0xd09c, 0x1138, 0x080c, 0x72e5, 0x0138, - 0x7824, 0xd0ac, 0x1904, 0x0d0f, 0x1f04, 0x0c0a, 0x0070, 0x7824, - 0x080c, 0x72ff, 0x0118, 0xd0ac, 0x1904, 0x0d0f, 0x9084, 0x1800, - 0x0d98, 0x7003, 0x0001, 0x0804, 0x0d0f, 0x2001, 0x0001, 0x080c, - 0x264c, 0x0804, 0x0d22, 0x2001, 0x1984, 0x2004, 0x9005, 0x1518, - 0x080c, 0x2a75, 0x1148, 0x2001, 0x0001, 0x080c, 0x29dd, 0x2001, - 0x0001, 0x080c, 0x29c0, 0x00b8, 0x080c, 0x2a7d, 0x1138, 0x9006, - 0x080c, 0x29dd, 0x9006, 0x080c, 0x29c0, 0x0068, 0x080c, 0x2a85, + 0x2ade, 0x1148, 0x2001, 0x0001, 0x080c, 0x2a46, 0x2001, 0x0001, + 0x080c, 0x2a29, 0x00b8, 0x080c, 0x2ae6, 0x1138, 0x9006, 0x080c, + 0x2a46, 0x9006, 0x080c, 0x2a29, 0x0068, 0x080c, 0x2aee, 0x1d50, + 0x2001, 0x1974, 0x2004, 0xd0fc, 0x0108, 0x0020, 0x080c, 0x2854, + 0x0804, 0x0d0b, 0x080c, 0x7362, 0x0148, 0x080c, 0x7374, 0x1118, + 0x080c, 0x765b, 0x0050, 0x080c, 0x7359, 0x0dd0, 0x080c, 0x7656, + 0x080c, 0x764c, 0x080c, 0x727e, 0x0058, 0x080c, 0x7351, 0x0140, + 0x2009, 0x00f8, 0x080c, 0x5f2f, 0x7843, 0x0090, 0x7843, 0x0010, + 0x20a9, 0x09c4, 0x7820, 0xd09c, 0x1138, 0x080c, 0x7351, 0x0138, + 0x7824, 0xd0ac, 0x1904, 0x0d10, 0x1f04, 0x0c0a, 0x0070, 0x7824, + 0x080c, 0x736b, 0x0118, 0xd0ac, 0x1904, 0x0d10, 0x9084, 0x1800, + 0x0d98, 0x7003, 0x0001, 0x0804, 0x0d10, 0x2001, 0x0001, 0x080c, + 0x26b1, 0x0804, 0x0d23, 0x2001, 0x1984, 0x2004, 0x9005, 0x1518, + 0x080c, 0x2ade, 0x1148, 0x2001, 0x0001, 0x080c, 0x2a46, 0x2001, + 0x0001, 0x080c, 0x2a29, 0x00b8, 0x080c, 0x2ae6, 0x1138, 0x9006, + 0x080c, 0x2a46, 0x9006, 0x080c, 0x2a29, 0x0068, 0x080c, 0x2aee, 0x1d50, 0x2001, 0x1974, 0x2004, 0xd0fc, 0x0108, 0x0020, 0x080c, - 0x27eb, 0x0804, 0x0d0a, 0x7850, 0x9085, 0x0040, 0x7852, 0x7938, - 0x7850, 0x9084, 0xfbcf, 0x7852, 0x080c, 0x2a8d, 0x9085, 0x2000, - 0x7852, 0x793a, 0x20a9, 0x0046, 0x1d04, 0x0c64, 0x080c, 0x8454, + 0x2854, 0x0804, 0x0d0b, 0x7850, 0x9085, 0x0040, 0x7852, 0x7938, + 0x7850, 0x9084, 0xfbcf, 0x7852, 0x080c, 0x2af6, 0x9085, 0x2000, + 0x7852, 0x793a, 0x20a9, 0x0046, 0x1d04, 0x0c64, 0x080c, 0x85c0, 0x1f04, 0x0c64, 0x7850, 0x9085, 0x0400, 0x9084, 0xdfbf, 0x7852, - 0x793a, 0x080c, 0x72f6, 0x0148, 0x080c, 0x7308, 0x1118, 0x080c, - 0x75eb, 0x0050, 0x080c, 0x72ed, 0x0dd0, 0x080c, 0x75e6, 0x080c, - 0x75dc, 0x080c, 0x7212, 0x0020, 0x2009, 0x00f8, 0x080c, 0x5e72, + 0x793a, 0x080c, 0x7362, 0x0148, 0x080c, 0x7374, 0x1118, 0x080c, + 0x765b, 0x0050, 0x080c, 0x7359, 0x0dd0, 0x080c, 0x7656, 0x080c, + 0x764c, 0x080c, 0x727e, 0x0020, 0x2009, 0x00f8, 0x080c, 0x5f2f, 0x20a9, 0x0028, 0xa001, 0x1f04, 0x0c8a, 0x7850, 0x9085, 0x1400, - 0x7852, 0x080c, 0x72e5, 0x0120, 0x7843, 0x0090, 0x7843, 0x0010, - 0x2021, 0xe678, 0x2019, 0xea60, 0x0d0c, 0x8454, 0x7820, 0xd09c, - 0x1580, 0x080c, 0x72e5, 0x0904, 0x0cef, 0x7824, 0xd0ac, 0x1904, - 0x0d0f, 0x080c, 0x7308, 0x1528, 0x0046, 0x2021, 0x0320, 0x8421, - 0x1df0, 0x004e, 0x7827, 0x1800, 0x080c, 0x2a8d, 0x7824, 0x9084, - 0x1800, 0x1160, 0x9484, 0x0fff, 0x1138, 0x2001, 0x1810, 0x2004, - 0xd0fc, 0x0110, 0x080c, 0x0d34, 0x8421, 0x1158, 0x1d04, 0x0cca, - 0x080c, 0x8454, 0x080c, 0x75e6, 0x080c, 0x75dc, 0x7003, 0x0001, - 0x04f0, 0x8319, 0x1948, 0x1d04, 0x0cd7, 0x080c, 0x8454, 0x2009, - 0x1977, 0x2104, 0x9005, 0x0118, 0x8001, 0x200a, 0x1178, 0x200b, - 0x000a, 0x7827, 0x0048, 0x20a9, 0x0002, 0x080c, 0x2a6e, 0x7924, - 0x080c, 0x2a8d, 0xd19c, 0x0110, 0x080c, 0x29ae, 0x00d8, 0x080c, - 0x72f6, 0x1140, 0x94a2, 0x03e8, 0x1128, 0x080c, 0x72bd, 0x7003, - 0x0001, 0x00a8, 0x7827, 0x1800, 0x080c, 0x2a8d, 0x7824, 0x080c, - 0x72ff, 0x0110, 0xd0ac, 0x1158, 0x9084, 0x1800, 0x0950, 0x7003, - 0x0001, 0x0028, 0x2001, 0x0001, 0x080c, 0x264c, 0x0078, 0x2009, - 0x180c, 0x210c, 0xd19c, 0x1120, 0x7904, 0x918d, 0x0002, 0x7906, - 0x7827, 0x0048, 0x7828, 0x9085, 0x0028, 0x782a, 0x7850, 0x9085, - 0x0400, 0x7852, 0x2001, 0x1984, 0x2003, 0x0000, 0x9006, 0x78f2, - 0x015e, 0x003e, 0x000e, 0x080c, 0x55b6, 0x090c, 0x0e64, 0x012e, - 0x00fe, 0x004e, 0x001e, 0x0005, 0x0006, 0x0016, 0x0036, 0x0046, - 0x00b6, 0x00c6, 0x00d6, 0x00e6, 0x00f6, 0x0156, 0x0069, 0x0d0c, - 0x8454, 0x015e, 0x00fe, 0x00ee, 0x00de, 0x00ce, 0x00be, 0x004e, - 0x003e, 0x001e, 0x000e, 0x0005, 0x00e6, 0x2071, 0x189f, 0x7004, - 0x9086, 0x0001, 0x1110, 0x080c, 0x32f3, 0x00ee, 0x0005, 0x0005, - 0x2a70, 0x2061, 0x1988, 0x2063, 0x0003, 0x6007, 0x0003, 0x600b, - 0x001a, 0x600f, 0x0107, 0x2001, 0x1959, 0x900e, 0x2102, 0x7192, - 0x2001, 0x0100, 0x2004, 0x9082, 0x0002, 0x0218, 0x705b, 0xffff, - 0x0008, 0x715a, 0x7063, 0xffff, 0x717a, 0x717e, 0x080c, 0xbc7a, - 0x2061, 0x1949, 0x6003, 0x0909, 0x6106, 0x600b, 0x8800, 0x600f, - 0x0200, 0x6013, 0x00ff, 0x6017, 0x000f, 0x611a, 0x601f, 0x07d0, - 0x2061, 0x1951, 0x6003, 0x8000, 0x6106, 0x610a, 0x600f, 0x0200, - 0x6013, 0x00ff, 0x6116, 0x601b, 0x0001, 0x611e, 0x2061, 0x1965, - 0x6003, 0x514c, 0x6007, 0x4f47, 0x600b, 0x4943, 0x600f, 0x2020, - 0x2001, 0x182b, 0x2102, 0x0005, 0x9016, 0x080c, 0x6411, 0x1178, - 0xb804, 0x90c4, 0x00ff, 0x98c6, 0x0006, 0x0128, 0x90c4, 0xff00, - 0x98c6, 0x0600, 0x1120, 0x9186, 0x0080, 0x0108, 0x8210, 0x8108, - 0x9186, 0x0800, 0x1d50, 0x2208, 0x0005, 0x2091, 0x8000, 0x2079, - 0x0000, 0x000e, 0x00f6, 0x0010, 0x2091, 0x8000, 0x0e04, 0x0dc6, - 0x0006, 0x0016, 0x2001, 0x8002, 0x0006, 0x2079, 0x0000, 0x000e, - 0x7882, 0x7836, 0x001e, 0x798e, 0x000e, 0x788a, 0x000e, 0x7886, - 0x3900, 0x789a, 0x00d6, 0x2069, 0x0300, 0x6818, 0x78ae, 0x681c, - 0x78b2, 0x2001, 0x19e5, 0x2004, 0x78b6, 0x2001, 0x1a61, 0x2004, - 0x78ba, 0x6808, 0x78be, 0x00de, 0x7833, 0x0012, 0x2091, 0x5000, - 0x0156, 0x00d6, 0x0036, 0x0026, 0x2079, 0x0300, 0x2069, 0x1a84, - 0x7a08, 0x226a, 0x2069, 0x1a85, 0x7a18, 0x226a, 0x8d68, 0x7a1c, - 0x226a, 0x782c, 0x2019, 0x1a92, 0x201a, 0x2019, 0x1a95, 0x9016, - 0x7808, 0xd09c, 0x0168, 0x7820, 0x201a, 0x8210, 0x8318, 0x9386, - 0x1a9e, 0x0108, 0x0ca8, 0x7808, 0xd09c, 0x0110, 0x2011, 0xdead, - 0x2019, 0x1a93, 0x782c, 0x201a, 0x8318, 0x221a, 0x7803, 0x0000, - 0x2069, 0x1a64, 0x901e, 0x20a9, 0x0020, 0x7b26, 0x7a28, 0x226a, - 0x8d68, 0x8318, 0x1f04, 0x0e25, 0x002e, 0x003e, 0x00de, 0x015e, - 0x2079, 0x1800, 0x7803, 0x0005, 0x2091, 0x4080, 0x2001, 0x0089, - 0x2004, 0xd084, 0x0188, 0x2001, 0x19f8, 0x2004, 0x9005, 0x0130, - 0x2001, 0x008b, 0x2004, 0x9084, 0x8004, 0x0dd0, 0x2001, 0x008a, - 0x2003, 0x0002, 0x2003, 0x1001, 0x080c, 0x55b6, 0x1110, 0x080c, - 0x0e9b, 0x0cd0, 0x0005, 0x918c, 0x03ff, 0x2001, 0x0003, 0x2004, - 0x9084, 0x0600, 0x1118, 0x918d, 0x2800, 0x0010, 0x918d, 0x2000, - 0x2001, 0x017f, 0x2102, 0x0005, 0x00f6, 0x0006, 0x2079, 0x1826, - 0x2f04, 0x8000, 0x207a, 0x080c, 0x2a85, 0x1150, 0x0006, 0x2001, - 0x1974, 0x2004, 0xd0fc, 0x000e, 0x1118, 0x9082, 0x7530, 0x0010, - 0x9082, 0x000f, 0x0258, 0x9006, 0x207a, 0x2079, 0x1829, 0x2f04, - 0x9084, 0x0001, 0x9086, 0x0001, 0x207a, 0x0090, 0x2079, 0x1829, - 0x2f7c, 0x8fff, 0x1138, 0x0026, 0x2011, 0x0080, 0x080c, 0x0ee1, - 0x002e, 0x0030, 0x0026, 0x2011, 0x0000, 0x080c, 0x0ee1, 0x002e, - 0x000e, 0x00fe, 0x0005, 0x0026, 0x0126, 0x2011, 0x0080, 0x080c, - 0x0ee1, 0x20a9, 0x0fff, 0x080c, 0x0f02, 0x2011, 0x0040, 0x04c9, - 0x20a9, 0x0fff, 0x080c, 0x0f02, 0x0c80, 0x2011, 0x0040, 0x0488, - 0x2011, 0x0080, 0x0470, 0x0005, 0x0026, 0x70eb, 0x0000, 0x04b1, - 0x1148, 0x080c, 0x2a85, 0x1118, 0x2011, 0x8484, 0x0058, 0x2011, - 0x8282, 0x0040, 0x080c, 0x2a85, 0x1118, 0x2011, 0xcdc5, 0x0010, - 0x2011, 0xcac2, 0x0441, 0x002e, 0x0005, 0x080c, 0x55b6, 0x1140, - 0x0026, 0x2001, 0x1800, 0x2004, 0x9084, 0x0007, 0x0013, 0x002e, - 0x0005, 0x0ecc, 0x0eb0, 0x0eb0, 0x0ead, 0x0e64, 0x0eb0, 0x0eb0, - 0x0e64, 0x0016, 0x3b08, 0x3a00, 0x9104, 0x918d, 0x00c0, 0x21d8, - 0x9084, 0xff3f, 0x9205, 0x20d0, 0x001e, 0x0005, 0x2001, 0x1839, - 0x2004, 0xd0dc, 0x0005, 0x9e86, 0x1800, 0x190c, 0x0dc4, 0x70e4, - 0xd0e4, 0x0108, 0xc2e5, 0x72e6, 0xd0e4, 0x1118, 0x9294, 0x00c0, - 0x0c01, 0x0005, 0x1d04, 0x0f02, 0x2091, 0x6000, 0x1f04, 0x0f02, - 0x0005, 0x890e, 0x810e, 0x810f, 0x9194, 0x003f, 0x918c, 0xffc0, - 0x0005, 0x0006, 0x2200, 0x914d, 0x894f, 0x894d, 0x894d, 0x000e, - 0x0005, 0x01d6, 0x0146, 0x0036, 0x0096, 0x2061, 0x188e, 0x600b, - 0x0000, 0x600f, 0x0000, 0x6003, 0x0000, 0x6007, 0x0000, 0x2009, - 0xffc0, 0x2105, 0x0006, 0x2001, 0xaaaa, 0x200f, 0x2019, 0x5555, - 0x9016, 0x2049, 0x0bff, 0xab02, 0xa001, 0xa001, 0xa800, 0x9306, - 0x1138, 0x2105, 0x9306, 0x0120, 0x8210, 0x99c8, 0x0400, 0x0c98, - 0x000e, 0x200f, 0x2001, 0x189e, 0x928a, 0x000e, 0x1638, 0x928a, - 0x0006, 0x2011, 0x0006, 0x1210, 0x2011, 0x0000, 0x2202, 0x9006, - 0x2008, 0x82ff, 0x01b0, 0x8200, 0x600a, 0x600f, 0xffff, 0x6003, - 0x0002, 0x6007, 0x0000, 0x0026, 0x2019, 0x0010, 0x9280, 0x0001, - 0x20e8, 0x21a0, 0x21a8, 0x4104, 0x8319, 0x1de0, 0x8211, 0x1da0, - 0x002e, 0x009e, 0x003e, 0x014e, 0x01de, 0x0005, 0x2011, 0x000e, - 0x08e8, 0x0016, 0x0026, 0x0096, 0x3348, 0x080c, 0x0f09, 0x2100, - 0x9300, 0x2098, 0x22e0, 0x009e, 0x002e, 0x001e, 0x0036, 0x3518, - 0x20a9, 0x0001, 0x4002, 0x8007, 0x4004, 0x8319, 0x1dd8, 0x003e, - 0x0005, 0x20e9, 0x0001, 0x71b4, 0x81ff, 0x11c0, 0x9006, 0x2009, - 0x0200, 0x20a9, 0x0002, 0x9298, 0x0018, 0x23a0, 0x4001, 0x2009, - 0x0700, 0x20a9, 0x0002, 0x9298, 0x0008, 0x23a0, 0x4001, 0x7078, - 0x8007, 0x717c, 0x810f, 0x20a9, 0x0002, 0x4001, 0x9298, 0x000c, - 0x23a0, 0x900e, 0x080c, 0x0da4, 0x2001, 0x0000, 0x810f, 0x20a9, - 0x0002, 0x4001, 0x0005, 0x89ff, 0x0140, 0xa804, 0xa807, 0x0000, - 0x0006, 0x080c, 0x1033, 0x009e, 0x0cb0, 0x0005, 0x00e6, 0x2071, - 0x1800, 0x080c, 0x10ac, 0x090c, 0x0dc4, 0x00ee, 0x0005, 0x0086, - 0x00e6, 0x0006, 0x0026, 0x0036, 0x0126, 0x2091, 0x8000, 0x00c9, - 0x2071, 0x1800, 0x73bc, 0x702c, 0x9016, 0x9045, 0x0158, 0x8210, - 0x9906, 0x090c, 0x0dc4, 0x2300, 0x9202, 0x0120, 0x1a0c, 0x0dc4, - 0xa000, 0x0c98, 0x012e, 0x003e, 0x002e, 0x000e, 0x00ee, 0x008e, - 0x0005, 0x0086, 0x00e6, 0x0006, 0x0126, 0x2091, 0x8000, 0x2071, - 0x1911, 0x7010, 0x9005, 0x0140, 0x7018, 0x9045, 0x0128, 0x9906, - 0x090c, 0x0dc4, 0xa000, 0x0cc8, 0x012e, 0x000e, 0x00ee, 0x008e, - 0x0005, 0x00e6, 0x2071, 0x1800, 0x0126, 0x2091, 0x8000, 0x70bc, - 0x8001, 0x0270, 0x70be, 0x702c, 0x2048, 0x9085, 0x0001, 0xa800, - 0x702e, 0xa803, 0x0000, 0xa807, 0x0000, 0x012e, 0x00ee, 0x0005, - 0x904e, 0x0cd8, 0x00e6, 0x0126, 0x2091, 0x8000, 0x2071, 0x1800, - 0x70bc, 0x90ca, 0x0040, 0x0268, 0x8001, 0x70be, 0x702c, 0x2048, - 0xa800, 0x702e, 0xa803, 0x0000, 0xa807, 0x0000, 0x012e, 0x00ee, - 0x0005, 0x904e, 0x0cd8, 0x00e6, 0x0126, 0x2091, 0x8000, 0x0016, - 0x890e, 0x810e, 0x810f, 0x9184, 0x003f, 0xa862, 0x9184, 0xffc0, - 0xa85e, 0x001e, 0x0020, 0x00e6, 0x0126, 0x2091, 0x8000, 0x2071, - 0x1800, 0x702c, 0xa802, 0x2900, 0x702e, 0x70bc, 0x8000, 0x70be, - 0x080c, 0x8245, 0x012e, 0x00ee, 0x0005, 0x2071, 0x1800, 0x9026, - 0x2009, 0x0000, 0x2049, 0x0400, 0x2900, 0x702e, 0x8940, 0x2800, - 0xa802, 0xa95e, 0xa863, 0x0001, 0x8420, 0x9886, 0x0440, 0x0120, - 0x2848, 0x9188, 0x0040, 0x0c90, 0x2071, 0x188e, 0x7000, 0x9005, - 0x11a0, 0x2001, 0x04d4, 0xa802, 0x2048, 0x2009, 0x3500, 0x8940, - 0x2800, 0xa802, 0xa95e, 0xa863, 0x0001, 0x8420, 0x9886, 0x0800, - 0x0120, 0x2848, 0x9188, 0x0040, 0x0c90, 0x2071, 0x188e, 0x7104, - 0x7200, 0x82ff, 0x01d0, 0x7308, 0x8318, 0x831f, 0x831b, 0x831b, - 0x7312, 0x8319, 0x2001, 0x0800, 0xa802, 0x2048, 0x8900, 0xa802, - 0x2040, 0xa95e, 0xaa62, 0x8420, 0x2300, 0x9906, 0x0130, 0x2848, - 0x9188, 0x0040, 0x9291, 0x0000, 0x0c88, 0xa803, 0x0000, 0x2071, - 0x1800, 0x74ba, 0x74be, 0x0005, 0x00e6, 0x0016, 0x9984, 0xfc00, - 0x01e8, 0x908c, 0xf800, 0x1168, 0x9982, 0x0400, 0x02b8, 0x9982, - 0x0440, 0x0278, 0x9982, 0x04d4, 0x0288, 0x9982, 0x0800, 0x1270, - 0x0040, 0x9982, 0x0800, 0x0250, 0x2071, 0x188e, 0x7010, 0x9902, - 0x1228, 0x9085, 0x0001, 0x001e, 0x00ee, 0x0005, 0x9006, 0x0cd8, - 0x00e6, 0x2071, 0x19f7, 0x7007, 0x0000, 0x9006, 0x701e, 0x7022, - 0x7002, 0x2071, 0x0000, 0x7010, 0x9085, 0x8044, 0x7012, 0x2071, - 0x0080, 0x9006, 0x20a9, 0x0040, 0x7022, 0x1f04, 0x10e4, 0x702b, - 0x0020, 0x00ee, 0x0005, 0x0126, 0x2091, 0x8000, 0x00e6, 0xa073, - 0x0000, 0x2071, 0x19f7, 0x701c, 0x9088, 0x1a01, 0x280a, 0x8000, - 0x9084, 0x003f, 0x701e, 0x7120, 0x9106, 0x090c, 0x0dc4, 0x7004, - 0x9005, 0x1128, 0x00f6, 0x2079, 0x0080, 0x00a9, 0x00fe, 0x00ee, - 0x012e, 0x0005, 0x0126, 0x2091, 0x8000, 0x00e6, 0x2071, 0x19f7, - 0x7004, 0x9005, 0x1128, 0x00f6, 0x2079, 0x0080, 0x0021, 0x00fe, - 0x00ee, 0x012e, 0x0005, 0x7004, 0x9086, 0x0000, 0x1110, 0x7007, - 0x0006, 0x7000, 0x0002, 0x112d, 0x112b, 0x112b, 0x112b, 0x12a7, - 0x12a7, 0x12a7, 0x12a7, 0x080c, 0x0dc4, 0x701c, 0x7120, 0x9106, - 0x1148, 0x792c, 0x9184, 0x0001, 0x1120, 0xd1fc, 0x1110, 0x7007, - 0x0000, 0x0005, 0x0096, 0x9180, 0x1a01, 0x2004, 0x700a, 0x2048, - 0x8108, 0x918c, 0x003f, 0x7122, 0x782b, 0x0026, 0xa890, 0x7802, - 0xa894, 0x7806, 0xa898, 0x780a, 0xa89c, 0x780e, 0xa87c, 0x700e, - 0xa874, 0x7016, 0xa878, 0x701a, 0xa86c, 0x009e, 0xd084, 0x0120, - 0x7007, 0x0001, 0x0029, 0x0005, 0x7007, 0x0002, 0x00b1, 0x0005, - 0x0016, 0x0026, 0x710c, 0x2011, 0x0040, 0x9182, 0x0040, 0x1210, - 0x2110, 0x9006, 0x700e, 0x7212, 0x8203, 0x7812, 0x782b, 0x0020, - 0x782b, 0x0041, 0x002e, 0x001e, 0x0005, 0x0016, 0x0026, 0x0136, - 0x0146, 0x0156, 0x7014, 0x20e0, 0x7018, 0x2098, 0x20e9, 0x0000, - 0x20a1, 0x0088, 0x782b, 0x0026, 0x710c, 0x2011, 0x0040, 0x9182, - 0x0040, 0x1210, 0x2110, 0x9006, 0x700e, 0x22a8, 0x4006, 0x8203, - 0x7812, 0x782b, 0x0020, 0x3300, 0x701a, 0x782b, 0x0001, 0x015e, - 0x014e, 0x013e, 0x002e, 0x001e, 0x0005, 0x0016, 0x2009, 0x19f7, - 0x2104, 0xc095, 0x200a, 0x080c, 0x110a, 0x001e, 0x0005, 0x0016, - 0x00e6, 0x2071, 0x19f7, 0x00f6, 0x2079, 0x0080, 0x792c, 0xd1bc, - 0x190c, 0x0dbd, 0x782b, 0x0002, 0xd1fc, 0x0120, 0x918c, 0x0700, - 0x7004, 0x0023, 0x00fe, 0x00ee, 0x001e, 0x0005, 0x111b, 0x11c5, - 0x11f9, 0x0dc4, 0x0dc4, 0x12b3, 0x0dc4, 0x918c, 0x0700, 0x1550, - 0x0136, 0x0146, 0x0156, 0x7014, 0x20e8, 0x7018, 0x20a0, 0x20e1, - 0x0000, 0x2099, 0x0088, 0x782b, 0x0040, 0x7010, 0x20a8, 0x4005, - 0x3400, 0x701a, 0x015e, 0x014e, 0x013e, 0x700c, 0x9005, 0x0578, - 0x7800, 0x7802, 0x7804, 0x7806, 0x080c, 0x1160, 0x0005, 0x7008, - 0x0096, 0x2048, 0xa873, 0x0100, 0x009e, 0x7007, 0x0000, 0x080c, - 0x111b, 0x0005, 0x7008, 0x0096, 0x2048, 0xa873, 0x0200, 0x009e, - 0x0ca0, 0x918c, 0x0700, 0x1150, 0x700c, 0x9005, 0x0180, 0x7800, - 0x7802, 0x7804, 0x7806, 0x080c, 0x1175, 0x0005, 0x7008, 0x0096, - 0x2048, 0xa873, 0x0200, 0x009e, 0x7007, 0x0000, 0x0080, 0x0096, - 0x7008, 0x2048, 0x7800, 0xa892, 0x7804, 0xa896, 0x7808, 0xa89a, - 0x780c, 0xa89e, 0xa873, 0x0100, 0x009e, 0x7007, 0x0000, 0x0096, - 0x00d6, 0x7008, 0x2048, 0x2001, 0x18ba, 0x2004, 0x9906, 0x1128, - 0xa8a0, 0x080f, 0x00de, 0x009e, 0x00a0, 0x00de, 0x009e, 0x0096, - 0x00d6, 0x7008, 0x2048, 0x0081, 0x0150, 0xa8a0, 0x0086, 0x2940, - 0x080f, 0x008e, 0x00de, 0x009e, 0x080c, 0x110a, 0x0005, 0x00de, - 0x009e, 0x080c, 0x110a, 0x0005, 0xa8ac, 0xd08c, 0x0005, 0x0096, - 0xa0a4, 0x904d, 0x090c, 0x0dc4, 0xa070, 0x908e, 0x0100, 0x0130, - 0xa87f, 0x0030, 0xa887, 0x0000, 0xa89b, 0x4002, 0xa898, 0x908e, - 0x006b, 0x090c, 0x469d, 0x080c, 0x6b11, 0xa0a3, 0x0000, 0xa0a7, - 0x0000, 0x2848, 0x080c, 0x1033, 0x009e, 0x0005, 0x00a6, 0xa0a4, - 0x904d, 0x090c, 0x0dc4, 0xa070, 0x908e, 0x0100, 0x0128, 0xa87f, - 0x0001, 0xa887, 0x0000, 0x00c0, 0xa80c, 0x2050, 0xb004, 0x9005, - 0x0198, 0xa80e, 0x2050, 0x8006, 0x8006, 0x8007, 0x908c, 0x003f, - 0x9084, 0xffc0, 0x9080, 0x0002, 0xa07a, 0xa176, 0xb000, 0xa07e, - 0x2810, 0x080c, 0x10eb, 0x00c8, 0xa980, 0xa898, 0x0016, 0x0006, - 0x080c, 0x6b11, 0x000e, 0x001e, 0xd1a4, 0x0128, 0x00c6, 0x2060, - 0x080c, 0x9f18, 0x00ce, 0x7008, 0x2048, 0xa8a3, 0x0000, 0xa8a7, - 0x0000, 0x080c, 0x1033, 0x080c, 0x110a, 0x00ae, 0x0005, 0x0126, - 0x2091, 0x8000, 0x782b, 0x1001, 0x7007, 0x0005, 0x7000, 0xc094, - 0x7002, 0x012e, 0x0005, 0x7007, 0x0000, 0x080c, 0x111b, 0x0005, - 0x0126, 0x2091, 0x2200, 0x2079, 0x0300, 0x2071, 0x1a41, 0x7003, - 0x0000, 0x78bf, 0x00f6, 0x781b, 0x4800, 0x00c1, 0x7803, 0x0003, - 0x780f, 0x0000, 0x20a9, 0x0259, 0x2061, 0xd387, 0x2c0d, 0x7912, - 0xe104, 0x9ce0, 0x0002, 0x7916, 0x1f04, 0x12ce, 0x7807, 0x0007, - 0x7803, 0x0000, 0x7803, 0x0001, 0x012e, 0x0005, 0x00c6, 0x7803, - 0x0000, 0x7808, 0xd09c, 0x0110, 0x7820, 0x0cd8, 0x2001, 0x1a42, - 0x2003, 0x0000, 0x78ab, 0x0004, 0x78ac, 0xd0ac, 0x1de8, 0x78ab, - 0x0002, 0x7807, 0x0007, 0x7827, 0x0030, 0x782b, 0x0400, 0x7827, - 0x0031, 0x782b, 0x1a64, 0x781f, 0xff00, 0x781b, 0xb700, 0x2001, - 0x0200, 0x2004, 0xd0dc, 0x0110, 0x781f, 0x0303, 0x2061, 0x1a64, - 0x602f, 0x1cc8, 0x2001, 0x1819, 0x2004, 0x9082, 0x1cc8, 0x6032, - 0x603b, 0x1f70, 0x2001, 0x31cc, 0xd0fc, 0x190c, 0x0dc4, 0x2001, - 0x1810, 0x2004, 0xd0c4, 0x1128, 0x2001, 0x0003, 0x2004, 0xd0d4, - 0x1118, 0x783f, 0x31cc, 0x0020, 0x9084, 0xc000, 0x783f, 0xb1cc, - 0x00ce, 0x0005, 0x0126, 0x2091, 0x2200, 0x7908, 0x9184, 0x0030, - 0x190c, 0x0dbd, 0xd19c, 0x0158, 0x7820, 0x908c, 0xf000, 0x15f0, - 0x908a, 0x0024, 0x1a0c, 0x0dc4, 0x0023, 0x012e, 0x0005, 0x012e, - 0x0005, 0x1366, 0x1366, 0x137d, 0x1382, 0x1386, 0x138b, 0x13b3, - 0x13b7, 0x13c5, 0x13c9, 0x1366, 0x1452, 0x1456, 0x14c6, 0x1366, - 0x1366, 0x1366, 0x1366, 0x1366, 0x1366, 0x1366, 0x1366, 0x1366, - 0x1366, 0x1366, 0x1366, 0x1366, 0x138d, 0x1366, 0x1366, 0x1366, - 0x1366, 0x1366, 0x1366, 0x136a, 0x1368, 0x1366, 0x080c, 0x0dc4, - 0x080c, 0x0dbd, 0x080c, 0x14cd, 0x2009, 0x1a59, 0x2104, 0x8000, - 0x200a, 0x080c, 0x7d22, 0x080c, 0x199b, 0x0005, 0x2009, 0x0048, - 0x2060, 0x080c, 0x9f88, 0x012e, 0x0005, 0x7004, 0xc085, 0xc0b5, - 0x7006, 0x0005, 0x7004, 0xc085, 0x7006, 0x0005, 0x080c, 0x14cd, - 0x080c, 0x1636, 0x0005, 0x080c, 0x0dc4, 0x080c, 0x14cd, 0x2060, - 0x6014, 0x0096, 0x2048, 0xa83b, 0xffff, 0x009e, 0x2009, 0x0048, - 0x080c, 0x9f88, 0x2001, 0x015d, 0x2003, 0x0000, 0x2009, 0x03e8, - 0x8109, 0x0160, 0x2001, 0x0201, 0x2004, 0x9005, 0x0dc8, 0x2001, - 0x0218, 0x2004, 0xd0ec, 0x1110, 0x080c, 0x14d2, 0x2001, 0x0307, - 0x2003, 0x8000, 0x0005, 0x7004, 0xc095, 0x7006, 0x0005, 0x080c, - 0x14cd, 0x2060, 0x6014, 0x0096, 0x2048, 0xa83b, 0xffff, 0x009e, - 0x2009, 0x0048, 0x080c, 0x9f88, 0x0005, 0x080c, 0x14cd, 0x080c, - 0x0dc4, 0x080c, 0x14cd, 0x080c, 0x143d, 0x7827, 0x0018, 0x79ac, - 0xd1dc, 0x0540, 0x7827, 0x0015, 0x7828, 0x782b, 0x0000, 0x9065, - 0x0138, 0x2001, 0x020d, 0x2003, 0x0050, 0x2003, 0x0020, 0x0400, - 0x7004, 0x9005, 0x1180, 0x78ab, 0x0004, 0x7827, 0x0018, 0x782b, - 0x0000, 0xd1bc, 0x090c, 0x0dc4, 0x2001, 0x020d, 0x2003, 0x0050, - 0x2003, 0x0020, 0x0478, 0x78ab, 0x0004, 0x7803, 0x0001, 0x080c, - 0x1456, 0x0005, 0x7828, 0x782b, 0x0000, 0x9065, 0x090c, 0x0dc4, - 0x6014, 0x2048, 0x78ab, 0x0004, 0x918c, 0x0700, 0x01d8, 0x080c, - 0x7d22, 0x080c, 0x199b, 0x080c, 0xb955, 0x0158, 0xa9b0, 0xa936, - 0xa9b4, 0xa93a, 0xa83f, 0xffff, 0xa843, 0xffff, 0xa884, 0xc0bd, - 0xa886, 0xa984, 0x9184, 0x0020, 0x1120, 0xc1ad, 0xa986, 0x080c, - 0xb5c5, 0x0005, 0x2029, 0x00c8, 0x8529, 0x0128, 0x2001, 0x0201, - 0x2004, 0x9005, 0x0dc8, 0x7dbc, 0x080c, 0xd314, 0xd5a4, 0x1118, - 0x080c, 0x14d2, 0x0005, 0x080c, 0x7d22, 0x080c, 0x199b, 0x0005, - 0x781f, 0x0300, 0x7803, 0x0001, 0x0005, 0x0016, 0x0066, 0x0076, - 0x00f6, 0x2079, 0x0300, 0x7908, 0x918c, 0x0007, 0x9186, 0x0003, - 0x0120, 0x2001, 0x0016, 0x080c, 0x1553, 0x00fe, 0x007e, 0x006e, - 0x001e, 0x0005, 0x7004, 0xc09d, 0x7006, 0x0005, 0x7104, 0x9184, - 0x0004, 0x190c, 0x0dc4, 0xd184, 0x11b1, 0xd19c, 0x0180, 0xc19c, - 0x7106, 0x0016, 0x080c, 0x1619, 0x001e, 0x0148, 0x2001, 0x020d, - 0x2003, 0x0050, 0x2003, 0x0020, 0x080c, 0x14d2, 0x0005, 0x81ff, - 0x190c, 0x0dc4, 0x0005, 0x2100, 0xc184, 0xc1b4, 0x7106, 0xd0b4, - 0x0016, 0x00e6, 0x1904, 0x14bb, 0x2071, 0x0200, 0x080c, 0x160d, - 0x080c, 0x1619, 0x05a8, 0x6014, 0x9005, 0x05a8, 0x0096, 0x2048, - 0xa868, 0x009e, 0x9084, 0x00ff, 0x908e, 0x0029, 0x0160, 0x908e, - 0x0048, 0x1548, 0x601c, 0xd084, 0x11d8, 0x00f6, 0x2c78, 0x080c, - 0x1679, 0x00fe, 0x00a8, 0x00f6, 0x2c78, 0x080c, 0x17bd, 0x00fe, - 0x2009, 0x01f4, 0x8109, 0x0160, 0x2001, 0x0201, 0x2004, 0x9005, - 0x0dc8, 0x2001, 0x0218, 0x2004, 0xd0ec, 0x1110, 0x0419, 0x0040, - 0x2001, 0x020d, 0x2003, 0x0020, 0x080c, 0x12de, 0x7803, 0x0001, - 0x00ee, 0x001e, 0x0005, 0x080c, 0x1619, 0x0dd0, 0x2001, 0x020d, - 0x2003, 0x0050, 0x2003, 0x0020, 0x0069, 0x0c90, 0x0031, 0x2060, - 0x2009, 0x0053, 0x080c, 0x9f88, 0x0005, 0x7808, 0xd09c, 0x0de8, - 0x7820, 0x0005, 0x080c, 0x143d, 0x00d6, 0x2069, 0x0200, 0x2009, - 0x01f4, 0x8109, 0x0520, 0x6804, 0x9005, 0x0dd8, 0x2001, 0x015d, - 0x2003, 0x0000, 0x79bc, 0xd1a4, 0x1578, 0x79b8, 0x918c, 0x0fff, - 0x0180, 0x9182, 0x0841, 0x1268, 0x9188, 0x0007, 0x918c, 0x0ff8, - 0x810c, 0x810c, 0x810c, 0x080c, 0x153f, 0x6827, 0x0001, 0x8109, - 0x1dd0, 0x080c, 0x153f, 0x6827, 0x0002, 0x080c, 0x153f, 0x6804, - 0x9005, 0x1170, 0x682c, 0xd0e4, 0x1540, 0x691c, 0x9184, 0x0014, - 0x0120, 0x6830, 0x9084, 0x9554, 0x15b9, 0x6804, 0x9005, 0x0da8, - 0x79b8, 0xd1ec, 0x1130, 0x0870, 0x080c, 0x7d22, 0x080c, 0x199b, - 0x0090, 0x7827, 0x0015, 0x782b, 0x0000, 0x7827, 0x0018, 0x782b, - 0x0000, 0x2001, 0x020d, 0x2003, 0x0020, 0x2001, 0x0307, 0x2003, - 0x0300, 0x7803, 0x0001, 0x00de, 0x0005, 0x682c, 0x9084, 0x5400, - 0x9086, 0x5400, 0x0d30, 0x7827, 0x0015, 0x782b, 0x0000, 0x7803, - 0x0001, 0x6800, 0x9085, 0x1800, 0x6802, 0x00de, 0x0005, 0x6824, - 0x9084, 0x0003, 0x1de0, 0x0005, 0x2079, 0x0001, 0x000e, 0x00f6, - 0x0804, 0x0dc6, 0x2001, 0x0030, 0x2c08, 0x621c, 0x0021, 0x7830, - 0x9086, 0x0041, 0x0005, 0x00f6, 0x2079, 0x0300, 0x0006, 0x7808, - 0xd09c, 0x0140, 0x0016, 0x0026, 0x00c6, 0x080c, 0x132a, 0x00ce, - 0x002e, 0x001e, 0x000e, 0x0006, 0x7832, 0x7936, 0x7a3a, 0x781b, - 0x8080, 0x0059, 0x1118, 0x000e, 0x00fe, 0x0005, 0x000e, 0x792c, - 0x3900, 0x8000, 0x2004, 0x080c, 0x0dc4, 0x2009, 0x180c, 0x2104, - 0xc0f4, 0x200a, 0x2009, 0xff00, 0x8109, 0x0904, 0x15d1, 0x7a18, - 0x9284, 0x0030, 0x0904, 0x15cc, 0x9284, 0x0048, 0x9086, 0x0008, - 0x1904, 0x15cc, 0x2001, 0x0109, 0x2004, 0xd08c, 0x01f0, 0x0006, - 0x01c6, 0x01d6, 0x0136, 0x0146, 0x0156, 0x0126, 0x2091, 0x2800, - 0x00f6, 0x0026, 0x0016, 0x2009, 0x1a5c, 0x2104, 0x8000, 0x0208, - 0x200a, 0x080c, 0x8689, 0x001e, 0x002e, 0x00fe, 0x012e, 0x015e, - 0x014e, 0x013e, 0x01de, 0x01ce, 0x000e, 0x2001, 0x009b, 0x2004, - 0xd0fc, 0x01d0, 0x0006, 0x0126, 0x01c6, 0x01d6, 0x0136, 0x0146, - 0x0156, 0x00f6, 0x0016, 0x2009, 0x1a5d, 0x2104, 0x8000, 0x0208, - 0x200a, 0x080c, 0x1d94, 0x001e, 0x00fe, 0x015e, 0x014e, 0x013e, - 0x01de, 0x01ce, 0x012e, 0x000e, 0x7818, 0xd0bc, 0x1904, 0x157c, - 0x0005, 0x2001, 0x180c, 0x2004, 0xd0f4, 0x1528, 0x7a18, 0x9284, - 0x0030, 0x0508, 0x9284, 0x0048, 0x9086, 0x0008, 0x11e0, 0x2001, - 0x19d3, 0x2004, 0x9005, 0x01b8, 0x2001, 0x1a44, 0x2004, 0x9086, - 0x0000, 0x0188, 0x2009, 0x1a5b, 0x2104, 0x8000, 0x0208, 0x200a, - 0x080c, 0x96a1, 0x2009, 0x180c, 0x2104, 0xc0f5, 0x200a, 0x2009, - 0xff00, 0x0804, 0x157c, 0x9085, 0x0001, 0x0005, 0x7832, 0x7936, - 0x7a3a, 0x781b, 0x8080, 0x080c, 0x1575, 0x1108, 0x0005, 0x792c, - 0x3900, 0x8000, 0x2004, 0x080c, 0x0dc4, 0x7037, 0x0001, 0x7150, - 0x7037, 0x0002, 0x7050, 0x2060, 0xd1bc, 0x1110, 0x7054, 0x2060, - 0x0005, 0x0006, 0x0046, 0x00e6, 0x2071, 0x0200, 0x7037, 0x0002, - 0x7058, 0x9084, 0xff00, 0x8007, 0x9086, 0x00bc, 0x1158, 0x2021, - 0x1a5a, 0x2404, 0x8000, 0x0208, 0x2022, 0x080c, 0x7d22, 0x080c, - 0x199b, 0x9006, 0x00ee, 0x004e, 0x000e, 0x0005, 0x0c11, 0x1108, - 0x0005, 0x00e6, 0x0016, 0x2071, 0x0200, 0x0879, 0x6120, 0x9186, - 0x0000, 0x0560, 0x9186, 0x0002, 0x0548, 0x7358, 0x745c, 0x6014, - 0x905d, 0x0520, 0x2b48, 0xab42, 0xac3e, 0x2001, 0x1880, 0x2004, - 0xd0b4, 0x1138, 0x601c, 0xd0e4, 0x1120, 0xa83b, 0x7fff, 0xa837, - 0xffff, 0x080c, 0x1f90, 0x1190, 0x080c, 0x181a, 0x2a00, 0xa816, + 0x7852, 0x080c, 0x7351, 0x0120, 0x7843, 0x0090, 0x7843, 0x0010, + 0x2021, 0xe678, 0x2019, 0xea60, 0x0d0c, 0x85c0, 0x7820, 0xd09c, + 0x1588, 0x080c, 0x7351, 0x0904, 0x0cf0, 0x7824, 0xd0ac, 0x1904, + 0x0d10, 0x080c, 0x7374, 0x1530, 0x0046, 0x2021, 0x0320, 0x8421, + 0x1df0, 0x004e, 0x7827, 0x1800, 0x080c, 0x2af6, 0x7824, 0x9084, + 0x1800, 0x1168, 0x9484, 0x0fff, 0x1140, 0x2001, 0x1810, 0x2004, + 0x9084, 0x9000, 0x0110, 0x080c, 0x0d31, 0x8421, 0x1158, 0x1d04, + 0x0ccb, 0x080c, 0x85c0, 0x080c, 0x7656, 0x080c, 0x764c, 0x7003, + 0x0001, 0x04f0, 0x8319, 0x1940, 0x1d04, 0x0cd8, 0x080c, 0x85c0, + 0x2009, 0x1977, 0x2104, 0x9005, 0x0118, 0x8001, 0x200a, 0x1178, + 0x200b, 0x000a, 0x7827, 0x0048, 0x20a9, 0x0002, 0x080c, 0x2ad7, + 0x7924, 0x080c, 0x2af6, 0xd19c, 0x0110, 0x080c, 0x2a17, 0x00d8, + 0x080c, 0x7362, 0x1140, 0x94a2, 0x03e8, 0x1128, 0x080c, 0x7329, + 0x7003, 0x0001, 0x00a8, 0x7827, 0x1800, 0x080c, 0x2af6, 0x7824, + 0x080c, 0x736b, 0x0110, 0xd0ac, 0x1158, 0x9084, 0x1800, 0x0950, + 0x7003, 0x0001, 0x0028, 0x2001, 0x0001, 0x080c, 0x26b1, 0x0078, + 0x2009, 0x180c, 0x210c, 0xd19c, 0x1120, 0x7904, 0x918d, 0x0002, + 0x7906, 0x7827, 0x0048, 0x7828, 0x9085, 0x0028, 0x782a, 0x7850, + 0x9085, 0x0400, 0x7852, 0x2001, 0x1984, 0x2003, 0x0000, 0x9006, + 0x78f2, 0x015e, 0x003e, 0x000e, 0x012e, 0x00fe, 0x004e, 0x001e, + 0x0005, 0x0006, 0x0016, 0x0036, 0x0046, 0x00b6, 0x00c6, 0x00d6, + 0x00e6, 0x00f6, 0x0156, 0x0069, 0x0d0c, 0x85c0, 0x015e, 0x00fe, + 0x00ee, 0x00de, 0x00ce, 0x00be, 0x004e, 0x003e, 0x001e, 0x000e, + 0x0005, 0x00e6, 0x2071, 0x189f, 0x7004, 0x9086, 0x0001, 0x1110, + 0x080c, 0x338f, 0x00ee, 0x0005, 0x0005, 0x2a70, 0x2061, 0x1988, + 0x2063, 0x0003, 0x6007, 0x0003, 0x600b, 0x001a, 0x600f, 0x0117, + 0x2001, 0x1958, 0x900e, 0x2102, 0x7192, 0x2001, 0x0100, 0x2004, + 0x9082, 0x0002, 0x0218, 0x705b, 0xffff, 0x0008, 0x715a, 0x7063, + 0xffff, 0x717a, 0x717e, 0x080c, 0xc617, 0x70e7, 0x00c0, 0x2061, + 0x1948, 0x6003, 0x0909, 0x6106, 0x600b, 0x8800, 0x600f, 0x0200, + 0x6013, 0x00ff, 0x6017, 0x000f, 0x611a, 0x601f, 0x07d0, 0x2061, + 0x1950, 0x6003, 0x8000, 0x6106, 0x610a, 0x600f, 0x0200, 0x6013, + 0x00ff, 0x6116, 0x601b, 0x0001, 0x611e, 0x2061, 0x1965, 0x6003, + 0x514c, 0x6007, 0x4f47, 0x600b, 0x4943, 0x600f, 0x2020, 0x2001, + 0x182b, 0x2102, 0x0005, 0x9016, 0x080c, 0x64fc, 0x1178, 0xb804, + 0x90c4, 0x00ff, 0x98c6, 0x0006, 0x0128, 0x90c4, 0xff00, 0x98c6, + 0x0600, 0x1120, 0x9186, 0x0080, 0x0108, 0x8210, 0x8108, 0x9186, + 0x0800, 0x1d50, 0x2208, 0x0005, 0x2091, 0x8000, 0x2079, 0x0000, + 0x000e, 0x00f6, 0x0010, 0x2091, 0x8000, 0x0e04, 0x0dc5, 0x0006, + 0x0016, 0x2001, 0x8002, 0x0006, 0x2079, 0x0000, 0x000e, 0x7882, + 0x7836, 0x001e, 0x798e, 0x000e, 0x788a, 0x000e, 0x7886, 0x3900, + 0x789a, 0x00d6, 0x2069, 0x0300, 0x6818, 0x78ae, 0x681c, 0x78b2, + 0x2001, 0x19e5, 0x2004, 0x78b6, 0x2001, 0x1a61, 0x2004, 0x78ba, + 0x6808, 0x78be, 0x00de, 0x7833, 0x0012, 0x2091, 0x5000, 0x0156, + 0x00d6, 0x0036, 0x0026, 0x2079, 0x0300, 0x2069, 0x1a84, 0x7a08, + 0x226a, 0x2069, 0x1a85, 0x7a18, 0x226a, 0x8d68, 0x7a1c, 0x226a, + 0x782c, 0x2019, 0x1a92, 0x201a, 0x2019, 0x1a95, 0x9016, 0x7808, + 0xd09c, 0x0168, 0x7820, 0x201a, 0x8210, 0x8318, 0x9386, 0x1aaa, + 0x0108, 0x0ca8, 0x7808, 0xd09c, 0x0110, 0x2011, 0xdead, 0x2019, + 0x1a93, 0x782c, 0x201a, 0x8318, 0x221a, 0x7803, 0x0000, 0x2069, + 0x1a64, 0x901e, 0x20a9, 0x0020, 0x7b26, 0x7a28, 0x226a, 0x8d68, + 0x8318, 0x1f04, 0x0e24, 0x002e, 0x003e, 0x00de, 0x015e, 0x2079, + 0x1800, 0x7803, 0x0005, 0x2091, 0x4080, 0x2001, 0x0089, 0x2004, + 0xd084, 0x0188, 0x2001, 0x19f8, 0x2004, 0x9005, 0x0130, 0x2001, + 0x008b, 0x2004, 0x9084, 0x8004, 0x0dd0, 0x2001, 0x008a, 0x2003, + 0x0002, 0x2003, 0x1001, 0x080c, 0x5673, 0x1108, 0x0099, 0x0cd8, + 0x0005, 0x918c, 0x03ff, 0x2001, 0x0003, 0x2004, 0x9084, 0x0600, + 0x1118, 0x918d, 0x2800, 0x0010, 0x918d, 0x2000, 0x2001, 0x017f, + 0x2102, 0x0005, 0x0026, 0x0126, 0x2011, 0x0080, 0x080c, 0x0eed, + 0x20a9, 0x0900, 0x080c, 0x0f0e, 0x2011, 0x0040, 0x080c, 0x0eed, + 0x20a9, 0x0900, 0x080c, 0x0f0e, 0x0c78, 0x0026, 0x080c, 0x0efa, + 0x1118, 0x2011, 0x0040, 0x0098, 0x2011, 0x010e, 0x2214, 0x9294, + 0x0007, 0x9296, 0x0007, 0x0118, 0x2011, 0xa880, 0x0010, 0x2011, + 0x6840, 0xd0e4, 0x70eb, 0x0000, 0x1120, 0x70eb, 0x0fa0, 0x080c, + 0x0eff, 0x002e, 0x0005, 0x0026, 0x080c, 0x0efa, 0x0128, 0xd0a4, + 0x1138, 0x2011, 0xcdd5, 0x0010, 0x2011, 0x0080, 0x080c, 0x0eff, + 0x002e, 0x0005, 0x0026, 0x70eb, 0x0000, 0x080c, 0x0efa, 0x1148, + 0x080c, 0x2aee, 0x1118, 0x2011, 0x8484, 0x0058, 0x2011, 0x8282, + 0x0040, 0x080c, 0x2aee, 0x1118, 0x2011, 0xcdc5, 0x0010, 0x2011, + 0xcac2, 0x080c, 0x0eff, 0x002e, 0x0005, 0x00e6, 0x0006, 0x2071, + 0x1800, 0xd0b4, 0x70e4, 0x1110, 0xc0e4, 0x0048, 0x0006, 0x3b00, + 0x9084, 0xff3f, 0x20d8, 0x000e, 0x70eb, 0x0000, 0xc0e5, 0x0079, + 0x000e, 0x00ee, 0x0005, 0x00e6, 0x2071, 0x1800, 0xd0e4, 0x70e4, + 0x1110, 0xc0dc, 0x0008, 0xc0dd, 0x0011, 0x00ee, 0x0005, 0x70e6, + 0x7000, 0x9084, 0x0007, 0x000b, 0x0005, 0x0ebc, 0x0e93, 0x0e93, + 0x0e75, 0x0ea2, 0x0e93, 0x0e93, 0x0ea2, 0x0016, 0x3b08, 0x3a00, + 0x9104, 0x918d, 0x00c0, 0x21d8, 0x9084, 0xff3f, 0x9205, 0x20d0, + 0x001e, 0x0005, 0x2001, 0x1839, 0x2004, 0xd0dc, 0x0005, 0x9e86, + 0x1800, 0x190c, 0x0dc3, 0x70e4, 0xd0e4, 0x0108, 0xc2e5, 0x72e6, + 0xd0e4, 0x1118, 0x9294, 0x00c0, 0x0c01, 0x0005, 0x1d04, 0x0f0e, + 0x2091, 0x6000, 0x1f04, 0x0f0e, 0x0005, 0x890e, 0x810e, 0x810f, + 0x9194, 0x003f, 0x918c, 0xffc0, 0x0005, 0x0006, 0x2200, 0x914d, + 0x894f, 0x894d, 0x894d, 0x000e, 0x0005, 0x01d6, 0x0146, 0x0036, + 0x0096, 0x2061, 0x188e, 0x600b, 0x0000, 0x600f, 0x0000, 0x6003, + 0x0000, 0x6007, 0x0000, 0x2009, 0xffc0, 0x2105, 0x0006, 0x2001, + 0xaaaa, 0x200f, 0x2019, 0x5555, 0x9016, 0x2049, 0x0bff, 0xab02, + 0xa001, 0xa001, 0xa800, 0x9306, 0x1138, 0x2105, 0x9306, 0x0120, + 0x8210, 0x99c8, 0x0400, 0x0c98, 0x000e, 0x200f, 0x2001, 0x189e, + 0x928a, 0x000e, 0x1638, 0x928a, 0x0006, 0x2011, 0x0006, 0x1210, + 0x2011, 0x0000, 0x2202, 0x9006, 0x2008, 0x82ff, 0x01b0, 0x8200, + 0x600a, 0x600f, 0xffff, 0x6003, 0x0002, 0x6007, 0x0000, 0x0026, + 0x2019, 0x0010, 0x9280, 0x0001, 0x20e8, 0x21a0, 0x21a8, 0x4104, + 0x8319, 0x1de0, 0x8211, 0x1da0, 0x002e, 0x009e, 0x003e, 0x014e, + 0x01de, 0x0005, 0x2011, 0x000e, 0x08e8, 0x0016, 0x0026, 0x0096, + 0x3348, 0x080c, 0x0f15, 0x2100, 0x9300, 0x2098, 0x22e0, 0x009e, + 0x002e, 0x001e, 0x0036, 0x3518, 0x20a9, 0x0001, 0x4002, 0x8007, + 0x4004, 0x8319, 0x1dd8, 0x003e, 0x0005, 0x20e9, 0x0001, 0x71b4, + 0x81ff, 0x11c0, 0x9006, 0x2009, 0x0200, 0x20a9, 0x0002, 0x9298, + 0x0018, 0x23a0, 0x4001, 0x2009, 0x0700, 0x20a9, 0x0002, 0x9298, + 0x0008, 0x23a0, 0x4001, 0x7078, 0x8007, 0x717c, 0x810f, 0x20a9, + 0x0002, 0x4001, 0x9298, 0x000c, 0x23a0, 0x900e, 0x080c, 0x0da3, + 0x2001, 0x0000, 0x810f, 0x20a9, 0x0002, 0x4001, 0x0005, 0x89ff, + 0x0140, 0xa804, 0xa807, 0x0000, 0x0006, 0x080c, 0x103f, 0x009e, + 0x0cb0, 0x0005, 0x00e6, 0x2071, 0x1800, 0x080c, 0x10b8, 0x090c, + 0x0dc3, 0x00ee, 0x0005, 0x0086, 0x00e6, 0x0006, 0x0026, 0x0036, + 0x0126, 0x2091, 0x8000, 0x00c9, 0x2071, 0x1800, 0x73bc, 0x702c, + 0x9016, 0x9045, 0x0158, 0x8210, 0x9906, 0x090c, 0x0dc3, 0x2300, + 0x9202, 0x0120, 0x1a0c, 0x0dc3, 0xa000, 0x0c98, 0x012e, 0x003e, + 0x002e, 0x000e, 0x00ee, 0x008e, 0x0005, 0x0086, 0x00e6, 0x0006, + 0x0126, 0x2091, 0x8000, 0x2071, 0x1911, 0x7010, 0x9005, 0x0140, + 0x7018, 0x9045, 0x0128, 0x9906, 0x090c, 0x0dc3, 0xa000, 0x0cc8, + 0x012e, 0x000e, 0x00ee, 0x008e, 0x0005, 0x00e6, 0x2071, 0x1800, + 0x0126, 0x2091, 0x8000, 0x70bc, 0x8001, 0x0270, 0x70be, 0x702c, + 0x2048, 0x9085, 0x0001, 0xa800, 0x702e, 0xa803, 0x0000, 0xa807, + 0x0000, 0x012e, 0x00ee, 0x0005, 0x904e, 0x0cd8, 0x00e6, 0x0126, + 0x2091, 0x8000, 0x2071, 0x1800, 0x70bc, 0x90ca, 0x0040, 0x0268, + 0x8001, 0x70be, 0x702c, 0x2048, 0xa800, 0x702e, 0xa803, 0x0000, + 0xa807, 0x0000, 0x012e, 0x00ee, 0x0005, 0x904e, 0x0cd8, 0x00e6, + 0x0126, 0x2091, 0x8000, 0x0016, 0x890e, 0x810e, 0x810f, 0x9184, + 0x003f, 0xa862, 0x9184, 0xffc0, 0xa85e, 0x001e, 0x0020, 0x00e6, + 0x0126, 0x2091, 0x8000, 0x2071, 0x1800, 0x702c, 0xa802, 0x2900, + 0x702e, 0x70bc, 0x8000, 0x70be, 0x080c, 0x83a7, 0x012e, 0x00ee, + 0x0005, 0x2071, 0x1800, 0x9026, 0x2009, 0x0000, 0x2049, 0x0400, + 0x2900, 0x702e, 0x8940, 0x2800, 0xa802, 0xa95e, 0xa863, 0x0001, + 0x8420, 0x9886, 0x0440, 0x0120, 0x2848, 0x9188, 0x0040, 0x0c90, + 0x2071, 0x188e, 0x7000, 0x9005, 0x11a0, 0x2001, 0x0534, 0xa802, + 0x2048, 0x2009, 0x4d00, 0x8940, 0x2800, 0xa802, 0xa95e, 0xa863, + 0x0001, 0x8420, 0x9886, 0x0800, 0x0120, 0x2848, 0x9188, 0x0040, + 0x0c90, 0x2071, 0x188e, 0x7104, 0x7200, 0x82ff, 0x01d0, 0x7308, + 0x8318, 0x831f, 0x831b, 0x831b, 0x7312, 0x8319, 0x2001, 0x0800, + 0xa802, 0x2048, 0x8900, 0xa802, 0x2040, 0xa95e, 0xaa62, 0x8420, + 0x2300, 0x9906, 0x0130, 0x2848, 0x9188, 0x0040, 0x9291, 0x0000, + 0x0c88, 0xa803, 0x0000, 0x2071, 0x1800, 0x74ba, 0x74be, 0x0005, + 0x00e6, 0x0016, 0x9984, 0xfc00, 0x01e8, 0x908c, 0xf800, 0x1168, + 0x9982, 0x0400, 0x02b8, 0x9982, 0x0440, 0x0278, 0x9982, 0x0534, + 0x0288, 0x9982, 0x0800, 0x1270, 0x0040, 0x9982, 0x0800, 0x0250, + 0x2071, 0x188e, 0x7010, 0x9902, 0x1228, 0x9085, 0x0001, 0x001e, + 0x00ee, 0x0005, 0x9006, 0x0cd8, 0x00e6, 0x2071, 0x19f7, 0x7007, + 0x0000, 0x9006, 0x701e, 0x7022, 0x7002, 0x2071, 0x0000, 0x7010, + 0x9085, 0x8044, 0x7012, 0x2071, 0x0080, 0x9006, 0x20a9, 0x0040, + 0x7022, 0x1f04, 0x10f0, 0x702b, 0x0020, 0x00ee, 0x0005, 0x0126, + 0x2091, 0x8000, 0x00e6, 0xa073, 0x0000, 0x2071, 0x19f7, 0x701c, + 0x9088, 0x1a01, 0x280a, 0x8000, 0x9084, 0x003f, 0x701e, 0x7120, + 0x9106, 0x090c, 0x0dc3, 0x7004, 0x9005, 0x1128, 0x00f6, 0x2079, + 0x0080, 0x00a9, 0x00fe, 0x00ee, 0x012e, 0x0005, 0x0126, 0x2091, + 0x8000, 0x00e6, 0x2071, 0x19f7, 0x7004, 0x9005, 0x1128, 0x00f6, + 0x2079, 0x0080, 0x0021, 0x00fe, 0x00ee, 0x012e, 0x0005, 0x7004, + 0x9086, 0x0000, 0x1110, 0x7007, 0x0006, 0x7000, 0x0002, 0x1139, + 0x1137, 0x1137, 0x1137, 0x12b3, 0x12b3, 0x12b3, 0x12b3, 0x080c, + 0x0dc3, 0x701c, 0x7120, 0x9106, 0x1148, 0x792c, 0x9184, 0x0001, + 0x1120, 0xd1fc, 0x1110, 0x7007, 0x0000, 0x0005, 0x0096, 0x9180, + 0x1a01, 0x2004, 0x700a, 0x2048, 0x8108, 0x918c, 0x003f, 0x7122, + 0x782b, 0x0026, 0xa890, 0x7802, 0xa894, 0x7806, 0xa898, 0x780a, + 0xa89c, 0x780e, 0xa87c, 0x700e, 0xa874, 0x7016, 0xa878, 0x701a, + 0xa86c, 0x009e, 0xd084, 0x0120, 0x7007, 0x0001, 0x0029, 0x0005, + 0x7007, 0x0002, 0x00b1, 0x0005, 0x0016, 0x0026, 0x710c, 0x2011, + 0x0040, 0x9182, 0x0040, 0x1210, 0x2110, 0x9006, 0x700e, 0x7212, + 0x8203, 0x7812, 0x782b, 0x0020, 0x782b, 0x0041, 0x002e, 0x001e, + 0x0005, 0x0016, 0x0026, 0x0136, 0x0146, 0x0156, 0x7014, 0x20e0, + 0x7018, 0x2098, 0x20e9, 0x0000, 0x20a1, 0x0088, 0x782b, 0x0026, + 0x710c, 0x2011, 0x0040, 0x9182, 0x0040, 0x1210, 0x2110, 0x9006, + 0x700e, 0x22a8, 0x4006, 0x8203, 0x7812, 0x782b, 0x0020, 0x3300, + 0x701a, 0x782b, 0x0001, 0x015e, 0x014e, 0x013e, 0x002e, 0x001e, + 0x0005, 0x0016, 0x2009, 0x19f7, 0x2104, 0xc095, 0x200a, 0x080c, + 0x1116, 0x001e, 0x0005, 0x0016, 0x00e6, 0x2071, 0x19f7, 0x00f6, + 0x2079, 0x0080, 0x792c, 0xd1bc, 0x190c, 0x0dbc, 0x782b, 0x0002, + 0xd1fc, 0x0120, 0x918c, 0x0700, 0x7004, 0x0023, 0x00fe, 0x00ee, + 0x001e, 0x0005, 0x1127, 0x11d1, 0x1205, 0x0dc3, 0x0dc3, 0x12bf, + 0x0dc3, 0x918c, 0x0700, 0x1550, 0x0136, 0x0146, 0x0156, 0x7014, + 0x20e8, 0x7018, 0x20a0, 0x20e1, 0x0000, 0x2099, 0x0088, 0x782b, + 0x0040, 0x7010, 0x20a8, 0x4005, 0x3400, 0x701a, 0x015e, 0x014e, + 0x013e, 0x700c, 0x9005, 0x0578, 0x7800, 0x7802, 0x7804, 0x7806, + 0x080c, 0x116c, 0x0005, 0x7008, 0x0096, 0x2048, 0xa873, 0x0100, + 0x009e, 0x7007, 0x0000, 0x080c, 0x1127, 0x0005, 0x7008, 0x0096, + 0x2048, 0xa873, 0x0200, 0x009e, 0x0ca0, 0x918c, 0x0700, 0x1150, + 0x700c, 0x9005, 0x0180, 0x7800, 0x7802, 0x7804, 0x7806, 0x080c, + 0x1181, 0x0005, 0x7008, 0x0096, 0x2048, 0xa873, 0x0200, 0x009e, + 0x7007, 0x0000, 0x0080, 0x0096, 0x7008, 0x2048, 0x7800, 0xa892, + 0x7804, 0xa896, 0x7808, 0xa89a, 0x780c, 0xa89e, 0xa873, 0x0100, + 0x009e, 0x7007, 0x0000, 0x0096, 0x00d6, 0x7008, 0x2048, 0x2001, + 0x18ba, 0x2004, 0x9906, 0x1128, 0xa8a0, 0x080f, 0x00de, 0x009e, + 0x00a0, 0x00de, 0x009e, 0x0096, 0x00d6, 0x7008, 0x2048, 0x0081, + 0x0150, 0xa8a0, 0x0086, 0x2940, 0x080f, 0x008e, 0x00de, 0x009e, + 0x080c, 0x1116, 0x0005, 0x00de, 0x009e, 0x080c, 0x1116, 0x0005, + 0xa8ac, 0xd08c, 0x0005, 0x0096, 0xa0a4, 0x904d, 0x090c, 0x0dc3, + 0xa070, 0x908e, 0x0100, 0x0130, 0xa87f, 0x0030, 0xa887, 0x0000, + 0xa89b, 0x4002, 0xa898, 0x908e, 0x006b, 0x090c, 0x4740, 0x080c, + 0x6bf5, 0xa0a3, 0x0000, 0xa0a7, 0x0000, 0x2848, 0x080c, 0x103f, + 0x009e, 0x0005, 0x00a6, 0xa0a4, 0x904d, 0x090c, 0x0dc3, 0xa070, + 0x908e, 0x0100, 0x0128, 0xa87f, 0x0001, 0xa887, 0x0000, 0x00c0, + 0xa80c, 0x2050, 0xb004, 0x9005, 0x0198, 0xa80e, 0x2050, 0x8006, + 0x8006, 0x8007, 0x908c, 0x003f, 0x9084, 0xffc0, 0x9080, 0x0002, + 0xa07a, 0xa176, 0xb000, 0xa07e, 0x2810, 0x080c, 0x10f7, 0x00c8, + 0xa980, 0xa898, 0x0016, 0x0006, 0x080c, 0x6bf5, 0x000e, 0x001e, + 0xd1a4, 0x0128, 0x00c6, 0x2060, 0x080c, 0xa39d, 0x00ce, 0x7008, + 0x2048, 0xa8a3, 0x0000, 0xa8a7, 0x0000, 0x080c, 0x103f, 0x080c, + 0x1116, 0x00ae, 0x0005, 0x0126, 0x2091, 0x8000, 0x782b, 0x1001, + 0x7007, 0x0005, 0x7000, 0xc094, 0x7002, 0x012e, 0x0005, 0x7007, + 0x0000, 0x080c, 0x1127, 0x0005, 0x0126, 0x2091, 0x2200, 0x2079, + 0x0300, 0x2071, 0x1a41, 0x7003, 0x0000, 0x78bf, 0x00f6, 0x781b, + 0x4800, 0x00c1, 0x7803, 0x0003, 0x780f, 0x0000, 0x20a9, 0x0266, + 0x2061, 0xe114, 0x2c0d, 0x7912, 0xe104, 0x9ce0, 0x0002, 0x7916, + 0x1f04, 0x12da, 0x7807, 0x0007, 0x7803, 0x0000, 0x7803, 0x0001, + 0x012e, 0x0005, 0x00c6, 0x7803, 0x0000, 0x7808, 0xd09c, 0x0110, + 0x7820, 0x0cd8, 0x2001, 0x1a42, 0x2003, 0x0000, 0x78ab, 0x0004, + 0x78ac, 0xd0ac, 0x1de8, 0x78ab, 0x0002, 0x7807, 0x0007, 0x7827, + 0x0030, 0x782b, 0x0400, 0x7827, 0x0031, 0x782b, 0x1a64, 0x781f, + 0xff00, 0x781b, 0xb700, 0x2001, 0x0200, 0x2004, 0xd0dc, 0x0110, + 0x781f, 0x0303, 0x2061, 0x1a64, 0x602f, 0x1cd0, 0x2001, 0x1819, + 0x2004, 0x9082, 0x1cd0, 0x6032, 0x603b, 0x1fb8, 0x2001, 0x3268, + 0xd0fc, 0x190c, 0x0dc3, 0x2001, 0x1810, 0x2004, 0xd0c4, 0x1128, + 0x2001, 0x0003, 0x2004, 0xd0d4, 0x1118, 0x783f, 0x3268, 0x0020, + 0x9084, 0xc000, 0x783f, 0xb268, 0x00ce, 0x0005, 0x0126, 0x2091, + 0x2200, 0x7908, 0x9184, 0x0030, 0x190c, 0x0dbc, 0xd19c, 0x0158, + 0x7820, 0x908c, 0xf000, 0x15f0, 0x908a, 0x0024, 0x1a0c, 0x0dc3, + 0x0023, 0x012e, 0x0005, 0x012e, 0x0005, 0x1372, 0x1372, 0x1389, + 0x138e, 0x1392, 0x1397, 0x13bf, 0x13c3, 0x13d1, 0x13d5, 0x1372, + 0x1467, 0x146b, 0x14db, 0x1372, 0x1372, 0x1372, 0x1372, 0x1372, + 0x1372, 0x1372, 0x1372, 0x1372, 0x1372, 0x1372, 0x1372, 0x1372, + 0x1399, 0x1372, 0x1372, 0x1372, 0x1372, 0x1372, 0x1372, 0x1376, + 0x1374, 0x1372, 0x080c, 0x0dc3, 0x080c, 0x0dbc, 0x080c, 0x14e2, + 0x2009, 0x1a59, 0x2104, 0x8000, 0x200a, 0x080c, 0x7dcd, 0x080c, + 0x19e3, 0x0005, 0x2009, 0x0048, 0x2060, 0x080c, 0xa419, 0x012e, + 0x0005, 0x7004, 0xc085, 0xc0b5, 0x7006, 0x0005, 0x7004, 0xc085, + 0x7006, 0x0005, 0x080c, 0x14e2, 0x080c, 0x164b, 0x0005, 0x080c, + 0x0dc3, 0x080c, 0x14e2, 0x2060, 0x6014, 0x0096, 0x2048, 0xa83b, + 0xffff, 0x009e, 0x2009, 0x0048, 0x080c, 0xa419, 0x2001, 0x015d, + 0x2003, 0x0000, 0x2009, 0x03e8, 0x8109, 0x0160, 0x2001, 0x0201, + 0x2004, 0x9005, 0x0dc8, 0x2001, 0x0218, 0x2004, 0xd0ec, 0x1110, + 0x080c, 0x14e7, 0x2001, 0x0307, 0x2003, 0x8000, 0x0005, 0x7004, + 0xc095, 0x7006, 0x0005, 0x080c, 0x14e2, 0x2060, 0x6014, 0x0096, + 0x2048, 0xa83b, 0xffff, 0x009e, 0x2009, 0x0048, 0x080c, 0xa419, + 0x0005, 0x080c, 0x14e2, 0x080c, 0x0dc3, 0x080c, 0x14e2, 0x080c, + 0x1452, 0x7827, 0x0018, 0x79ac, 0xd1dc, 0x0540, 0x7827, 0x0015, + 0x7828, 0x782b, 0x0000, 0x9065, 0x0138, 0x2001, 0x020d, 0x2003, + 0x0050, 0x2003, 0x0020, 0x0400, 0x7004, 0x9005, 0x1180, 0x78ab, + 0x0004, 0x7827, 0x0018, 0x782b, 0x0000, 0xd1bc, 0x090c, 0x0dc3, + 0x2001, 0x020d, 0x2003, 0x0050, 0x2003, 0x0020, 0x04c0, 0x78ab, + 0x0004, 0x7803, 0x0001, 0x080c, 0x146b, 0x0005, 0x7828, 0x782b, + 0x0000, 0x9065, 0x090c, 0x0dc3, 0x6014, 0x2048, 0x78ab, 0x0004, + 0x918c, 0x0700, 0x01d8, 0x080c, 0x7dcd, 0x080c, 0x19e3, 0x080c, + 0xc1cd, 0x0158, 0xa9b0, 0xa936, 0xa9b4, 0xa93a, 0xa83f, 0xffff, + 0xa843, 0xffff, 0xa884, 0xc0bd, 0xa886, 0xa984, 0x9184, 0x0020, + 0x1120, 0xc1ad, 0xa986, 0x080c, 0xbde5, 0x0005, 0x6010, 0x00b6, + 0x2058, 0xb800, 0x00be, 0xd0bc, 0x6024, 0x190c, 0xc5b0, 0x2029, + 0x00c8, 0x8529, 0x0128, 0x2001, 0x0201, 0x2004, 0x9005, 0x0dc8, + 0x7dbc, 0x080c, 0xe0a1, 0xd5a4, 0x1118, 0x080c, 0x14e7, 0x0005, + 0x080c, 0x7dcd, 0x080c, 0x19e3, 0x0005, 0x781f, 0x0300, 0x7803, + 0x0001, 0x0005, 0x0016, 0x0066, 0x0076, 0x00f6, 0x2079, 0x0300, + 0x7908, 0x918c, 0x0007, 0x9186, 0x0003, 0x0120, 0x2001, 0x0016, + 0x080c, 0x1568, 0x00fe, 0x007e, 0x006e, 0x001e, 0x0005, 0x7004, + 0xc09d, 0x7006, 0x0005, 0x7104, 0x9184, 0x0004, 0x190c, 0x0dc3, + 0xd184, 0x11b1, 0xd19c, 0x0180, 0xc19c, 0x7106, 0x0016, 0x080c, + 0x162e, 0x001e, 0x0148, 0x2001, 0x020d, 0x2003, 0x0050, 0x2003, + 0x0020, 0x080c, 0x14e7, 0x0005, 0x81ff, 0x190c, 0x0dc3, 0x0005, + 0x2100, 0xc184, 0xc1b4, 0x7106, 0xd0b4, 0x0016, 0x00e6, 0x1904, + 0x14d0, 0x2071, 0x0200, 0x080c, 0x1622, 0x080c, 0x162e, 0x05a8, + 0x6014, 0x9005, 0x05a8, 0x0096, 0x2048, 0xa868, 0x009e, 0x9084, + 0x00ff, 0x908e, 0x0029, 0x0160, 0x908e, 0x0048, 0x1548, 0x601c, + 0xd084, 0x11d8, 0x00f6, 0x2c78, 0x080c, 0x16c1, 0x00fe, 0x00a8, + 0x00f6, 0x2c78, 0x080c, 0x1805, 0x00fe, 0x2009, 0x01f4, 0x8109, + 0x0160, 0x2001, 0x0201, 0x2004, 0x9005, 0x0dc8, 0x2001, 0x0218, + 0x2004, 0xd0ec, 0x1110, 0x0419, 0x0040, 0x2001, 0x020d, 0x2003, + 0x0020, 0x080c, 0x12ea, 0x7803, 0x0001, 0x00ee, 0x001e, 0x0005, + 0x080c, 0x162e, 0x0dd0, 0x2001, 0x020d, 0x2003, 0x0050, 0x2003, + 0x0020, 0x0069, 0x0c90, 0x0031, 0x2060, 0x2009, 0x0053, 0x080c, + 0xa419, 0x0005, 0x7808, 0xd09c, 0x0de8, 0x7820, 0x0005, 0x080c, + 0x1452, 0x00d6, 0x2069, 0x0200, 0x2009, 0x01f4, 0x8109, 0x0520, + 0x6804, 0x9005, 0x0dd8, 0x2001, 0x015d, 0x2003, 0x0000, 0x79bc, + 0xd1a4, 0x1578, 0x79b8, 0x918c, 0x0fff, 0x0180, 0x9182, 0x0841, + 0x1268, 0x9188, 0x0007, 0x918c, 0x0ff8, 0x810c, 0x810c, 0x810c, + 0x080c, 0x1554, 0x6827, 0x0001, 0x8109, 0x1dd0, 0x080c, 0x1554, + 0x6827, 0x0002, 0x080c, 0x1554, 0x6804, 0x9005, 0x1170, 0x682c, + 0xd0e4, 0x1540, 0x691c, 0x9184, 0x0014, 0x0120, 0x6830, 0x9084, + 0x9554, 0x15b9, 0x6804, 0x9005, 0x0da8, 0x79b8, 0xd1ec, 0x1130, + 0x0870, 0x080c, 0x7dcd, 0x080c, 0x19e3, 0x0090, 0x7827, 0x0015, + 0x782b, 0x0000, 0x7827, 0x0018, 0x782b, 0x0000, 0x2001, 0x020d, + 0x2003, 0x0020, 0x2001, 0x0307, 0x2003, 0x0300, 0x7803, 0x0001, + 0x00de, 0x0005, 0x682c, 0x9084, 0x5400, 0x9086, 0x5400, 0x0d30, + 0x7827, 0x0015, 0x782b, 0x0000, 0x7803, 0x0001, 0x6800, 0x9085, + 0x1800, 0x6802, 0x00de, 0x0005, 0x6824, 0x9084, 0x0003, 0x1de0, + 0x0005, 0x2079, 0x0001, 0x000e, 0x00f6, 0x0804, 0x0dc5, 0x2001, + 0x0030, 0x2c08, 0x621c, 0x0021, 0x7830, 0x9086, 0x0041, 0x0005, + 0x00f6, 0x2079, 0x0300, 0x0006, 0x7808, 0xd09c, 0x0140, 0x0016, + 0x0026, 0x00c6, 0x080c, 0x1336, 0x00ce, 0x002e, 0x001e, 0x000e, + 0x0006, 0x7832, 0x7936, 0x7a3a, 0x781b, 0x8080, 0x0059, 0x1118, + 0x000e, 0x00fe, 0x0005, 0x000e, 0x792c, 0x3900, 0x8000, 0x2004, + 0x080c, 0x0dc3, 0x2009, 0x180c, 0x2104, 0xc0f4, 0x200a, 0x2009, + 0xff00, 0x8109, 0x0904, 0x15e6, 0x7a18, 0x9284, 0x0030, 0x0904, + 0x15e1, 0x9284, 0x0048, 0x9086, 0x0008, 0x1904, 0x15e1, 0x2001, + 0x0109, 0x2004, 0xd08c, 0x01f0, 0x0006, 0x01c6, 0x01d6, 0x0136, + 0x0146, 0x0156, 0x0126, 0x2091, 0x2800, 0x00f6, 0x0026, 0x0016, + 0x2009, 0x1a5c, 0x2104, 0x8000, 0x0208, 0x200a, 0x080c, 0x885a, + 0x001e, 0x002e, 0x00fe, 0x012e, 0x015e, 0x014e, 0x013e, 0x01de, + 0x01ce, 0x000e, 0x2001, 0x009b, 0x2004, 0xd0fc, 0x01d0, 0x0006, + 0x0126, 0x01c6, 0x01d6, 0x0136, 0x0146, 0x0156, 0x00f6, 0x0016, + 0x2009, 0x1a5d, 0x2104, 0x8000, 0x0208, 0x200a, 0x080c, 0x1ddc, + 0x001e, 0x00fe, 0x015e, 0x014e, 0x013e, 0x01de, 0x01ce, 0x012e, + 0x000e, 0x7818, 0xd0bc, 0x1904, 0x1591, 0x0005, 0x2001, 0x180c, + 0x2004, 0xd0f4, 0x1528, 0x7a18, 0x9284, 0x0030, 0x0508, 0x9284, + 0x0048, 0x9086, 0x0008, 0x11e0, 0x2001, 0x19d3, 0x2004, 0x9005, + 0x01b8, 0x2001, 0x1a44, 0x2004, 0x9086, 0x0000, 0x0188, 0x2009, + 0x1a5b, 0x2104, 0x8000, 0x0208, 0x200a, 0x080c, 0x994f, 0x2009, + 0x180c, 0x2104, 0xc0f5, 0x200a, 0x2009, 0xff00, 0x0804, 0x1591, + 0x9085, 0x0001, 0x0005, 0x7832, 0x7936, 0x7a3a, 0x781b, 0x8080, + 0x080c, 0x158a, 0x1108, 0x0005, 0x792c, 0x3900, 0x8000, 0x2004, + 0x080c, 0x0dc3, 0x7037, 0x0001, 0x7150, 0x7037, 0x0002, 0x7050, + 0x2060, 0xd1bc, 0x1110, 0x7054, 0x2060, 0x0005, 0x0006, 0x0046, + 0x00e6, 0x2071, 0x0200, 0x7037, 0x0002, 0x7058, 0x9084, 0xff00, + 0x8007, 0x9086, 0x00bc, 0x1158, 0x2021, 0x1a5a, 0x2404, 0x8000, + 0x0208, 0x2022, 0x080c, 0x7dcd, 0x080c, 0x19e3, 0x9006, 0x00ee, + 0x004e, 0x000e, 0x0005, 0x0c11, 0x1108, 0x0005, 0x00e6, 0x0016, + 0x2071, 0x0200, 0x0879, 0x6120, 0x9186, 0x0000, 0x0904, 0x16b6, + 0x9186, 0x0002, 0x0904, 0x16b6, 0x6124, 0xd1dc, 0x01f8, 0x701c, + 0xd08c, 0x0904, 0x16b6, 0x7017, 0x0000, 0x2001, 0x0264, 0x2004, + 0xd0bc, 0x0904, 0x16b6, 0x2001, 0x0268, 0x00c6, 0x2064, 0x6104, + 0x6038, 0x00ce, 0x918e, 0x0039, 0x1904, 0x16b6, 0x9c06, 0x15f0, + 0x0126, 0x2091, 0x2600, 0x080c, 0x7d14, 0x012e, 0x7358, 0x745c, + 0x6014, 0x905d, 0x0598, 0x2b48, 0x6010, 0x00b6, 0x2058, 0xb800, + 0x00be, 0xd0bc, 0x190c, 0xc58b, 0xab42, 0xac3e, 0x2001, 0x1880, + 0x2004, 0xd0b4, 0x1170, 0x601c, 0xd0e4, 0x1158, 0x6010, 0x00b6, + 0x2058, 0xb800, 0x00be, 0xd0bc, 0x1120, 0xa83b, 0x7fff, 0xa837, + 0xffff, 0x080c, 0x1fd8, 0x1190, 0x080c, 0x1862, 0x2a00, 0xa816, 0x0130, 0x2800, 0xa80e, 0x2c05, 0xa80a, 0x2c00, 0xa812, 0x7037, 0x0020, 0x781f, 0x0300, 0x001e, 0x00ee, 0x0005, 0x7037, 0x0050, - 0x7037, 0x0020, 0x001e, 0x00ee, 0x080c, 0x14d2, 0x0005, 0x080c, - 0x0dc4, 0x2001, 0x180d, 0x2004, 0xd08c, 0x190c, 0x6818, 0x2ff0, + 0x7037, 0x0020, 0x001e, 0x00ee, 0x080c, 0x14e7, 0x0005, 0x080c, + 0x0dc3, 0x2001, 0x180d, 0x2004, 0xd08c, 0x190c, 0x693f, 0x2ff0, 0x0126, 0x2091, 0x2200, 0x0016, 0x00c6, 0x3e60, 0x6014, 0x2048, 0x2940, 0x903e, 0x2730, 0xa868, 0x2068, 0xa81a, 0x9d84, 0x000f, - 0x9088, 0x1f70, 0x2165, 0x0002, 0x16ab, 0x16f8, 0x16ab, 0x16ab, - 0x16ab, 0x16da, 0x16ab, 0x16af, 0x16a4, 0x16ef, 0x16ab, 0x16ab, - 0x16ab, 0x17b5, 0x16c3, 0x16b9, 0xa968, 0x918c, 0x00ff, 0x918e, - 0x0048, 0x0904, 0x16ef, 0x9085, 0x0001, 0x0804, 0x17ab, 0xa880, + 0x9088, 0x1fb8, 0x2165, 0x0002, 0x16f3, 0x1740, 0x16f3, 0x16f3, + 0x16f3, 0x1722, 0x16f3, 0x16f7, 0x16ec, 0x1737, 0x16f3, 0x16f3, + 0x16f3, 0x17fd, 0x170b, 0x1701, 0xa968, 0x918c, 0x00ff, 0x918e, + 0x0048, 0x0904, 0x1737, 0x9085, 0x0001, 0x0804, 0x17f3, 0xa880, 0xd0bc, 0x0dc8, 0xa894, 0xa842, 0xa890, 0xa83e, 0xa88c, 0x0804, - 0x16ff, 0xa880, 0xd0bc, 0x0d78, 0xa894, 0xa842, 0xa890, 0xa83e, - 0xa88c, 0x0804, 0x174e, 0xa880, 0xd0bc, 0x0d28, 0xa894, 0xa842, - 0xa890, 0xa83e, 0xa804, 0x9045, 0x090c, 0x0dc4, 0xa168, 0xa91a, - 0x91ec, 0x000f, 0x9d80, 0x1f70, 0x2065, 0xa88c, 0xd19c, 0x1904, - 0x174e, 0x0428, 0xa880, 0xd0ac, 0x0970, 0xa804, 0x9045, 0x090c, - 0x0dc4, 0xa168, 0xa91a, 0x91ec, 0x000f, 0x9d80, 0x1f70, 0x2065, - 0x9006, 0xa842, 0xa83e, 0xd19c, 0x1904, 0x174e, 0x0080, 0xa880, - 0xd0ac, 0x0904, 0x16ab, 0x9006, 0xa842, 0xa83e, 0x0804, 0x174e, - 0xa880, 0xd0ac, 0x0904, 0x16ab, 0x9006, 0xa842, 0xa83e, 0x2c05, - 0x908a, 0x0037, 0x1a0c, 0x0dc4, 0x9082, 0x001c, 0x0002, 0x1722, - 0x1722, 0x1724, 0x1722, 0x1722, 0x1722, 0x172a, 0x1722, 0x1722, - 0x1722, 0x1730, 0x1722, 0x1722, 0x1722, 0x1736, 0x1722, 0x1722, - 0x1722, 0x173c, 0x1722, 0x1722, 0x1722, 0x1742, 0x1722, 0x1722, - 0x1722, 0x1748, 0x080c, 0x0dc4, 0xa578, 0xa47c, 0xa380, 0xa284, - 0x0804, 0x1793, 0xa588, 0xa48c, 0xa390, 0xa294, 0x0804, 0x1793, - 0xa598, 0xa49c, 0xa3a0, 0xa2a4, 0x0804, 0x1793, 0xa5a8, 0xa4ac, - 0xa3b0, 0xa2b4, 0x0804, 0x1793, 0xa5b8, 0xa4bc, 0xa3c0, 0xa2c4, - 0x0804, 0x1793, 0xa5c8, 0xa4cc, 0xa3d0, 0xa2d4, 0x0804, 0x1793, - 0xa5d8, 0xa4dc, 0xa3e0, 0xa2e4, 0x0804, 0x1793, 0x2c05, 0x908a, - 0x0035, 0x1a0c, 0x0dc4, 0x9082, 0x001c, 0x0002, 0x1771, 0x176f, - 0x176f, 0x176f, 0x176f, 0x176f, 0x1778, 0x176f, 0x176f, 0x176f, - 0x176f, 0x176f, 0x177f, 0x176f, 0x176f, 0x176f, 0x176f, 0x176f, - 0x1786, 0x176f, 0x176f, 0x176f, 0x176f, 0x176f, 0x178d, 0x080c, - 0x0dc4, 0xa570, 0xa474, 0xa778, 0xa67c, 0xa380, 0xa284, 0x00d8, + 0x1747, 0xa880, 0xd0bc, 0x0d78, 0xa894, 0xa842, 0xa890, 0xa83e, + 0xa88c, 0x0804, 0x1796, 0xa880, 0xd0bc, 0x0d28, 0xa894, 0xa842, + 0xa890, 0xa83e, 0xa804, 0x9045, 0x090c, 0x0dc3, 0xa168, 0xa91a, + 0x91ec, 0x000f, 0x9d80, 0x1fb8, 0x2065, 0xa88c, 0xd19c, 0x1904, + 0x1796, 0x0428, 0xa880, 0xd0ac, 0x0970, 0xa804, 0x9045, 0x090c, + 0x0dc3, 0xa168, 0xa91a, 0x91ec, 0x000f, 0x9d80, 0x1fb8, 0x2065, + 0x9006, 0xa842, 0xa83e, 0xd19c, 0x1904, 0x1796, 0x0080, 0xa880, + 0xd0ac, 0x0904, 0x16f3, 0x9006, 0xa842, 0xa83e, 0x0804, 0x1796, + 0xa880, 0xd0ac, 0x0904, 0x16f3, 0x9006, 0xa842, 0xa83e, 0x2c05, + 0x908a, 0x0037, 0x1a0c, 0x0dc3, 0x9082, 0x001c, 0x0002, 0x176a, + 0x176a, 0x176c, 0x176a, 0x176a, 0x176a, 0x1772, 0x176a, 0x176a, + 0x176a, 0x1778, 0x176a, 0x176a, 0x176a, 0x177e, 0x176a, 0x176a, + 0x176a, 0x1784, 0x176a, 0x176a, 0x176a, 0x178a, 0x176a, 0x176a, + 0x176a, 0x1790, 0x080c, 0x0dc3, 0xa578, 0xa47c, 0xa380, 0xa284, + 0x0804, 0x17db, 0xa588, 0xa48c, 0xa390, 0xa294, 0x0804, 0x17db, + 0xa598, 0xa49c, 0xa3a0, 0xa2a4, 0x0804, 0x17db, 0xa5a8, 0xa4ac, + 0xa3b0, 0xa2b4, 0x0804, 0x17db, 0xa5b8, 0xa4bc, 0xa3c0, 0xa2c4, + 0x0804, 0x17db, 0xa5c8, 0xa4cc, 0xa3d0, 0xa2d4, 0x0804, 0x17db, + 0xa5d8, 0xa4dc, 0xa3e0, 0xa2e4, 0x0804, 0x17db, 0x2c05, 0x908a, + 0x0035, 0x1a0c, 0x0dc3, 0x9082, 0x001c, 0x0002, 0x17b9, 0x17b7, + 0x17b7, 0x17b7, 0x17b7, 0x17b7, 0x17c0, 0x17b7, 0x17b7, 0x17b7, + 0x17b7, 0x17b7, 0x17c7, 0x17b7, 0x17b7, 0x17b7, 0x17b7, 0x17b7, + 0x17ce, 0x17b7, 0x17b7, 0x17b7, 0x17b7, 0x17b7, 0x17d5, 0x080c, + 0x0dc3, 0xa570, 0xa474, 0xa778, 0xa67c, 0xa380, 0xa284, 0x00d8, 0xa588, 0xa48c, 0xa790, 0xa694, 0xa398, 0xa29c, 0x00a0, 0xa5a0, 0xa4a4, 0xa7a8, 0xa6ac, 0xa3b0, 0xa2b4, 0x0068, 0xa5b8, 0xa4bc, 0xa7c0, 0xa6c4, 0xa3c8, 0xa2cc, 0x0030, 0xa5d0, 0xa4d4, 0xa7d8, @@ -538,120 +547,120 @@ static const uint16_t isp_2300_risc_code 0xae2a, 0xa98c, 0x8c60, 0x2c1d, 0xa8b0, 0xaab4, 0xa836, 0xaa3a, 0x8109, 0xa916, 0x1160, 0x3e60, 0x601c, 0xc085, 0x601e, 0xa880, 0xc0dd, 0xa882, 0x9006, 0x00ce, 0x001e, 0x012e, 0x0005, 0x2800, - 0xa80e, 0xab0a, 0x2c00, 0xa812, 0x0c70, 0x0804, 0x16ab, 0x2001, - 0x180d, 0x2004, 0xd08c, 0x190c, 0x6818, 0x2ff0, 0x0126, 0x2091, + 0xa80e, 0xab0a, 0x2c00, 0xa812, 0x0c70, 0x0804, 0x16f3, 0x2001, + 0x180d, 0x2004, 0xd08c, 0x190c, 0x693f, 0x2ff0, 0x0126, 0x2091, 0x2200, 0x0016, 0x00c6, 0x3e60, 0x6014, 0x2048, 0x2940, 0xa80e, - 0x2061, 0x1f6b, 0xa813, 0x1f6b, 0x2c05, 0xa80a, 0xa968, 0xa91a, - 0xa880, 0xd0ac, 0x090c, 0x0dc4, 0x9006, 0xa842, 0xa83e, 0x2c05, - 0x908a, 0x0035, 0x1a0c, 0x0dc4, 0xadd0, 0xacd4, 0xafd8, 0xaedc, + 0x2061, 0x1fb3, 0xa813, 0x1fb3, 0x2c05, 0xa80a, 0xa968, 0xa91a, + 0xa880, 0xd0ac, 0x090c, 0x0dc3, 0x9006, 0xa842, 0xa83e, 0x2c05, + 0x908a, 0x0035, 0x1a0c, 0x0dc3, 0xadd0, 0xacd4, 0xafd8, 0xaedc, 0xabe0, 0xaae4, 0xab2e, 0xaa32, 0xad1e, 0xac22, 0xaf26, 0xae2a, 0xa8b0, 0xaab4, 0xa836, 0xaa3a, 0xa98c, 0xa868, 0x9084, 0x00ff, 0x9086, 0x0008, 0x1120, 0x8109, 0xa916, 0x0128, 0x0080, 0x918a, 0x0002, 0xa916, 0x1160, 0x3e60, 0x601c, 0xc085, 0x601e, 0xa880, 0xc0dd, 0xa882, 0x9006, 0x00ce, 0x001e, 0x012e, 0x0005, 0xa804, - 0x9045, 0x090c, 0x0dc4, 0xa80e, 0xa068, 0xa81a, 0x9084, 0x000f, - 0x9080, 0x1f70, 0x2015, 0x82ff, 0x090c, 0x0dc4, 0xaa12, 0x2205, + 0x9045, 0x090c, 0x0dc3, 0xa80e, 0xa068, 0xa81a, 0x9084, 0x000f, + 0x9080, 0x1fb8, 0x2015, 0x82ff, 0x090c, 0x0dc3, 0xaa12, 0x2205, 0xa80a, 0x0c08, 0x903e, 0x2730, 0xa884, 0xd0fc, 0x1190, 0x2d00, - 0x0002, 0x190f, 0x1871, 0x1871, 0x190f, 0x190f, 0x1909, 0x190f, - 0x1871, 0x18c0, 0x18c0, 0x18c0, 0x190f, 0x190f, 0x190f, 0x1906, - 0x18c0, 0xc0fc, 0xa886, 0xab2c, 0xaa30, 0xad1c, 0xac20, 0xdd9c, - 0x0904, 0x1911, 0x2c05, 0x908a, 0x0035, 0x1a0c, 0x0dc4, 0x9082, - 0x001c, 0x0002, 0x185d, 0x185b, 0x185b, 0x185b, 0x185b, 0x185b, - 0x1861, 0x185b, 0x185b, 0x185b, 0x185b, 0x185b, 0x1865, 0x185b, - 0x185b, 0x185b, 0x185b, 0x185b, 0x1869, 0x185b, 0x185b, 0x185b, - 0x185b, 0x185b, 0x186d, 0x080c, 0x0dc4, 0xa778, 0xa67c, 0x0804, - 0x1911, 0xa790, 0xa694, 0x0804, 0x1911, 0xa7a8, 0xa6ac, 0x0804, - 0x1911, 0xa7c0, 0xa6c4, 0x0804, 0x1911, 0xa7d8, 0xa6dc, 0x0804, - 0x1911, 0x2c05, 0x908a, 0x0037, 0x1a0c, 0x0dc4, 0x9082, 0x001c, - 0x0002, 0x1894, 0x1894, 0x1896, 0x1894, 0x1894, 0x1894, 0x189c, - 0x1894, 0x1894, 0x1894, 0x18a2, 0x1894, 0x1894, 0x1894, 0x18a8, - 0x1894, 0x1894, 0x1894, 0x18ae, 0x1894, 0x1894, 0x1894, 0x18b4, - 0x1894, 0x1894, 0x1894, 0x18ba, 0x080c, 0x0dc4, 0xa578, 0xa47c, *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:20:11 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 654071065674; Sun, 2 Sep 2012 15:20:11 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 45E1C8FC14; Sun, 2 Sep 2012 15:20:11 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82FKBHi024521; Sun, 2 Sep 2012 15:20:11 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82FKBmP024519; Sun, 2 Sep 2012 15:20:11 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021520.q82FKBmP024519@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:20:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240021 - stable/9/sys/cam/ctl X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:20:11 -0000 Author: mjacob Date: Sun Sep 2 15:20:10 2012 New Revision: 240021 URL: http://svn.freebsd.org/changeset/base/240021 Log: MFC of 238870. Handle a case where we had an SRR that pushed back the.. Modified: stable/9/sys/cam/ctl/scsi_ctl.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/cam/ctl/scsi_ctl.c ============================================================================== --- stable/9/sys/cam/ctl/scsi_ctl.c Sun Sep 2 15:18:08 2012 (r240020) +++ stable/9/sys/cam/ctl/scsi_ctl.c Sun Sep 2 15:20:10 2012 (r240021) @@ -1081,11 +1081,81 @@ ctlfe_free_ccb(struct cam_periph *periph } } +static int +ctlfe_adjust_cdb(struct ccb_accept_tio *atio, uint32_t offset) +{ + uint64_t lba; + uint32_t num_blocks, nbc; + uint8_t *cmdbyt = (atio->ccb_h.flags & CAM_CDB_POINTER)? + atio->cdb_io.cdb_ptr : atio->cdb_io.cdb_bytes; + + nbc = offset >> 9; /* ASSUMING 512 BYTE BLOCKS */ + + switch (cmdbyt[0]) { + case READ_6: + case WRITE_6: + { + struct scsi_rw_6 *cdb = (struct scsi_rw_6 *)cmdbyt; + lba = scsi_3btoul(cdb->addr); + lba &= 0x1fffff; + num_blocks = cdb->length; + if (num_blocks == 0) + num_blocks = 256; + lba += nbc; + num_blocks -= nbc; + scsi_ulto3b(lba, cdb->addr); + cdb->length = num_blocks; + break; + } + case READ_10: + case WRITE_10: + { + struct scsi_rw_10 *cdb = (struct scsi_rw_10 *)cmdbyt; + lba = scsi_4btoul(cdb->addr); + num_blocks = scsi_2btoul(cdb->length); + lba += nbc; + num_blocks -= nbc; + scsi_ulto4b(lba, cdb->addr); + scsi_ulto2b(num_blocks, cdb->length); + break; + } + case READ_12: + case WRITE_12: + { + struct scsi_rw_12 *cdb = (struct scsi_rw_12 *)cmdbyt; + lba = scsi_4btoul(cdb->addr); + num_blocks = scsi_4btoul(cdb->length); + lba += nbc; + num_blocks -= nbc; + scsi_ulto4b(lba, cdb->addr); + scsi_ulto4b(num_blocks, cdb->length); + break; + } + case READ_16: + case WRITE_16: + { + struct scsi_rw_16 *cdb = (struct scsi_rw_16 *)cmdbyt; + lba = scsi_8btou64(cdb->addr); + num_blocks = scsi_4btoul(cdb->length); + lba += nbc; + num_blocks -= nbc; + scsi_u64to8b(lba, cdb->addr); + scsi_ulto4b(num_blocks, cdb->length); + break; + } + default: + return -1; + } + return (0); +} + static void ctlfedone(struct cam_periph *periph, union ccb *done_ccb) { struct ctlfe_lun_softc *softc; struct ctlfe_softc *bus_softc; + struct ccb_accept_tio *atio = NULL; + union ctl_io *io = NULL; #ifdef CTLFE_DEBUG printf("%s: entered, func_code = %#x, type = %#lx\n", __func__, @@ -1123,13 +1193,12 @@ ctlfedone(struct cam_periph *periph, uni } switch (done_ccb->ccb_h.func_code) { case XPT_ACCEPT_TARGET_IO: { - union ctl_io *io; - struct ccb_accept_tio *atio; atio = &done_ccb->atio; softc->atios_returned++; + resubmit: /* * Allocate a ctl_io, pass it to CTL, and wait for the * datamove or done. @@ -1213,8 +1282,8 @@ ctlfedone(struct cam_periph *periph, uni break; } case XPT_CONT_TARGET_IO: { - struct ccb_accept_tio *atio; - union ctl_io *io; + int srr = 0; + uint32_t srr_off = 0; atio = (struct ccb_accept_tio *)done_ccb->ccb_h.ccb_atio; io = (union ctl_io *)atio->ccb_h.io_ptr; @@ -1225,6 +1294,57 @@ ctlfedone(struct cam_periph *periph, uni __func__, atio->tag_id, done_ccb->ccb_h.flags); #endif /* + * Handle SRR case were the data pointer is pushed back hack + */ + if ((done_ccb->ccb_h.status & CAM_STATUS_MASK) == CAM_MESSAGE_RECV + && done_ccb->csio.msg_ptr != NULL + && done_ccb->csio.msg_ptr[0] == MSG_EXTENDED + && done_ccb->csio.msg_ptr[1] == 5 + && done_ccb->csio.msg_ptr[2] == 0) { + srr = 1; + srr_off = + (done_ccb->csio.msg_ptr[3] << 24) + | (done_ccb->csio.msg_ptr[4] << 16) + | (done_ccb->csio.msg_ptr[5] << 8) + | (done_ccb->csio.msg_ptr[6]); + } + + if (srr && (done_ccb->ccb_h.flags & CAM_SEND_STATUS)) { + /* + * If status was being sent, the back end data is now + * history. Hack it up and resubmit a new command with + * the CDB adjusted. If the SIM does the right thing, + * all of the resid math should work. + */ + softc->ccbs_freed++; + xpt_release_ccb(done_ccb); + ctl_free_io(io); + if (ctlfe_adjust_cdb(atio, srr_off) == 0) { + done_ccb = (union ccb *)atio; + goto resubmit; + } + /* + * Fall through to doom.... + */ + } else if (srr) { + /* + * If we have an srr and we're still sending data, we + * should be able to adjust offsets and cycle again. + */ + io->scsiio.kern_rel_offset = + io->scsiio.ext_data_filled = srr_off; + io->scsiio.ext_data_len = io->scsiio.kern_total_len - + io->scsiio.kern_rel_offset; + softc->ccbs_freed++; + io->scsiio.io_hdr.status = CTL_STATUS_NONE; + xpt_release_ccb(done_ccb); + TAILQ_INSERT_HEAD(&softc->work_queue, &atio->ccb_h, + periph_links.tqe); + xpt_schedule(periph, /*priority*/ 1); + return; + } + + /* * If we were sending status back to the initiator, free up * resources. If we were doing a datamove, call the * datamove done routine. From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:21:56 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 34FE2106564A; Sun, 2 Sep 2012 15:21:56 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2023C8FC08; Sun, 2 Sep 2012 15:21:56 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82FLtGh024799; Sun, 2 Sep 2012 15:21:55 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82FLtqH024797; Sun, 2 Sep 2012 15:21:55 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021521.q82FLtqH024797@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:21:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240022 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:21:56 -0000 Author: mjacob Date: Sun Sep 2 15:21:55 2012 New Revision: 240022 URL: http://svn.freebsd.org/changeset/base/240022 Log: MFC of 238887- fix compilation on isp_sbus.c Modified: stable/9/sys/dev/isp/isp_sbus.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_sbus.c ============================================================================== --- stable/9/sys/dev/isp/isp_sbus.c Sun Sep 2 15:20:10 2012 (r240021) +++ stable/9/sys/dev/isp/isp_sbus.c Sun Sep 2 15:21:55 2012 (r240022) @@ -600,7 +600,7 @@ dma2(void *arg, bus_dma_segment_t *dm_se ddir = ISP_NOXFR; } - if (isp_send_cmd(isp, rq, dm_segs, nseg, XS_XFRLEN(csio), ddir) != CMD_QUEUED) { + if (isp_send_cmd(isp, rq, dm_segs, nseg, XS_XFRLEN(csio), ddir, NULL) != CMD_QUEUED) { mp->error = MUSHERR_NOQENTRIES; } } From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:23:01 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id ECD65106564A; Sun, 2 Sep 2012 15:23:01 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BE5B28FC18; Sun, 2 Sep 2012 15:23:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82FN1H8024991; Sun, 2 Sep 2012 15:23:01 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82FN1Aw024989; Sun, 2 Sep 2012 15:23:01 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021523.q82FN1Aw024989@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:23:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240023 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:23:02 -0000 Author: mjacob Date: Sun Sep 2 15:23:01 2012 New Revision: 240023 URL: http://svn.freebsd.org/changeset/base/240023 Log: MFC of 239010 Oops. We only do allocate room for extended commands and responses for 2300 cards are newer. Modified: stable/9/sys/dev/isp/isp_pci.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_pci.c ============================================================================== --- stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 15:21:55 2012 (r240022) +++ stable/9/sys/dev/isp/isp_pci.c Sun Sep 2 15:23:01 2012 (r240023) @@ -1482,16 +1482,18 @@ imc(void *arg, bus_dma_segment_t *segs, segs->ds_addr += ISP_QUEUE_SIZE(RESULT_QUEUE_LEN(imushp->isp)); imushp->vbase += ISP_QUEUE_SIZE(RESULT_QUEUE_LEN(imushp->isp)); - imushp->isp->isp_osinfo.ecmd_dma = segs->ds_addr; - imushp->isp->isp_osinfo.ecmd_free = (isp_ecmd_t *)imushp->vbase; - imushp->isp->isp_osinfo.ecmd_base = imushp->isp->isp_osinfo.ecmd_free; - for (ecmd = imushp->isp->isp_osinfo.ecmd_free; ecmd < &imushp->isp->isp_osinfo.ecmd_free[N_XCMDS]; ecmd++) { - if (ecmd == &imushp->isp->isp_osinfo.ecmd_free[N_XCMDS - 1]) { - ecmd->next = NULL; - } else { - ecmd->next = ecmd + 1; - } - } + if (imushp->isp->isp_type >= ISP_HA_FC_2300) { + imushp->isp->isp_osinfo.ecmd_dma = segs->ds_addr; + imushp->isp->isp_osinfo.ecmd_free = (isp_ecmd_t *)imushp->vbase; + imushp->isp->isp_osinfo.ecmd_base = imushp->isp->isp_osinfo.ecmd_free; + for (ecmd = imushp->isp->isp_osinfo.ecmd_free; ecmd < &imushp->isp->isp_osinfo.ecmd_free[N_XCMDS]; ecmd++) { + if (ecmd == &imushp->isp->isp_osinfo.ecmd_free[N_XCMDS - 1]) { + ecmd->next = NULL; + } else { + ecmd->next = ecmd + 1; + } + } + } #ifdef ISP_TARGET_MODE segs->ds_addr += (N_XCMDS * XCMD_SIZE); imushp->vbase += (N_XCMDS * XCMD_SIZE); From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:24:58 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 398C7106564A; Sun, 2 Sep 2012 15:24:58 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 23DA18FC14; Sun, 2 Sep 2012 15:24:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82FOvri025281; Sun, 2 Sep 2012 15:24:57 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82FOvkE025279; Sun, 2 Sep 2012 15:24:57 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021524.q82FOvkE025279@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:24:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240024 - stable/9/sys/cam/scsi X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:24:58 -0000 Author: mjacob Date: Sun Sep 2 15:24:57 2012 New Revision: 240024 URL: http://svn.freebsd.org/changeset/base/240024 Log: MFC of 239212 Add VERIFY_10 def. Modified: stable/9/sys/cam/scsi/scsi_all.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/cam/scsi/scsi_all.h ============================================================================== --- stable/9/sys/cam/scsi/scsi_all.h Sun Sep 2 15:23:01 2012 (r240023) +++ stable/9/sys/cam/scsi/scsi_all.h Sun Sep 2 15:24:57 2012 (r240024) @@ -984,6 +984,7 @@ struct ata_pass_16 { #define WRITE_10 0x2A #define POSITION_TO_ELEMENT 0x2B #define WRITE_VERIFY_10 0x2E +#define VERIFY_10 0x2F #define SYNCHRONIZE_CACHE 0x35 #define READ_DEFECT_DATA_10 0x37 #define WRITE_BUFFER 0x3B From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 15:27:20 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D4050106564A; Sun, 2 Sep 2012 15:27:20 +0000 (UTC) (envelope-from mjacob@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B44818FC0C; Sun, 2 Sep 2012 15:27:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82FRKTr025621; Sun, 2 Sep 2012 15:27:20 GMT (envelope-from mjacob@svn.freebsd.org) Received: (from mjacob@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82FRKd2025619; Sun, 2 Sep 2012 15:27:20 GMT (envelope-from mjacob@svn.freebsd.org) Message-Id: <201209021527.q82FRKd2025619@svn.freebsd.org> From: Matt Jacob Date: Sun, 2 Sep 2012 15:27:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240025 - stable/9/sys/dev/isp X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 15:27:21 -0000 Author: mjacob Date: Sun Sep 2 15:27:20 2012 New Revision: 240025 URL: http://svn.freebsd.org/changeset/base/240025 Log: MFC of 239023 Add detach logic to SBus variant. Modified: stable/9/sys/dev/isp/isp_sbus.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/isp/ (props changed) Modified: stable/9/sys/dev/isp/isp_sbus.c ============================================================================== --- stable/9/sys/dev/isp/isp_sbus.c Sun Sep 2 15:24:57 2012 (r240024) +++ stable/9/sys/dev/isp/isp_sbus.c Sun Sep 2 15:27:20 2012 (r240025) @@ -78,19 +78,22 @@ static struct ispmdvec mdvec = { static int isp_sbus_probe (device_t); static int isp_sbus_attach (device_t); +static int isp_sbus_detach (device_t); #define ISP_SBD(isp) ((struct isp_sbussoftc *)isp)->sbus_dev struct isp_sbussoftc { ispsoftc_t sbus_isp; device_t sbus_dev; - struct resource * sbus_reg; + struct resource * regs; + void * irq; + int iqd; + int rgd; void * ih; int16_t sbus_poff[_NREG_BLKS]; sdparam sbus_param; struct isp_spi sbus_spi; struct ispmdvec sbus_mdvec; - struct resource * sbus_ires; }; @@ -98,6 +101,7 @@ static device_method_t isp_sbus_methods[ /* Device interface */ DEVMETHOD(device_probe, isp_sbus_probe), DEVMETHOD(device_attach, isp_sbus_attach), + DEVMETHOD(device_detach, isp_sbus_detach), { 0, 0 } }; @@ -136,13 +140,21 @@ isp_sbus_probe(device_t dev) static int isp_sbus_attach(device_t dev) { - struct resource *regs; - int tval, iqd, isp_debug, role, rid, ispburst, default_id; + int tval, isp_debug, role, ispburst, default_id; struct isp_sbussoftc *sbs; ispsoftc_t *isp = NULL; int locksetup = 0; int ints_setup = 0; + sbs = device_get_softc(dev); + if (sbs == NULL) { + device_printf(dev, "cannot get softc\n"); + return (ENOMEM); + } + + sbs->sbus_dev = dev; + sbs->sbus_mdvec = mdvec; + /* * Figure out if we're supposed to skip this one. * If we are, we actually go to ISP_ROLE_NONE. @@ -165,23 +177,15 @@ isp_sbus_attach(device_t dev) role = ISP_DEFAULT_ROLES; } - sbs = malloc(sizeof (*sbs), M_DEVBUF, M_NOWAIT | M_ZERO); - if (sbs == NULL) { - device_printf(dev, "cannot allocate softc\n"); - return (ENOMEM); - } + sbs->irq = sbs->regs = NULL; + sbs->rgd = sbs->iqd = 0; - regs = NULL; - iqd = 0; - rid = 0; - regs = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &rid, RF_ACTIVE); - if (regs == 0) { + sbs->regs = bus_alloc_resource_any(dev, SYS_RES_MEMORY, &sbs->rgd, + RF_ACTIVE); + if (sbs->regs == NULL) { device_printf(dev, "unable to map registers\n"); goto bad; } - sbs->sbus_dev = dev; - sbs->sbus_reg = regs; - sbs->sbus_mdvec = mdvec; sbs->sbus_poff[BIU_BLOCK >> _BLK_REG_SHFT] = BIU_REGS_OFF; sbs->sbus_poff[MBOX_BLOCK >> _BLK_REG_SHFT] = SBUS_MBOX_REGS_OFF; @@ -189,8 +193,8 @@ isp_sbus_attach(device_t dev) sbs->sbus_poff[RISC_BLOCK >> _BLK_REG_SHFT] = SBUS_RISC_REGS_OFF; sbs->sbus_poff[DMA_BLOCK >> _BLK_REG_SHFT] = DMA_REGS_OFF; isp = &sbs->sbus_isp; - isp->isp_bus_tag = rman_get_bustag(regs); - isp->isp_bus_handle = rman_get_bushandle(regs); + isp->isp_bus_tag = rman_get_bustag(sbs->regs); + isp->isp_bus_handle = rman_get_bushandle(sbs->regs); isp->isp_mdvec = &sbs->sbus_mdvec; isp->isp_bustype = ISP_BT_SBUS; isp->isp_type = ISP_HA_SCSI_UNKNOWN; @@ -244,7 +248,6 @@ isp_sbus_attach(device_t dev) SDPARAM(isp, 0)->isp_ptisp = 1; } - isp->isp_osinfo.fw = firmware_get("isp_1000"); if (isp->isp_osinfo.fw) { union { @@ -280,16 +283,15 @@ isp_sbus_attach(device_t dev) mtx_init(&isp->isp_osinfo.lock, "isp", NULL, MTX_DEF); locksetup++; - iqd = 0; - sbs->sbus_ires = bus_alloc_resource_any(dev, SYS_RES_IRQ, &iqd, + sbs->irq = bus_alloc_resource_any(dev, SYS_RES_IRQ, &sbs->iqd, RF_ACTIVE | RF_SHAREABLE); - if (sbs->sbus_ires == NULL) { + if (sbs->irq == NULL) { device_printf(dev, "could not allocate interrupt\n"); goto bad; } - if (isp_setup_intr(dev, sbs->sbus_ires, ISP_IFLAGS, NULL, - isp_platform_intr, isp, &sbs->ih)) { + if (isp_setup_intr(dev, sbs->irq, ISP_IFLAGS, NULL, isp_platform_intr, + isp, &sbs->ih)) { device_printf(dev, "could not setup interrupt\n"); goto bad; } @@ -333,25 +335,49 @@ isp_sbus_attach(device_t dev) bad: if (sbs && ints_setup) { - (void) bus_teardown_intr(dev, sbs->sbus_ires, sbs->ih); + (void) bus_teardown_intr(dev, sbs->irq, sbs->ih); } - if (sbs && sbs->sbus_ires) { - bus_release_resource(dev, SYS_RES_IRQ, iqd, sbs->sbus_ires); + if (sbs && sbs->irq) { + bus_release_resource(dev, SYS_RES_IRQ, sbs->iqd, sbs->irq); } if (locksetup && isp) { mtx_destroy(&isp->isp_osinfo.lock); } - if (regs) { - (void) bus_release_resource(dev, SYS_RES_MEMORY, 0, regs); + if (sbs->regs) { + (void) bus_release_resource(dev, SYS_RES_MEMORY, sbs->rgd, + sbs->regs); } + return (ENXIO); +} - if (sbs) { - free(sbs, M_DEVBUF); +static int +isp_sbus_detach(device_t dev) +{ + struct isp_sbussoftc *sbs; + ispsoftc_t *isp; + int status; + + sbs = device_get_softc(dev); + if (sbs == NULL) { + return (ENXIO); } - return (ENXIO); + isp = (ispsoftc_t *) sbs; + status = isp_detach(isp); + if (status) + return (status); + ISP_LOCK(isp); + isp_uninit(isp); + if (sbs->ih) { + (void) bus_teardown_intr(dev, sbs->irq, sbs->ih); + } + ISP_UNLOCK(isp); + mtx_destroy(&isp->isp_osinfo.lock); + (void) bus_release_resource(dev, SYS_RES_IRQ, sbs->iqd, sbs->irq); + (void) bus_release_resource(dev, SYS_RES_MEMORY, sbs->rgd, sbs->regs); + return (0); } #define IspVirt2Off(a, x) \ From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 17:46:46 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E2648106564A; Sun, 2 Sep 2012 17:46:46 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id CDC5A8FC12; Sun, 2 Sep 2012 17:46:46 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82HkkPN043589; Sun, 2 Sep 2012 17:46:46 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82HkkJZ043587; Sun, 2 Sep 2012 17:46:46 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021746.q82HkkJZ043587@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 17:46:46 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240027 - stable/9/sys/dev/puc X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 17:46:47 -0000 Author: eadler Date: Sun Sep 2 17:46:46 2012 New Revision: 240027 URL: http://svn.freebsd.org/changeset/base/240027 Log: MFC r239048: Add additional Perle Speed LE serial cards PR: kern/168816 Approved by: cperciva (implicit) Modified: stable/9/sys/dev/puc/pucdata.c Directory Properties: stable/9/sys/dev/puc/ (props changed) Modified: stable/9/sys/dev/puc/pucdata.c ============================================================================== --- stable/9/sys/dev/puc/pucdata.c Sun Sep 2 17:39:02 2012 (r240026) +++ stable/9/sys/dev/puc/pucdata.c Sun Sep 2 17:46:46 2012 (r240027) @@ -768,11 +768,36 @@ const struct puc_cfg puc_pci_devices[] = */ { 0x155f, 0x0331, 0xffff, 0, + "Perle Ultraport4 Express", + DEFAULT_RCLK * 8, + PUC_PORT_4S, 0x10, 0, 8, + }, + + { 0x155f, 0xB012, 0xffff, 0, + "Perle Speed2 LE", + DEFAULT_RCLK * 8, + PUC_PORT_2S, 0x10, 0, 8, + }, + + { 0x155f, 0xB022, 0xffff, 0, + "Perle Speed2 LE", + DEFAULT_RCLK * 8, + PUC_PORT_2S, 0x10, 0, 8, + }, + + { 0x155f, 0xB004, 0xffff, 0, "Perle Speed4 LE", DEFAULT_RCLK * 8, PUC_PORT_4S, 0x10, 0, 8, }, + { 0x155f, 0xB008, 0xffff, 0, + "Perle Speed8 LE", + DEFAULT_RCLK * 8, + PUC_PORT_8S, 0x10, 0, 8, + }, + + /* * Oxford Semiconductor PCI Express Expresso family * From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:04:52 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 284B7106580D; Sun, 2 Sep 2012 18:04:51 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0D02B8FC17; Sun, 2 Sep 2012 18:04:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82I4op1045940; Sun, 2 Sep 2012 18:04:50 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82I4oP0045937; Sun, 2 Sep 2012 18:04:50 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021804.q82I4oP0045937@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:04:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240032 - stable/9/sys/dev/puc X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:04:52 -0000 Author: eadler Date: Sun Sep 2 18:04:50 2012 New Revision: 240032 URL: http://svn.freebsd.org/changeset/base/240032 Log: MFC r239076: Add support for SIIG Cyber Serial Dual PCI 16C850 Approved by: cperciva (implicit) Modified: stable/9/sys/dev/puc/pucdata.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/puc/ (props changed) Modified: stable/9/sys/dev/puc/pucdata.c ============================================================================== --- stable/9/sys/dev/puc/pucdata.c Sun Sep 2 18:04:27 2012 (r240031) +++ stable/9/sys/dev/puc/pucdata.c Sun Sep 2 18:04:50 2012 (r240032) @@ -737,6 +737,12 @@ const struct puc_cfg puc_pci_devices[] = PUC_PORT_2S, 0x10, 0, 8, }, + { 0x1415, 0x950a, 0x131f, 0x2032, + "SIIG Cyber Serial Dual PCI 16C850", + DEFAULT_RCLK * 10, + PUC_PORT_4S, 0x10, 0, 8, + }, + { 0x1415, 0x950a, 0xffff, 0, "Oxford Semiconductor OX16PCI954 UARTs", DEFAULT_RCLK, From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:08:42 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 403351065670; Sun, 2 Sep 2012 18:08:42 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2B1768FC0A; Sun, 2 Sep 2012 18:08:42 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82I8gBB046395; Sun, 2 Sep 2012 18:08:42 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82I8fji046393; Sun, 2 Sep 2012 18:08:41 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021808.q82I8fji046393@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:08:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240033 - stable/9/sbin/mount X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:08:42 -0000 Author: eadler Date: Sun Sep 2 18:08:41 2012 New Revision: 240033 URL: http://svn.freebsd.org/changeset/base/240033 Log: MFC r238399: Document the behavior of mount with failok specified. PR: docs/163742 Approved by: cperciva (implicit) Modified: stable/9/sbin/mount/mount.8 Directory Properties: stable/9/sbin/mount/ (props changed) Modified: stable/9/sbin/mount/mount.8 ============================================================================== --- stable/9/sbin/mount/mount.8 Sun Sep 2 18:04:50 2012 (r240032) +++ stable/9/sbin/mount/mount.8 Sun Sep 2 18:08:41 2012 (r240033) @@ -28,7 +28,7 @@ .\" @(#)mount.8 8.8 (Berkeley) 6/16/94 .\" $FreeBSD$ .\" -.Dd June 6, 2011 +.Dd July 12, 2012 .Dt MOUNT 8 .Os .Sh NAME @@ -145,6 +145,11 @@ When used with the .Fl u flag, this is the same as specifying the options currently in effect for the mounted file system. +.It Cm failok +If this option is specified, +.Nm +will return 0 even if an error occurs +during the mount of the filesystem. .It Cm force The same as .Fl f ; From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:10:29 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D68FC106567F; Sun, 2 Sep 2012 18:10:29 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C1C7C8FC17; Sun, 2 Sep 2012 18:10:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IATVi046664; Sun, 2 Sep 2012 18:10:29 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IATLu046662; Sun, 2 Sep 2012 18:10:29 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021810.q82IATLu046662@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:10:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240035 - stable/9/usr.sbin/ancontrol X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:10:30 -0000 Author: eadler Date: Sun Sep 2 18:10:29 2012 New Revision: 240035 URL: http://svn.freebsd.org/changeset/base/240035 Log: MFC r238221: Fix always 0 tautologly revealed by gcc46 Approved by: cperciva (implicit) Modified: stable/9/usr.sbin/ancontrol/ancontrol.c Directory Properties: stable/9/usr.sbin/ancontrol/ (props changed) Modified: stable/9/usr.sbin/ancontrol/ancontrol.c ============================================================================== --- stable/9/usr.sbin/ancontrol/ancontrol.c Sun Sep 2 18:08:46 2012 (r240034) +++ stable/9/usr.sbin/ancontrol/ancontrol.c Sun Sep 2 18:10:29 2012 (r240035) @@ -1443,7 +1443,7 @@ an_enable_leap_mode(const char *iface, c caps = (struct an_ltv_caps *)&areq; - if (!caps->an_softcaps & AN_AUTHTYPE_LEAP) { + if (!(caps->an_softcaps & AN_AUTHTYPE_LEAP)) { fprintf(stderr, "Firmware does not support LEAP\n"); exit(1); } From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:13:23 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id F03AA106566C; Sun, 2 Sep 2012 18:13:22 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DBC658FC1E; Sun, 2 Sep 2012 18:13:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IDM5f047162; Sun, 2 Sep 2012 18:13:22 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IDM7j047160; Sun, 2 Sep 2012 18:13:22 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021813.q82IDM7j047160@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:13:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240039 - stable/9/sys/dev/ata/chipsets X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:13:23 -0000 Author: eadler Date: Sun Sep 2 18:13:22 2012 New Revision: 240039 URL: http://svn.freebsd.org/changeset/base/240039 Log: MFC r238203: Remove variables which are initialized but never used thereafter reported by gcc46 warning Approved by: cperciva (implicit) Modified: stable/9/sys/dev/ata/chipsets/ata-via.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/ata/chipsets/ata-via.c ============================================================================== --- stable/9/sys/dev/ata/chipsets/ata-via.c Sun Sep 2 18:13:18 2012 (r240038) +++ stable/9/sys/dev/ata/chipsets/ata-via.c Sun Sep 2 18:13:22 2012 (r240039) @@ -472,12 +472,10 @@ ata_via_sata_reset(device_t dev) static int ata_via_sata_scr_read(device_t dev, int port, int reg, u_int32_t *result) { - struct ata_channel *ch; device_t parent; uint32_t val; parent = device_get_parent(dev); - ch = device_get_softc(dev); port = (port == 1) ? 1 : 0; switch (reg) { case ATA_SSTATUS: @@ -520,12 +518,10 @@ ata_via_sata_scr_read(device_t dev, int static int ata_via_sata_scr_write(device_t dev, int port, int reg, u_int32_t value) { - struct ata_channel *ch; device_t parent; uint32_t val; parent = device_get_parent(dev); - ch = device_get_softc(dev); port = (port == 1) ? 1 : 0; switch (reg) { case ATA_SERROR: From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:17:20 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AD33610656F8; Sun, 2 Sep 2012 18:17:20 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 8AD938FC17; Sun, 2 Sep 2012 18:17:20 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IHKKK047883; Sun, 2 Sep 2012 18:17:20 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IHK74047881; Sun, 2 Sep 2012 18:17:20 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021817.q82IHK74047881@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:17:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240043 - stable/9/sys/dev/aac X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:17:20 -0000 Author: eadler Date: Sun Sep 2 18:17:20 2012 New Revision: 240043 URL: http://svn.freebsd.org/changeset/base/240043 Log: MFC r238201: Remove variables which are initialized but never used thereafter reported by gcc46 warning Approved by: cperciva (implicit) Modified: stable/9/sys/dev/aac/aac_disk.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/aac/aac_disk.c ============================================================================== --- stable/9/sys/dev/aac/aac_disk.c Sun Sep 2 18:17:16 2012 (r240042) +++ stable/9/sys/dev/aac/aac_disk.c Sun Sep 2 18:17:20 2012 (r240043) @@ -332,9 +332,6 @@ aac_disk_dump(void *arg, void *virtual, void aac_biodone(struct bio *bp) { - struct aac_disk *sc; - - sc = (struct aac_disk *)bp->bio_disk->d_drv1; fwprintf(NULL, HBA_FLAGS_DBG_FUNCTION_ENTRY_B, ""); if (bp->bio_flags & BIO_ERROR) From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:19:41 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D62D31065673; Sun, 2 Sep 2012 18:19:41 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C17498FC16; Sun, 2 Sep 2012 18:19:41 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IJfg8048235; Sun, 2 Sep 2012 18:19:41 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IJfGZ048232; Sun, 2 Sep 2012 18:19:41 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021819.q82IJfGZ048232@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:19:41 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240045 - stable/9/sys/vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:19:42 -0000 Author: eadler Date: Sun Sep 2 18:19:41 2012 New Revision: 240045 URL: http://svn.freebsd.org/changeset/base/240045 Log: MFC r238206: Add missing sleep stat increase PR: kern/168211 Approved by: cperciva (implicit) Modified: stable/9/sys/vm/uma_core.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/vm/uma_core.c ============================================================================== --- stable/9/sys/vm/uma_core.c Sun Sep 2 18:19:37 2012 (r240044) +++ stable/9/sys/vm/uma_core.c Sun Sep 2 18:19:41 2012 (r240045) @@ -2166,6 +2166,7 @@ keg_fetch_slab(uma_keg_t keg, uma_zone_t zone->uz_flags |= UMA_ZFLAG_FULL; if (flags & M_NOWAIT) break; + zone->uz_sleeps++; msleep(keg, &keg->uk_lock, PVM, "keglimit", 0); continue; } From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:28:09 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D8E34106566B; Sun, 2 Sep 2012 18:28:09 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C37988FC14; Sun, 2 Sep 2012 18:28:09 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IS9Uc049339; Sun, 2 Sep 2012 18:28:09 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IS9e0049337; Sun, 2 Sep 2012 18:28:09 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021828.q82IS9e0049337@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:28:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240046 - stable/9/sbin/growfs X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:28:10 -0000 Author: eadler Date: Sun Sep 2 18:28:09 2012 New Revision: 240046 URL: http://svn.freebsd.org/changeset/base/240046 Log: MFC r238204: Remove unneeded variable reported by gcc46 which stopped being used in r234178. Approved by: cperciva (implicit) Modified: stable/9/sbin/growfs/growfs.c Directory Properties: stable/9/sbin/growfs/ (props changed) Modified: stable/9/sbin/growfs/growfs.c ============================================================================== --- stable/9/sbin/growfs/growfs.c Sun Sep 2 18:19:41 2012 (r240045) +++ stable/9/sbin/growfs/growfs.c Sun Sep 2 18:28:09 2012 (r240046) @@ -803,7 +803,6 @@ updcsloc(time_t modtime, int fsi, int fs DBG_FUNC("updcsloc") struct csum *cs; int ocscg, ncscg; - int blocks; ufs2_daddr_t d; int lcs = 0; int block; @@ -820,8 +819,6 @@ updcsloc(time_t modtime, int fsi, int fs } ocscg = dtog(&osblock, osblock.fs_csaddr); cs = fscs + ocscg; - blocks = 1 + howmany(sblock.fs_cssize, sblock.fs_bsize) - - howmany(osblock.fs_cssize, osblock.fs_bsize); /* * Read original cylinder group from disk, and make a copy. From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:31:23 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AE5851065670; Sun, 2 Sep 2012 18:31:23 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 990D48FC16; Sun, 2 Sep 2012 18:31:23 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IVNtt049749; Sun, 2 Sep 2012 18:31:23 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IVN9w049746; Sun, 2 Sep 2012 18:31:23 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021831.q82IVN9w049746@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:31:23 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240047 - stable/9/sys/cam/scsi X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:31:23 -0000 Author: eadler Date: Sun Sep 2 18:31:23 2012 New Revision: 240047 URL: http://svn.freebsd.org/changeset/base/240047 Log: MFC r238200: Remove variables which are initialized but never used thereafter reported by gcc46 warning Approved by: cperciva (implicit) Modified: stable/9/sys/cam/scsi/scsi_all.c stable/9/sys/cam/scsi/scsi_ch.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/cam/scsi/scsi_all.c ============================================================================== --- stable/9/sys/cam/scsi/scsi_all.c Sun Sep 2 18:28:09 2012 (r240046) +++ stable/9/sys/cam/scsi/scsi_all.c Sun Sep 2 18:31:23 2012 (r240047) @@ -4148,9 +4148,9 @@ scsi_sense_desc_sbuf(struct sbuf *sb, st struct scsi_inquiry_data *inq_data, struct scsi_sense_desc_header *header) { - int i, found; + int i; - for (i = 0, found = 0; i < (sizeof(scsi_sense_printers) / + for (i = 0; i < (sizeof(scsi_sense_printers) / sizeof(scsi_sense_printers[0])); i++) { struct scsi_sense_desc_printer *printer; Modified: stable/9/sys/cam/scsi/scsi_ch.c ============================================================================== --- stable/9/sys/cam/scsi/scsi_ch.c Sun Sep 2 18:28:09 2012 (r240046) +++ stable/9/sys/cam/scsi/scsi_ch.c Sun Sep 2 18:31:23 2012 (r240047) @@ -433,17 +433,11 @@ static int chclose(struct cdev *dev, int flag, int fmt, struct thread *td) { struct cam_periph *periph; - struct ch_softc *softc; - int error; - - error = 0; periph = (struct cam_periph *)dev->si_drv1; if (periph == NULL) return(ENXIO); - softc = (struct ch_softc *)periph->softc; - cam_periph_release(periph); return(0); From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:33:51 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B6E2F1065794; Sun, 2 Sep 2012 18:33:51 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 918F28FC1B; Sun, 2 Sep 2012 18:33:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IXprU050153; Sun, 2 Sep 2012 18:33:51 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IXppZ050151; Sun, 2 Sep 2012 18:33:51 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021833.q82IXppZ050151@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:33:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240050 - stable/9/sys/dev/acpica X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:33:52 -0000 Author: eadler Date: Sun Sep 2 18:33:51 2012 New Revision: 240050 URL: http://svn.freebsd.org/changeset/base/240050 Log: MFC r238199: Remove variables which are initialized but never used thereafter reported by gcc46 warning Approved by: cperciva (implicit) Modified: stable/9/sys/dev/acpica/acpi_powerres.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/acpica/acpi_powerres.c ============================================================================== --- stable/9/sys/dev/acpica/acpi_powerres.c Sun Sep 2 18:33:47 2012 (r240049) +++ stable/9/sys/dev/acpica/acpi_powerres.c Sun Sep 2 18:33:51 2012 (r240050) @@ -314,7 +314,6 @@ acpi_pwr_switch_consumer(ACPI_HANDLE con ACPI_OBJECT *reslist_object; ACPI_STATUS status; char *method_name, *reslist_name; - int res_changed; ACPI_FUNCTION_TRACE((char *)(uintptr_t)__func__); @@ -445,7 +444,7 @@ acpi_pwr_switch_consumer(ACPI_HANDLE con * Now we are ready to switch, so kill off any current power * resource references. */ - res_changed = acpi_pwr_dereference_resource(pc); + acpi_pwr_dereference_resource(pc); /* * Add new power resource references, if we have any. Traverse the @@ -457,7 +456,6 @@ acpi_pwr_switch_consumer(ACPI_HANDLE con reslist_object->Package.Count)); acpi_ForeachPackageObject(reslist_object, acpi_pwr_reference_resource, pc); - res_changed = 1; } /* From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:40:20 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CE71510656F3; Sun, 2 Sep 2012 18:40:18 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6600D8FC12; Sun, 2 Sep 2012 18:40:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IeI3u050982; Sun, 2 Sep 2012 18:40:18 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IeI2w050980; Sun, 2 Sep 2012 18:40:18 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021840.q82IeI2w050980@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:40:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240053 - stable/9/share/syscons/keymaps X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:40:20 -0000 Author: eadler Date: Sun Sep 2 18:40:17 2012 New Revision: 240053 URL: http://svn.freebsd.org/changeset/base/240053 Log: MFC r235251,r238205: Add Spanish Dvorak keyboard model to syscons. (not verified to be accurate) PR: conf/160235 Approved by: cperciva (implicit) Modified: stable/9/share/syscons/keymaps/INDEX.keymaps Directory Properties: stable/9/share/syscons/keymaps/ (props changed) Modified: stable/9/share/syscons/keymaps/INDEX.keymaps ============================================================================== --- stable/9/share/syscons/keymaps/INDEX.keymaps Sun Sep 2 18:40:14 2012 (r240052) +++ stable/9/share/syscons/keymaps/INDEX.keymaps Sun Sep 2 18:40:17 2012 (r240053) @@ -378,6 +378,8 @@ ru.koi8-r.win.kbd:pt:Russo koi8-r (winke ru.koi8-r.win.kbd:es:Ruso koi8-r (winkeys) ru.koi8-r.win.kbd:uk:òÏÓ¦ÊÓØËÁ koi8-r (winkeys) +spanish.dvorak.kbd:en:Spanish Dvorak + spanish.iso.kbd:en:Spanish ISO-8859-1 spanish.iso.kbd:de:Spanisch ISO-8859-1 spanish.iso.kbd:fr:Espagnol ISO-8859-1 From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:44:48 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3E5301065791; Sun, 2 Sep 2012 18:44:48 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2900C8FC15; Sun, 2 Sep 2012 18:44:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IimTJ051641; Sun, 2 Sep 2012 18:44:48 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82Iil9m051639; Sun, 2 Sep 2012 18:44:47 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021844.q82Iil9m051639@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:44:47 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240056 - stable/9/share/man/man4 X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:44:48 -0000 Author: eadler Date: Sun Sep 2 18:44:47 2012 New Revision: 240056 URL: http://svn.freebsd.org/changeset/base/240056 Log: MFC r237178,r237180: Fix mdoc style nits PR: kern/168910 Approved by: cperciva (implicit) Modified: stable/9/share/man/man4/hptrr.4 Directory Properties: stable/9/share/man/man4/ (props changed) Modified: stable/9/share/man/man4/hptrr.4 ============================================================================== --- stable/9/share/man/man4/hptrr.4 Sun Sep 2 18:44:43 2012 (r240055) +++ stable/9/share/man/man4/hptrr.4 Sun Sep 2 18:44:47 2012 (r240056) @@ -24,7 +24,7 @@ .\" .\" $FreeBSD$ .\" -.Dd November 8, 2009 +.Dd June 6, 2012 .Dt HPTRR 4 .Os .Sh NAME @@ -51,7 +51,10 @@ The following tunables are settable from .Bl -ohang .It Va hw.hptrr.attach_generic set to 1 to permit driver attach to chips with generic Marvell (non-HighPoint) -PCI identification. These chips are also supported by ata(4) and mvs(4). +PCI identification. These chips are also supported by +.Xr ata 4 +and +.Xr mvs 4 . Some vendors are using same chips, but without providing RAID BIOS. .El .Sh DESCRIPTION @@ -112,8 +115,8 @@ This driver supersedes the older rr232x .Xr ata 4 , .Xr cam 4 , .Xr hptmv 4 , -.Xr loader 8 , -.Xr mvs 4 +.Xr mvs 4 , +.Xr loader 8 .Sh HISTORY The .Nm From owner-svn-src-stable-9@FreeBSD.ORG Sun Sep 2 18:54:51 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id B9F121065673; Sun, 2 Sep 2012 18:54:51 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A3A5A8FC16; Sun, 2 Sep 2012 18:54:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q82IspRu053207; Sun, 2 Sep 2012 18:54:51 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q82IspLY053203; Sun, 2 Sep 2012 18:54:51 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209021854.q82IspLY053203@svn.freebsd.org> From: Eitan Adler Date: Sun, 2 Sep 2012 18:54:51 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240059 - in stable/9: sys/netinet/libalias usr.bin/gzip usr.bin/usbhidctl X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Sep 2012 18:54:51 -0000 Author: eadler Date: Sun Sep 2 18:54:51 2012 New Revision: 240059 URL: http://svn.freebsd.org/changeset/base/240059 Log: MFC r236596: Fix style nit: don't use leading zero for dates in .Dd Approved by: cperciva (implicit) Modified: stable/9/sys/netinet/libalias/libalias.3 stable/9/usr.bin/gzip/zmore.1 stable/9/usr.bin/usbhidctl/usbhidctl.1 Directory Properties: stable/9/sys/ (props changed) stable/9/usr.bin/gzip/ (props changed) stable/9/usr.bin/usbhidctl/ (props changed) Modified: stable/9/sys/netinet/libalias/libalias.3 ============================================================================== --- stable/9/sys/netinet/libalias/libalias.3 Sun Sep 2 18:54:47 2012 (r240058) +++ stable/9/sys/netinet/libalias/libalias.3 Sun Sep 2 18:54:51 2012 (r240059) @@ -25,7 +25,7 @@ .\" .\" $FreeBSD$ .\" -.Dd July 04, 2011 +.Dd July 4, 2011 .Dt LIBALIAS 3 .Os .Sh NAME Modified: stable/9/usr.bin/gzip/zmore.1 ============================================================================== --- stable/9/usr.bin/gzip/zmore.1 Sun Sep 2 18:54:47 2012 (r240058) +++ stable/9/usr.bin/gzip/zmore.1 Sun Sep 2 18:54:51 2012 (r240059) @@ -20,7 +20,7 @@ .\" Materiel Command, USAF, under agreement number F39502-99-1-0512. .\" .\" $FreeBSD$ -.Dd February 06, 2011 +.Dd February 6, 2011 .Dt ZMORE 1 .Os .Sh NAME Modified: stable/9/usr.bin/usbhidctl/usbhidctl.1 ============================================================================== --- stable/9/usr.bin/usbhidctl/usbhidctl.1 Sun Sep 2 18:54:47 2012 (r240058) +++ stable/9/usr.bin/usbhidctl/usbhidctl.1 Sun Sep 2 18:54:51 2012 (r240059) @@ -28,7 +28,7 @@ .\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE .\" POSSIBILITY OF SUCH DAMAGE. .\" -.Dd August 01, 2011 +.Dd August 1, 2011 .Dt USBHIDCTL 1 .Os .Sh NAME From owner-svn-src-stable-9@FreeBSD.ORG Mon Sep 3 07:18:25 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 8A762106564A; Mon, 3 Sep 2012 07:18:25 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6B1228FC12; Mon, 3 Sep 2012 07:18:25 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q837IPLS040723; Mon, 3 Sep 2012 07:18:25 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q837IPuh040721; Mon, 3 Sep 2012 07:18:25 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201209030718.q837IPuh040721@svn.freebsd.org> From: Dimitry Andric Date: Mon, 3 Sep 2012 07:18:25 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240066 - stable/9/tools/build/mk X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 03 Sep 2012 07:18:25 -0000 Author: dim Date: Mon Sep 3 07:18:24 2012 New Revision: 240066 URL: http://svn.freebsd.org/changeset/base/240066 Log: MFC r239715: Add libc++ and libcxxrt related files to OptionalObsoleteFiles.inc. Modified: stable/9/tools/build/mk/OptionalObsoleteFiles.inc Directory Properties: stable/9/tools/ (props changed) stable/9/tools/build/ (props changed) Modified: stable/9/tools/build/mk/OptionalObsoleteFiles.inc ============================================================================== --- stable/9/tools/build/mk/OptionalObsoleteFiles.inc Mon Sep 3 02:32:00 2012 (r240065) +++ stable/9/tools/build/mk/OptionalObsoleteFiles.inc Mon Sep 3 07:18:24 2012 (r240066) @@ -2695,6 +2695,121 @@ OLD_FILES+=usr/share/man/man8/verify_krb # to be filled in #.endif +.if ${MK_LIBCPLUSPLUS} == no +OLD_LIBS+=lib/libcxxrt.so.1 +OLD_FILES+=usr/lib/libc++.a +OLD_FILES+=usr/lib/libc++_p.a +OLD_FILES+=usr/lib/libc++.so +OLD_LIBS+=usr/lib/libc++.so.1 +OLD_FILES+=usr/lib/libcxxrt.a +OLD_FILES+=usr/lib/libcxxrt.so +OLD_FILES+=usr/lib/libcxxrt_p.a +OLD_FILES+=usr/include/c++/v1/__bit_reference +OLD_FILES+=usr/include/c++/v1/__config +OLD_FILES+=usr/include/c++/v1/__debug +OLD_FILES+=usr/include/c++/v1/__functional_03 +OLD_FILES+=usr/include/c++/v1/__functional_base +OLD_FILES+=usr/include/c++/v1/__functional_base_03 +OLD_FILES+=usr/include/c++/v1/__hash_table +OLD_FILES+=usr/include/c++/v1/__locale +OLD_FILES+=usr/include/c++/v1/__mutex_base +OLD_FILES+=usr/include/c++/v1/__split_buffer +OLD_FILES+=usr/include/c++/v1/__sso_allocator +OLD_FILES+=usr/include/c++/v1/__std_stream +OLD_FILES+=usr/include/c++/v1/__tree +OLD_FILES+=usr/include/c++/v1/__tuple +OLD_FILES+=usr/include/c++/v1/__tuple_03 +OLD_FILES+=usr/include/c++/v1/__undef_min_max +OLD_FILES+=usr/include/c++/v1/algorithm +OLD_FILES+=usr/include/c++/v1/array +OLD_FILES+=usr/include/c++/v1/atomic +OLD_FILES+=usr/include/c++/v1/bitset +OLD_FILES+=usr/include/c++/v1/cassert +OLD_FILES+=usr/include/c++/v1/ccomplex +OLD_FILES+=usr/include/c++/v1/cctype +OLD_FILES+=usr/include/c++/v1/cerrno +OLD_FILES+=usr/include/c++/v1/cfenv +OLD_FILES+=usr/include/c++/v1/cfloat +OLD_FILES+=usr/include/c++/v1/chrono +OLD_FILES+=usr/include/c++/v1/cinttypes +OLD_FILES+=usr/include/c++/v1/ciso646 +OLD_FILES+=usr/include/c++/v1/climits +OLD_FILES+=usr/include/c++/v1/clocale +OLD_FILES+=usr/include/c++/v1/cmath +OLD_FILES+=usr/include/c++/v1/codecvt +OLD_FILES+=usr/include/c++/v1/complex +OLD_FILES+=usr/include/c++/v1/complex.h +OLD_FILES+=usr/include/c++/v1/condition_variable +OLD_FILES+=usr/include/c++/v1/csetjmp +OLD_FILES+=usr/include/c++/v1/csignal +OLD_FILES+=usr/include/c++/v1/cstdarg +OLD_FILES+=usr/include/c++/v1/cstdbool +OLD_FILES+=usr/include/c++/v1/cstddef +OLD_FILES+=usr/include/c++/v1/cstdint +OLD_FILES+=usr/include/c++/v1/cstdio +OLD_FILES+=usr/include/c++/v1/cstdlib +OLD_FILES+=usr/include/c++/v1/cstring +OLD_FILES+=usr/include/c++/v1/ctgmath +OLD_FILES+=usr/include/c++/v1/ctime +OLD_FILES+=usr/include/c++/v1/cwchar +OLD_FILES+=usr/include/c++/v1/cwctype +OLD_FILES+=usr/include/c++/v1/cxxabi.h +OLD_FILES+=usr/include/c++/v1/deque +OLD_FILES+=usr/include/c++/v1/exception +OLD_FILES+=usr/include/c++/v1/ext/__hash +OLD_FILES+=usr/include/c++/v1/ext/hash_map +OLD_FILES+=usr/include/c++/v1/ext/hash_set +OLD_FILES+=usr/include/c++/v1/forward_list +OLD_FILES+=usr/include/c++/v1/fstream +OLD_FILES+=usr/include/c++/v1/functional +OLD_FILES+=usr/include/c++/v1/future +OLD_FILES+=usr/include/c++/v1/initializer_list +OLD_FILES+=usr/include/c++/v1/iomanip +OLD_FILES+=usr/include/c++/v1/ios +OLD_FILES+=usr/include/c++/v1/iosfwd +OLD_FILES+=usr/include/c++/v1/iostream +OLD_FILES+=usr/include/c++/v1/istream +OLD_FILES+=usr/include/c++/v1/iterator +OLD_FILES+=usr/include/c++/v1/limits +OLD_FILES+=usr/include/c++/v1/list +OLD_FILES+=usr/include/c++/v1/locale +OLD_FILES+=usr/include/c++/v1/map +OLD_FILES+=usr/include/c++/v1/memory +OLD_FILES+=usr/include/c++/v1/mutex +OLD_FILES+=usr/include/c++/v1/new +OLD_FILES+=usr/include/c++/v1/numeric +OLD_FILES+=usr/include/c++/v1/ostream +OLD_FILES+=usr/include/c++/v1/queue +OLD_FILES+=usr/include/c++/v1/random +OLD_FILES+=usr/include/c++/v1/ratio +OLD_FILES+=usr/include/c++/v1/regex +OLD_FILES+=usr/include/c++/v1/scoped_allocator +OLD_FILES+=usr/include/c++/v1/set +OLD_FILES+=usr/include/c++/v1/sstream +OLD_FILES+=usr/include/c++/v1/stack +OLD_FILES+=usr/include/c++/v1/stdexcept +OLD_FILES+=usr/include/c++/v1/streambuf +OLD_FILES+=usr/include/c++/v1/string +OLD_FILES+=usr/include/c++/v1/strstream +OLD_FILES+=usr/include/c++/v1/system_error +OLD_FILES+=usr/include/c++/v1/tgmath.h +OLD_FILES+=usr/include/c++/v1/thread +OLD_FILES+=usr/include/c++/v1/tuple +OLD_FILES+=usr/include/c++/v1/type_traits +OLD_FILES+=usr/include/c++/v1/typeindex +OLD_FILES+=usr/include/c++/v1/typeinfo +OLD_FILES+=usr/include/c++/v1/unordered_map +OLD_FILES+=usr/include/c++/v1/unordered_set +OLD_FILES+=usr/include/c++/v1/unwind-arm.h +OLD_FILES+=usr/include/c++/v1/unwind-itanium.h +OLD_FILES+=usr/include/c++/v1/unwind.h +OLD_FILES+=usr/include/c++/v1/utility +OLD_FILES+=usr/include/c++/v1/valarray +OLD_FILES+=usr/include/c++/v1/vector +OLD_DIRS+=usr/include/c++/v1/ext +OLD_DIRS+=usr/include/c++/v1 +.endif + #.if ${MK_LIBTHR} == no # to be filled in #.endif From owner-svn-src-stable-9@FreeBSD.ORG Tue Sep 4 15:58:59 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 29FE11065670; Tue, 4 Sep 2012 15:58:59 +0000 (UTC) (envelope-from jimharris@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 143C78FC14; Tue, 4 Sep 2012 15:58:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q84FwwYU080034; Tue, 4 Sep 2012 15:58:58 GMT (envelope-from jimharris@svn.freebsd.org) Received: (from jimharris@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q84Fwwbw080032; Tue, 4 Sep 2012 15:58:58 GMT (envelope-from jimharris@svn.freebsd.org) Message-Id: <201209041558.q84Fwwbw080032@svn.freebsd.org> From: Jim Harris Date: Tue, 4 Sep 2012 15:58:58 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240089 - stable/9/sys/dev/isci/scil X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Sep 2012 15:58:59 -0000 Author: jimharris Date: Tue Sep 4 15:58:58 2012 New Revision: 240089 URL: http://svn.freebsd.org/changeset/base/240089 Log: MFC r239889: Do not call sati_check_data_io() for SATI_UNMAP sequences. This routine is intended only for commands such as INQUIRY where the controller may fill out a smaller amount of data than allocated by the host. The end result of this bug was that isci(4) would report non-zero resid for successful SCSI_UNMAP commands. Sponsored by: Intel Modified: stable/9/sys/dev/isci/scil/sati.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/isci/scil/sati.c ============================================================================== --- stable/9/sys/dev/isci/scil/sati.c Tue Sep 4 12:27:23 2012 (r240088) +++ stable/9/sys/dev/isci/scil/sati.c Tue Sep 4 15:58:58 2012 (r240089) @@ -1095,10 +1095,6 @@ SATI_STATUS sati_translate_command_respo status = sati_unmap_translate_response( sequence, scsi_io, ata_io ); - if(status == SATI_COMPLETE) - { - status = sati_check_data_io(sequence); - } break; #endif // !defined(DISABLE_SATI_UNMAP) From owner-svn-src-stable-9@FreeBSD.ORG Tue Sep 4 17:24:12 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 67BA9106564A; Tue, 4 Sep 2012 17:24:12 +0000 (UTC) (envelope-from jimharris@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 521738FC15; Tue, 4 Sep 2012 17:24:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q84HOC6F091782; Tue, 4 Sep 2012 17:24:12 GMT (envelope-from jimharris@svn.freebsd.org) Received: (from jimharris@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q84HOCVF091780; Tue, 4 Sep 2012 17:24:12 GMT (envelope-from jimharris@svn.freebsd.org) Message-Id: <201209041724.q84HOCVF091780@svn.freebsd.org> From: Jim Harris Date: Tue, 4 Sep 2012 17:24:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240093 - stable/9/usr.sbin/pmcstat X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Sep 2012 17:24:12 -0000 Author: jimharris Date: Tue Sep 4 17:24:11 2012 New Revision: 240093 URL: http://svn.freebsd.org/changeset/base/240093 Log: MFC r239571: Add -m option (for printing sampled PCs to a file) to pmcstat usage message. Modified: stable/9/usr.sbin/pmcstat/pmcstat.c Directory Properties: stable/9/usr.sbin/pmcstat/ (props changed) Modified: stable/9/usr.sbin/pmcstat/pmcstat.c ============================================================================== --- stable/9/usr.sbin/pmcstat/pmcstat.c Tue Sep 4 17:15:19 2012 (r240092) +++ stable/9/usr.sbin/pmcstat/pmcstat.c Tue Sep 4 17:24:11 2012 (r240093) @@ -509,6 +509,7 @@ pmcstat_show_usage(void) "\t -f spec\t pass \"spec\" to as plugin option\n" "\t -g\t\t produce gprof(1) compatible profiles\n" "\t -k dir\t\t set the path to the kernel\n" + "\t -m file\t print sampled PCs to \"file\"\n" "\t -n rate\t set sampling rate\n" "\t -o file\t send print output to \"file\"\n" "\t -p spec\t allocate a process-private counting PMC\n" From owner-svn-src-stable-9@FreeBSD.ORG Tue Sep 4 19:14:58 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 324F5106567B; Tue, 4 Sep 2012 19:14:58 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1A45D8FC12; Tue, 4 Sep 2012 19:14:58 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q84JEv4J005538; Tue, 4 Sep 2012 19:14:57 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q84JEvd4005534; Tue, 4 Sep 2012 19:14:57 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201209041914.q84JEvd4005534@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Tue, 4 Sep 2012 19:14:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240097 - in stable/9/sys: amd64/include boot/common i386/include X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Sep 2012 19:14:58 -0000 Author: des Date: Tue Sep 4 19:14:57 2012 New Revision: 240097 URL: http://svn.freebsd.org/changeset/base/240097 Log: MFH (r239255, r239730): increase maxswzone on i386 and remove it on amd64. Modified: stable/9/sys/amd64/include/param.h stable/9/sys/boot/common/loader.8 stable/9/sys/i386/include/param.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/boot/ (props changed) Modified: stable/9/sys/amd64/include/param.h ============================================================================== --- stable/9/sys/amd64/include/param.h Tue Sep 4 19:04:02 2012 (r240096) +++ stable/9/sys/amd64/include/param.h Tue Sep 4 19:14:57 2012 (r240097) @@ -123,14 +123,6 @@ #define KSTACK_GUARD_PAGES 1 /* pages of kstack guard; 0 disables */ /* - * Ceiling on amount of swblock kva space, can be changed via - * the kern.maxswzone /boot/loader.conf variable. - */ -#ifndef VM_SWZONE_SIZE_MAX -#define VM_SWZONE_SIZE_MAX (32 * 1024 * 1024) -#endif - -/* * Mach derived conversion macros */ #define round_page(x) ((((unsigned long)(x)) + PAGE_MASK) & ~(PAGE_MASK)) Modified: stable/9/sys/boot/common/loader.8 ============================================================================== --- stable/9/sys/boot/common/loader.8 Tue Sep 4 19:04:02 2012 (r240096) +++ stable/9/sys/boot/common/loader.8 Tue Sep 4 19:14:57 2012 (r240097) @@ -613,17 +613,26 @@ Not all architectures use such buffers; for details. .It Va kern.maxswzone Limits the amount of KVM to be used to hold swap -meta information, which directly governs the -maximum amount of swap the system can support. -This value is specified in bytes of KVA space -and defaults to 32MBytes on i386 and amd64. -Care should be taken -to not reduce this value such that the actual -amount of configured swap exceeds 1/2 the -kernel-supported swap. -The default of 32MB allows -the kernel to support a maximum of ~7GB of swap. -Only change +metadata, which directly governs the +maximum amount of swap the system can support, +at the rate of approximately 200 MB of swap space +per 1 MB of metadata. +This value is specified in bytes of KVA space. +If no value is provided, the system allocates +enough memory to handle an amount of swap +that corresponds to eight times the amount of +physical memory present in the system. +.Pp +Note that swap metadata can be fragmented, +which means that the system can run out of +space before it reaches the theoretical limit. +Therefore, care should be taken to not configure +more swap than approximately half of the +theoretical maximum. +.Pp +Running out of space for swap metadata can leave +the system in an unrecoverable state. +Therefore, you should only change this parameter if you need to greatly extend the KVM reservation for other resources such as the buffer cache or Modified: stable/9/sys/i386/include/param.h ============================================================================== --- stable/9/sys/i386/include/param.h Tue Sep 4 19:04:02 2012 (r240096) +++ stable/9/sys/i386/include/param.h Tue Sep 4 19:14:57 2012 (r240097) @@ -125,9 +125,15 @@ /* * Ceiling on amount of swblock kva space, can be changed via * the kern.maxswzone /boot/loader.conf variable. + * + * 276 is sizeof(struct swblock), but we do not always have a definition + * in scope for struct swblock, so we have to hardcode it. Each struct + * swblock holds metadata for 32 pages, so in theory, this is enough for + * 16 GB of swap. In practice, however, the usable amount is considerably + * lower due to fragmentation. */ #ifndef VM_SWZONE_SIZE_MAX -#define VM_SWZONE_SIZE_MAX (32 * 1024 * 1024) +#define VM_SWZONE_SIZE_MAX (276 * 128 * 1024) #endif /* From owner-svn-src-stable-9@FreeBSD.ORG Tue Sep 4 20:45:59 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D59C1106564A; Tue, 4 Sep 2012 20:45:59 +0000 (UTC) (envelope-from des@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C00B58FC08; Tue, 4 Sep 2012 20:45:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q84KjxLU016295; Tue, 4 Sep 2012 20:45:59 GMT (envelope-from des@svn.freebsd.org) Received: (from des@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q84KjxmT016293; Tue, 4 Sep 2012 20:45:59 GMT (envelope-from des@svn.freebsd.org) Message-Id: <201209042045.q84KjxmT016293@svn.freebsd.org> From: Dag-Erling Smørgrav Date: Tue, 4 Sep 2012 20:45:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240102 - stable/9/sbin/geom/class/part X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Sep 2012 20:46:00 -0000 Author: des Date: Tue Sep 4 20:45:59 2012 New Revision: 240102 URL: http://svn.freebsd.org/changeset/base/240102 Log: MFH (r239836): align the boot partition on a 4 kB boundary. Modified: stable/9/sbin/geom/class/part/gpart.8 Directory Properties: stable/9/sbin/geom/ (props changed) stable/9/sbin/geom/class/part/ (props changed) Modified: stable/9/sbin/geom/class/part/gpart.8 ============================================================================== --- stable/9/sbin/geom/class/part/gpart.8 Tue Sep 4 20:14:37 2012 (r240101) +++ stable/9/sbin/geom/class/part/gpart.8 Tue Sep 4 20:45:59 2012 (r240102) @@ -1006,11 +1006,12 @@ or but smaller than 545 kB since the first-stage loader will load the entire partition into memory during boot, regardless of how much data it actually contains. -This example uses 94 blocks (47 kB) so the next partition will be +This example uses 88 blocks (44 kB) so the next partition will be aligned on a 64 kB boundary without the need to specify an explicit offset or alignment. +The boot partition itself is aligned on a 4 kB boundary. .Bd -literal -offset indent -/sbin/gpart add -b 34 -s 94 -t freebsd-boot ad0 +/sbin/gpart add -b 40 -s 88 -t freebsd-boot ad0 /sbin/gpart bootcode -p /boot/gptboot -i 1 ad0 .Ed .Pp From owner-svn-src-stable-9@FreeBSD.ORG Tue Sep 4 23:24:01 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 646321065675; Tue, 4 Sep 2012 23:24:01 +0000 (UTC) (envelope-from delphij@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4CFCB8FC0A; Tue, 4 Sep 2012 23:24:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q84NO1tN036003; Tue, 4 Sep 2012 23:24:01 GMT (envelope-from delphij@svn.freebsd.org) Received: (from delphij@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q84NO1Jg035988; Tue, 4 Sep 2012 23:24:01 GMT (envelope-from delphij@svn.freebsd.org) Message-Id: <201209042324.q84NO1Jg035988@svn.freebsd.org> From: Xin LI Date: Tue, 4 Sep 2012 23:24:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240121 - in stable/9: contrib/less usr.bin/less X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Sep 2012 23:24:01 -0000 Author: delphij Date: Tue Sep 4 23:24:00 2012 New Revision: 240121 URL: http://svn.freebsd.org/changeset/base/240121 Log: MFC: less v451. Modified: stable/9/contrib/less/LICENSE stable/9/contrib/less/Makefile.aut stable/9/contrib/less/NEWS stable/9/contrib/less/README stable/9/contrib/less/brac.c stable/9/contrib/less/ch.c stable/9/contrib/less/charset.c stable/9/contrib/less/charset.h stable/9/contrib/less/cmd.h stable/9/contrib/less/cmdbuf.c stable/9/contrib/less/command.c stable/9/contrib/less/configure stable/9/contrib/less/configure.ac stable/9/contrib/less/cvt.c stable/9/contrib/less/decode.c stable/9/contrib/less/defines.ds stable/9/contrib/less/defines.h.in stable/9/contrib/less/defines.o2 stable/9/contrib/less/defines.o9 stable/9/contrib/less/defines.wn stable/9/contrib/less/edit.c stable/9/contrib/less/filename.c stable/9/contrib/less/forwback.c stable/9/contrib/less/funcs.h stable/9/contrib/less/help.c stable/9/contrib/less/ifile.c stable/9/contrib/less/input.c stable/9/contrib/less/jump.c stable/9/contrib/less/less.h stable/9/contrib/less/less.hlp stable/9/contrib/less/less.man stable/9/contrib/less/less.nro stable/9/contrib/less/lessecho.c stable/9/contrib/less/lessecho.man stable/9/contrib/less/lessecho.nro stable/9/contrib/less/lesskey.c stable/9/contrib/less/lesskey.h stable/9/contrib/less/lesskey.man stable/9/contrib/less/lesskey.nro stable/9/contrib/less/lglob.h stable/9/contrib/less/line.c stable/9/contrib/less/linenum.c stable/9/contrib/less/lsystem.c stable/9/contrib/less/main.c stable/9/contrib/less/mark.c stable/9/contrib/less/mkhelp.c stable/9/contrib/less/optfunc.c stable/9/contrib/less/option.c stable/9/contrib/less/option.h stable/9/contrib/less/opttbl.c stable/9/contrib/less/os.c stable/9/contrib/less/output.c stable/9/contrib/less/pattern.c stable/9/contrib/less/pattern.h stable/9/contrib/less/pckeys.h stable/9/contrib/less/position.c stable/9/contrib/less/position.h stable/9/contrib/less/prompt.c stable/9/contrib/less/screen.c stable/9/contrib/less/scrsize.c stable/9/contrib/less/search.c stable/9/contrib/less/signal.c stable/9/contrib/less/tags.c stable/9/contrib/less/ttyin.c stable/9/contrib/less/version.c stable/9/usr.bin/less/defines.h Directory Properties: stable/9/contrib/less/ (props changed) stable/9/usr.bin/less/ (props changed) Modified: stable/9/contrib/less/LICENSE ============================================================================== --- stable/9/contrib/less/LICENSE Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/LICENSE Tue Sep 4 23:24:00 2012 (r240121) @@ -2,7 +2,7 @@ ------------ Less -Copyright (C) 1984-2011 Mark Nudelman +Copyright (C) 1984-2012 Mark Nudelman Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions Modified: stable/9/contrib/less/Makefile.aut ============================================================================== --- stable/9/contrib/less/Makefile.aut Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/Makefile.aut Tue Sep 4 23:24:00 2012 (r240121) @@ -1,6 +1,6 @@ # Makefile for authoring less. -EMAIL = markn@greenwoodsoftware.com +EMAIL = bug-less@gnu.org HOMEPAGE = http://www.greenwoodsoftware.com/less SHELL = /bin/sh RCS = rcs @@ -112,8 +112,7 @@ dist: ${DISTFILES} echo "Preparing $$REL"; \ rm -rf $$REL; mkdir $$REL; \ for file in ${DISTFILES}; do \ - cp -p $$file $$REL; \ - chmod -w $$REL/$$file; \ + ./add_copyright $$file $$REL; \ done; \ cd $$REL; chmod +w ${DISTFILES_W}; cd ..; \ echo "Creating release/$$REL/$$REL.tar.gz"; \ Modified: stable/9/contrib/less/NEWS ============================================================================== --- stable/9/contrib/less/NEWS Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/NEWS Tue Sep 4 23:24:00 2012 (r240121) @@ -7,8 +7,34 @@ http://www.greenwoodsoftware.com/less You can also download the latest version of less from there. - To report bugs, suggestions or comments, send email to - bug-less@gnu.org or markn@greenwoodsoftware.com. + To report bugs, suggestions or comments, send email to bug-less@gnu.org. + +====================================================================== + + Major changes between "less" versions 444 and 451 + +* Add ESC-F command to keep reading data until a pattern is found. + +* Use exit code of LESSOPEN script if LESSOPEN starts with "||". + +* When up/down arrow is used on the command line immediately after + typing text, the next command starting with that text is found. + +* Add support for GNU regex. + +* Add configure option --with-regex=none and fix compile errors + when compiling with no regex library. + +* Fix bugs handling SGR sequences in Win32. + +* Fix possible crashes caused by malformed LESSOPEN or + LESSCLOSE variables. + +* Fix bug highlighting text which is discontiguous in the file + due to backspace processing. + +* Fix bug in displaying status column when scrolling backwards + with -J and -S in effect. ====================================================================== Modified: stable/9/contrib/less/README ============================================================================== --- stable/9/contrib/less/README Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/README Tue Sep 4 23:24:00 2012 (r240121) @@ -7,9 +7,9 @@ ************************************************************************** ************************************************************************** - Less, version 444 + Less, version 451 - This is the distribution of less, version 444, released 09 Jun 2011. + This is the distribution of less, version 451, released 21 Jul 2012. This program is part of the GNU project (http://www.gnu.org). This program is free software. You may redistribute it and/or @@ -21,7 +21,7 @@ or 2. The Less License, in the file LICENSE. - Please report any problems to bug-less@gnu.org or markn@greenwoodsoftware.com. + Please report any problems to bug-less@gnu.org. See http://www.greenwoodsoftware.com/less for the latest info. ========================================================================= @@ -60,10 +60,11 @@ INSTALLATION (Unix systems only): regcomp Use the V8-compatible regcomp. regcomp-local Use Henry Spencer's V8-compatible regcomp (source is supplied with less). + none No regular expressions, only simple string matching. --with-secure Builds a "secure" version of less, with some features disabled - to prevent users from viewing other files, accessing shell - commands, etc. + to prevent users from viewing other files, accessing shell + commands, etc. 3. It is a good idea to look over the generated Makefile and defines.h @@ -96,7 +97,7 @@ INSTALLATION (Unix systems only): bindir and/or mandir to the appropriate directories. If you have any problems building or running "less", suggestions, -complaints, etc., you may mail to the author at markn@greenwoodsoftware.com. +complaints, etc., you may mail to bug-less@gnu.org. Note to hackers: comments noting possible improvements are enclosed in double curly brackets {{ like this }}. Modified: stable/9/contrib/less/brac.c ============================================================================== --- stable/9/contrib/less/brac.c Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/brac.c Tue Sep 4 23:24:00 2012 (r240121) @@ -1,11 +1,10 @@ /* - * Copyright (C) 1984-2011 Mark Nudelman + * Copyright (C) 1984-2012 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. * - * For more information about less, or for information on how to - * contact the author, see the README file. + * For more information, see the README file. */ Modified: stable/9/contrib/less/ch.c ============================================================================== --- stable/9/contrib/less/ch.c Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/ch.c Tue Sep 4 23:24:00 2012 (r240121) @@ -1,11 +1,10 @@ /* - * Copyright (C) 1984-2011 Mark Nudelman + * Copyright (C) 1984-2012 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. * - * For more information about less, or for information on how to - * contact the author, see the README file. + * For more information, see the README file. */ @@ -582,6 +581,8 @@ ch_length() return (NULL_POSITION); if (ch_flags & CH_HELPFILE) return (size_helpdata); + if (ch_flags & CH_NODATA) + return (0); return (ch_fsize); } @@ -806,6 +807,17 @@ seekable(f) } /* + * Force EOF to be at the current read position. + * This is used after an ignore_eof read, during which the EOF may change. + */ + public void +ch_set_eof() +{ + ch_fsize = ch_fpos; +} + + +/* * Initialize file state for a new file. */ public void Modified: stable/9/contrib/less/charset.c ============================================================================== --- stable/9/contrib/less/charset.c Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/charset.c Tue Sep 4 23:24:00 2012 (r240121) @@ -1,11 +1,10 @@ /* - * Copyright (C) 1984-2011 Mark Nudelman + * Copyright (C) 1984-2012 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. * - * For more information about less, or for information on how to - * contact the author, see the README file. + * For more information, see the README file. */ Modified: stable/9/contrib/less/charset.h ============================================================================== --- stable/9/contrib/less/charset.h Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/charset.h Tue Sep 4 23:24:00 2012 (r240121) @@ -1,11 +1,10 @@ /* - * Copyright (C) 2005-2011 Mark Nudelman + * Copyright (C) 1984-2012 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. * - * For more information about less, or for information on how to - * contact the author, see the README file. + * For more information, see the README file. */ #define IS_ASCII_OCTET(c) (((c) & 0x80) == 0) Modified: stable/9/contrib/less/cmd.h ============================================================================== --- stable/9/contrib/less/cmd.h Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/cmd.h Tue Sep 4 23:24:00 2012 (r240121) @@ -1,15 +1,14 @@ /* - * Copyright (C) 1984-2011 Mark Nudelman + * Copyright (C) 1984-2012 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. * - * For more information about less, or for information on how to - * contact the author, see the README file. + * For more information, see the README file. */ -#define MAX_USERCMD 500 +#define MAX_USERCMD 1000 #define MAX_CMDLEN 16 #define A_B_LINE 2 @@ -66,6 +65,7 @@ #define A_NEXT_TAG 53 #define A_PREV_TAG 54 #define A_FILTER 55 +#define A_F_UNTIL_HILITE 56 #define A_INVALID 100 #define A_NOACTION 101 @@ -78,7 +78,7 @@ #define A_EXTRA 0200 -/* Line editting characters */ +/* Line editing characters */ #define EC_BACKSPACE 1 #define EC_LINEKILL 2 Modified: stable/9/contrib/less/cmdbuf.c ============================================================================== --- stable/9/contrib/less/cmdbuf.c Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/cmdbuf.c Tue Sep 4 23:24:00 2012 (r240121) @@ -1,11 +1,10 @@ /* - * Copyright (C) 1984-2011 Mark Nudelman + * Copyright (C) 1984-2012 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. * - * For more information about less, or for information on how to - * contact the author, see the README file. + * For more information, see the README file. */ @@ -30,6 +29,7 @@ static int prompt_col; /* Column of cur static char *cp; /* Pointer into cmdbuf */ static int cmd_offset; /* Index into cmdbuf of first displayed char */ static int literal; /* Next input char should not be interpreted */ +static int updown_match = -1; /* Prefix length in up/down movement */ #if TAB_COMPLETE_FILENAME static int cmd_complete(); @@ -122,6 +122,7 @@ cmd_reset() cmd_offset = 0; literal = 0; cmd_mbc_buf_len = 0; + updown_match = -1; } /* @@ -132,6 +133,7 @@ clear_cmd() { cmd_col = prompt_col = 0; cmd_mbc_buf_len = 0; + updown_match = -1; } /* @@ -504,6 +506,7 @@ cmd_ichar(cs, clen) /* * Reprint the tail of the line from the inserted char. */ + updown_match = -1; cmd_repaint(cp); cmd_right(); return (CC_OK); @@ -547,6 +550,7 @@ cmd_erase() /* * Repaint the buffer after the erased char. */ + updown_match = -1; cmd_repaint(cp); /* @@ -643,6 +647,7 @@ cmd_kill() cmd_offset = 0; cmd_home(); *cp = '\0'; + updown_match = -1; cmd_repaint(cp); /* @@ -675,12 +680,15 @@ set_mlist(mlist, cmdflags) #if CMD_HISTORY /* * Move up or down in the currently selected command history list. + * Only consider entries whose first updown_match chars are equal to + * cmdbuf's corresponding chars. */ static int cmd_updown(action) int action; { char *s; + struct mlist *ml; if (curr_mlist == NULL) { @@ -690,24 +698,47 @@ cmd_updown(action) bell(); return (CC_OK); } - cmd_home(); - clear_eol(); + + if (updown_match < 0) + { + updown_match = cp - cmdbuf; + } + /* - * Move curr_mp to the next/prev entry. + * Find the next history entry which matches. */ - if (action == EC_UP) - curr_mlist->curr_mp = curr_mlist->curr_mp->prev; - else - curr_mlist->curr_mp = curr_mlist->curr_mp->next; - /* - * Copy the entry into cmdbuf and echo it on the screen. - */ - s = curr_mlist->curr_mp->string; - if (s == NULL) - s = ""; - strcpy(cmdbuf, s); - for (cp = cmdbuf; *cp != '\0'; ) - cmd_right(); + for (ml = curr_mlist->curr_mp;;) + { + ml = (action == EC_UP) ? ml->prev : ml->next; + if (ml == curr_mlist) + { + /* + * We reached the end (or beginning) of the list. + */ + break; + } + if (strncmp(cmdbuf, ml->string, updown_match) == 0) + { + /* + * This entry matches; stop here. + * Copy the entry into cmdbuf and echo it on the screen. + */ + curr_mlist->curr_mp = ml; + s = ml->string; + if (s == NULL) + s = ""; + strcpy(cmdbuf, s); + cmd_home(); + clear_eol(); + for (cp = cmdbuf; *cp != '\0'; ) + cmd_right(); + return (CC_OK); + } + } + /* + * We didn't find a history entry that matches. + */ + bell(); return (CC_OK); } #endif @@ -1056,7 +1087,11 @@ init_compl() tk_text = fcomplete(word); } else { +#if MSDOS_COMPILER + char *qword = NULL; +#else char *qword = shell_quote(word+1); +#endif if (qword == NULL) tk_text = fcomplete(word+1); else @@ -1457,9 +1492,6 @@ save_cmdhist() FILE *f; int modified = 0; - filename = histfile_name(); - if (filename == NULL) - return; if (mlist_search.modified) modified = 1; #if SHELL_ESCAPE || PIPEC @@ -1468,6 +1500,9 @@ save_cmdhist() #endif if (!modified) return; + filename = histfile_name(); + if (filename == NULL) + return; f = fopen(filename, "w"); free(filename); if (f == NULL) Modified: stable/9/contrib/less/command.c ============================================================================== --- stable/9/contrib/less/command.c Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/command.c Tue Sep 4 23:24:00 2012 (r240121) @@ -1,12 +1,11 @@ /* $FreeBSD$ */ /* - * Copyright (C) 1984-2011 Mark Nudelman + * Copyright (C) 1984-2012 Mark Nudelman * * You may distribute under the terms of either the GNU General Public * License or the Less License, as specified in the README file. * - * For more information about less, or for information on how to - * contact the author, see the README file. + * For more information, see the README file. */ @@ -38,6 +37,7 @@ extern int secure; extern int hshift; extern int show_attn; extern int less_is_more; +extern POSITION highest_hilite; extern char *every_first_cmd; extern char *curr_altfilename; extern char version[]; @@ -104,8 +104,8 @@ cmd_exec() static void start_mca(action, prompt, mlist, cmdflags) int action; - char *prompt; - void constant *mlist; + constant char *prompt; + constant void *mlist; int cmdflags; { mca = action; @@ -686,7 +686,7 @@ make_display() static void prompt() { - register char constant *p; + register constant char *p; if (ungot != NULL) { @@ -962,6 +962,46 @@ multi_search(pattern, n) } /* + * Forward forever, or until a highlighted line appears. + */ + static int +forw_loop(until_hilite) + int until_hilite; +{ + POSITION curr_len; + + if (ch_getflags() & CH_HELPFILE) + return (A_NOACTION); + + cmd_exec(); + jump_forw(); + curr_len = ch_length(); + highest_hilite = until_hilite ? curr_len : NULL_POSITION; + ignore_eoi = 1; + while (!sigs) + { + if (until_hilite && highest_hilite > curr_len) + { + bell(); + break; + } + make_display(); + forward(1, 0, 0); + } + ignore_eoi = 0; + ch_set_eof(); + + /* + * This gets us back in "F mode" after processing + * a non-abort signal (e.g. window-change). + */ + if (sigs && !ABORT_SIGS()) + return (until_hilite ? A_F_UNTIL_HILITE : A_F_FOREVER); + + return (A_NOACTION); +} + +/* * Main command processor. * Accept and execute commands until a quit command. */ @@ -979,6 +1019,7 @@ commands() IFILE old_ifile; IFILE new_ifile; char *tagfile; + int until_hilite = 0; search_type = SRCH_FORW; wscroll = (sc_height + 1) / 2; @@ -1206,23 +1247,11 @@ commands() /* * Forward forever, ignoring EOF. */ - if (ch_getflags() & CH_HELPFILE) - break; - cmd_exec(); - jump_forw(); - ignore_eoi = 1; - while (!sigs) - { - make_display(); - forward(1, 0, 0); - } - ignore_eoi = 0; - /* - * This gets us back in "F mode" after processing - * a non-abort signal (e.g. window-change). - */ - if (sigs && !ABORT_SIGS()) - newaction = A_F_FOREVER; + newaction = forw_loop(0); + break; + + case A_F_UNTIL_HILITE: + newaction = forw_loop(1); break; case A_F_SCROLL: Modified: stable/9/contrib/less/configure ============================================================================== --- stable/9/contrib/less/configure Tue Sep 4 23:16:58 2012 (r240120) +++ stable/9/contrib/less/configure Tue Sep 4 23:24:00 2012 (r240121) @@ -1,6 +1,6 @@ #! /bin/sh # Guess values for system-dependent variables and create Makefiles. -# Generated by GNU Autoconf 2.67 for less 1. +# Generated by GNU Autoconf 2.68 for less 1. # # # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1998, 1999, 2000, 2001, @@ -89,6 +89,7 @@ fi IFS=" "" $as_nl" # Find who we are. Look in the path if we contain no directory separator. +as_myself= case $0 in #(( *[\\/]* ) as_myself=$0 ;; *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -214,11 +215,18 @@ IFS=$as_save_IFS # We cannot yet assume a decent shell, so we have to provide a # neutralization value for shells without unset; and this also # works around shells that cannot unset nonexistent variables. + # Preserve -v and -x to the replacement shell. BASH_ENV=/dev/null ENV=/dev/null (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV export CONFIG_SHELL - exec "$CONFIG_SHELL" "$as_myself" ${1+"$@"} + case $- in # (((( + *v*x* | *x*v* ) as_opts=-vx ;; + *v* ) as_opts=-v ;; + *x* ) as_opts=-x ;; + * ) as_opts= ;; + esac + exec "$CONFIG_SHELL" $as_opts "$as_myself" ${1+"$@"} fi if test x$as_have_required = xno; then : @@ -1067,7 +1075,7 @@ Try \`$0 --help' for more information" $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 - : ${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option} + : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" ;; esac @@ -1281,7 +1289,7 @@ Optional Packages: --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) --with-secure Compile in secure mode --with-no-float Do not use floating point - --with-regex={auto,pcre,posix,regcmp,re_comp,regcomp,regcomp-local} Select a regular expression library auto + --with-regex={auto,gnu,pcre,posix,regcmp,re_comp,regcomp,regcomp-local,none} Select a regular expression library auto --with-editor=PROGRAM use PROGRAM as the default editor vi Some influential environment variables: @@ -1361,7 +1369,7 @@ test -n "$ac_init_help" && exit $ac_stat if $ac_init_version; then cat <<\_ACEOF less configure 1 -generated by GNU Autoconf 2.67 +generated by GNU Autoconf 2.68 Copyright (C) 2010 Free Software Foundation, Inc. This configure script is free software; the Free Software Foundation @@ -1407,7 +1415,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_compile @@ -1453,7 +1461,7 @@ fi # interfere with the next link command; also delete a directory that is # left behind by Apple's compiler. We do this before executing the actions. rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_link @@ -1490,7 +1498,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=1 fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_cpp @@ -1532,7 +1540,7 @@ sed 's/^/| /' conftest.$ac_ext >&5 ac_retval=$ac_status fi rm -rf conftest.dSYM conftest_ipa8_conftest.oo - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno as_fn_set_status $ac_retval } # ac_fn_c_try_run @@ -1545,10 +1553,10 @@ fi ac_fn_c_check_header_mongrel () { as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack - if eval "test \"\${$3+set}\"" = set; then : + if eval \${$3+:} false; then : { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 fi eval ac_res=\$$3 @@ -1611,7 +1619,7 @@ $as_echo "$as_me: WARNING: $2: proceedin esac { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=\$ac_header_compiler" @@ -1620,7 +1628,7 @@ eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } fi - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_mongrel @@ -1633,7 +1641,7 @@ ac_fn_c_check_header_compile () as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -1651,7 +1659,7 @@ fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_header_compile @@ -1664,7 +1672,7 @@ ac_fn_c_check_type () as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else eval "$3=no" @@ -1705,7 +1713,7 @@ fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_type @@ -1717,7 +1725,7 @@ ac_fn_c_check_func () as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 $as_echo_n "checking for $2... " >&6; } -if eval "test \"\${$3+set}\"" = set; then : +if eval \${$3+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -1772,7 +1780,7 @@ fi eval ac_res=\$$3 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 $as_echo "$ac_res" >&6; } - eval $as_lineno_stack; test "x$as_lineno_stack" = x && { as_lineno=; unset as_lineno;} + eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno } # ac_fn_c_check_func cat >config.log <<_ACEOF @@ -1780,7 +1788,7 @@ This file contains any messages produced running configure, to aid debugging if configure makes a mistake. It was created by less $as_me 1, which was -generated by GNU Autoconf 2.67. Invocation command line was +generated by GNU Autoconf 2.68. Invocation command line was $ $0 $@ @@ -2142,7 +2150,7 @@ if test -n "$ac_tool_prefix"; then set dummy ${ac_tool_prefix}gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2182,7 +2190,7 @@ if test -z "$ac_cv_prog_CC"; then set dummy gcc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -2235,7 +2243,7 @@ if test -z "$CC"; then set dummy ${ac_tool_prefix}cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2275,7 +2283,7 @@ if test -z "$CC"; then set dummy cc; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2334,7 +2342,7 @@ if test -z "$CC"; then set dummy $ac_tool_prefix$ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_CC+set}" = set; then : +if ${ac_cv_prog_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$CC"; then @@ -2378,7 +2386,7 @@ do set dummy $ac_prog; ac_word=$2 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 $as_echo_n "checking for $ac_word... " >&6; } -if test "${ac_cv_prog_ac_ct_CC+set}" = set; then : +if ${ac_cv_prog_ac_ct_CC+:} false; then : $as_echo_n "(cached) " >&6 else if test -n "$ac_ct_CC"; then @@ -2661,7 +2669,7 @@ rm -f conftest.$ac_ext conftest$ac_cv_ex ac_clean_files=$ac_clean_files_save { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 $as_echo_n "checking for suffix of object files... " >&6; } -if test "${ac_cv_objext+set}" = set; then : +if ${ac_cv_objext+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -2712,7 +2720,7 @@ OBJEXT=$ac_cv_objext ac_objext=$OBJEXT { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } -if test "${ac_cv_c_compiler_gnu+set}" = set; then : +if ${ac_cv_c_compiler_gnu+:} false; then : $as_echo_n "(cached) " >&6 else cat confdefs.h - <<_ACEOF >conftest.$ac_ext @@ -2749,7 +2757,7 @@ ac_test_CFLAGS=${CFLAGS+set} ac_save_CFLAGS=$CFLAGS { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 $as_echo_n "checking whether $CC accepts -g... " >&6; } -if test "${ac_cv_prog_cc_g+set}" = set; then : +if ${ac_cv_prog_cc_g+:} false; then : $as_echo_n "(cached) " >&6 else ac_save_c_werror_flag=$ac_c_werror_flag @@ -2827,7 +2835,7 @@ else fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } -if test "${ac_cv_prog_cc_c89+set}" = set; then : +if ${ac_cv_prog_cc_c89+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_prog_cc_c89=no @@ -2925,7 +2933,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking for library containing strerror" >&5 $as_echo_n "checking for library containing strerror... " >&6; } -if test "${ac_cv_search_strerror+set}" = set; then : +if ${ac_cv_search_strerror+:} false; then : $as_echo_n "(cached) " >&6 else ac_func_search_save_LIBS=$LIBS @@ -2959,11 +2967,11 @@ for ac_lib in '' cposix; do fi rm -f core conftest.err conftest.$ac_objext \ conftest$ac_exeext - if test "${ac_cv_search_strerror+set}" = set; then : + if ${ac_cv_search_strerror+:} false; then : break fi done -if test "${ac_cv_search_strerror+set}" = set; then : +if ${ac_cv_search_strerror+:} false; then : else ac_cv_search_strerror=no @@ -2991,7 +2999,7 @@ if test -n "$CPP" && test -d "$CPP"; the CPP= fi if test -z "$CPP"; then - if test "${ac_cv_prog_CPP+set}" = set; then : + if ${ac_cv_prog_CPP+:} false; then : $as_echo_n "(cached) " >&6 else # Double quotes because CPP needs to be expanded @@ -3119,7 +3127,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } -if test "${ac_cv_path_GREP+set}" = set; then : +if ${ac_cv_path_GREP+:} false; then : $as_echo_n "(cached) " >&6 else if test -z "$GREP"; then @@ -3182,7 +3190,7 @@ $as_echo "$ac_cv_path_GREP" >&6; } { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 $as_echo_n "checking for egrep... " >&6; } -if test "${ac_cv_path_EGREP+set}" = set; then : +if ${ac_cv_path_EGREP+:} false; then : $as_echo_n "(cached) " >&6 else if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 @@ -3250,7 +3258,7 @@ $as_echo "$ac_cv_path_EGREP" >&6; } if test $ac_cv_c_compiler_gnu = yes; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC needs -traditional" >&5 $as_echo_n "checking whether $CC needs -traditional... " >&6; } -if test "${ac_cv_prog_gcc_traditional+set}" = set; then : +if ${ac_cv_prog_gcc_traditional+:} false; then : $as_echo_n "(cached) " >&6 else ac_pattern="Autoconf.*'x'" @@ -3335,7 +3343,7 @@ ac_configure="$SHELL $ac_aux_dir/configu { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 $as_echo_n "checking for a BSD-compatible install... " >&6; } if test -z "$INSTALL"; then -if test "${ac_cv_path_install+set}" = set; then : +if ${ac_cv_path_install+:} false; then : $as_echo_n "(cached) " >&6 else as_save_IFS=$IFS; IFS=$PATH_SEPARATOR @@ -3422,7 +3430,7 @@ if test "$enable_largefile" != no; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for special C compiler options needed for large files" >&5 $as_echo_n "checking for special C compiler options needed for large files... " >&6; } -if test "${ac_cv_sys_largefile_CC+set}" = set; then : +if ${ac_cv_sys_largefile_CC+:} false; then : $as_echo_n "(cached) " >&6 else ac_cv_sys_largefile_CC=no @@ -3473,7 +3481,7 @@ $as_echo "$ac_cv_sys_largefile_CC" >&6; { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _FILE_OFFSET_BITS value needed for large files" >&5 $as_echo_n "checking for _FILE_OFFSET_BITS value needed for large files... " >&6; } -if test "${ac_cv_sys_file_offset_bits+set}" = set; then : +if ${ac_cv_sys_file_offset_bits+:} false; then : $as_echo_n "(cached) " >&6 else while :; do @@ -3542,7 +3550,7 @@ rm -rf conftest* if test $ac_cv_sys_file_offset_bits = unknown; then { $as_echo "$as_me:${as_lineno-$LINENO}: checking for _LARGE_FILES value needed for large files" >&5 $as_echo_n "checking for _LARGE_FILES value needed for large files... " >&6; } -if test "${ac_cv_sys_large_files+set}" = set; then : +if ${ac_cv_sys_large_files+:} false; then : $as_echo_n "(cached) " >&6 else while :; do @@ -3615,7 +3623,7 @@ fi # Checks for general libraries. { $as_echo "$as_me:${as_lineno-$LINENO}: checking for tgoto in -ltinfo" >&5 $as_echo_n "checking for tgoto in -ltinfo... " >&6; } -if test "${ac_cv_lib_tinfo_tgoto+set}" = set; then : +if ${ac_cv_lib_tinfo_tgoto+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -3649,7 +3657,7 @@ LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_tinfo_tgoto" >&5 $as_echo "$ac_cv_lib_tinfo_tgoto" >&6; } -if test "x$ac_cv_lib_tinfo_tgoto" = x""yes; then : +if test "x$ac_cv_lib_tinfo_tgoto" = xyes; then : have_tinfo=yes else have_tinfo=no @@ -3657,7 +3665,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lxcurses" >&5 $as_echo_n "checking for initscr in -lxcurses... " >&6; } -if test "${ac_cv_lib_xcurses_initscr+set}" = set; then : +if ${ac_cv_lib_xcurses_initscr+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -3691,7 +3699,7 @@ LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_xcurses_initscr" >&5 $as_echo "$ac_cv_lib_xcurses_initscr" >&6; } -if test "x$ac_cv_lib_xcurses_initscr" = x""yes; then : +if test "x$ac_cv_lib_xcurses_initscr" = xyes; then : have_xcurses=yes else have_xcurses=no @@ -3699,7 +3707,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lncursesw" >&5 $as_echo_n "checking for initscr in -lncursesw... " >&6; } -if test "${ac_cv_lib_ncursesw_initscr+set}" = set; then : +if ${ac_cv_lib_ncursesw_initscr+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -3733,7 +3741,7 @@ LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncursesw_initscr" >&5 $as_echo "$ac_cv_lib_ncursesw_initscr" >&6; } -if test "x$ac_cv_lib_ncursesw_initscr" = x""yes; then : +if test "x$ac_cv_lib_ncursesw_initscr" = xyes; then : have_ncursesw=yes else have_ncursesw=no @@ -3741,7 +3749,7 @@ fi { $as_echo "$as_me:${as_lineno-$LINENO}: checking for initscr in -lncurses" >&5 $as_echo_n "checking for initscr in -lncurses... " >&6; } -if test "${ac_cv_lib_ncurses_initscr+set}" = set; then : +if ${ac_cv_lib_ncurses_initscr+:} false; then : $as_echo_n "(cached) " >&6 else ac_check_lib_save_LIBS=$LIBS @@ -3775,7 +3783,7 @@ LIBS=$ac_check_lib_save_LIBS fi { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ncurses_initscr" >&5 $as_echo "$ac_cv_lib_ncurses_initscr" >&6; } -if test "x$ac_cv_lib_ncurses_initscr" = x""yes; then : +if test "x$ac_cv_lib_ncurses_initscr" = xyes; then : have_ncurses=yes *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 02:03:44 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 769DE1065678; Wed, 5 Sep 2012 02:03:44 +0000 (UTC) (envelope-from emaste@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 613BD8FC17; Wed, 5 Sep 2012 02:03:44 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q8523ihM054777; Wed, 5 Sep 2012 02:03:44 GMT (envelope-from emaste@svn.freebsd.org) Received: (from emaste@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q8523iNf054775; Wed, 5 Sep 2012 02:03:44 GMT (envelope-from emaste@svn.freebsd.org) Message-Id: <201209050203.q8523iNf054775@svn.freebsd.org> From: Ed Maste Date: Wed, 5 Sep 2012 02:03:44 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240123 - stable/9/bin/ps X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 02:03:44 -0000 Author: emaste Date: Wed Sep 5 02:03:43 2012 New Revision: 240123 URL: http://svn.freebsd.org/changeset/base/240123 Log: MFC 239883: Avoid passing uninitialized stack to addelem() if called with an empty arg. PR: bin/171174 Modified: stable/9/bin/ps/ps.c Directory Properties: stable/9/bin/ps/ (props changed) Modified: stable/9/bin/ps/ps.c ============================================================================== --- stable/9/bin/ps/ps.c Tue Sep 4 23:27:07 2012 (r240122) +++ stable/9/bin/ps/ps.c Wed Sep 5 02:03:43 2012 (r240123) @@ -889,8 +889,8 @@ add_list(struct listinfo *inf, const cha int toolong; char elemcopy[PATH_MAX]; - if (*argp == 0) - inf->addelem(inf, elemcopy); + if (*argp == '\0') + inf->addelem(inf, argp); while (*argp != '\0') { while (*argp != '\0' && strchr(W_SEP, *argp) != NULL) argp++; From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 07:47:10 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 6521D106564A; Wed, 5 Sep 2012 07:47:10 +0000 (UTC) (envelope-from tuexen@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4FBD68FC15; Wed, 5 Sep 2012 07:47:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q857lAQv097745; Wed, 5 Sep 2012 07:47:10 GMT (envelope-from tuexen@svn.freebsd.org) Received: (from tuexen@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q857lAqD097741; Wed, 5 Sep 2012 07:47:10 GMT (envelope-from tuexen@svn.freebsd.org) Message-Id: <201209050747.q857lAqD097741@svn.freebsd.org> From: Michael Tuexen Date: Wed, 5 Sep 2012 07:47:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240129 - stable/9/sys/netinet X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 07:47:10 -0000 Author: tuexen Date: Wed Sep 5 07:47:09 2012 New Revision: 240129 URL: http://svn.freebsd.org/changeset/base/240129 Log: MFC r240007: Fix a typo which results in RTT to be off by a factor of 10, if the RTT is larger than 1 second. Modified: stable/9/sys/netinet/sctputil.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/netinet/sctputil.c ============================================================================== --- stable/9/sys/netinet/sctputil.c Wed Sep 5 06:51:28 2012 (r240128) +++ stable/9/sys/netinet/sctputil.c Wed Sep 5 07:47:09 2012 (r240129) @@ -2384,7 +2384,7 @@ sctp_calculate_rto(struct sctp_tcb *stcb } timevalsub(&now, old); /* store the current RTT in us */ - net->rtt = (uint64_t) 10000000 *(uint64_t) now.tv_sec + + net->rtt = (uint64_t) 1000000 *(uint64_t) now.tv_sec + (uint64_t) now.tv_usec; /* computer rtt in ms */ From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 16:35:38 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 58A3B1065670; Wed, 5 Sep 2012 16:35:38 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 42A778FC08; Wed, 5 Sep 2012 16:35:38 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q85GZcW7068982; Wed, 5 Sep 2012 16:35:38 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q85GZcN5068978; Wed, 5 Sep 2012 16:35:38 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209051635.q85GZcN5068978@svn.freebsd.org> From: Konstantin Belousov Date: Wed, 5 Sep 2012 16:35:38 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240142 - in stable/9/sys: sys vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 16:35:38 -0000 Author: kib Date: Wed Sep 5 16:35:37 2012 New Revision: 240142 URL: http://svn.freebsd.org/changeset/base/240142 Log: MFC r238212: Drop page queues mutex on each iteration of vm_pageout_scan over the inactive queue, unless busy page is found. MFC r238258: Avoid vm page queues lock leak after r238212. Modified: stable/9/sys/sys/vmmeter.h stable/9/sys/vm/vm_pageout.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/sys/vmmeter.h ============================================================================== --- stable/9/sys/sys/vmmeter.h Wed Sep 5 16:01:08 2012 (r240141) +++ stable/9/sys/sys/vmmeter.h Wed Sep 5 16:35:37 2012 (r240142) @@ -79,7 +79,7 @@ struct vmmeter { u_int v_pdpages; /* (q) pages analyzed by daemon */ u_int v_tcached; /* (p) total pages cached */ - u_int v_dfree; /* (q) pages freed by daemon */ + u_int v_dfree; /* (p) pages freed by daemon */ u_int v_pfree; /* (p) pages freed by exiting processes */ u_int v_tfree; /* (p) total pages freed */ /* Modified: stable/9/sys/vm/vm_pageout.c ============================================================================== --- stable/9/sys/vm/vm_pageout.c Wed Sep 5 16:01:08 2012 (r240141) +++ stable/9/sys/vm/vm_pageout.c Wed Sep 5 16:35:37 2012 (r240142) @@ -743,6 +743,7 @@ vm_pageout_scan(int pass) int actcount; int vnodes_skipped = 0; int maxlaunder; + boolean_t queues_locked; /* * Decrease registered cache sizes. @@ -784,6 +785,7 @@ vm_pageout_scan(int pass) if (pass) maxlaunder = 10000; vm_page_lock_queues(); + queues_locked = TRUE; rescan0: addl_page_shortage = addl_page_shortage_init; maxscan = cnt.v_inactive_count; @@ -791,6 +793,8 @@ rescan0: for (m = TAILQ_FIRST(&vm_page_queues[PQ_INACTIVE].pl); m != NULL && maxscan-- > 0 && page_shortage > 0; m = next) { + KASSERT(queues_locked, ("unlocked queues")); + mtx_assert(&vm_page_queue_mtx, MA_OWNED); cnt.v_pdpages++; @@ -850,6 +854,16 @@ rescan0: } /* + * We unlock vm_page_queue_mtx, invalidating the + * 'next' pointer. Use our marker to remember our + * place. + */ + TAILQ_INSERT_AFTER(&vm_page_queues[PQ_INACTIVE].pl, + m, &marker, pageq); + vm_page_unlock_queues(); + queues_locked = FALSE; + + /* * If the object is not being used, we ignore previous * references. */ @@ -873,7 +887,7 @@ rescan0: vm_page_unlock(m); m->act_count += actcount + ACT_ADVANCE; VM_OBJECT_UNLOCK(object); - continue; + goto relock_queues; } /* @@ -889,7 +903,7 @@ rescan0: vm_page_unlock(m); m->act_count += actcount + ACT_ADVANCE + 1; VM_OBJECT_UNLOCK(object); - continue; + goto relock_queues; } /* @@ -924,7 +938,7 @@ rescan0: * Invalid pages can be easily freed */ vm_page_free(m); - cnt.v_dfree++; + PCPU_INC(cnt.v_dfree); --page_shortage; } else if (m->dirty == 0) { /* @@ -947,6 +961,8 @@ rescan0: * the thrash point for a heavily loaded machine. */ m->flags |= PG_WINATCFLS; + vm_page_lock_queues(); + queues_locked = TRUE; vm_page_requeue(m); } else if (maxlaunder > 0) { /* @@ -976,21 +992,13 @@ rescan0: if (!swap_pageouts_ok || (object->flags & OBJ_DEAD)) { vm_page_unlock(m); VM_OBJECT_UNLOCK(object); + vm_page_lock_queues(); + queues_locked = TRUE; vm_page_requeue(m); - continue; + goto relock_queues; } /* - * Following operations may unlock - * vm_page_queue_mtx, invalidating the 'next' - * pointer. To prevent an inordinate number - * of restarts we use our marker to remember - * our place. - * - */ - TAILQ_INSERT_AFTER(&vm_page_queues[PQ_INACTIVE].pl, - m, &marker, pageq); - /* * The object is already known NOT to be dead. It * is possible for the vget() to block the whole * pageout daemon, but the new low-memory handling @@ -1014,7 +1022,6 @@ rescan0: * of time. */ if (object->type == OBJT_VNODE) { - vm_page_unlock_queues(); vm_page_unlock(m); vp = object->handle; if (vp->v_type == VREG && @@ -1023,7 +1030,6 @@ rescan0: ++pageout_lock_miss; if (object->flags & OBJ_MIGHTBEDIRTY) vnodes_skipped++; - vm_page_lock_queues(); goto unlock_and_continue; } KASSERT(mp != NULL, @@ -1034,7 +1040,6 @@ rescan0: if (vget(vp, LK_EXCLUSIVE | LK_TIMELOCK, curthread)) { VM_OBJECT_LOCK(object); - vm_page_lock_queues(); ++pageout_lock_miss; if (object->flags & OBJ_MIGHTBEDIRTY) vnodes_skipped++; @@ -1044,6 +1049,7 @@ rescan0: VM_OBJECT_LOCK(object); vm_page_lock(m); vm_page_lock_queues(); + queues_locked = TRUE; /* * The page might have been moved to another * queue during potential blocking in vget() @@ -1081,6 +1087,8 @@ rescan0: vnodes_skipped++; goto unlock_and_continue; } + vm_page_unlock_queues(); + queues_locked = FALSE; } /* @@ -1093,32 +1101,37 @@ rescan0: * the (future) cleaned page. Otherwise we could wind * up laundering or cleaning too many pages. */ - vm_page_unlock_queues(); if (vm_pageout_clean(m) != 0) { --page_shortage; --maxlaunder; } - vm_page_lock_queues(); unlock_and_continue: vm_page_lock_assert(m, MA_NOTOWNED); VM_OBJECT_UNLOCK(object); if (mp != NULL) { - vm_page_unlock_queues(); + if (queues_locked) { + vm_page_unlock_queues(); + queues_locked = FALSE; + } if (vp != NULL) vput(vp); VFS_UNLOCK_GIANT(vfslocked); vm_object_deallocate(object); vn_finished_write(mp); - vm_page_lock_queues(); } - next = TAILQ_NEXT(&marker, pageq); - TAILQ_REMOVE(&vm_page_queues[PQ_INACTIVE].pl, - &marker, pageq); vm_page_lock_assert(m, MA_NOTOWNED); - continue; + goto relock_queues; } vm_page_unlock(m); VM_OBJECT_UNLOCK(object); +relock_queues: + if (!queues_locked) { + vm_page_lock_queues(); + queues_locked = TRUE; + } + next = TAILQ_NEXT(&marker, pageq); + TAILQ_REMOVE(&vm_page_queues[PQ_INACTIVE].pl, + &marker, pageq); } /* From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 16:47:00 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id DBB4A106566C; Wed, 5 Sep 2012 16:47:00 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C72628FC0A; Wed, 5 Sep 2012 16:47:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q85Gl00P070330; Wed, 5 Sep 2012 16:47:00 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q85Gl0VJ070328; Wed, 5 Sep 2012 16:47:00 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209051647.q85Gl0VJ070328@svn.freebsd.org> From: Konstantin Belousov Date: Wed, 5 Sep 2012 16:47:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240143 - stable/9/sys/vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 16:47:01 -0000 Author: kib Date: Wed Sep 5 16:47:00 2012 New Revision: 240143 URL: http://svn.freebsd.org/changeset/base/240143 Log: MFC r238604: Do not restart scan of the inactive queue when non-inactive page is found. Rather, we shall not find such pages on inactive queue at all. Modified: stable/9/sys/vm/vm_pageout.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/vm/vm_pageout.c ============================================================================== --- stable/9/sys/vm/vm_pageout.c Wed Sep 5 16:35:37 2012 (r240142) +++ stable/9/sys/vm/vm_pageout.c Wed Sep 5 16:47:00 2012 (r240143) @@ -786,7 +786,6 @@ vm_pageout_scan(int pass) maxlaunder = 10000; vm_page_lock_queues(); queues_locked = TRUE; -rescan0: addl_page_shortage = addl_page_shortage_init; maxscan = cnt.v_inactive_count; @@ -795,12 +794,9 @@ rescan0: m = next) { KASSERT(queues_locked, ("unlocked queues")); mtx_assert(&vm_page_queue_mtx, MA_OWNED); + KASSERT(m->queue == PQ_INACTIVE, ("Inactive queue %p", m)); cnt.v_pdpages++; - - if (m->queue != PQ_INACTIVE) - goto rescan0; - next = TAILQ_NEXT(m, pageq); /* From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 18:49:00 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id A79BD106566C; Wed, 5 Sep 2012 18:49:00 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 91C958FC0A; Wed, 5 Sep 2012 18:49:00 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q85In0WJ084693; Wed, 5 Sep 2012 18:49:00 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q85In0II084690; Wed, 5 Sep 2012 18:49:00 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209051849.q85In0II084690@svn.freebsd.org> From: Konstantin Belousov Date: Wed, 5 Sep 2012 18:49:00 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240147 - stable/9/sys/vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 18:49:00 -0000 Author: kib Date: Wed Sep 5 18:49:00 2012 New Revision: 240147 URL: http://svn.freebsd.org/changeset/base/240147 Log: MFC r238732 (by alc): Addendum to r238604. If the inactive queue scan isn't restarted, then the variable "addl_page_shortage_init" isn't needed. Modified: stable/9/sys/vm/vm_pageout.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/vm/vm_pageout.c ============================================================================== --- stable/9/sys/vm/vm_pageout.c Wed Sep 5 18:27:45 2012 (r240146) +++ stable/9/sys/vm/vm_pageout.c Wed Sep 5 18:49:00 2012 (r240147) @@ -738,7 +738,7 @@ vm_pageout_scan(int pass) vm_page_t m, next; struct vm_page marker; int page_shortage, maxscan, pcount; - int addl_page_shortage, addl_page_shortage_init; + int addl_page_shortage; vm_object_t object; int actcount; int vnodes_skipped = 0; @@ -754,13 +754,13 @@ vm_pageout_scan(int pass) */ uma_reclaim(); - addl_page_shortage_init = atomic_readandclear_int(&vm_pageout_deficit); + addl_page_shortage = atomic_readandclear_int(&vm_pageout_deficit); /* * Calculate the number of pages we want to either free or move * to the cache. */ - page_shortage = vm_paging_target() + addl_page_shortage_init; + page_shortage = vm_paging_target() + addl_page_shortage; vm_pageout_init_marker(&marker, PQ_INACTIVE); @@ -786,7 +786,6 @@ vm_pageout_scan(int pass) maxlaunder = 10000; vm_page_lock_queues(); queues_locked = TRUE; - addl_page_shortage = addl_page_shortage_init; maxscan = cnt.v_inactive_count; for (m = TAILQ_FIRST(&vm_page_queues[PQ_INACTIVE].pl); From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 18:55:35 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B1CDF1065670; Wed, 5 Sep 2012 18:55:35 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 9C3C08FC08; Wed, 5 Sep 2012 18:55:35 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q85ItZPY085678; Wed, 5 Sep 2012 18:55:35 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q85ItZYB085676; Wed, 5 Sep 2012 18:55:35 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209051855.q85ItZYB085676@svn.freebsd.org> From: Konstantin Belousov Date: Wed, 5 Sep 2012 18:55:35 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240149 - stable/9/sys/vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 18:55:35 -0000 Author: kib Date: Wed Sep 5 18:55:35 2012 New Revision: 240149 URL: http://svn.freebsd.org/changeset/base/240149 Log: MFC r238791: Do not requeue held page or page for which locking failed, just leave them alone. Process the act_count updates for the held pages in the vm_pageout loop over the inactive queue, instead of refusing to do anything with such page. Clarify the intent of the addl_page_shortage counter and change its use for pages which are not processed in the loop according to the description. Modified: stable/9/sys/vm/vm_pageout.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/vm/vm_pageout.c ============================================================================== --- stable/9/sys/vm/vm_pageout.c Wed Sep 5 18:52:01 2012 (r240148) +++ stable/9/sys/vm/vm_pageout.c Wed Sep 5 18:55:35 2012 (r240149) @@ -754,6 +754,12 @@ vm_pageout_scan(int pass) */ uma_reclaim(); + /* + * The addl_page_shortage is the the number of temporarily + * stuck pages in the inactive queue. In other words, the + * number of pages from cnt.v_inactive_count that should be + * discounted in setting the target for the active queue scan. + */ addl_page_shortage = atomic_readandclear_int(&vm_pageout_deficit); /* @@ -810,38 +816,31 @@ vm_pageout_scan(int pass) ("Unmanaged page %p cannot be in inactive queue", m)); /* - * Lock the page. + * The page or object lock acquisitions fail if the + * page was removed from the queue or moved to a + * different position within the queue. In either + * case, addl_page_shortage should not be incremented. */ if (!vm_pageout_page_lock(m, &next)) { vm_page_unlock(m); - addl_page_shortage++; continue; } - - /* - * A held page may be undergoing I/O, so skip it. - */ - if (m->hold_count) { + object = m->object; + if (!VM_OBJECT_TRYLOCK(object) && + !vm_pageout_fallback_object_lock(m, &next)) { vm_page_unlock(m); - vm_page_requeue(m); - addl_page_shortage++; + VM_OBJECT_UNLOCK(object); continue; } /* - * Don't mess with busy pages, keep in the front of the - * queue, most likely are being paged out. + * Don't mess with busy pages, keep them at at the + * front of the queue, most likely they are being + * paged out. Increment addl_page_shortage for busy + * pages, because they may leave the inactive queue + * shortly after page scan is finished. */ - object = m->object; - if (!VM_OBJECT_TRYLOCK(object) && - (!vm_pageout_fallback_object_lock(m, &next) || - m->hold_count != 0)) { - VM_OBJECT_UNLOCK(object); - vm_page_unlock(m); - addl_page_shortage++; - continue; - } - if (m->busy || (m->oflags & VPO_BUSY)) { + if (m->busy != 0 || (m->oflags & VPO_BUSY) != 0) { vm_page_unlock(m); VM_OBJECT_UNLOCK(object); addl_page_shortage++; @@ -901,6 +900,21 @@ vm_pageout_scan(int pass) goto relock_queues; } + if (m->hold_count != 0) { + vm_page_unlock(m); + VM_OBJECT_UNLOCK(object); + + /* + * Held pages are essentially stuck in the + * queue. So, they ought to be discounted + * from cnt.v_inactive_count. See the + * calculation of the page_shortage for the + * loop over the active queue below. + */ + addl_page_shortage++; + goto relock_queues; + } + /* * If the upper level VM system does not believe that the page * is fully dirty, but it is mapped for write access, then we From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 20:40:12 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5B3F7106566B; Wed, 5 Sep 2012 20:40:12 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4367E8FC0A; Wed, 5 Sep 2012 20:40:12 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q85KeCtO098724; Wed, 5 Sep 2012 20:40:12 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q85KeCTe098721; Wed, 5 Sep 2012 20:40:12 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209052040.q85KeCTe098721@svn.freebsd.org> From: Konstantin Belousov Date: Wed, 5 Sep 2012 20:40:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240151 - in stable/9/sys: amd64/amd64 amd64/include i386/i386 i386/xen kern mips/mips sparc64/sparc64 vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 20:40:12 -0000 Author: kib Date: Wed Sep 5 20:40:11 2012 New Revision: 240151 URL: http://svn.freebsd.org/changeset/base/240151 Log: MFC r233122,r237086,r237228,r237264,r237290,r237404,r237414,r237513,r237551, r237592,r237604,r237623,r237684,r237733,r237813,r237855,r238124,r238126, r238163,r238414,r238610,r238889,r238970,r239072,r239137,r240126 (all by alc): Add fine-grained PV chunk and list locking to the amd64 pmap, enabling concurrent execution of the following functions on different pmaps: pmap_change_wiring() pmap_copy() pmap_enter() pmap_enter_object() pmap_enter_quick() pmap_page_exists_quick() pmap_page_is_mapped() pmap_protect() pmap_remove() pmap_remove_pages() Requested and approved by: alc Modified: stable/9/sys/amd64/amd64/pmap.c stable/9/sys/amd64/include/cpufunc.h stable/9/sys/i386/i386/pmap.c stable/9/sys/i386/xen/pmap.c stable/9/sys/kern/subr_witness.c stable/9/sys/mips/mips/pmap.c stable/9/sys/sparc64/sparc64/pmap.c stable/9/sys/vm/vm_map.c stable/9/sys/vm/vm_page.c Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/amd64/amd64/pmap.c ============================================================================== --- stable/9/sys/amd64/amd64/pmap.c Wed Sep 5 19:01:39 2012 (r240150) +++ stable/9/sys/amd64/amd64/pmap.c Wed Sep 5 20:40:11 2012 (r240151) @@ -168,6 +168,39 @@ __FBSDID("$FreeBSD$"); #define pa_index(pa) ((pa) >> PDRSHIFT) #define pa_to_pvh(pa) (&pv_table[pa_index(pa)]) +#define NPV_LIST_LOCKS MAXCPU + +#define PHYS_TO_PV_LIST_LOCK(pa) \ + (&pv_list_locks[pa_index(pa) % NPV_LIST_LOCKS]) + +#define CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, pa) do { \ + struct rwlock **_lockp = (lockp); \ + struct rwlock *_new_lock; \ + \ + _new_lock = PHYS_TO_PV_LIST_LOCK(pa); \ + if (_new_lock != *_lockp) { \ + if (*_lockp != NULL) \ + rw_wunlock(*_lockp); \ + *_lockp = _new_lock; \ + rw_wlock(*_lockp); \ + } \ +} while (0) + +#define CHANGE_PV_LIST_LOCK_TO_VM_PAGE(lockp, m) \ + CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, VM_PAGE_TO_PHYS(m)) + +#define RELEASE_PV_LIST_LOCK(lockp) do { \ + struct rwlock **_lockp = (lockp); \ + \ + if (*_lockp != NULL) { \ + rw_wunlock(*_lockp); \ + *_lockp = NULL; \ + } \ +} while (0) + +#define VM_PAGE_TO_PV_LIST_LOCK(m) \ + PHYS_TO_PV_LIST_LOCK(VM_PAGE_TO_PHYS(m)) + struct pmap kernel_pmap_store; vm_offset_t virtual_avail; /* VA of first avail page (after kernel bss) */ @@ -214,7 +247,8 @@ static struct { * Data for the pv entry allocation mechanism */ static TAILQ_HEAD(pch, pv_chunk) pv_chunks = TAILQ_HEAD_INITIALIZER(pv_chunks); -static long pv_entry_count; +static struct mtx pv_chunks_mutex; +static struct rwlock pv_list_locks[NPV_LIST_LOCKS]; static struct md_page *pv_table; /* @@ -230,10 +264,17 @@ static caddr_t crashdumpmap; static void free_pv_chunk(struct pv_chunk *pc); static void free_pv_entry(pmap_t pmap, pv_entry_t pv); -static pv_entry_t get_pv_entry(pmap_t pmap, boolean_t try); -static void pmap_pv_demote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa); -static boolean_t pmap_pv_insert_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa); -static void pmap_pv_promote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa); +static pv_entry_t get_pv_entry(pmap_t pmap, struct rwlock **lockp); +static int popcnt_pc_map_elem(uint64_t elem); +static vm_page_t reclaim_pv_chunk(pmap_t locked_pmap, struct rwlock **lockp); +static void reserve_pv_entries(pmap_t pmap, int needed, + struct rwlock **lockp); +static void pmap_pv_demote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa, + struct rwlock **lockp); +static boolean_t pmap_pv_insert_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa, + struct rwlock **lockp); +static void pmap_pv_promote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa, + struct rwlock **lockp); static void pmap_pvh_free(struct md_page *pvh, pmap_t pmap, vm_offset_t va); static pv_entry_t pmap_pvh_remove(struct md_page *pvh, pmap_t pmap, vm_offset_t va); @@ -241,12 +282,14 @@ static int pmap_pvh_wired_mappings(struc static int pmap_change_attr_locked(vm_offset_t va, vm_size_t size, int mode); static boolean_t pmap_demote_pde(pmap_t pmap, pd_entry_t *pde, vm_offset_t va); +static boolean_t pmap_demote_pde_locked(pmap_t pmap, pd_entry_t *pde, + vm_offset_t va, struct rwlock **lockp); static boolean_t pmap_demote_pdpe(pmap_t pmap, pdp_entry_t *pdpe, vm_offset_t va); static boolean_t pmap_enter_pde(pmap_t pmap, vm_offset_t va, vm_page_t m, - vm_prot_t prot); + vm_prot_t prot, struct rwlock **lockp); static vm_page_t pmap_enter_quick_locked(pmap_t pmap, vm_offset_t va, - vm_page_t m, vm_prot_t prot, vm_page_t mpte); + vm_page_t m, vm_prot_t prot, vm_page_t mpte, struct rwlock **lockp); static void pmap_fill_ptp(pt_entry_t *firstpte, pt_entry_t newpte); static void pmap_insert_pt_page(pmap_t pmap, vm_page_t mpte); static boolean_t pmap_is_modified_pvh(struct md_page *pvh); @@ -254,32 +297,34 @@ static boolean_t pmap_is_referenced_pvh( static void pmap_kenter_attr(vm_offset_t va, vm_paddr_t pa, int mode); static vm_page_t pmap_lookup_pt_page(pmap_t pmap, vm_offset_t va); static void pmap_pde_attr(pd_entry_t *pde, int cache_bits); -static void pmap_promote_pde(pmap_t pmap, pd_entry_t *pde, vm_offset_t va); +static void pmap_promote_pde(pmap_t pmap, pd_entry_t *pde, vm_offset_t va, + struct rwlock **lockp); static boolean_t pmap_protect_pde(pmap_t pmap, pd_entry_t *pde, vm_offset_t sva, vm_prot_t prot); static void pmap_pte_attr(pt_entry_t *pte, int cache_bits); static int pmap_remove_pde(pmap_t pmap, pd_entry_t *pdq, vm_offset_t sva, - vm_page_t *free); + vm_page_t *free, struct rwlock **lockp); static int pmap_remove_pte(pmap_t pmap, pt_entry_t *ptq, - vm_offset_t sva, pd_entry_t ptepde, vm_page_t *free); + vm_offset_t sva, pd_entry_t ptepde, vm_page_t *free, + struct rwlock **lockp); static void pmap_remove_pt_page(pmap_t pmap, vm_page_t mpte); static void pmap_remove_page(pmap_t pmap, vm_offset_t va, pd_entry_t *pde, vm_page_t *free); -static void pmap_remove_entry(struct pmap *pmap, vm_page_t m, - vm_offset_t va); -static void pmap_insert_entry(pmap_t pmap, vm_offset_t va, vm_page_t m); static boolean_t pmap_try_insert_pv_entry(pmap_t pmap, vm_offset_t va, - vm_page_t m); + vm_page_t m, struct rwlock **lockp); static void pmap_update_pde(pmap_t pmap, vm_offset_t va, pd_entry_t *pde, pd_entry_t newpde); static void pmap_update_pde_invalidate(vm_offset_t va, pd_entry_t newpde); -static vm_page_t pmap_allocpde(pmap_t pmap, vm_offset_t va, int flags); -static vm_page_t pmap_allocpte(pmap_t pmap, vm_offset_t va, int flags); +static vm_page_t _pmap_allocpte(pmap_t pmap, vm_pindex_t ptepindex, + struct rwlock **lockp); +static vm_page_t pmap_allocpde(pmap_t pmap, vm_offset_t va, + struct rwlock **lockp); +static vm_page_t pmap_allocpte(pmap_t pmap, vm_offset_t va, + struct rwlock **lockp); -static vm_page_t _pmap_allocpte(pmap_t pmap, vm_pindex_t ptepindex, int flags); -static int _pmap_unwire_pte_hold(pmap_t pmap, vm_offset_t va, vm_page_t m, - vm_page_t* free); +static void _pmap_unwire_ptp(pmap_t pmap, vm_offset_t va, vm_page_t m, + vm_page_t *free); static int pmap_unuse_pt(pmap_t, vm_offset_t, pd_entry_t, vm_page_t *); static vm_offset_t pmap_kmem_choose(vm_offset_t addr); @@ -597,7 +642,7 @@ pmap_bootstrap(vm_paddr_t *firstaddr) /* * Initialize the global pv list lock. */ - rw_init(&pvh_global_lock, "pvh global"); + rw_init(&pvh_global_lock, "pmap pv global"); /* * Reserve some special page table entries/VA space for temporary @@ -763,6 +808,17 @@ pmap_init(void) } /* + * Initialize the pv chunk list mutex. + */ + mtx_init(&pv_chunks_mutex, "pmap pv chunk list", NULL, MTX_DEF); + + /* + * Initialize the pool of pv list locks. + */ + for (i = 0; i < NPV_LIST_LOCKS; i++) + rw_init(&pv_list_locks[i], "pmap pv list"); + + /* * Calculate the size of the pv head table for superpages. */ for (i = 0; phys_avail[i + 1]; i += 2); @@ -1501,23 +1557,25 @@ pmap_remove_pt_page(pmap_t pmap, vm_page } /* - * This routine unholds page table pages, and if the hold count - * drops to zero, then it decrements the wire count. + * Decrements a page table page's wire count, which is used to record the + * number of valid page table entries within the page. If the wire count + * drops to zero, then the page table page is unmapped. Returns TRUE if the + * page table page was unmapped and FALSE otherwise. */ -static __inline int -pmap_unwire_pte_hold(pmap_t pmap, vm_offset_t va, vm_page_t m, vm_page_t *free) +static inline boolean_t +pmap_unwire_ptp(pmap_t pmap, vm_offset_t va, vm_page_t m, vm_page_t *free) { --m->wire_count; - if (m->wire_count == 0) - return (_pmap_unwire_pte_hold(pmap, va, m, free)); - else - return (0); + if (m->wire_count == 0) { + _pmap_unwire_ptp(pmap, va, m, free); + return (TRUE); + } else + return (FALSE); } -static int -_pmap_unwire_pte_hold(pmap_t pmap, vm_offset_t va, vm_page_t m, - vm_page_t *free) +static void +_pmap_unwire_ptp(pmap_t pmap, vm_offset_t va, vm_page_t m, vm_page_t *free) { PMAP_LOCK_ASSERT(pmap, MA_OWNED); @@ -1546,14 +1604,14 @@ _pmap_unwire_pte_hold(pmap_t pmap, vm_of vm_page_t pdpg; pdpg = PHYS_TO_VM_PAGE(*pmap_pdpe(pmap, va) & PG_FRAME); - pmap_unwire_pte_hold(pmap, va, pdpg, free); + pmap_unwire_ptp(pmap, va, pdpg, free); } if (m->pindex >= NUPDE && m->pindex < (NUPDE + NUPDPE)) { /* We just released a PD, unhold the matching PDP */ vm_page_t pdppg; pdppg = PHYS_TO_VM_PAGE(*pmap_pml4e(pmap, va) & PG_FRAME); - pmap_unwire_pte_hold(pmap, va, pdppg, free); + pmap_unwire_ptp(pmap, va, pdppg, free); } /* @@ -1568,8 +1626,6 @@ _pmap_unwire_pte_hold(pmap_t pmap, vm_of * *ALL* TLB shootdown is done */ pmap_add_delayed_free_list(m, free, TRUE); - - return (1); } /* @@ -1585,7 +1641,7 @@ pmap_unuse_pt(pmap_t pmap, vm_offset_t v return (0); KASSERT(ptepde != 0, ("pmap_unuse_pt: ptepde != 0")); mpte = PHYS_TO_VM_PAGE(ptepde & PG_FRAME); - return (pmap_unwire_pte_hold(pmap, va, mpte, free)); + return (pmap_unwire_ptp(pmap, va, mpte, free)); } void @@ -1644,8 +1700,10 @@ pmap_pinit(pmap_t pmap) } /* - * this routine is called if the page table page is not - * mapped correctly. + * This routine is called if the desired page table page does not exist. + * + * If page table page allocation fails, this routine may sleep before + * returning NULL. It sleeps only if a lock pointer was given. * * Note: If a page allocation fails at page table level two or three, * one or two pages may be held during the wait, only to be released @@ -1653,25 +1711,23 @@ pmap_pinit(pmap_t pmap) * race conditions. */ static vm_page_t -_pmap_allocpte(pmap_t pmap, vm_pindex_t ptepindex, int flags) +_pmap_allocpte(pmap_t pmap, vm_pindex_t ptepindex, struct rwlock **lockp) { vm_page_t m, pdppg, pdpg; - KASSERT((flags & (M_NOWAIT | M_WAITOK)) == M_NOWAIT || - (flags & (M_NOWAIT | M_WAITOK)) == M_WAITOK, - ("_pmap_allocpte: flags is neither M_NOWAIT nor M_WAITOK")); - PMAP_LOCK_ASSERT(pmap, MA_OWNED); + /* * Allocate a page table page. */ if ((m = vm_page_alloc(NULL, ptepindex, VM_ALLOC_NOOBJ | VM_ALLOC_WIRED | VM_ALLOC_ZERO)) == NULL) { - if (flags & M_WAITOK) { + if (lockp != NULL) { + RELEASE_PV_LIST_LOCK(lockp); PMAP_UNLOCK(pmap); - rw_wunlock(&pvh_global_lock); + rw_runlock(&pvh_global_lock); VM_WAIT; - rw_wlock(&pvh_global_lock); + rw_rlock(&pvh_global_lock); PMAP_LOCK(pmap); } @@ -1712,7 +1768,7 @@ _pmap_allocpte(pmap_t pmap, vm_pindex_t if ((*pml4 & PG_V) == 0) { /* Have to allocate a new pdp, recurse */ if (_pmap_allocpte(pmap, NUPDE + NUPDPE + pml4index, - flags) == NULL) { + lockp) == NULL) { --m->wire_count; atomic_subtract_int(&cnt.v_wire_count, 1); vm_page_free_zero(m); @@ -1745,7 +1801,7 @@ _pmap_allocpte(pmap_t pmap, vm_pindex_t if ((*pml4 & PG_V) == 0) { /* Have to allocate a new pd, recurse */ if (_pmap_allocpte(pmap, NUPDE + pdpindex, - flags) == NULL) { + lockp) == NULL) { --m->wire_count; atomic_subtract_int(&cnt.v_wire_count, 1); vm_page_free_zero(m); @@ -1759,7 +1815,7 @@ _pmap_allocpte(pmap_t pmap, vm_pindex_t if ((*pdp & PG_V) == 0) { /* Have to allocate a new pd, recurse */ if (_pmap_allocpte(pmap, NUPDE + pdpindex, - flags) == NULL) { + lockp) == NULL) { --m->wire_count; atomic_subtract_int(&cnt.v_wire_count, 1); @@ -1785,15 +1841,12 @@ _pmap_allocpte(pmap_t pmap, vm_pindex_t } static vm_page_t -pmap_allocpde(pmap_t pmap, vm_offset_t va, int flags) +pmap_allocpde(pmap_t pmap, vm_offset_t va, struct rwlock **lockp) { vm_pindex_t pdpindex, ptepindex; pdp_entry_t *pdpe; vm_page_t pdpg; - KASSERT((flags & (M_NOWAIT | M_WAITOK)) == M_NOWAIT || - (flags & (M_NOWAIT | M_WAITOK)) == M_WAITOK, - ("pmap_allocpde: flags is neither M_NOWAIT nor M_WAITOK")); retry: pdpe = pmap_pdpe(pmap, va); if (pdpe != NULL && (*pdpe & PG_V) != 0) { @@ -1804,24 +1857,20 @@ retry: /* Allocate a pd page. */ ptepindex = pmap_pde_pindex(va); pdpindex = ptepindex >> NPDPEPGSHIFT; - pdpg = _pmap_allocpte(pmap, NUPDE + pdpindex, flags); - if (pdpg == NULL && (flags & M_WAITOK)) + pdpg = _pmap_allocpte(pmap, NUPDE + pdpindex, lockp); + if (pdpg == NULL && lockp != NULL) goto retry; } return (pdpg); } static vm_page_t -pmap_allocpte(pmap_t pmap, vm_offset_t va, int flags) +pmap_allocpte(pmap_t pmap, vm_offset_t va, struct rwlock **lockp) { vm_pindex_t ptepindex; pd_entry_t *pd; vm_page_t m; - KASSERT((flags & (M_NOWAIT | M_WAITOK)) == M_NOWAIT || - (flags & (M_NOWAIT | M_WAITOK)) == M_WAITOK, - ("pmap_allocpte: flags is neither M_NOWAIT nor M_WAITOK")); - /* * Calculate pagetable page index */ @@ -1837,7 +1886,7 @@ retry: * normal 4K page. */ if (pd != NULL && (*pd & (PG_PS | PG_V)) == (PG_PS | PG_V)) { - if (!pmap_demote_pde(pmap, pd, va)) { + if (!pmap_demote_pde_locked(pmap, pd, va, lockp)) { /* * Invalidation of the 2MB page mapping may have caused * the deallocation of the underlying PD page. @@ -1858,8 +1907,8 @@ retry: * Here if the pte page isn't mapped, or if it has been * deallocated. */ - m = _pmap_allocpte(pmap, ptepindex, flags); - if (m == NULL && (flags & M_WAITOK)) + m = _pmap_allocpte(pmap, ptepindex, lockp); + if (m == NULL && lockp != NULL) goto retry; } return (m); @@ -2023,9 +2072,6 @@ pv_to_chunk(pv_entry_t pv) static const uint64_t pc_freemask[_NPCM] = { PC_FREE0, PC_FREE1, PC_FREE2 }; -SYSCTL_LONG(_vm_pmap, OID_AUTO, pv_entry_count, CTLFLAG_RD, &pv_entry_count, 0, - "Current number of pv entries"); - #ifdef PV_STATS static int pc_chunk_count, pc_chunk_allocs, pc_chunk_frees, pc_chunk_tryfail; @@ -2038,13 +2084,15 @@ SYSCTL_INT(_vm_pmap, OID_AUTO, pc_chunk_ SYSCTL_INT(_vm_pmap, OID_AUTO, pc_chunk_tryfail, CTLFLAG_RD, &pc_chunk_tryfail, 0, "Number of times tried to get a chunk page but failed."); -static long pv_entry_frees, pv_entry_allocs; +static long pv_entry_frees, pv_entry_allocs, pv_entry_count; static int pv_entry_spare; SYSCTL_LONG(_vm_pmap, OID_AUTO, pv_entry_frees, CTLFLAG_RD, &pv_entry_frees, 0, "Current number of pv entry frees"); SYSCTL_LONG(_vm_pmap, OID_AUTO, pv_entry_allocs, CTLFLAG_RD, &pv_entry_allocs, 0, "Current number of pv entry allocs"); +SYSCTL_LONG(_vm_pmap, OID_AUTO, pv_entry_count, CTLFLAG_RD, &pv_entry_count, 0, + "Current number of pv entries"); SYSCTL_INT(_vm_pmap, OID_AUTO, pv_entry_spare, CTLFLAG_RD, &pv_entry_spare, 0, "Current number of spare pv entries"); #endif @@ -2054,14 +2102,16 @@ SYSCTL_INT(_vm_pmap, OID_AUTO, pv_entry_ * drastic measures to free some pages so we can allocate * another pv entry chunk. * + * Returns NULL if PV entries were reclaimed from the specified pmap. + * * We do not, however, unmap 2mpages because subsequent accesses will * allocate per-page pv entries until repromotion occurs, thereby * exacerbating the shortage of free pv entries. */ static vm_page_t -pmap_pv_reclaim(pmap_t locked_pmap) +reclaim_pv_chunk(pmap_t locked_pmap, struct rwlock **lockp) { - struct pch newtail; + struct pch new_tail; struct pv_chunk *pc; struct md_page *pvh; pd_entry_t *pde; @@ -2073,13 +2123,16 @@ pmap_pv_reclaim(pmap_t locked_pmap) uint64_t inuse; int bit, field, freed; - rw_assert(&pvh_global_lock, RA_WLOCKED); + rw_assert(&pvh_global_lock, RA_LOCKED); PMAP_LOCK_ASSERT(locked_pmap, MA_OWNED); + KASSERT(lockp != NULL, ("reclaim_pv_chunk: lockp is NULL")); pmap = NULL; free = m_pc = NULL; - TAILQ_INIT(&newtail); + TAILQ_INIT(&new_tail); + mtx_lock(&pv_chunks_mutex); while ((pc = TAILQ_FIRST(&pv_chunks)) != NULL && free == NULL) { TAILQ_REMOVE(&pv_chunks, pc, pc_lru); + mtx_unlock(&pv_chunks_mutex); if (pmap != pc->pc_pmap) { if (pmap != NULL) { pmap_invalidate_all(pmap); @@ -2088,11 +2141,14 @@ pmap_pv_reclaim(pmap_t locked_pmap) } pmap = pc->pc_pmap; /* Avoid deadlock and lock recursion. */ - if (pmap > locked_pmap) + if (pmap > locked_pmap) { + RELEASE_PV_LIST_LOCK(lockp); PMAP_LOCK(pmap); - else if (pmap != locked_pmap && !PMAP_TRYLOCK(pmap)) { + } else if (pmap != locked_pmap && + !PMAP_TRYLOCK(pmap)) { pmap = NULL; - TAILQ_INSERT_TAIL(&newtail, pc, pc_lru); + TAILQ_INSERT_TAIL(&new_tail, pc, pc_lru); + mtx_lock(&pv_chunks_mutex); continue; } } @@ -2121,6 +2177,7 @@ pmap_pv_reclaim(pmap_t locked_pmap) vm_page_dirty(m); if ((tpte & PG_A) != 0) vm_page_aflag_set(m, PGA_REFERENCED); + CHANGE_PV_LIST_LOCK_TO_VM_PAGE(lockp, m); TAILQ_REMOVE(&m->md.pv_list, pv, pv_list); if (TAILQ_EMPTY(&m->md.pv_list) && (m->flags & PG_FICTITIOUS) == 0) { @@ -2136,32 +2193,36 @@ pmap_pv_reclaim(pmap_t locked_pmap) } } if (freed == 0) { - TAILQ_INSERT_TAIL(&newtail, pc, pc_lru); + TAILQ_INSERT_TAIL(&new_tail, pc, pc_lru); + mtx_lock(&pv_chunks_mutex); continue; } /* Every freed mapping is for a 4 KB page. */ pmap_resident_count_dec(pmap, freed); - PV_STAT(pv_entry_frees += freed); - PV_STAT(pv_entry_spare += freed); - pv_entry_count -= freed; + PV_STAT(atomic_add_long(&pv_entry_frees, freed)); + PV_STAT(atomic_add_int(&pv_entry_spare, freed)); + PV_STAT(atomic_subtract_long(&pv_entry_count, freed)); TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); if (pc->pc_map[0] == PC_FREE0 && pc->pc_map[1] == PC_FREE1 && pc->pc_map[2] == PC_FREE2) { - PV_STAT(pv_entry_spare -= _NPCPV); - PV_STAT(pc_chunk_count--); - PV_STAT(pc_chunk_frees++); + PV_STAT(atomic_subtract_int(&pv_entry_spare, _NPCPV)); + PV_STAT(atomic_subtract_int(&pc_chunk_count, 1)); + PV_STAT(atomic_add_int(&pc_chunk_frees, 1)); /* Entire chunk is free; return it. */ m_pc = PHYS_TO_VM_PAGE(DMAP_TO_PHYS((vm_offset_t)pc)); dump_drop_page(m_pc->phys_addr); + mtx_lock(&pv_chunks_mutex); break; } TAILQ_INSERT_HEAD(&pmap->pm_pvchunk, pc, pc_list); - TAILQ_INSERT_TAIL(&newtail, pc, pc_lru); + TAILQ_INSERT_TAIL(&new_tail, pc, pc_lru); + mtx_lock(&pv_chunks_mutex); /* One freed pv entry in locked_pmap is sufficient. */ if (pmap == locked_pmap) break; } - TAILQ_CONCAT(&pv_chunks, &newtail, pc_lru); + TAILQ_CONCAT(&pv_chunks, &new_tail, pc_lru); + mtx_unlock(&pv_chunks_mutex); if (pmap != NULL) { pmap_invalidate_all(pmap); if (pmap != locked_pmap) @@ -2187,11 +2248,11 @@ free_pv_entry(pmap_t pmap, pv_entry_t pv struct pv_chunk *pc; int idx, field, bit; - rw_assert(&pvh_global_lock, RA_WLOCKED); + rw_assert(&pvh_global_lock, RA_LOCKED); PMAP_LOCK_ASSERT(pmap, MA_OWNED); - PV_STAT(pv_entry_frees++); - PV_STAT(pv_entry_spare++); - pv_entry_count--; + PV_STAT(atomic_add_long(&pv_entry_frees, 1)); + PV_STAT(atomic_add_int(&pv_entry_spare, 1)); + PV_STAT(atomic_subtract_long(&pv_entry_count, 1)); pc = pv_to_chunk(pv); idx = pv - &pc->pc_pventry[0]; field = idx / 64; @@ -2215,10 +2276,12 @@ free_pv_chunk(struct pv_chunk *pc) { vm_page_t m; + mtx_lock(&pv_chunks_mutex); TAILQ_REMOVE(&pv_chunks, pc, pc_lru); - PV_STAT(pv_entry_spare -= _NPCPV); - PV_STAT(pc_chunk_count--); - PV_STAT(pc_chunk_frees++); + mtx_unlock(&pv_chunks_mutex); + PV_STAT(atomic_subtract_int(&pv_entry_spare, _NPCPV)); + PV_STAT(atomic_subtract_int(&pc_chunk_count, 1)); + PV_STAT(atomic_add_int(&pc_chunk_frees, 1)); /* entire chunk is free, return it */ m = PHYS_TO_VM_PAGE(DMAP_TO_PHYS((vm_offset_t)pc)); dump_drop_page(m->phys_addr); @@ -2227,20 +2290,24 @@ free_pv_chunk(struct pv_chunk *pc) } /* - * get a new pv_entry, allocating a block from the system - * when needed. + * Returns a new PV entry, allocating a new PV chunk from the system when + * needed. If this PV chunk allocation fails and a PV list lock pointer was + * given, a PV chunk is reclaimed from an arbitrary pmap. Otherwise, NULL is + * returned. + * + * The given PV list lock may be released. */ static pv_entry_t -get_pv_entry(pmap_t pmap, boolean_t try) +get_pv_entry(pmap_t pmap, struct rwlock **lockp) { int bit, field; pv_entry_t pv; struct pv_chunk *pc; vm_page_t m; - rw_assert(&pvh_global_lock, RA_WLOCKED); + rw_assert(&pvh_global_lock, RA_LOCKED); PMAP_LOCK_ASSERT(pmap, MA_OWNED); - PV_STAT(pv_entry_allocs++); + PV_STAT(atomic_add_long(&pv_entry_allocs, 1)); retry: pc = TAILQ_FIRST(&pmap->pm_pvchunk); if (pc != NULL) { @@ -2260,8 +2327,8 @@ retry: TAILQ_INSERT_TAIL(&pmap->pm_pvchunk, pc, pc_list); } - pv_entry_count++; - PV_STAT(pv_entry_spare--); + PV_STAT(atomic_add_long(&pv_entry_count, 1)); + PV_STAT(atomic_subtract_int(&pv_entry_spare, 1)); return (pv); } } @@ -2269,31 +2336,121 @@ retry: m = vm_page_alloc(NULL, 0, VM_ALLOC_NORMAL | VM_ALLOC_NOOBJ | VM_ALLOC_WIRED); if (m == NULL) { - if (try) { + if (lockp == NULL) { PV_STAT(pc_chunk_tryfail++); return (NULL); } - m = pmap_pv_reclaim(pmap); + m = reclaim_pv_chunk(pmap, lockp); if (m == NULL) goto retry; } - PV_STAT(pc_chunk_count++); - PV_STAT(pc_chunk_allocs++); + PV_STAT(atomic_add_int(&pc_chunk_count, 1)); + PV_STAT(atomic_add_int(&pc_chunk_allocs, 1)); dump_add_page(m->phys_addr); pc = (void *)PHYS_TO_DMAP(m->phys_addr); pc->pc_pmap = pmap; pc->pc_map[0] = PC_FREE0 & ~1ul; /* preallocated bit 0 */ pc->pc_map[1] = PC_FREE1; pc->pc_map[2] = PC_FREE2; + mtx_lock(&pv_chunks_mutex); TAILQ_INSERT_TAIL(&pv_chunks, pc, pc_lru); + mtx_unlock(&pv_chunks_mutex); pv = &pc->pc_pventry[0]; TAILQ_INSERT_HEAD(&pmap->pm_pvchunk, pc, pc_list); - pv_entry_count++; - PV_STAT(pv_entry_spare += _NPCPV - 1); + PV_STAT(atomic_add_long(&pv_entry_count, 1)); + PV_STAT(atomic_add_int(&pv_entry_spare, _NPCPV - 1)); return (pv); } /* + * Returns the number of one bits within the given PV chunk map element. + */ +static int +popcnt_pc_map_elem(uint64_t elem) +{ + int count; + + /* + * This simple method of counting the one bits performs well because + * the given element typically contains more zero bits than one bits. + */ + count = 0; + for (; elem != 0; elem &= elem - 1) + count++; + return (count); +} + +/* + * Ensure that the number of spare PV entries in the specified pmap meets or + * exceeds the given count, "needed". + * + * The given PV list lock may be released. + */ +static void +reserve_pv_entries(pmap_t pmap, int needed, struct rwlock **lockp) +{ + struct pch new_tail; + struct pv_chunk *pc; + int avail, free; + vm_page_t m; + + rw_assert(&pvh_global_lock, RA_LOCKED); + PMAP_LOCK_ASSERT(pmap, MA_OWNED); + KASSERT(lockp != NULL, ("reserve_pv_entries: lockp is NULL")); + + /* + * Newly allocated PV chunks must be stored in a private list until + * the required number of PV chunks have been allocated. Otherwise, + * reclaim_pv_chunk() could recycle one of these chunks. In + * contrast, these chunks must be added to the pmap upon allocation. + */ + TAILQ_INIT(&new_tail); +retry: + avail = 0; + TAILQ_FOREACH(pc, &pmap->pm_pvchunk, pc_list) { + if ((cpu_feature2 & CPUID2_POPCNT) == 0) { + free = popcnt_pc_map_elem(pc->pc_map[0]); + free += popcnt_pc_map_elem(pc->pc_map[1]); + free += popcnt_pc_map_elem(pc->pc_map[2]); + } else { + free = popcntq(pc->pc_map[0]); + free += popcntq(pc->pc_map[1]); + free += popcntq(pc->pc_map[2]); + } + if (free == 0) + break; + avail += free; + if (avail >= needed) + break; + } + for (; avail < needed; avail += _NPCPV) { + m = vm_page_alloc(NULL, 0, VM_ALLOC_NORMAL | VM_ALLOC_NOOBJ | + VM_ALLOC_WIRED); + if (m == NULL) { + m = reclaim_pv_chunk(pmap, lockp); + if (m == NULL) + goto retry; + } + PV_STAT(atomic_add_int(&pc_chunk_count, 1)); + PV_STAT(atomic_add_int(&pc_chunk_allocs, 1)); + dump_add_page(m->phys_addr); + pc = (void *)PHYS_TO_DMAP(m->phys_addr); + pc->pc_pmap = pmap; + pc->pc_map[0] = PC_FREE0; + pc->pc_map[1] = PC_FREE1; + pc->pc_map[2] = PC_FREE2; + TAILQ_INSERT_HEAD(&pmap->pm_pvchunk, pc, pc_list); + TAILQ_INSERT_TAIL(&new_tail, pc, pc_lru); + PV_STAT(atomic_add_int(&pv_entry_spare, _NPCPV)); + } + if (!TAILQ_EMPTY(&new_tail)) { + mtx_lock(&pv_chunks_mutex); + TAILQ_CONCAT(&pv_chunks, &new_tail, pc_lru); + mtx_unlock(&pv_chunks_mutex); + } +} + +/* * First find and then remove the pv entry for the specified pmap and virtual * address from the specified pv list. Returns the pv entry if found and NULL * otherwise. This operation can be performed on pv lists for either 4KB or @@ -2304,7 +2461,7 @@ pmap_pvh_remove(struct md_page *pvh, pma { pv_entry_t pv; - rw_assert(&pvh_global_lock, RA_WLOCKED); + rw_assert(&pvh_global_lock, RA_LOCKED); TAILQ_FOREACH(pv, &pvh->pv_list, pv_list) { if (pmap == PV_PMAP(pv) && va == pv->pv_va) { TAILQ_REMOVE(&pvh->pv_list, pv, pv_list); @@ -2320,20 +2477,26 @@ pmap_pvh_remove(struct md_page *pvh, pma * entries for each of the 4KB page mappings. */ static void -pmap_pv_demote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa) +pmap_pv_demote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa, + struct rwlock **lockp) { struct md_page *pvh; + struct pv_chunk *pc; pv_entry_t pv; vm_offset_t va_last; vm_page_t m; + int bit, field; - rw_assert(&pvh_global_lock, RA_WLOCKED); + rw_assert(&pvh_global_lock, RA_LOCKED); + PMAP_LOCK_ASSERT(pmap, MA_OWNED); KASSERT((pa & PDRMASK) == 0, ("pmap_pv_demote_pde: pa is not 2mpage aligned")); + CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, pa); /* * Transfer the 2mpage's pv entry for this mapping to the first - * page's pv list. + * page's pv list. Once this transfer begins, the pv list lock + * must not be released until the last pv entry is reinstantiated. */ pvh = pa_to_pvh(pa); va = trunc_2mpage(va); @@ -2342,14 +2505,37 @@ pmap_pv_demote_pde(pmap_t pmap, vm_offse m = PHYS_TO_VM_PAGE(pa); TAILQ_INSERT_TAIL(&m->md.pv_list, pv, pv_list); /* Instantiate the remaining NPTEPG - 1 pv entries. */ + PV_STAT(atomic_add_long(&pv_entry_allocs, NPTEPG - 1)); va_last = va + NBPDR - PAGE_SIZE; - do { - m++; - KASSERT((m->oflags & VPO_UNMANAGED) == 0, - ("pmap_pv_demote_pde: page %p is not managed", m)); - va += PAGE_SIZE; - pmap_insert_entry(pmap, va, m); - } while (va < va_last); + for (;;) { + pc = TAILQ_FIRST(&pmap->pm_pvchunk); + KASSERT(pc->pc_map[0] != 0 || pc->pc_map[1] != 0 || + pc->pc_map[2] != 0, ("pmap_pv_demote_pde: missing spare")); + for (field = 0; field < _NPCM; field++) { + while (pc->pc_map[field]) { + bit = bsfq(pc->pc_map[field]); + pc->pc_map[field] &= ~(1ul << bit); + pv = &pc->pc_pventry[field * 64 + bit]; + va += PAGE_SIZE; + pv->pv_va = va; + m++; + KASSERT((m->oflags & VPO_UNMANAGED) == 0, + ("pmap_pv_demote_pde: page %p is not managed", m)); + TAILQ_INSERT_TAIL(&m->md.pv_list, pv, pv_list); + if (va == va_last) + goto out; + } + } + TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); + TAILQ_INSERT_TAIL(&pmap->pm_pvchunk, pc, pc_list); + } +out: + if (pc->pc_map[0] == 0 && pc->pc_map[1] == 0 && pc->pc_map[2] == 0) { + TAILQ_REMOVE(&pmap->pm_pvchunk, pc, pc_list); + TAILQ_INSERT_TAIL(&pmap->pm_pvchunk, pc, pc_list); + } + PV_STAT(atomic_add_long(&pv_entry_count, NPTEPG - 1)); + PV_STAT(atomic_subtract_int(&pv_entry_spare, NPTEPG - 1)); } /* @@ -2358,23 +2544,25 @@ pmap_pv_demote_pde(pmap_t pmap, vm_offse * for the 2MB page mapping. */ static void -pmap_pv_promote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa) +pmap_pv_promote_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa, + struct rwlock **lockp) { struct md_page *pvh; pv_entry_t pv; vm_offset_t va_last; vm_page_t m; - rw_assert(&pvh_global_lock, RA_WLOCKED); + rw_assert(&pvh_global_lock, RA_LOCKED); KASSERT((pa & PDRMASK) == 0, ("pmap_pv_promote_pde: pa is not 2mpage aligned")); + CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, pa); /* - * Transfer the first page's pv entry for this mapping to the - * 2mpage's pv list. Aside from avoiding the cost of a call - * to get_pv_entry(), a transfer avoids the possibility that - * get_pv_entry() calls pmap_collect() and that pmap_collect() - * removes one of the mappings that is being promoted. + * Transfer the first page's pv entry for this mapping to the 2mpage's + * pv list. Aside from avoiding the cost of a call to get_pv_entry(), + * a transfer avoids the possibility that get_pv_entry() calls + * reclaim_pv_chunk() and that reclaim_pv_chunk() removes one of the + * mappings that is being promoted. */ m = PHYS_TO_VM_PAGE(pa); va = trunc_2mpage(va); @@ -2406,48 +2594,22 @@ pmap_pvh_free(struct md_page *pvh, pmap_ free_pv_entry(pmap, pv); } -static void -pmap_remove_entry(pmap_t pmap, vm_page_t m, vm_offset_t va) -{ - struct md_page *pvh; - - rw_assert(&pvh_global_lock, RA_WLOCKED); - pmap_pvh_free(&m->md, pmap, va); - if (TAILQ_EMPTY(&m->md.pv_list) && (m->flags & PG_FICTITIOUS) == 0) { - pvh = pa_to_pvh(VM_PAGE_TO_PHYS(m)); - if (TAILQ_EMPTY(&pvh->pv_list)) - vm_page_aflag_clear(m, PGA_WRITEABLE); - } -} - /* - * Create a pv entry for page at pa for - * (pmap, va). - */ -static void -pmap_insert_entry(pmap_t pmap, vm_offset_t va, vm_page_t m) -{ - pv_entry_t pv; - - rw_assert(&pvh_global_lock, RA_WLOCKED); - PMAP_LOCK_ASSERT(pmap, MA_OWNED); - pv = get_pv_entry(pmap, FALSE); - pv->pv_va = va; - TAILQ_INSERT_TAIL(&m->md.pv_list, pv, pv_list); -} - -/* - * Conditionally create a pv entry. + * Conditionally create the PV entry for a 4KB page mapping if the required + * memory can be allocated without resorting to reclamation. */ static boolean_t -pmap_try_insert_pv_entry(pmap_t pmap, vm_offset_t va, vm_page_t m) +pmap_try_insert_pv_entry(pmap_t pmap, vm_offset_t va, vm_page_t m, + struct rwlock **lockp) { pv_entry_t pv; - rw_assert(&pvh_global_lock, RA_WLOCKED); + rw_assert(&pvh_global_lock, RA_LOCKED); PMAP_LOCK_ASSERT(pmap, MA_OWNED); - if ((pv = get_pv_entry(pmap, TRUE)) != NULL) { + /* Pass NULL instead of the lock pointer to disable reclamation. */ + if ((pv = get_pv_entry(pmap, NULL)) != NULL) { pv->pv_va = va; + CHANGE_PV_LIST_LOCK_TO_VM_PAGE(lockp, m); TAILQ_INSERT_TAIL(&m->md.pv_list, pv, pv_list); return (TRUE); } else @@ -2455,17 +2617,22 @@ pmap_try_insert_pv_entry(pmap_t pmap, vm } /* - * Create the pv entry for a 2MB page mapping. + * Conditionally create the PV entry for a 2MB page mapping if the required + * memory can be allocated without resorting to reclamation. */ static boolean_t -pmap_pv_insert_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa) +pmap_pv_insert_pde(pmap_t pmap, vm_offset_t va, vm_paddr_t pa, + struct rwlock **lockp) { struct md_page *pvh; pv_entry_t pv; - rw_assert(&pvh_global_lock, RA_WLOCKED); - if ((pv = get_pv_entry(pmap, TRUE)) != NULL) { + rw_assert(&pvh_global_lock, RA_LOCKED); + PMAP_LOCK_ASSERT(pmap, MA_OWNED); + /* Pass NULL instead of the lock pointer to disable reclamation. */ + if ((pv = get_pv_entry(pmap, NULL)) != NULL) { pv->pv_va = va; + CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, pa); pvh = pa_to_pvh(pa); TAILQ_INSERT_TAIL(&pvh->pv_list, pv, pv_list); return (TRUE); @@ -2494,6 +2661,20 @@ pmap_fill_ptp(pt_entry_t *firstpte, pt_e static boolean_t pmap_demote_pde(pmap_t pmap, pd_entry_t *pde, vm_offset_t va) { + struct rwlock *lock; + boolean_t rv; + + lock = NULL; + rv = pmap_demote_pde_locked(pmap, pde, va, &lock); + if (lock != NULL) + rw_wunlock(lock); + return (rv); +} + +static boolean_t +pmap_demote_pde_locked(pmap_t pmap, pd_entry_t *pde, vm_offset_t va, + struct rwlock **lockp) +{ pd_entry_t newpde, oldpde; pt_entry_t *firstpte, newpte; vm_paddr_t mptepa; @@ -2528,7 +2709,8 @@ pmap_demote_pde(pmap_t pmap, pd_entry_t DMAP_MAX_ADDRESS ? VM_ALLOC_INTERRUPT : VM_ALLOC_NORMAL) | VM_ALLOC_NOOBJ | VM_ALLOC_WIRED)) == NULL) { free = NULL; - pmap_remove_pde(pmap, pde, trunc_2mpage(va), &free); + pmap_remove_pde(pmap, pde, trunc_2mpage(va), &free, + lockp); pmap_invalidate_page(pmap, trunc_2mpage(va)); pmap_free_zero_pages(free); CTR2(KTR_PMAP, "pmap_demote_pde: failure for va %#lx" @@ -2568,6 +2750,17 @@ pmap_demote_pde(pmap_t pmap, pd_entry_t pmap_fill_ptp(firstpte, newpte); /* + * The spare PV entries must be reserved prior to demoting the + * mapping, that is, prior to changing the PDE. Otherwise, the state + * of the PDE and the PV lists will be inconsistent, which can result + * in reclaim_pv_chunk() attempting to remove a PV entry from the + * wrong PV list and pmap_pv_demote_pde() failing to find the expected + * PV entry for the 2MB page mapping that is being demoted. + */ + if ((oldpde & PG_MANAGED) != 0) + reserve_pv_entries(pmap, NPTEPG - 1, lockp); + + /* * Demote the mapping. This pmap is locked. The old PDE has * PG_A set. If the old PDE has PG_RW set, it also has PG_M * set. Thus, there is no danger of a race with another @@ -2586,18 +2779,12 @@ pmap_demote_pde(pmap_t pmap, pd_entry_t pmap_invalidate_page(pmap, (vm_offset_t)vtopte(va)); /* - * Demote the pv entry. This depends on the earlier demotion - * of the mapping. Specifically, the (re)creation of a per- - * page pv entry might trigger the execution of pmap_collect(), - * which might reclaim a newly (re)created per-page pv entry - * and destroy the associated mapping. In order to destroy - * the mapping, the PDE must have already changed from mapping - * the 2mpage to referencing the page table page. + * Demote the PV entry. */ if ((oldpde & PG_MANAGED) != 0) - pmap_pv_demote_pde(pmap, va, oldpde & PG_PS_FRAME); + pmap_pv_demote_pde(pmap, va, oldpde & PG_PS_FRAME, lockp); - pmap_pde_demotions++; + atomic_add_long(&pmap_pde_demotions, 1); CTR2(KTR_PMAP, "pmap_demote_pde: success for va %#lx" " in pmap %p", va, pmap); return (TRUE); @@ -2608,7 +2795,7 @@ pmap_demote_pde(pmap_t pmap, pd_entry_t */ static int pmap_remove_pde(pmap_t pmap, pd_entry_t *pdq, vm_offset_t sva, - vm_page_t *free) + vm_page_t *free, struct rwlock **lockp) { struct md_page *pvh; pd_entry_t oldpde; @@ -2630,6 +2817,7 @@ pmap_remove_pde(pmap_t pmap, pd_entry_t pmap_invalidate_page(kernel_pmap, sva); pmap_resident_count_dec(pmap, NBPDR / PAGE_SIZE); if (oldpde & PG_MANAGED) { + CHANGE_PV_LIST_LOCK_TO_PHYS(lockp, oldpde & PG_PS_FRAME); pvh = pa_to_pvh(oldpde & PG_PS_FRAME); pmap_pvh_free(pvh, pmap, sva); *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-9@FreeBSD.ORG Wed Sep 5 21:27:29 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BD830106564A; Wed, 5 Sep 2012 21:27:29 +0000 (UTC) (envelope-from alc@rice.edu) Received: from mh10.mail.rice.edu (mh10.mail.rice.edu [128.42.201.30]) by mx1.freebsd.org (Postfix) with ESMTP id 8714C8FC0A; Wed, 5 Sep 2012 21:27:29 +0000 (UTC) Received: from mh10.mail.rice.edu (localhost.localdomain [127.0.0.1]) by mh10.mail.rice.edu (Postfix) with ESMTP id 3025C6051A; Wed, 5 Sep 2012 16:27:27 -0500 (CDT) Received: from mh10.mail.rice.edu (localhost.localdomain [127.0.0.1]) by mh10.mail.rice.edu (Postfix) with ESMTP id 2E58F604F5; Wed, 5 Sep 2012 16:27:27 -0500 (CDT) X-Virus-Scanned: by amavis-2.7.0 at mh10.mail.rice.edu, auth channel Received: from mh10.mail.rice.edu ([127.0.0.1]) by mh10.mail.rice.edu (mh10.mail.rice.edu [127.0.0.1]) (amavis, port 10026) with ESMTP id ym41si1-z6RI; Wed, 5 Sep 2012 16:27:27 -0500 (CDT) Received: from [10.74.20.46] (staff-74-dun20-046.rice.edu [10.74.20.46]) (using TLSv1 with cipher RC4-MD5 (128/128 bits)) (No client certificate requested) (Authenticated sender: alc) by mh10.mail.rice.edu (Postfix) with ESMTPSA id E2E3C604C6; Wed, 5 Sep 2012 16:27:26 -0500 (CDT) Message-ID: <5047C3A4.4040509@rice.edu> Date: Wed, 05 Sep 2012 16:27:00 -0500 From: Alan Cox User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:14.0) Gecko/20120713 Thunderbird/14.0 MIME-Version: 1.0 To: Konstantin Belousov References: <201209052040.q85KeCTe098721@svn.freebsd.org> In-Reply-To: <201209052040.q85KeCTe098721@svn.freebsd.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240151 - in stable/9/sys: amd64/amd64 amd64/include i386/i386 i386/xen kern mips/mips sparc64/sparc64 vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Sep 2012 21:27:29 -0000 On 9/5/2012 3:40 PM, Konstantin Belousov wrote: > Author: kib > Date: Wed Sep 5 20:40:11 2012 > New Revision: 240151 > URL: http://svn.freebsd.org/changeset/base/240151 > > Log: > MFC r233122,r237086,r237228,r237264,r237290,r237404,r237414,r237513,r237551, > r237592,r237604,r237623,r237684,r237733,r237813,r237855,r238124,r238126, > r238163,r238414,r238610,r238889,r238970,r239072,r239137,r240126 (all by alc): > > Add fine-grained PV chunk and list locking to the amd64 pmap, enabling > concurrent execution of the following functions on different pmaps: > > pmap_change_wiring() > pmap_copy() > pmap_enter() > pmap_enter_object() > pmap_enter_quick() > pmap_page_exists_quick() > pmap_page_is_mapped() > pmap_protect() > pmap_remove() > pmap_remove_pages() > > Requested and approved by: alc > > Modified: > stable/9/sys/amd64/amd64/pmap.c > stable/9/sys/amd64/include/cpufunc.h > stable/9/sys/i386/i386/pmap.c > stable/9/sys/i386/xen/pmap.c > stable/9/sys/kern/subr_witness.c > stable/9/sys/mips/mips/pmap.c > stable/9/sys/sparc64/sparc64/pmap.c > stable/9/sys/vm/vm_map.c > stable/9/sys/vm/vm_page.c > Directory Properties: > stable/9/sys/ (props changed) > Thank you! Alan From owner-svn-src-stable-9@FreeBSD.ORG Thu Sep 6 06:17:40 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3D2651065670; Thu, 6 Sep 2012 06:17:40 +0000 (UTC) (envelope-from mckay@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 0F2F58FC0A; Thu, 6 Sep 2012 06:17:40 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q866Hd41072347; Thu, 6 Sep 2012 06:17:39 GMT (envelope-from mckay@svn.freebsd.org) Received: (from mckay@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q866Hdpl072343; Thu, 6 Sep 2012 06:17:39 GMT (envelope-from mckay@svn.freebsd.org) Message-Id: <201209060617.q866Hdpl072343@svn.freebsd.org> From: Stephen McKay Date: Thu, 6 Sep 2012 06:17:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240157 - in stable/9: contrib/file lib/libmagic X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Sep 2012 06:17:40 -0000 Author: mckay Date: Thu Sep 6 06:17:39 2012 New Revision: 240157 URL: http://svn.freebsd.org/changeset/base/240157 Log: MFC r235638,r239348: - Work around failure to compile on FreeBSD 7.x machines. - Correct a regression introduced during the import of file(1) 5.11. PR: bin/170415 Reviewed by: obrien@ Modified: stable/9/contrib/file/apprentice.c stable/9/lib/libmagic/Makefile stable/9/lib/libmagic/config.h Directory Properties: stable/9/ (props changed) stable/9/contrib/file/ (props changed) stable/9/lib/ (props changed) Modified: stable/9/contrib/file/apprentice.c ============================================================================== --- stable/9/contrib/file/apprentice.c Thu Sep 6 03:19:48 2012 (r240156) +++ stable/9/contrib/file/apprentice.c Thu Sep 6 06:17:39 2012 (r240157) @@ -648,7 +648,6 @@ set_test_type(struct magic *mstart, stru break; case FILE_REGEX: case FILE_SEARCH: -#ifndef COMPILE_ONLY /* Check for override */ if (mstart->str_flags & STRING_BINTEST) mstart->flag |= BINTEST; @@ -664,7 +663,6 @@ set_test_type(struct magic *mstart, stru mstart->flag |= BINTEST; else mstart->flag |= TEXTTEST; -#endif break; case FILE_DEFAULT: /* can't deduce anything; we shouldn't see this at the Modified: stable/9/lib/libmagic/Makefile ============================================================================== --- stable/9/lib/libmagic/Makefile Thu Sep 6 03:19:48 2012 (r240156) +++ stable/9/lib/libmagic/Makefile Thu Sep 6 06:17:39 2012 (r240157) @@ -40,8 +40,9 @@ magic.mgc: mkmagic magic CLEANFILES+= mkmagic build-tools: mkmagic -mkmagic: apprentice.c funcs.c magic.c print.c - ${CC} ${CFLAGS} -DCOMPILE_ONLY ${LDFLAGS} -o ${.TARGET} ${.ALLSRC} +mkmagic: apprentice.c encoding.c funcs.c getline.c magic.c print.c + ${CC} ${CFLAGS} -DCOMPILE_ONLY -DHOSTPROG ${LDFLAGS} \ + -o ${.TARGET} ${.ALLSRC} FILEVER!= awk '$$1 == "\#define" && $$2 == "VERSION" { print $$3; exit }' \ ${.CURDIR}/config.h Modified: stable/9/lib/libmagic/config.h ============================================================================== --- stable/9/lib/libmagic/config.h Thu Sep 6 03:19:48 2012 (r240156) +++ stable/9/lib/libmagic/config.h Thu Sep 6 06:17:39 2012 (r240157) @@ -39,7 +39,9 @@ #define HAVE_FSEEKO 1 /* Define to 1 if you have the `getline' function. */ +#ifndef HOSTPROG #define HAVE_GETLINE 1 +#endif /* Define to 1 if you have the header file. */ #define HAVE_GETOPT_H 1 From owner-svn-src-stable-9@FreeBSD.ORG Thu Sep 6 07:45:46 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0299E106566C; Thu, 6 Sep 2012 07:45:46 +0000 (UTC) (envelope-from thomas@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id DFB708FC08; Thu, 6 Sep 2012 07:45:45 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q867jjQX083093; Thu, 6 Sep 2012 07:45:45 GMT (envelope-from thomas@svn.freebsd.org) Received: (from thomas@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q867jjHO083089; Thu, 6 Sep 2012 07:45:45 GMT (envelope-from thomas@svn.freebsd.org) Message-Id: <201209060745.q867jjHO083089@svn.freebsd.org> From: Thomas Quinot Date: Thu, 6 Sep 2012 07:45:45 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240159 - in stable/9: sbin/geom/class/multipath sys/geom/multipath X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Sep 2012 07:45:46 -0000 Author: thomas Date: Thu Sep 6 07:45:45 2012 New Revision: 240159 URL: http://svn.freebsd.org/changeset/base/240159 Log: MFC: merge rev. 239012 from head to stable/9 New command "gmultipath prefer" to force selection of a specified provider in an Active/Passive configuration. Modified: stable/9/sbin/geom/class/multipath/geom_multipath.c stable/9/sbin/geom/class/multipath/gmultipath.8 stable/9/sys/geom/multipath/g_multipath.c Directory Properties: stable/9/sbin/geom/class/multipath/ (props changed) stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/e1000/ (props changed) stable/9/sys/dev/isp/ (props changed) stable/9/sys/dev/ixgbe/ (props changed) stable/9/sys/dev/puc/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/modules/ (props changed) Modified: stable/9/sbin/geom/class/multipath/geom_multipath.c ============================================================================== --- stable/9/sbin/geom/class/multipath/geom_multipath.c Thu Sep 6 07:03:56 2012 (r240158) +++ stable/9/sbin/geom/class/multipath/geom_multipath.c Thu Sep 6 07:45:45 2012 (r240159) @@ -49,6 +49,7 @@ uint32_t version = G_MULTIPATH_VERSION; static void mp_main(struct gctl_req *, unsigned int); static void mp_label(struct gctl_req *); static void mp_clear(struct gctl_req *); +static void mp_prefer(struct gctl_req *); struct g_command class_commands[] = { { @@ -87,6 +88,10 @@ struct g_command class_commands[] = { "[-v] name prov" }, { + "prefer", G_FLAG_VERBOSE, mp_main, G_NULL_OPTS, + "[-v] prov ..." + }, + { "fail", G_FLAG_VERBOSE, NULL, G_NULL_OPTS, "[-v] name prov" }, @@ -131,6 +136,8 @@ mp_main(struct gctl_req *req, unsigned i mp_label(req); } else if (strcmp(name, "clear") == 0) { mp_clear(req); + } else if (strcmp(name, "prefer") == 0) { + mp_prefer(req); } else { gctl_error(req, "Unknown command: %s.", name); } @@ -293,3 +300,22 @@ mp_clear(struct gctl_req *req) } } +static void +mp_prefer(struct gctl_req *req) +{ + const char *name, *comp, *errstr; + int nargs; + + nargs = gctl_get_int(req, "nargs"); + if (nargs != 2) { + gctl_error(req, "Usage: prefer GEOM PROVIDER"); + return; + } + name = gctl_get_ascii(req, "arg0"); + comp = gctl_get_ascii(req, "arg1"); + errstr = gctl_issue (req); + if (errstr != NULL) { + fprintf(stderr, "Can't set %s preferred provider to %s: %s.\n", + name, comp, errstr); + } +} Modified: stable/9/sbin/geom/class/multipath/gmultipath.8 ============================================================================== --- stable/9/sbin/geom/class/multipath/gmultipath.8 Thu Sep 6 07:03:56 2012 (r240158) +++ stable/9/sbin/geom/class/multipath/gmultipath.8 Thu Sep 6 07:45:45 2012 (r240159) @@ -66,6 +66,11 @@ .Op Fl v .Ar name .Nm +.Cm prefer +.Op Fl v +.Ar name +.Ar prov +.Nm .Cm getactive .Op Fl v .Ar name @@ -171,7 +176,9 @@ If there are other paths present, new re Mark specified provider as a path of the specified multipath device as operational, allowing it to handle requests. .It Cm rotate -Change the active provider/path in Active/Passive mode. +Change the active provider/path to the next available provider in Active/Passive mode. +.It Cm prefer +Change the active provider/path to the specified provider in Active/Passive mode. .It Cm getactive Get the currently active provider(s)/path(s). .It Cm destroy Modified: stable/9/sys/geom/multipath/g_multipath.c ============================================================================== --- stable/9/sys/geom/multipath/g_multipath.c Thu Sep 6 07:03:56 2012 (r240158) +++ stable/9/sys/geom/multipath/g_multipath.c Thu Sep 6 07:45:45 2012 (r240159) @@ -849,6 +849,78 @@ g_multipath_ctl_add_name(struct gctl_req } static void +g_multipath_ctl_prefer(struct gctl_req *req, struct g_class *mp) +{ + struct g_geom *gp; + struct g_multipath_softc *sc; + struct g_consumer *cp; + const char *name, *mpname; + static const char devpf[6] = "/dev/"; + int *nargs; + + g_topology_assert(); + + mpname = gctl_get_asciiparam(req, "arg0"); + if (mpname == NULL) { + gctl_error(req, "No 'arg0' argument"); + return; + } + gp = g_multipath_find_geom(mp, mpname); + if (gp == NULL) { + gctl_error(req, "Device %s is invalid", mpname); + return; + } + sc = gp->softc; + + nargs = gctl_get_paraml(req, "nargs", sizeof(*nargs)); + if (nargs == NULL) { + gctl_error(req, "No 'nargs' argument"); + return; + } + if (*nargs != 2) { + gctl_error(req, "missing device"); + return; + } + + name = gctl_get_asciiparam(req, "arg1"); + if (name == NULL) { + gctl_error(req, "No 'arg1' argument"); + return; + } + if (strncmp(name, devpf, 5) == 0) { + name += 5; + } + + LIST_FOREACH(cp, &gp->consumer, consumer) { + if (cp->provider != NULL + && strcmp(cp->provider->name, name) == 0) + break; + } + + if (cp == NULL) { + gctl_error(req, "Provider %s not found", name); + return; + } + + mtx_lock(&sc->sc_mtx); + + if (cp->index & MP_BAD) { + gctl_error(req, "Consumer %s is invalid", name); + mtx_unlock(&sc->sc_mtx); + return; + } + + /* Here when the consumer is present and in good shape */ + + sc->sc_active = cp; + if (!sc->sc_active_active) + printf("GEOM_MULTIPATH: %s now active path in %s\n", + sc->sc_active->provider->name, sc->sc_name); + + mtx_unlock(&sc->sc_mtx); +} + +static void g_multipath_ctl_add(struct gctl_req *req, struct g_class *mp) { struct g_multipath_softc *sc; @@ -1278,6 +1350,8 @@ g_multipath_config(struct gctl_req *req, gctl_error(req, "Userland and kernel parts are out of sync"); } else if (strcmp(verb, "add") == 0) { g_multipath_ctl_add(req, mp); + } else if (strcmp(verb, "prefer") == 0) { + g_multipath_ctl_prefer(req, mp); } else if (strcmp(verb, "create") == 0) { g_multipath_ctl_create(req, mp); } else if (strcmp(verb, "configure") == 0) { From owner-svn-src-stable-9@FreeBSD.ORG Thu Sep 6 17:28:48 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 62799106566C; Thu, 6 Sep 2012 17:28:48 +0000 (UTC) (envelope-from np@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 45BAC8FC1E; Thu, 6 Sep 2012 17:28:48 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q86HSmUV057793; Thu, 6 Sep 2012 17:28:48 GMT (envelope-from np@svn.freebsd.org) Received: (from np@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q86HSm32057780; Thu, 6 Sep 2012 17:28:48 GMT (envelope-from np@svn.freebsd.org) Message-Id: <201209061728.q86HSm32057780@svn.freebsd.org> From: Navdeep Parhar Date: Thu, 6 Sep 2012 17:28:48 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240169 - in stable/9/sys: dev/cxgb/ulp/tom dev/cxgbe dev/cxgbe/common dev/cxgbe/firmware dev/cxgbe/tom modules/cxgbe/if_cxgbe modules/cxgbe/tom X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Sep 2012 17:28:48 -0000 Author: np Date: Thu Sep 6 17:28:47 2012 New Revision: 240169 URL: http://svn.freebsd.org/changeset/base/240169 Log: MFC many cxgb and cxgbe features and fixes (r239258, r239259, r239264, r239266, r239336, r239338, r239339, r239341, r239344, r239514, r239527, r239528, r239544. r239258: Convert some fixed parameters to tunables (with reasonable default values). - cong_drop specifies what to do on congestion: nothing, backpressure, or drop. - fl_pktshift specifies the padding before Ethernet payload. - fl_pad specifies the boundary upto which to pad Ethernet payload. - spg_len controls the length of the status page. r239259: if_iqdrops should include frames truncated within the chip. r239264: Assume INET, INET6, and TCP_OFFLOAD when the driver is built out of tree and KERNBUILDDIR is not set. r239266: The size of the buffers in an Ethernet freelist has to be higher than the interface's MTU. Initialize such freelists with correct values. This wasn't a problem for common MTUs (1500 and 9000) as the buffers (2048 and 9216 in size) happened to have enough spare room. I ran into it when playing around with unusual MTUs. r239336: Allow for a different handler for each type of firmware message. r239338: Add a routine (t4_set_tcb_field) to update arbitrary parts of a hardware TCB. Filters are programmed by modifying the TCB too (via a different routine) and the reply to any TCB update is delivered via a CPL_SET_TCB_RPL. Figure out whether the reply is for a filter-write or something else and route it appropriately. r239339: Make room for DDP page pods in the default configuration profile. While here, bump up the L2 table's size to 4K entries. r239341: Initialize various DDP parameters in the main cxgbe(4) driver: - Setup multiple DDP page sizes. When the driver attempts DDP it will try to combine physically contiguous pages into regions of these sizes. - Set the indicate size such that the payload carried in the indicate can be copied in the header mbuf (and the 16K rx buffer can be recycled). - Set DDP threshold to the max payload that the chip will coalesce and deliver to the driver (this is ~16K by default, which is also why the offload rx queue is backed by 16K buffers). If the chip is able to coalesce up to the max it's allowed to, it's a good sign that the peer is transmitting in bulk without any TCP PSH. r239344: Support for TCP DDP (Direct Data Placement) in the T4 TOE module. Basically, this is automatic rx zero copy when feasible. TCP payload is DMA'd directly into the userspace buffer described by the uio submitted in soreceive by an application. - Works with sockets that are being handled by the TCP offload engine of a T4 chip (you need t4_tom.ko module loaded after cxgbe, and an "ifconfig +toe" on the cxgbe interface). - Does not require any modification to the application. - Not enabled by default. Use hw.t4nex..toe.ddp="1" to enable it. r239514: Minor cleanup: use bitwise ops instead of pointless wrappers around setbit/clrbit. r239527: Cannot hold a mutex around vm_fault_quick_hold_pages, so don't. Tweak some comments while here. r239528: Avoid a NULL pointer dereference. r239544: Deal with the case where a syncache entry added by the TOE driver is evicted from the syncache but a later syncache_expand succeeds because of syncookies. The TOE driver has to resort to more direct means to install its hooks in the socket in this case. Added: stable/9/sys/dev/cxgbe/tom/t4_ddp.c - copied, changed from r239344, head/sys/dev/cxgbe/tom/t4_ddp.c Modified: stable/9/sys/dev/cxgb/ulp/tom/cxgb_listen.c stable/9/sys/dev/cxgb/ulp/tom/cxgb_toepcb.h stable/9/sys/dev/cxgbe/adapter.h stable/9/sys/dev/cxgbe/common/t4_hw.h stable/9/sys/dev/cxgbe/common/t4_msg.h stable/9/sys/dev/cxgbe/firmware/t4fw_cfg.txt stable/9/sys/dev/cxgbe/offload.h stable/9/sys/dev/cxgbe/t4_main.c stable/9/sys/dev/cxgbe/t4_sge.c stable/9/sys/dev/cxgbe/tom/t4_connect.c stable/9/sys/dev/cxgbe/tom/t4_cpl_io.c stable/9/sys/dev/cxgbe/tom/t4_listen.c stable/9/sys/dev/cxgbe/tom/t4_tom.c stable/9/sys/dev/cxgbe/tom/t4_tom.h stable/9/sys/modules/cxgbe/if_cxgbe/Makefile stable/9/sys/modules/cxgbe/tom/Makefile Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/modules/ (props changed) Modified: stable/9/sys/dev/cxgb/ulp/tom/cxgb_listen.c ============================================================================== --- stable/9/sys/dev/cxgb/ulp/tom/cxgb_listen.c Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgb/ulp/tom/cxgb_listen.c Thu Sep 6 17:28:47 2012 (r240169) @@ -41,6 +41,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #define TCPSTATES #include @@ -759,6 +760,15 @@ reset: goto reset; } + if (__predict_false(!(synqe->flags & TP_SYNQE_EXPANDED))) { + struct inpcb *new_inp = sotoinpcb(so); + + INP_WLOCK(new_inp); + tcp_timer_activate(intotcpcb(new_inp), TT_KEEP, 0); + t3_offload_socket(tod, synqe, so); + INP_WUNLOCK(new_inp); + } + /* Remove the synq entry and release its reference on the lctx */ TAILQ_REMOVE(&lctx->synq, synqe, link); inp = release_lctx(td, lctx); @@ -1136,5 +1146,6 @@ t3_offload_socket(struct toedev *tod, vo offload_socket(so, toep); make_established(so, cpl->snd_isn, cpl->rcv_isn, cpl->tcp_opt); update_tid(td, toep, synqe->tid); + synqe->flags |= TP_SYNQE_EXPANDED; } #endif Modified: stable/9/sys/dev/cxgb/ulp/tom/cxgb_toepcb.h ============================================================================== --- stable/9/sys/dev/cxgb/ulp/tom/cxgb_toepcb.h Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgb/ulp/tom/cxgb_toepcb.h Thu Sep 6 17:28:47 2012 (r240169) @@ -44,6 +44,7 @@ #define TP_IS_A_SYNQ_ENTRY (1 << 9) #define TP_ABORT_RPL_SENT (1 << 10) #define TP_SEND_FIN (1 << 11) +#define TP_SYNQE_EXPANDED (1 << 12) struct toepcb { TAILQ_ENTRY(toepcb) link; /* toep_list */ Modified: stable/9/sys/dev/cxgbe/adapter.h ============================================================================== --- stable/9/sys/dev/cxgbe/adapter.h Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/adapter.h Thu Sep 6 17:28:47 2012 (r240169) @@ -135,6 +135,7 @@ enum { #else FL_BUF_SIZES = 3, /* cluster, jumbo9k, jumbo16k */ #endif + OFLD_BUF_SIZE = MJUM16BYTES, /* size of fl buffer for TOE rxq */ CTRL_EQ_QSIZE = 128, @@ -143,6 +144,12 @@ enum { TX_WR_FLITS = SGE_MAX_WR_LEN / 8 }; +#ifdef T4_PKT_TIMESTAMP +#define RX_COPY_THRESHOLD (MINCLSIZE - 8) +#else +#define RX_COPY_THRESHOLD MINCLSIZE +#endif + enum { /* adapter intr_type */ INTR_INTX = (1 << 0), @@ -510,6 +517,7 @@ struct rss_header; typedef int (*cpl_handler_t)(struct sge_iq *, const struct rss_header *, struct mbuf *); typedef int (*an_handler_t)(struct sge_iq *, const struct rsp_ctrl *); +typedef int (*fw_msg_handler_t)(struct adapter *, const __be64 *); struct adapter { SLIST_ENTRY(adapter) link; @@ -582,7 +590,8 @@ struct adapter { struct callout sfl_callout; an_handler_t an_handler __aligned(CACHE_LINE_SIZE); - cpl_handler_t cpl_handler[256]; + fw_msg_handler_t fw_msg_handler[4]; /* NUM_FW6_TYPES */ + cpl_handler_t cpl_handler[0xef]; /* NUM_CPL_CMDS */ }; #define ADAPTER_LOCK(sc) mtx_lock(&(sc)->sc_lock) @@ -741,6 +750,8 @@ void t4_os_link_changed(struct adapter * void t4_iterate(void (*)(struct adapter *, void *), void *); int t4_register_cpl_handler(struct adapter *, int, cpl_handler_t); int t4_register_an_handler(struct adapter *, an_handler_t); +int t4_register_fw_msg_handler(struct adapter *, int, fw_msg_handler_t); +int t4_filter_rpl(struct sge_iq *, const struct rss_header *, struct mbuf *); /* t4_sge.c */ void t4_sge_modload(void); Modified: stable/9/sys/dev/cxgbe/common/t4_hw.h ============================================================================== --- stable/9/sys/dev/cxgbe/common/t4_hw.h Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/common/t4_hw.h Thu Sep 6 17:28:47 2012 (r240169) @@ -161,10 +161,12 @@ struct pagepod { #define S_PPOD_TAG 6 #define M_PPOD_TAG 0xFFFFFF #define V_PPOD_TAG(x) ((x) << S_PPOD_TAG) +#define G_PPOD_TAG(x) (((x) >> S_PPOD_TAG) & M_PPOD_TAG) #define S_PPOD_PGSZ 30 #define M_PPOD_PGSZ 0x3 #define V_PPOD_PGSZ(x) ((x) << S_PPOD_PGSZ) +#define G_PPOD_PGSZ(x) (((x) >> S_PPOD_PGSZ) & M_PPOD_PGSZ) #define S_PPOD_TID 32 #define M_PPOD_TID 0xFFFFFF Modified: stable/9/sys/dev/cxgbe/common/t4_msg.h ============================================================================== --- stable/9/sys/dev/cxgbe/common/t4_msg.h Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/common/t4_msg.h Thu Sep 6 17:28:47 2012 (r240169) @@ -792,6 +792,14 @@ struct cpl_set_tcb_field { __be64 val; }; +struct cpl_set_tcb_field_core { + union opcode_tid ot; + __be16 reply_ctrl; + __be16 word_cookie; + __be64 mask; + __be64 val; +}; + /* cpl_set_tcb_field.word_cookie fields */ #define S_WORD 0 #define M_WORD 0x1F @@ -1376,6 +1384,11 @@ struct cpl_rx_data_ack { __be32 credit_dack; }; +struct cpl_rx_data_ack_core { + union opcode_tid ot; + __be32 credit_dack; +}; + /* cpl_rx_data_ack.ack_seq fields */ #define S_RX_CREDITS 0 #define M_RX_CREDITS 0x3FFFFFF @@ -2281,6 +2294,8 @@ enum { FW6_TYPE_WR_RPL = 1, FW6_TYPE_CQE = 2, FW6_TYPE_OFLD_CONNECTION_WR_RPL = 3, + + NUM_FW6_TYPES }; struct cpl_fw6_msg_ofld_connection_wr_rpl { Modified: stable/9/sys/dev/cxgbe/firmware/t4fw_cfg.txt ============================================================================== --- stable/9/sys/dev/cxgbe/firmware/t4fw_cfg.txt Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/firmware/t4fw_cfg.txt Thu Sep 6 17:28:47 2012 (r240169) @@ -20,7 +20,7 @@ filterMode = fragmentation, mpshittype, protocol, vlan, port, fcoe # TP rx and tx payload memory (% of the total EDRAM + DDR3). - tp_pmrx = 40 + tp_pmrx = 38 tp_pmtx = 60 tp_pmrx_pagesize = 64K tp_pmtx_pagesize = 64K @@ -67,7 +67,8 @@ # driver will mask off features it won't use protocol = ofld - tp_l2t = 100 + tp_l2t = 4096 + tp_ddp = 2 # TCAM has 8K cells; each region must start at a multiple of 128 cell. # Each entry in these categories takes 4 cells each. nhash will use the @@ -136,7 +137,7 @@ [fini] version = 0x1 - checksum = 0xdb5813f9 + checksum = 0x162df193 # # $FreeBSD$ # Modified: stable/9/sys/dev/cxgbe/offload.h ============================================================================== --- stable/9/sys/dev/cxgbe/offload.h Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/offload.h Thu Sep 6 17:28:47 2012 (r240169) @@ -31,13 +31,16 @@ #ifndef __T4_OFFLOAD_H__ #define __T4_OFFLOAD_H__ -#define INIT_ULPTX_WR(w, wrlen, atomic, tid) do { \ - (w)->wr.wr_hi = htonl(V_FW_WR_OP(FW_ULPTX_WR) | V_FW_WR_ATOMIC(atomic)); \ - (w)->wr.wr_mid = htonl(V_FW_WR_LEN16(DIV_ROUND_UP(wrlen, 16)) | \ +#define INIT_ULPTX_WRH(w, wrlen, atomic, tid) do { \ + (w)->wr_hi = htonl(V_FW_WR_OP(FW_ULPTX_WR) | V_FW_WR_ATOMIC(atomic)); \ + (w)->wr_mid = htonl(V_FW_WR_LEN16(DIV_ROUND_UP(wrlen, 16)) | \ V_FW_WR_FLOWID(tid)); \ - (w)->wr.wr_lo = cpu_to_be64(0); \ + (w)->wr_lo = cpu_to_be64(0); \ } while (0) +#define INIT_ULPTX_WR(w, wrlen, atomic, tid) \ + INIT_ULPTX_WRH(&((w)->wr), wrlen, atomic, tid) + #define INIT_TP_WR(w, tid) do { \ (w)->wr.wr_hi = htonl(V_FW_WR_OP(FW_TP_WR) | \ V_FW_WR_IMMDLEN(sizeof(*w) - sizeof(w->wr))); \ Modified: stable/9/sys/dev/cxgbe/t4_main.c ============================================================================== --- stable/9/sys/dev/cxgbe/t4_main.c Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/t4_main.c Thu Sep 6 17:28:47 2012 (r240169) @@ -306,6 +306,7 @@ static void cxgbe_vlan_config(void *, st static int cpl_not_handled(struct sge_iq *, const struct rss_header *, struct mbuf *); static int an_not_handled(struct sge_iq *, const struct rsp_ctrl *); +static int fw_msg_not_handled(struct adapter *, const __be64 *); static int t4_sysctls(struct adapter *); static int cxgbe_sysctls(struct port_info *); static int sysctl_int_array(SYSCTL_HANDLER_ARGS); @@ -345,8 +346,6 @@ static int del_filter(struct adapter *, static void clear_filter(struct filter_entry *); static int set_filter_wr(struct adapter *, int); static int del_filter_wr(struct adapter *, int); -static int filter_rpl(struct sge_iq *, const struct rss_header *, - struct mbuf *); static int get_sge_context(struct adapter *, struct t4_sge_context *); static int read_card_mem(struct adapter *, struct t4_mem_range *); #ifdef TCP_OFFLOAD @@ -381,6 +380,10 @@ CTASSERT(offsetof(struct sge_ofld_rxq, i CTASSERT(offsetof(struct sge_ofld_rxq, fl) == offsetof(struct sge_rxq, fl)); #endif +/* No easy way to include t4_msg.h before adapter.h so we check this way */ +CTASSERT(ARRAY_SIZE(((struct adapter *)0)->cpl_handler) == NUM_CPL_CMDS); +CTASSERT(ARRAY_SIZE(((struct adapter *)0)->fw_msg_handler) == NUM_FW6_TYPES); + static int t4_probe(device_t dev) { @@ -458,7 +461,9 @@ t4_attach(device_t dev) sc->an_handler = an_not_handled; for (i = 0; i < ARRAY_SIZE(sc->cpl_handler); i++) sc->cpl_handler[i] = cpl_not_handled; - t4_register_cpl_handler(sc, CPL_SET_TCB_RPL, filter_rpl); + for (i = 0; i < ARRAY_SIZE(sc->fw_msg_handler); i++) + sc->fw_msg_handler[i] = fw_msg_not_handled; + t4_register_cpl_handler(sc, CPL_SET_TCB_RPL, t4_filter_rpl); /* Prepare the adapter for operation */ rc = -t4_prep_adapter(sc); @@ -510,18 +515,24 @@ t4_attach(device_t dev) goto done; /* error message displayed already */ if (sc->flags & MASTER_PF) { + uint16_t indsz = min(RX_COPY_THRESHOLD - 1, M_INDICATESIZE); /* final tweaks to some settings */ t4_load_mtus(sc, sc->params.mtus, sc->params.a_wnd, sc->params.b_wnd); - t4_write_reg(sc, A_ULP_RX_TDDP_PSZ, V_HPZ0(PAGE_SHIFT - 12)); + /* 4K, 16K, 64K, 256K DDP "page sizes" */ + t4_write_reg(sc, A_ULP_RX_TDDP_PSZ, V_HPZ0(0) | V_HPZ1(2) | + V_HPZ2(4) | V_HPZ3(6)); + t4_set_reg_field(sc, A_ULP_RX_CTL, F_TDDPTAGTCB, F_TDDPTAGTCB); t4_set_reg_field(sc, A_TP_PARA_REG3, F_TUNNELCNGDROP0 | - F_TUNNELCNGDROP1 | F_TUNNELCNGDROP2 | F_TUNNELCNGDROP3, 0); + F_TUNNELCNGDROP1 | F_TUNNELCNGDROP2 | F_TUNNELCNGDROP3, + F_TUNNELCNGDROP0 | F_TUNNELCNGDROP1 | F_TUNNELCNGDROP2 | + F_TUNNELCNGDROP3); t4_set_reg_field(sc, A_TP_PARA_REG5, V_INDICATESIZE(M_INDICATESIZE) | F_REARMDDPOFFSET | F_RESETDDPOFFSET, - V_INDICATESIZE(M_INDICATESIZE) | + V_INDICATESIZE(indsz) | F_REARMDDPOFFSET | F_RESETDDPOFFSET); } else { /* @@ -2942,7 +2953,8 @@ cxgbe_tick(void *arg) ifp->if_omcasts = s->tx_mcast_frames - s->tx_pause; ifp->if_imcasts = s->rx_mcast_frames - s->rx_pause; ifp->if_iqdrops = s->rx_ovflow0 + s->rx_ovflow1 + s->rx_ovflow2 + - s->rx_ovflow3; + s->rx_ovflow3 + s->rx_trunc0 + s->rx_trunc1 + s->rx_trunc2 + + s->rx_trunc3; drops = s->tx_drop; for_each_txq(pi, i, txq) @@ -2977,7 +2989,7 @@ cpl_not_handled(struct sge_iq *iq, const panic("%s: opcode 0x%02x on iq %p with payload %p", __func__, rss->opcode, iq, m); #else - log(LOG_ERR, "%s: opcode 0x%02x on iq %p with payload %p", + log(LOG_ERR, "%s: opcode 0x%02x on iq %p with payload %p\n", __func__, rss->opcode, iq, m); m_freem(m); #endif @@ -3006,7 +3018,7 @@ an_not_handled(struct sge_iq *iq, const #ifdef INVARIANTS panic("%s: async notification on iq %p (ctrl %p)", __func__, iq, ctrl); #else - log(LOG_ERR, "%s: async notification on iq %p (ctrl %p)", + log(LOG_ERR, "%s: async notification on iq %p (ctrl %p)\n", __func__, iq, ctrl); #endif return (EDOOFUS); @@ -3025,6 +3037,35 @@ t4_register_an_handler(struct adapter *s } static int +fw_msg_not_handled(struct adapter *sc, const __be64 *rpl) +{ + __be64 *r = __DECONST(__be64 *, rpl); + struct cpl_fw6_msg *cpl = member2struct(cpl_fw6_msg, data, r); + +#ifdef INVARIANTS + panic("%s: fw_msg type %d", __func__, cpl->type); +#else + log(LOG_ERR, "%s: fw_msg type %d\n", __func__, cpl->type); +#endif + return (EDOOFUS); +} + +int +t4_register_fw_msg_handler(struct adapter *sc, int type, fw_msg_handler_t h) +{ + uintptr_t *loc, new; + + if (type >= ARRAY_SIZE(sc->fw_msg_handler)) + return (EINVAL); + + new = h ? (uintptr_t)h : (uintptr_t)fw_msg_not_handled; + loc = (uintptr_t *) &sc->fw_msg_handler[type]; + atomic_store_rel_ptr(loc, new); + + return (0); +} + +static int t4_sysctls(struct adapter *sc) { struct sysctl_ctx_list *ctx; @@ -3191,10 +3232,13 @@ t4_sysctls(struct adapter *sc) sc->tt.ddp = 0; SYSCTL_ADD_INT(ctx, children, OID_AUTO, "ddp", CTLFLAG_RW, &sc->tt.ddp, 0, "DDP allowed"); - sc->tt.indsz = M_INDICATESIZE; + + sc->tt.indsz = G_INDICATESIZE(t4_read_reg(sc, A_TP_PARA_REG5)); SYSCTL_ADD_INT(ctx, children, OID_AUTO, "indsz", CTLFLAG_RW, &sc->tt.indsz, 0, "DDP max indicate size allowed"); - sc->tt.ddp_thres = 3*4096; + + sc->tt.ddp_thres = + G_RXCOALESCESIZE(t4_read_reg(sc, A_TP_PARA_REG2)); SYSCTL_ADD_INT(ctx, children, OID_AUTO, "ddp_thres", CTLFLAG_RW, &sc->tt.ddp_thres, 0, "DDP threshold"); } @@ -4961,8 +5005,8 @@ del_filter_wr(struct adapter *sc, int fi return (0); } -static int -filter_rpl(struct sge_iq *iq, const struct rss_header *rss, struct mbuf *m) +int +t4_filter_rpl(struct sge_iq *iq, const struct rss_header *rss, struct mbuf *m) { struct adapter *sc = iq->adapter; const struct cpl_set_tcb_rpl *rpl = (const void *)(rss + 1); Modified: stable/9/sys/dev/cxgbe/t4_sge.c ============================================================================== --- stable/9/sys/dev/cxgbe/t4_sge.c Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/t4_sge.c Thu Sep 6 17:28:47 2012 (r240169) @@ -68,12 +68,37 @@ static struct fl_buf_info fl_buf_info[FL #define FL_BUF_TYPE(x) (fl_buf_info[x].type) #define FL_BUF_ZONE(x) (fl_buf_info[x].zone) -enum { - FL_PKTSHIFT = 2 -}; +/* + * Ethernet frames are DMA'd at this byte offset into the freelist buffer. + * 0-7 are valid values. + */ +static int fl_pktshift = 2; +TUNABLE_INT("hw.cxgbe.fl_pktshift", &fl_pktshift); -static int fl_pad = CACHE_LINE_SIZE; -static int spg_len = 64; +/* + * Pad ethernet payload up to this boundary. + * -1: driver should figure out a good value. + * Any power of 2, from 32 to 4096 (both inclusive) is a valid value. + */ +static int fl_pad = -1; +TUNABLE_INT("hw.cxgbe.fl_pad", &fl_pad); + +/* + * Status page length. + * -1: driver should figure out a good value. + * 64 or 128 are the only other valid values. + */ +static int spg_len = -1; +TUNABLE_INT("hw.cxgbe.spg_len", &spg_len); + +/* + * Congestion drops. + * -1: no congestion feedback (not recommended). + * 0: backpressure the channel instead of dropping packets right away. + * 1: no backpressure, drop packets for the congested queue immediately. + */ +static int cong_drop = 0; +TUNABLE_INT("hw.cxgbe.cong_drop", &cong_drop); /* Used to track coalesced tx work request */ struct txpkts { @@ -160,7 +185,7 @@ static void write_eqflush_wr(struct sge_ static __be64 get_flit(bus_dma_segment_t *, int, int); static int handle_sge_egr_update(struct sge_iq *, const struct rss_header *, struct mbuf *); -static int handle_fw_rpl(struct sge_iq *, const struct rss_header *, +static int handle_fw_msg(struct sge_iq *, const struct rss_header *, struct mbuf *); static int sysctl_uint16(SYSCTL_HANDLER_ARGS); @@ -170,7 +195,8 @@ extern u_int cpu_clflush_line_size; #endif /* - * Called on MOD_LOAD and fills up fl_buf_info[]. + * Called on MOD_LOAD. Fills up fl_buf_info[] and validates/calculates the SGE + * tunables. */ void t4_sge_modload(void) @@ -191,10 +217,49 @@ t4_sge_modload(void) FL_BUF_ZONE(i) = m_getzone(bufsize[i]); } + if (fl_pktshift < 0 || fl_pktshift > 7) { + printf("Invalid hw.cxgbe.fl_pktshift value (%d)," + " using 2 instead.\n", fl_pktshift); + fl_pktshift = 2; + } + + if (fl_pad < 32 || fl_pad > 4096 || !powerof2(fl_pad)) { + int pad; + #if defined(__i386__) || defined(__amd64__) - fl_pad = max(cpu_clflush_line_size, 32); - spg_len = cpu_clflush_line_size > 64 ? 128 : 64; + pad = max(cpu_clflush_line_size, 32); +#else + pad = max(CACHE_LINE_SIZE, 32); #endif + pad = min(pad, 4096); + + if (fl_pad != -1) { + printf("Invalid hw.cxgbe.fl_pad value (%d)," + " using %d instead.\n", fl_pad, pad); + } + fl_pad = pad; + } + + if (spg_len != 64 && spg_len != 128) { + int len; + +#if defined(__i386__) || defined(__amd64__) + len = cpu_clflush_line_size > 64 ? 128 : 64; +#else + len = 64; +#endif + if (spg_len != -1) { + printf("Invalid hw.cxgbe.spg_len value (%d)," + " using %d instead.\n", spg_len, len); + } + spg_len = len; + } + + if (cong_drop < -1 || cong_drop > 1) { + printf("Invalid hw.cxgbe.cong_drop value (%d)," + " using 0 instead.\n", cong_drop); + cong_drop = 0; + } } /** @@ -215,7 +280,7 @@ t4_sge_init(struct adapter *sc) ctrl_mask = V_PKTSHIFT(M_PKTSHIFT) | F_RXPKTCPLMODE | V_INGPADBOUNDARY(M_INGPADBOUNDARY) | F_EGRSTATUSPAGESIZE; - ctrl_val = V_PKTSHIFT(FL_PKTSHIFT) | F_RXPKTCPLMODE | + ctrl_val = V_PKTSHIFT(fl_pktshift) | F_RXPKTCPLMODE | V_INGPADBOUNDARY(ilog2(fl_pad) - 5) | V_EGRSTATUSPAGESIZE(spg_len == 128); @@ -296,11 +361,13 @@ t4_sge_init(struct adapter *sc) sc->sge.timer_val[4] = G_TIMERVALUE4(v) / core_ticks_per_usec(sc); sc->sge.timer_val[5] = G_TIMERVALUE5(v) / core_ticks_per_usec(sc); - t4_register_cpl_handler(sc, CPL_FW4_MSG, handle_fw_rpl); - t4_register_cpl_handler(sc, CPL_FW6_MSG, handle_fw_rpl); + t4_register_cpl_handler(sc, CPL_FW4_MSG, handle_fw_msg); + t4_register_cpl_handler(sc, CPL_FW6_MSG, handle_fw_msg); t4_register_cpl_handler(sc, CPL_SGE_EGR_UPDATE, handle_sge_egr_update); t4_register_cpl_handler(sc, CPL_RX_PKT, t4_eth_rx); + t4_register_fw_msg_handler(sc, FW6_TYPE_CMD_RPL, t4_handle_fw_rpl); + return (rc); } @@ -477,6 +544,18 @@ port_intr_iq(struct port_info *pi, int i return (iq); } +static inline int +mtu_to_bufsize(int mtu) +{ + int bufsize; + + /* large enough for a frame even when VLAN extraction is disabled */ + bufsize = ETHER_HDR_LEN + ETHER_VLAN_ENCAP_LEN + mtu; + bufsize = roundup(bufsize + fl_pktshift, fl_pad); + + return (bufsize); +} + int t4_setup_port_queues(struct port_info *pi) { @@ -493,6 +572,7 @@ t4_setup_port_queues(struct port_info *p struct adapter *sc = pi->adapter; struct sysctl_oid *oid = device_get_sysctl_tree(pi->dev); struct sysctl_oid_list *children = SYSCTL_CHILDREN(oid); + int bufsize = mtu_to_bufsize(pi->ifp->if_mtu); oid = SYSCTL_ADD_NODE(&pi->ctx, children, OID_AUTO, "rxq", CTLFLAG_RD, NULL, "rx queues"); @@ -522,7 +602,7 @@ t4_setup_port_queues(struct port_info *p snprintf(name, sizeof(name), "%s rxq%d-fl", device_get_nameunit(pi->dev), i); - init_fl(&rxq->fl, pi->qsize_rxq / 8, pi->ifp->if_mtu, name); + init_fl(&rxq->fl, pi->qsize_rxq / 8, bufsize, name); if (sc->flags & INTR_DIRECT #ifdef TCP_OFFLOAD @@ -547,7 +627,7 @@ t4_setup_port_queues(struct port_info *p snprintf(name, sizeof(name), "%s ofld_rxq%d-fl", device_get_nameunit(pi->dev), i); - init_fl(&ofld_rxq->fl, pi->qsize_rxq / 8, MJUM16BYTES, name); + init_fl(&ofld_rxq->fl, pi->qsize_rxq / 8, OFLD_BUF_SIZE, name); if (sc->flags & INTR_DIRECT || (sc->intr_count > 1 && pi->nofldrxq > pi->nrxq)) { @@ -942,13 +1022,6 @@ service_iq(struct sge_iq *iq, int budget return (0); } - -#ifdef T4_PKT_TIMESTAMP -#define RX_COPY_THRESHOLD (MINCLSIZE - 8) -#else -#define RX_COPY_THRESHOLD MINCLSIZE -#endif - static struct mbuf * get_fl_payload(struct adapter *sc, struct sge_fl *fl, uint32_t len_newbuf, int *fl_bufs_used) @@ -1050,9 +1123,9 @@ t4_eth_rx(struct sge_iq *iq, const struc KASSERT(m0 != NULL, ("%s: no payload with opcode %02x", __func__, rss->opcode)); - m0->m_pkthdr.len -= FL_PKTSHIFT; - m0->m_len -= FL_PKTSHIFT; - m0->m_data += FL_PKTSHIFT; + m0->m_pkthdr.len -= fl_pktshift; + m0->m_len -= fl_pktshift; + m0->m_data += fl_pktshift; m0->m_pkthdr.rcvif = ifp; m0->m_flags |= M_FLOWID; @@ -1386,11 +1459,8 @@ t4_update_fl_bufsize(struct ifnet *ifp) struct port_info *pi = ifp->if_softc; struct sge_rxq *rxq; struct sge_fl *fl; - int i, bufsize; + int i, bufsize = mtu_to_bufsize(ifp->if_mtu); - /* large enough for a frame even when VLAN extraction is disabled */ - bufsize = ETHER_HDR_LEN + ETHER_VLAN_ENCAP_LEN + ifp->if_mtu; - bufsize = roundup(bufsize + FL_PKTSHIFT, fl_pad); for_each_rxq(pi, i, rxq) { fl = &rxq->fl; @@ -1793,6 +1863,18 @@ free_mgmtq(struct adapter *sc) return free_wrq(sc, &sc->sge.mgmtq); } +static inline int +tnl_cong(struct port_info *pi) +{ + + if (cong_drop == -1) + return (-1); + else if (cong_drop == 1) + return (0); + else + return (1 << pi->tx_chan); +} + static int alloc_rxq(struct port_info *pi, struct sge_rxq *rxq, int intr_idx, int idx, struct sysctl_oid *oid) @@ -1801,7 +1883,7 @@ alloc_rxq(struct port_info *pi, struct s struct sysctl_oid_list *children; char name[16]; - rc = alloc_iq_fl(pi, &rxq->iq, &rxq->fl, intr_idx, 1 << pi->tx_chan); + rc = alloc_iq_fl(pi, &rxq->iq, &rxq->fl, intr_idx, tnl_cong(pi)); if (rc != 0) return (rc); @@ -3433,17 +3515,15 @@ handle_sge_egr_update(struct sge_iq *iq, } static int -handle_fw_rpl(struct sge_iq *iq, const struct rss_header *rss, struct mbuf *m) +handle_fw_msg(struct sge_iq *iq, const struct rss_header *rss, struct mbuf *m) { + struct adapter *sc = iq->adapter; const struct cpl_fw6_msg *cpl = (const void *)(rss + 1); KASSERT(m == NULL, ("%s: payload with opcode %02x", __func__, rss->opcode)); - if (cpl->type == FW6_TYPE_CMD_RPL) - t4_handle_fw_rpl(iq->adapter, cpl->data); - - return (0); + return (sc->fw_msg_handler[cpl->type](sc, &cpl->data[0])); } static int Modified: stable/9/sys/dev/cxgbe/tom/t4_connect.c ============================================================================== --- stable/9/sys/dev/cxgbe/tom/t4_connect.c Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/tom/t4_connect.c Thu Sep 6 17:28:47 2012 (r240169) @@ -247,10 +247,14 @@ calc_opt2a(struct socket *so) opt2 |= F_RX_COALESCE_VALID | V_RX_COALESCE(M_RX_COALESCE); opt2 |= F_RSS_QUEUE_VALID | V_RSS_QUEUE(toep->ofld_rxq->iq.abs_id); +#ifdef USE_DDP_RX_FLOW_CONTROL + if (toep->ulp_mode == ULP_MODE_TCPDDP) + opt2 |= F_RX_FC_VALID | F_RX_FC_DDP; +#endif + return (htobe32(opt2)); } - void t4_init_connect_cpl_handlers(struct adapter *sc) { @@ -320,7 +324,10 @@ t4_connect(struct toedev *tod, struct so toep->tid = atid; toep->l2te = e; - toep->ulp_mode = ULP_MODE_NONE; + if (sc->tt.ddp && (so->so_options & SO_NO_DDP) == 0) + set_tcpddp_ulp_mode(toep); + else + toep->ulp_mode = ULP_MODE_NONE; SOCKBUF_LOCK(&so->so_rcv); /* opt0 rcv_bufsiz initially, assumes its normal meaning later */ toep->rx_credits = min(select_rcv_wnd(so) >> 10, M_RCV_BUFSIZ); @@ -354,7 +361,7 @@ t4_connect(struct toedev *tod, struct so rc = t4_l2t_send(sc, wr, e); if (rc == 0) { - toepcb_set_flag(toep, TPF_CPL_PENDING); + toep->flags |= TPF_CPL_PENDING; return (0); } Modified: stable/9/sys/dev/cxgbe/tom/t4_cpl_io.c ============================================================================== --- stable/9/sys/dev/cxgbe/tom/t4_cpl_io.c Thu Sep 6 16:38:55 2012 (r240168) +++ stable/9/sys/dev/cxgbe/tom/t4_cpl_io.c Thu Sep 6 17:28:47 2012 (r240169) @@ -53,6 +53,7 @@ __FBSDID("$FreeBSD$"); #include "common/common.h" #include "common/t4_msg.h" #include "common/t4_regs.h" +#include "common/t4_tcb.h" #include "tom/t4_tom_l2t.h" #include "tom/t4_tom.h" @@ -80,7 +81,7 @@ send_flowc_wr(struct toepcb *toep, struc unsigned int pfvf = G_FW_VIID_PFN(pi->viid) << S_FW_VIID_PFN; struct ofld_tx_sdesc *txsd = &toep->txsd[toep->txsd_pidx]; - KASSERT(!toepcb_flag(toep, TPF_FLOWC_WR_SENT), + KASSERT(!(toep->flags & TPF_FLOWC_WR_SENT), ("%s: flowc for tid %u sent already", __func__, toep->tid)); CTR2(KTR_CXGBE, "%s: tid %u", __func__, toep->tid); @@ -130,7 +131,7 @@ send_flowc_wr(struct toepcb *toep, struc toep->txsd_pidx = 0; toep->txsd_avail--; - toepcb_set_flag(toep, TPF_FLOWC_WR_SENT); + toep->flags |= TPF_FLOWC_WR_SENT; t4_wrq_tx(sc, wr); } @@ -150,15 +151,15 @@ send_reset(struct adapter *sc, struct to inp->inp_flags & INP_DROPPED ? "inp dropped" : tcpstates[tp->t_state], toep->flags, inp->inp_flags, - toepcb_flag(toep, TPF_ABORT_SHUTDOWN) ? + toep->flags & TPF_ABORT_SHUTDOWN ? " (abort already in progress)" : ""); - if (toepcb_flag(toep, TPF_ABORT_SHUTDOWN)) + if (toep->flags & TPF_ABORT_SHUTDOWN) return; /* abort already in progress */ - toepcb_set_flag(toep, TPF_ABORT_SHUTDOWN); + toep->flags |= TPF_ABORT_SHUTDOWN; - KASSERT(toepcb_flag(toep, TPF_FLOWC_WR_SENT), + KASSERT(toep->flags & TPF_FLOWC_WR_SENT, ("%s: flowc_wr not sent for tid %d.", __func__, tid)); wr = alloc_wrqe(sizeof(*req), toep->ofld_txq); @@ -173,7 +174,7 @@ send_reset(struct adapter *sc, struct to req->rsvd0 = htobe32(snd_nxt); else req->rsvd0 = htobe32(tp->snd_nxt); - req->rsvd1 = !toepcb_flag(toep, TPF_TX_DATA_SENT); + req->rsvd1 = !(toep->flags & TPF_TX_DATA_SENT); req->cmd = CPL_ABORT_SEND_RST; /* @@ -299,12 +300,14 @@ make_established(struct toepcb *toep, ui } static int -send_rx_credits(struct adapter *sc, struct toepcb *toep, uint32_t credits) +send_rx_credits(struct adapter *sc, struct toepcb *toep, int credits) { struct wrqe *wr; struct cpl_rx_data_ack *req; uint32_t dack = F_RX_DACK_CHANGE | V_RX_DACK_MODE(1); + KASSERT(credits >= 0, ("%s: %d credits", __func__, credits)); + wr = alloc_wrqe(sizeof(*req), toep->ctrlq); if (wr == NULL) return (0); @@ -323,25 +326,28 @@ t4_rcvd(struct toedev *tod, struct tcpcb struct adapter *sc = tod->tod_softc; struct inpcb *inp = tp->t_inpcb; struct socket *so = inp->inp_socket; - struct sockbuf *so_rcv = &so->so_rcv; + struct sockbuf *sb = &so->so_rcv; struct toepcb *toep = tp->t_toe; - int must_send; + int credits; INP_WLOCK_ASSERT(inp); - SOCKBUF_LOCK(so_rcv); - KASSERT(toep->enqueued >= so_rcv->sb_cc, - ("%s: so_rcv->sb_cc > enqueued", __func__)); - toep->rx_credits += toep->enqueued - so_rcv->sb_cc; - toep->enqueued = so_rcv->sb_cc; - SOCKBUF_UNLOCK(so_rcv); - - must_send = toep->rx_credits + 16384 >= tp->rcv_wnd; - if (must_send || toep->rx_credits >= 15 * 1024) { - int credits; + SOCKBUF_LOCK(sb); + KASSERT(toep->sb_cc >= sb->sb_cc, + ("%s: sb %p has more data (%d) than last time (%d).", + __func__, sb, sb->sb_cc, toep->sb_cc)); + toep->rx_credits += toep->sb_cc - sb->sb_cc; + toep->sb_cc = sb->sb_cc; + credits = toep->rx_credits; + SOCKBUF_UNLOCK(sb); + + if (credits > 0 && + (credits + 16384 >= tp->rcv_wnd || credits >= 15 * 1024)) { - credits = send_rx_credits(sc, toep, toep->rx_credits); + credits = send_rx_credits(sc, toep, credits); + SOCKBUF_LOCK(sb); toep->rx_credits -= credits; + SOCKBUF_UNLOCK(sb); tp->rcv_wnd += credits; tp->rcv_adv += credits; } @@ -358,12 +364,12 @@ close_conn(struct adapter *sc, struct to unsigned int tid = toep->tid; CTR3(KTR_CXGBE, "%s: tid %u%s", __func__, toep->tid, - toepcb_flag(toep, TPF_FIN_SENT) ? ", IGNORED" : ""); + toep->flags & TPF_FIN_SENT ? ", IGNORED" : ""); - if (toepcb_flag(toep, TPF_FIN_SENT)) + if (toep->flags & TPF_FIN_SENT) return (0); - KASSERT(toepcb_flag(toep, TPF_FLOWC_WR_SENT), + KASSERT(toep->flags & TPF_FLOWC_WR_SENT, ("%s: flowc_wr not sent for tid %u.", __func__, tid)); wr = alloc_wrqe(sizeof(*req), toep->ofld_txq); @@ -381,8 +387,8 @@ close_conn(struct adapter *sc, struct to OPCODE_TID(req) = htonl(MK_OPCODE_TID(CPL_CLOSE_CON_REQ, tid)); req->rsvd = 0; - toepcb_set_flag(toep, TPF_FIN_SENT); - toepcb_clr_flag(toep, TPF_SEND_FIN); + toep->flags |= TPF_FIN_SENT; + toep->flags &= ~TPF_SEND_FIN; t4_l2t_send(sc, wr, toep->l2te); return (0); @@ -534,17 +540,18 @@ t4_push_frames(struct adapter *sc, struc struct ofld_tx_sdesc *txsd = &toep->txsd[toep->txsd_pidx]; INP_WLOCK_ASSERT(inp); - KASSERT(toepcb_flag(toep, TPF_FLOWC_WR_SENT), + KASSERT(toep->flags & TPF_FLOWC_WR_SENT, ("%s: flowc_wr not sent for tid %u.", __func__, toep->tid)); - if (toep->ulp_mode != ULP_MODE_NONE) + if (__predict_false(toep->ulp_mode != ULP_MODE_NONE && + toep->ulp_mode != ULP_MODE_TCPDDP)) CXGBE_UNIMPLEMENTED("ulp_mode"); /* * This function doesn't resume by itself. Someone else must clear the * flag and call this function. */ - if (__predict_false(toepcb_flag(toep, TPF_TX_SUSPENDED))) + if (__predict_false(toep->flags & TPF_TX_SUSPENDED)) return; do { @@ -570,7 +577,7 @@ t4_push_frames(struct adapter *sc, struc plen -= m->m_len; if (plen == 0) { /* Too few credits */ - toepcb_set_flag(toep, TPF_TX_SUSPENDED); + toep->flags |= TPF_TX_SUSPENDED; SOCKBUF_UNLOCK(sb); return; } @@ -613,7 +620,7 @@ unlocked: break; } - if (__predict_false(toepcb_flag(toep, TPF_FIN_SENT))) + if (__predict_false(toep->flags & TPF_FIN_SENT)) panic("%s: excess tx.", __func__); if (plen <= max_imm) { @@ -624,7 +631,7 @@ unlocked: toep->ofld_txq); if (wr == NULL) { /* XXX: how will we recover from this? */ - toepcb_set_flag(toep, TPF_TX_SUSPENDED); + toep->flags |= TPF_TX_SUSPENDED; return; } txwr = wrtod(wr); @@ -642,7 +649,7 @@ unlocked: wr = alloc_wrqe(roundup(wr_len, 16), toep->ofld_txq); if (wr == NULL) { /* XXX: how will we recover from this? */ - toepcb_set_flag(toep, TPF_TX_SUSPENDED); + toep->flags |= TPF_TX_SUSPENDED; return; } txwr = wrtod(wr); @@ -671,7 +678,7 @@ unlocked: sb->sb_sndptr = sb_sndptr; SOCKBUF_UNLOCK(sb); - toepcb_set_flag(toep, TPF_TX_DATA_SENT); + toep->flags |= TPF_TX_DATA_SENT; KASSERT(toep->txsd_avail > 0, ("%s: no txsd", __func__)); txsd->plen = plen; @@ -687,7 +694,7 @@ unlocked: } while (m != NULL); /* Send a FIN if requested, but only if there's no more data to send */ - if (m == NULL && toepcb_flag(toep, TPF_SEND_FIN)) + if (m == NULL && toep->flags & TPF_SEND_FIN) close_conn(sc, toep); } @@ -724,7 +731,7 @@ t4_send_fin(struct toedev *tod, struct t ("%s: inp %p dropped.", __func__, inp)); KASSERT(toep != NULL, ("%s: toep is NULL", __func__)); - toepcb_set_flag(toep, TPF_SEND_FIN); + toep->flags |= TPF_SEND_FIN; t4_push_frames(sc, toep); return (0); @@ -745,7 +752,7 @@ t4_send_rst(struct toedev *tod, struct t KASSERT(toep != NULL, ("%s: toep is NULL", __func__)); /* hmmmm */ - KASSERT(toepcb_flag(toep, TPF_FLOWC_WR_SENT), + KASSERT(toep->flags & TPF_FLOWC_WR_SENT, ("%s: flowc for tid %u [%s] not sent already", __func__, toep->tid, tcpstates[tp->t_state])); @@ -765,7 +772,8 @@ do_peer_close(struct sge_iq *iq, const s struct toepcb *toep = lookup_tid(sc, tid); struct inpcb *inp = toep->inp; struct tcpcb *tp = NULL; - struct socket *so = NULL; + struct socket *so; + struct sockbuf *sb; #ifdef INVARIANTS unsigned int opcode = G_CPL_OPCODE(be32toh(OPCODE_TID(cpl))); #endif @@ -782,13 +790,38 @@ do_peer_close(struct sge_iq *iq, const s CTR5(KTR_CXGBE, "%s: tid %u (%s), toep_flags 0x%x, inp %p", __func__, tid, tp ? tcpstates[tp->t_state] : "no tp", toep->flags, inp); - if (toepcb_flag(toep, TPF_ABORT_SHUTDOWN)) + if (toep->flags & TPF_ABORT_SHUTDOWN) goto done; + tp->rcv_nxt++; /* FIN */ + so = inp->inp_socket; + sb = &so->so_rcv; + SOCKBUF_LOCK(sb); + if (__predict_false(toep->ddp_flags & (DDP_BUF0_ACTIVE | DDP_BUF1_ACTIVE))) { + m = m_get(M_NOWAIT, MT_DATA); + if (m == NULL) + CXGBE_UNIMPLEMENTED("mbuf alloc failure"); + + m->m_len = be32toh(cpl->rcv_nxt) - tp->rcv_nxt; + m->m_flags |= M_DDP; /* Data is already where it should be */ + m->m_data = "nothing to see here"; + tp->rcv_nxt = be32toh(cpl->rcv_nxt); + + toep->ddp_flags &= ~(DDP_BUF0_ACTIVE | DDP_BUF1_ACTIVE); + + KASSERT(toep->sb_cc >= sb->sb_cc, + ("%s: sb %p has more data (%d) than last time (%d).", + __func__, sb, sb->sb_cc, toep->sb_cc)); + toep->rx_credits += toep->sb_cc - sb->sb_cc; +#ifdef USE_DDP_RX_FLOW_CONTROL + toep->rx_credits -= m->m_len; /* adjust for F_RX_FC_DDP */ +#endif + sbappendstream_locked(sb, m); + toep->sb_cc = sb->sb_cc; + } + socantrcvmore_locked(so); /* unlocks the sockbuf */ - socantrcvmore(so); - tp->rcv_nxt++; /* FIN */ KASSERT(tp->rcv_nxt == be32toh(cpl->rcv_nxt), ("%s: rcv_nxt mismatch: %u %u", __func__, tp->rcv_nxt, be32toh(cpl->rcv_nxt))); @@ -855,7 +888,7 @@ do_close_con_rpl(struct sge_iq *iq, cons CTR4(KTR_CXGBE, "%s: tid %u (%s), toep_flags 0x%x", __func__, tid, tp ? tcpstates[tp->t_state] : "no tp", toep->flags); - if (toepcb_flag(toep, TPF_ABORT_SHUTDOWN)) + if (toep->flags & TPF_ABORT_SHUTDOWN) goto done; so = inp->inp_socket; @@ -953,7 +986,7 @@ do_abort_req(struct sge_iq *iq, const st ("%s: unexpected opcode 0x%x", __func__, opcode)); KASSERT(m == NULL, ("%s: wasn't expecting payload", __func__)); - if (toepcb_flag(toep, TPF_SYNQE)) + if (toep->flags & TPF_SYNQE) return (do_abort_req_synqe(iq, rss, m)); KASSERT(toep->tid == tid, ("%s: toep tid mismatch", __func__)); @@ -974,19 +1007,19 @@ do_abort_req(struct sge_iq *iq, const st CTR6(KTR_CXGBE, "%s: tid %d (%s), toep_flags 0x%x, inp_flags 0x%x, status %d", - __func__, tid, tcpstates[tp->t_state], toep->flags, inp->inp_flags, - cpl->status); + __func__, tid, tp ? tcpstates[tp->t_state] : "no tp", toep->flags, + inp->inp_flags, cpl->status); /* * If we'd initiated an abort earlier the reply to it is responsible for * cleaning up resources. Otherwise we tear everything down right here * right now. We owe the T4 a CPL_ABORT_RPL no matter what. */ - if (toepcb_flag(toep, TPF_ABORT_SHUTDOWN)) { + if (toep->flags & TPF_ABORT_SHUTDOWN) { INP_WUNLOCK(inp); goto done; } - toepcb_set_flag(toep, TPF_ABORT_SHUTDOWN); + toep->flags |= TPF_ABORT_SHUTDOWN; *** DIFF OUTPUT TRUNCATED AT 1000 LINES *** From owner-svn-src-stable-9@FreeBSD.ORG Fri Sep 7 10:11:29 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id EC0741065670; Fri, 7 Sep 2012 10:11:28 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D74638FC0C; Fri, 7 Sep 2012 10:11:28 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q87ABSg4079538; Fri, 7 Sep 2012 10:11:28 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q87ABS7K079536; Fri, 7 Sep 2012 10:11:28 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209071011.q87ABS7K079536@svn.freebsd.org> From: Konstantin Belousov Date: Fri, 7 Sep 2012 10:11:28 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240195 - stable/9/sys/fs/nfs X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 10:11:29 -0000 Author: kib Date: Fri Sep 7 10:11:28 2012 New Revision: 240195 URL: http://svn.freebsd.org/changeset/base/240195 Log: MFC r239039: The header uma_int.h is internal uma header, unused by this source file. Do not include it needlessly. Modified: stable/9/sys/fs/nfs/nfs_commonport.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/fs/ (props changed) Modified: stable/9/sys/fs/nfs/nfs_commonport.c ============================================================================== --- stable/9/sys/fs/nfs/nfs_commonport.c Fri Sep 7 09:45:08 2012 (r240194) +++ stable/9/sys/fs/nfs/nfs_commonport.c Fri Sep 7 10:11:28 2012 (r240195) @@ -49,7 +49,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include extern int nfscl_ticks; extern int nfsrv_nfsuserd; From owner-svn-src-stable-9@FreeBSD.ORG Fri Sep 7 14:04:01 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 998F41065670; Fri, 7 Sep 2012 14:04:01 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 69CBC8FC0A; Fri, 7 Sep 2012 14:04:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q87E41R3011558; Fri, 7 Sep 2012 14:04:01 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q87E41wI011553; Fri, 7 Sep 2012 14:04:01 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209071404.q87E41wI011553@svn.freebsd.org> From: Alexander Motin Date: Fri, 7 Sep 2012 14:04:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240199 - in stable/9/sys/dev: ahci ata ata/chipsets X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 14:04:01 -0000 Author: mav Date: Fri Sep 7 14:04:00 2012 New Revision: 240199 URL: http://svn.freebsd.org/changeset/base/240199 Log: MFC r239907: Add IDs for JMicron JMB360/JMB362 AHCI SATA controllers. Modified: stable/9/sys/dev/ahci/ahci.c stable/9/sys/dev/ata/ata-pci.h stable/9/sys/dev/ata/chipsets/ata-jmicron.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/ahci/ahci.c ============================================================================== --- stable/9/sys/dev/ahci/ahci.c Fri Sep 7 13:36:42 2012 (r240198) +++ stable/9/sys/dev/ahci/ahci.c Fri Sep 7 14:04:00 2012 (r240199) @@ -181,7 +181,9 @@ static struct { {0x1e0e8086, 0x00, "Intel Panther Point", 0}, {0x1e0f8086, 0x00, "Intel Panther Point", 0}, {0x23238086, 0x00, "Intel DH89xxCC", 0}, + {0x2360197b, 0x00, "JMicron JMB360", 0}, {0x2361197b, 0x00, "JMicron JMB361", AHCI_Q_NOFORCE}, + {0x2362197b, 0x00, "JMicron JMB362", 0}, {0x2363197b, 0x00, "JMicron JMB363", AHCI_Q_NOFORCE}, {0x2365197b, 0x00, "JMicron JMB365", AHCI_Q_NOFORCE}, {0x2366197b, 0x00, "JMicron JMB366", AHCI_Q_NOFORCE}, Modified: stable/9/sys/dev/ata/ata-pci.h ============================================================================== --- stable/9/sys/dev/ata/ata-pci.h Fri Sep 7 13:36:42 2012 (r240198) +++ stable/9/sys/dev/ata/ata-pci.h Fri Sep 7 14:04:00 2012 (r240199) @@ -266,6 +266,7 @@ struct ata_pci_controller { #define ATA_JMICRON_ID 0x197b #define ATA_JMB360 0x2360197b #define ATA_JMB361 0x2361197b +#define ATA_JMB362 0x2362197b #define ATA_JMB363 0x2363197b #define ATA_JMB365 0x2365197b #define ATA_JMB366 0x2366197b Modified: stable/9/sys/dev/ata/chipsets/ata-jmicron.c ============================================================================== --- stable/9/sys/dev/ata/chipsets/ata-jmicron.c Fri Sep 7 13:36:42 2012 (r240198) +++ stable/9/sys/dev/ata/chipsets/ata-jmicron.c Fri Sep 7 14:04:00 2012 (r240199) @@ -67,6 +67,7 @@ ata_jmicron_probe(device_t dev) static const struct ata_chip_id const ids[] = {{ ATA_JMB360, 0, 1, 0, ATA_SA300, "JMB360" }, { ATA_JMB361, 0, 1, 1, ATA_UDMA6, "JMB361" }, + { ATA_JMB362, 0, 2, 0, ATA_SA300, "JMB362" }, { ATA_JMB363, 0, 2, 1, ATA_UDMA6, "JMB363" }, { ATA_JMB365, 0, 1, 2, ATA_UDMA6, "JMB365" }, { ATA_JMB366, 0, 2, 2, ATA_UDMA6, "JMB366" }, From owner-svn-src-stable-9@FreeBSD.ORG Fri Sep 7 14:07:14 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 52BFB1065674; Fri, 7 Sep 2012 14:07:14 +0000 (UTC) (envelope-from mav@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 22E5E8FC15; Fri, 7 Sep 2012 14:07:14 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q87E7DoG012090; Fri, 7 Sep 2012 14:07:13 GMT (envelope-from mav@svn.freebsd.org) Received: (from mav@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q87E7Dkx012087; Fri, 7 Sep 2012 14:07:13 GMT (envelope-from mav@svn.freebsd.org) Message-Id: <201209071407.q87E7Dkx012087@svn.freebsd.org> From: Alexander Motin Date: Fri, 7 Sep 2012 14:07:13 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240201 - stable/9/sys/dev/sound/pci/hda X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 14:07:14 -0000 Author: mav Date: Fri Sep 7 14:07:13 2012 New Revision: 240201 URL: http://svn.freebsd.org/changeset/base/240201 Log: MFC r239908: Add bunch of ATI HDMI HDA controller IDs. Modified: stable/9/sys/dev/sound/pci/hda/hdac.c stable/9/sys/dev/sound/pci/hda/hdac.h Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) Modified: stable/9/sys/dev/sound/pci/hda/hdac.c ============================================================================== --- stable/9/sys/dev/sound/pci/hda/hdac.c Fri Sep 7 14:05:08 2012 (r240200) +++ stable/9/sys/dev/sound/pci/hda/hdac.c Fri Sep 7 14:07:13 2012 (r240201) @@ -138,6 +138,15 @@ static const struct { { HDA_ATI_RV730, "ATI RV730", 0, 0 }, { HDA_ATI_RV740, "ATI RV740", 0, 0 }, { HDA_ATI_RV770, "ATI RV770", 0, 0 }, + { HDA_ATI_RV810, "ATI RV810", 0, 0 }, + { HDA_ATI_RV830, "ATI RV830", 0, 0 }, + { HDA_ATI_RV840, "ATI RV840", 0, 0 }, + { HDA_ATI_RV870, "ATI RV870", 0, 0 }, + { HDA_ATI_RV910, "ATI RV910", 0, 0 }, + { HDA_ATI_RV930, "ATI RV930", 0, 0 }, + { HDA_ATI_RV940, "ATI RV940", 0, 0 }, + { HDA_ATI_RV970, "ATI RV970", 0, 0 }, + { HDA_ATI_R1000, "ATI R1000", 0, 0 }, { HDA_RDC_M3010, "RDC M3010", 0, 0 }, { HDA_VIA_VT82XX, "VIA VT8251/8237A",0, 0 }, { HDA_SIS_966, "SiS 966", 0, 0 }, Modified: stable/9/sys/dev/sound/pci/hda/hdac.h ============================================================================== --- stable/9/sys/dev/sound/pci/hda/hdac.h Fri Sep 7 14:05:08 2012 (r240200) +++ stable/9/sys/dev/sound/pci/hda/hdac.h Fri Sep 7 14:07:13 2012 (r240201) @@ -110,6 +110,15 @@ #define HDA_ATI_RV730 HDA_MODEL_CONSTRUCT(ATI, 0xaa38) #define HDA_ATI_RV710 HDA_MODEL_CONSTRUCT(ATI, 0xaa40) #define HDA_ATI_RV740 HDA_MODEL_CONSTRUCT(ATI, 0xaa48) +#define HDA_ATI_RV870 HDA_MODEL_CONSTRUCT(ATI, 0xaa50) +#define HDA_ATI_RV840 HDA_MODEL_CONSTRUCT(ATI, 0xaa58) +#define HDA_ATI_RV830 HDA_MODEL_CONSTRUCT(ATI, 0xaa60) +#define HDA_ATI_RV810 HDA_MODEL_CONSTRUCT(ATI, 0xaa68) +#define HDA_ATI_RV970 HDA_MODEL_CONSTRUCT(ATI, 0xaa80) +#define HDA_ATI_RV940 HDA_MODEL_CONSTRUCT(ATI, 0xaa88) +#define HDA_ATI_RV930 HDA_MODEL_CONSTRUCT(ATI, 0xaa90) +#define HDA_ATI_RV910 HDA_MODEL_CONSTRUCT(ATI, 0xaa98) +#define HDA_ATI_R1000 HDA_MODEL_CONSTRUCT(ATI, 0xaaa0) #define HDA_ATI_ALL HDA_MODEL_CONSTRUCT(ATI, 0xffff) /* RDC */ From owner-svn-src-stable-9@FreeBSD.ORG Fri Sep 7 17:51:13 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 42C601065674; Fri, 7 Sep 2012 17:51:13 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 2D2CD8FC18; Fri, 7 Sep 2012 17:51:13 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q87HpDFg039002; Fri, 7 Sep 2012 17:51:13 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q87HpCb8039000; Fri, 7 Sep 2012 17:51:12 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201209071751.q87HpCb8039000@svn.freebsd.org> From: Dimitry Andric Date: Fri, 7 Sep 2012 17:51:12 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240206 - stable/9/sys/i386/bios X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 17:51:13 -0000 Author: dim Date: Fri Sep 7 17:51:12 2012 New Revision: 240206 URL: http://svn.freebsd.org/changeset/base/240206 Log: MFC r239869: Remove the argument-less .align directive in sys/i386/bios/smapi_bios.S. Specifying no argument is undocumented in the gas manual, and clang's integrated assembler refuses to parse it. Also, removing it causes no change at all in the resulting object file. Modified: stable/9/sys/i386/bios/smapi_bios.S Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/i386/bios/smapi_bios.S ============================================================================== --- stable/9/sys/i386/bios/smapi_bios.S Fri Sep 7 16:59:30 2012 (r240205) +++ stable/9/sys/i386/bios/smapi_bios.S Fri Sep 7 17:51:12 2012 (r240206) @@ -6,7 +6,6 @@ __FBSDID("$FreeBSD$"); * Thomas Hood. */ - .align smapi32_entry: /* far pointer to SMAPI entry */ .globl smapi32_offset smapi32_offset: .long 0x00000000 /* set by caller */ From owner-svn-src-stable-9@FreeBSD.ORG Fri Sep 7 17:58:37 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3883E106564A; Fri, 7 Sep 2012 17:58:37 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 21D5C8FC15; Fri, 7 Sep 2012 17:58:37 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q87HwadQ040040; Fri, 7 Sep 2012 17:58:36 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q87Hwa51040031; Fri, 7 Sep 2012 17:58:36 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201209071758.q87Hwa51040031@svn.freebsd.org> From: Dimitry Andric Date: Fri, 7 Sep 2012 17:58:36 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240207 - in stable/9/sys: conf gnu/fs/xfs gnu/fs/xfs/FreeBSD modules/xfs X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 17:58:37 -0000 Author: dim Date: Fri Sep 7 17:58:36 2012 New Revision: 240207 URL: http://svn.freebsd.org/changeset/base/240207 Log: MFC r239959: Work around several warnings from clang in the xfs filesystem, when linking it statically into the kernel. With our gcc in base there are no warnings, so also remove the WERROR= from the module makefile. Noted by: Eir Nym MFC r240011: Partially revert r239959, after actually fixing most of the clang warnings in sys/gnu/fs/xfs. The only warnings that still need to be suppressed are those about array bound overruns of flexible array members in xfs_dir2_{block,sf}.c, which are too expensive (in terms of cascading code changes) to fix. Modified: stable/9/sys/conf/files stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_ioctl.c stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_stats.c stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_super.c stable/9/sys/gnu/fs/xfs/xfs_alloc.c stable/9/sys/gnu/fs/xfs/xfs_vfsops.c stable/9/sys/modules/xfs/Makefile Directory Properties: stable/9/sys/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/modules/ (props changed) Modified: stable/9/sys/conf/files ============================================================================== --- stable/9/sys/conf/files Fri Sep 7 17:51:12 2012 (r240206) +++ stable/9/sys/conf/files Fri Sep 7 17:58:36 2012 (r240207) @@ -3407,7 +3407,7 @@ gnu/fs/xfs/xfs_dir.c optional xfs \ gnu/fs/xfs/xfs_dir2.c optional xfs \ compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/xfs_dir2_block.c optional xfs \ - compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" + compile-with "${NORMAL_C} ${NO_WARRAY_BOUNDS} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/xfs_dir2_data.c optional xfs \ compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/xfs_dir2_leaf.c optional xfs \ @@ -3415,7 +3415,7 @@ gnu/fs/xfs/xfs_dir2_leaf.c optional xfs gnu/fs/xfs/xfs_dir2_node.c optional xfs \ compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/xfs_dir2_sf.c optional xfs \ - compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" + compile-with "${NORMAL_C} ${NO_WARRAY_BOUNDS} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/xfs_dir2_trace.c optional xfs \ compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/xfs_dir_leaf.c optional xfs \ @@ -3505,7 +3505,7 @@ gnu/fs/xfs/FreeBSD/xfs_sysctl.c optional gnu/fs/xfs/FreeBSD/xfs_fs_subr.c optional xfs \ compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/FreeBSD/xfs_ioctl.c optional xfs \ - compile-with "${NORMAL_C} ${NO_WSELF_ASSIGN} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" + compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/FreeBSD/support/debug.c optional xfs \ compile-with "${NORMAL_C} -I$S/gnu/fs/xfs/FreeBSD -I$S/gnu/fs/xfs/FreeBSD/support -I$S/gnu/fs/xfs" gnu/fs/xfs/FreeBSD/support/ktrace.c optional xfs \ Modified: stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_ioctl.c ============================================================================== --- stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_ioctl.c Fri Sep 7 17:51:12 2012 (r240206) +++ stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_ioctl.c Fri Sep 7 17:58:36 2012 (r240207) @@ -1249,7 +1249,6 @@ xfs_ioc_xattr( XFS_AT_NEXTENTS | XFS_AT_PROJID; XVOP_GETATTR(vp, vattr, 0, NULL, error); if (unlikely(error)) { - error = error; break; } @@ -1287,7 +1286,6 @@ xfs_ioc_xattr( if (likely(!error)) __vn_revalidate(vp, vattr); /* update flags */ #endif - error = error; break; } @@ -1296,7 +1294,6 @@ xfs_ioc_xattr( XFS_AT_ANEXTENTS | XFS_AT_PROJID; XVOP_GETATTR(vp, vattr, 0, NULL, error); if (unlikely(error)) { - error = error; break; } @@ -1347,7 +1344,6 @@ xfs_ioc_xattr( if (likely(!error)) __vn_revalidate(vp, vattr); /* update flags */ #endif - error = error; break; } Modified: stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_stats.c ============================================================================== --- stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_stats.c Fri Sep 7 17:51:12 2012 (r240206) +++ stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_stats.c Fri Sep 7 17:58:36 2012 (r240207) @@ -65,7 +65,7 @@ xfs_read_xfsstats( }; for (i=j=len = 0; i < sizeof(xstats)/sizeof(struct xstats_entry); i++) { - len += sprintf(buffer + len, xstats[i].desc); + len += sprintf(buffer + len, "%s", xstats[i].desc); /* inner loop does each group */ while (j < xstats[i].endpoint) { len += sprintf(buffer + len, " %u", Modified: stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_super.c ============================================================================== --- stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_super.c Fri Sep 7 17:51:12 2012 (r240206) +++ stable/9/sys/gnu/fs/xfs/FreeBSD/xfs_super.c Fri Sep 7 17:58:36 2012 (r240207) @@ -251,7 +251,7 @@ xfs_blkdev_issue_flush( int init_xfs_fs( void ) { - static char message[] = + static const char message[] = XFS_VERSION_STRING " with " XFS_BUILD_OPTIONS " enabled\n"; printf(message); Modified: stable/9/sys/gnu/fs/xfs/xfs_alloc.c ============================================================================== --- stable/9/sys/gnu/fs/xfs/xfs_alloc.c Fri Sep 7 17:51:12 2012 (r240206) +++ stable/9/sys/gnu/fs/xfs/xfs_alloc.c Fri Sep 7 17:58:36 2012 (r240207) @@ -1479,8 +1479,10 @@ xfs_alloc_ag_vextent_small( /* * Can't allocate from the freelist for some reason. */ - else + else { + fbno = NULLAGBLOCK; flen = 0; + } /* * Can't do the allocation, give up. */ Modified: stable/9/sys/gnu/fs/xfs/xfs_vfsops.c ============================================================================== --- stable/9/sys/gnu/fs/xfs/xfs_vfsops.c Fri Sep 7 17:51:12 2012 (r240206) +++ stable/9/sys/gnu/fs/xfs/xfs_vfsops.c Fri Sep 7 17:58:36 2012 (r240207) @@ -1955,7 +1955,7 @@ xfs_showargs( for (xfs_infop = xfs_info; xfs_infop->flag; xfs_infop++) { if (mp->m_flags & xfs_infop->flag) - sbuf_printf(m, xfs_infop->str); + sbuf_printf(m, "%s", xfs_infop->str); } if (mp->m_flags & XFS_MOUNT_IHASHSIZE) Modified: stable/9/sys/modules/xfs/Makefile ============================================================================== --- stable/9/sys/modules/xfs/Makefile Fri Sep 7 17:51:12 2012 (r240206) +++ stable/9/sys/modules/xfs/Makefile Fri Sep 7 17:58:36 2012 (r240207) @@ -6,8 +6,6 @@ KMOD= xfs -WERROR= - SRCS = vnode_if.h \ xfs_alloc.c \ xfs_alloc_btree.c \ @@ -86,5 +84,6 @@ CFLAGS+= -I${.CURDIR}/../../gnu/fs/xfs/F -I${.CURDIR}/../../gnu/fs/xfs/FreeBSD/support \ -I${.CURDIR}/../../gnu/fs/xfs -CWARNFLAGS.xfs_ioctl.c= ${NO_WSELF_ASSIGN} +CWARNFLAGS.xfs_dir2_block.c= ${NO_WARRAY_BOUNDS} +CWARNFLAGS.xfs_dir2_sf.c= ${NO_WARRAY_BOUNDS} CWARNFLAGS+= ${CWARNFLAGS.${.IMPSRC:T}} From owner-svn-src-stable-9@FreeBSD.ORG Fri Sep 7 18:03:29 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id E7EB0106564A; Fri, 7 Sep 2012 18:03:29 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id D1F198FC08; Fri, 7 Sep 2012 18:03:29 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q87I3TBl040768; Fri, 7 Sep 2012 18:03:29 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q87I3TJ8040766; Fri, 7 Sep 2012 18:03:29 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201209071803.q87I3TJ8040766@svn.freebsd.org> From: Dimitry Andric Date: Fri, 7 Sep 2012 18:03:29 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240208 - in stable: 7/contrib/binutils/binutils 8/contrib/binutils/binutils 9/contrib/binutils/binutils X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 18:03:30 -0000 Author: dim Date: Fri Sep 7 18:03:29 2012 New Revision: 240208 URL: http://svn.freebsd.org/changeset/base/240208 Log: MFC r239962: Fix a twelve year old bug in readelf: when process_dynamic_segment() encounters a DT_RUNPATH entry, the global dynamic_info[] array is overrun, causing some other global variable to be overwritten. In my testcase, this was the section_headers variable, leading to segfaults or jemalloc assertions when it was freed later on. Thanks to Koop Mast for providing samples of a few "bad" .so files. Modified: stable/9/contrib/binutils/binutils/readelf.c Directory Properties: stable/9/contrib/binutils/ (props changed) Changes in other areas also in this revision: Modified: stable/7/contrib/binutils/binutils/readelf.c stable/8/contrib/binutils/binutils/readelf.c Directory Properties: stable/7/contrib/binutils/ (props changed) stable/8/contrib/binutils/ (props changed) Modified: stable/9/contrib/binutils/binutils/readelf.c ============================================================================== --- stable/9/contrib/binutils/binutils/readelf.c Fri Sep 7 17:58:36 2012 (r240207) +++ stable/9/contrib/binutils/binutils/readelf.c Fri Sep 7 18:03:29 2012 (r240208) @@ -174,7 +174,7 @@ static Elf_Internal_Syminfo *dynamic_sym static unsigned long dynamic_syminfo_offset; static unsigned int dynamic_syminfo_nent; static char program_interpreter[PATH_MAX]; -static bfd_vma dynamic_info[DT_JMPREL + 1]; +static bfd_vma dynamic_info[DT_ENCODING]; static bfd_vma dynamic_info_DT_GNU_HASH; static bfd_vma version_info[16]; static Elf_Internal_Ehdr elf_header; From owner-svn-src-stable-9@FreeBSD.ORG Fri Sep 7 22:30:21 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 52C3B106564A; Fri, 7 Sep 2012 22:30:21 +0000 (UTC) (envelope-from thomas@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 23B1F8FC15; Fri, 7 Sep 2012 22:30:21 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q87MUKQT074584; Fri, 7 Sep 2012 22:30:20 GMT (envelope-from thomas@svn.freebsd.org) Received: (from thomas@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q87MUKfA074582; Fri, 7 Sep 2012 22:30:20 GMT (envelope-from thomas@svn.freebsd.org) Message-Id: <201209072230.q87MUKfA074582@svn.freebsd.org> From: Thomas Quinot Date: Fri, 7 Sep 2012 22:30:20 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240217 - stable/9/sys/geom/multipath X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Sep 2012 22:30:21 -0000 Author: thomas Date: Fri Sep 7 22:30:20 2012 New Revision: 240217 URL: http://svn.freebsd.org/changeset/base/240217 Log: Merge rev. 239673 from head to stable/9: (g_multipath_rotate): Fix algorithm so that it does rotate over all good providers, not just the last two. Modified: stable/9/sys/geom/multipath/g_multipath.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/amd64/include/xen/ (props changed) stable/9/sys/boot/ (props changed) stable/9/sys/boot/i386/efi/ (props changed) stable/9/sys/boot/ia64/efi/ (props changed) stable/9/sys/boot/ia64/ski/ (props changed) stable/9/sys/boot/powerpc/boot1.chrp/ (props changed) stable/9/sys/boot/powerpc/ofw/ (props changed) stable/9/sys/cddl/contrib/opensolaris/ (props changed) stable/9/sys/conf/ (props changed) stable/9/sys/contrib/dev/acpica/ (props changed) stable/9/sys/contrib/octeon-sdk/ (props changed) stable/9/sys/contrib/pf/ (props changed) stable/9/sys/contrib/x86emu/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/dev/e1000/ (props changed) stable/9/sys/dev/isp/ (props changed) stable/9/sys/dev/ixgbe/ (props changed) stable/9/sys/dev/puc/ (props changed) stable/9/sys/fs/ (props changed) stable/9/sys/fs/ntfs/ (props changed) stable/9/sys/modules/ (props changed) Modified: stable/9/sys/geom/multipath/g_multipath.c ============================================================================== --- stable/9/sys/geom/multipath/g_multipath.c Fri Sep 7 22:16:50 2012 (r240216) +++ stable/9/sys/geom/multipath/g_multipath.c Fri Sep 7 22:30:20 2012 (r240217) @@ -590,19 +590,26 @@ g_multipath_destroy_geom(struct gctl_req static int g_multipath_rotate(struct g_geom *gp) { - struct g_consumer *lcp; + struct g_consumer *lcp, *first_good_cp = NULL; struct g_multipath_softc *sc = gp->softc; + int active_cp_seen = 0; g_topology_assert(); if (sc == NULL) return (ENXIO); LIST_FOREACH(lcp, &gp->consumer, consumer) { if ((lcp->index & MP_BAD) == 0) { - if (sc->sc_active != lcp) + if (first_good_cp == NULL) + first_good_cp = lcp; + if (active_cp_seen) break; } + if (sc->sc_active == lcp) + active_cp_seen = 1; } - if (lcp) { + if (lcp == NULL) + lcp = first_good_cp; + if (lcp && lcp != sc->sc_active) { sc->sc_active = lcp; if (sc->sc_active_active != 1) printf("GEOM_MULTIPATH: %s is now active path in %s\n", From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 02:41:51 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 33D191065670; Sat, 8 Sep 2012 02:41:51 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 1E2C48FC14; Sat, 8 Sep 2012 02:41:51 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q882fo1K005950; Sat, 8 Sep 2012 02:41:50 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q882foC1005948; Sat, 8 Sep 2012 02:41:50 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209080241.q882foC1005948@svn.freebsd.org> From: Eitan Adler Date: Sat, 8 Sep 2012 02:41:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240225 - stable/9/sys/cddl/compat/opensolaris/sys X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 02:41:51 -0000 Author: eadler Date: Sat Sep 8 02:41:50 2012 New Revision: 240225 URL: http://svn.freebsd.org/changeset/base/240225 Log: MFC r230454: Use provided name when allocating ksid domain. It isn't really used on FreeBSD, but should fix a panic when pool is imported from another OS that is using this. No objections from; pjd Approved by: cperciva (implicit) Modified: stable/9/sys/cddl/compat/opensolaris/sys/sid.h Directory Properties: stable/9/sys/ (props changed) Modified: stable/9/sys/cddl/compat/opensolaris/sys/sid.h ============================================================================== --- stable/9/sys/cddl/compat/opensolaris/sys/sid.h Sat Sep 8 01:26:52 2012 (r240224) +++ stable/9/sys/cddl/compat/opensolaris/sys/sid.h Sat Sep 8 02:41:50 2012 (r240225) @@ -30,7 +30,7 @@ #define _OPENSOLARIS_SYS_SID_H_ typedef struct ksiddomain { - char kd_name[16]; /* Domain part of SID */ + char kd_name[1]; /* Domain part of SID */ } ksiddomain_t; typedef void ksid_t; @@ -39,8 +39,8 @@ ksid_lookupdomain(const char *domain) { ksiddomain_t *kd; - kd = kmem_alloc(sizeof(*kd), KM_SLEEP); - strlcpy(kd->kd_name, "FreeBSD", sizeof(kd->kd_name)); + kd = kmem_alloc(sizeof(*kd) + strlen(domain), KM_SLEEP); + strcpy(kd->kd_name, domain); return (kd); } From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 03:11:12 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id AA19B1065781; Sat, 8 Sep 2012 03:11:03 +0000 (UTC) (envelope-from eadler@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 55FD38FC14; Sat, 8 Sep 2012 03:11:03 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q883B340010090; Sat, 8 Sep 2012 03:11:03 GMT (envelope-from eadler@svn.freebsd.org) Received: (from eadler@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q883B3ql010089; Sat, 8 Sep 2012 03:11:03 GMT (envelope-from eadler@svn.freebsd.org) Message-Id: <201209080311.q883B3ql010089@svn.freebsd.org> From: Eitan Adler Date: Sat, 8 Sep 2012 03:11:03 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240229 - stable/9/sbin/mdconfig X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 03:11:12 -0000 Author: eadler Date: Sat Sep 8 03:11:02 2012 New Revision: 240229 URL: http://svn.freebsd.org/changeset/base/240229 Log: MFC r238202: Remove ancient vnconfig symlink Approved by: cperciva (implicit) Modified: stable/9/sbin/mdconfig/Makefile Directory Properties: stable/9/sbin/mdconfig/ (props changed) Modified: stable/9/sbin/mdconfig/Makefile ============================================================================== --- stable/9/sbin/mdconfig/Makefile Sat Sep 8 03:10:58 2012 (r240228) +++ stable/9/sbin/mdconfig/Makefile Sat Sep 8 03:11:02 2012 (r240229) @@ -2,7 +2,6 @@ PROG= mdconfig MAN= mdconfig.8 -MLINKS= mdconfig.8 vnconfig.8 DPADD= ${LIBUTIL} ${LIBGEOM} ${LIBBSDXML} ${LIBSBUF} LDADD= -lutil -lgeom -lbsdxml -lsbuf From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 04:35:55 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 784FD106564A; Sat, 8 Sep 2012 04:35:55 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 63A9A8FC0C; Sat, 8 Sep 2012 04:35:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q884ZttL020969; Sat, 8 Sep 2012 04:35:55 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q884ZtMO020967; Sat, 8 Sep 2012 04:35:55 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201209080435.q884ZtMO020967@svn.freebsd.org> From: Glen Barber Date: Sat, 8 Sep 2012 04:35:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240230 - stable/9 X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 04:35:55 -0000 Author: gjb (doc,ports committer) Date: Sat Sep 8 04:35:54 2012 New Revision: 240230 URL: http://svn.freebsd.org/changeset/base/240230 Log: MFC r240077: - Fix 'distributeworld' target when WITHOUT_GAMES is set. Modified: stable/9/Makefile.inc1 (contents, props changed) Modified: stable/9/Makefile.inc1 ============================================================================== --- stable/9/Makefile.inc1 Sat Sep 8 03:11:02 2012 (r240229) +++ stable/9/Makefile.inc1 Sat Sep 8 04:35:54 2012 (r240230) @@ -640,7 +640,10 @@ ITOOLS= [ awk cap_mkdb cat chflags chmod # # Non-base distributions produced by the base system -EXTRA_DISTRIBUTIONS= doc games +EXTRA_DISTRIBUTIONS= doc +.if ${MK_GAMES} != "no" +EXTRA_DISTRIBUTIONS+= games +.endif .if defined(LIB32TMP) && ${MK_LIB32} != "no" EXTRA_DISTRIBUTIONS+= lib32 .endif From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 04:42:10 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 382C2106564A; Sat, 8 Sep 2012 04:42:10 +0000 (UTC) (envelope-from gjb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 228D68FC0A; Sat, 8 Sep 2012 04:42:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q884g9BT021704; Sat, 8 Sep 2012 04:42:09 GMT (envelope-from gjb@svn.freebsd.org) Received: (from gjb@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q884g9J9021702; Sat, 8 Sep 2012 04:42:09 GMT (envelope-from gjb@svn.freebsd.org) Message-Id: <201209080442.q884g9J9021702@svn.freebsd.org> From: Glen Barber Date: Sat, 8 Sep 2012 04:42:09 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240231 - stable/9/cddl/contrib/opensolaris/cmd/zfs X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 04:42:10 -0000 Author: gjb (doc,ports committer) Date: Sat Sep 8 04:42:09 2012 New Revision: 240231 URL: http://svn.freebsd.org/changeset/base/240231 Log: MFC r240153: - Typo fix and minor word swap. PR: 171356 Modified: stable/9/cddl/contrib/opensolaris/cmd/zfs/zfs.8 Directory Properties: stable/9/cddl/contrib/opensolaris/ (props changed) Modified: stable/9/cddl/contrib/opensolaris/cmd/zfs/zfs.8 ============================================================================== --- stable/9/cddl/contrib/opensolaris/cmd/zfs/zfs.8 Sat Sep 8 04:35:54 2012 (r240230) +++ stable/9/cddl/contrib/opensolaris/cmd/zfs/zfs.8 Sat Sep 8 04:42:09 2012 (r240231) @@ -22,10 +22,11 @@ .\" Copyright (c) 2012 Nexenta Systems, Inc. All Rights Reserved. .\" Copyright (c) 2012, Joyent, Inc. All rights reserved. .\" Copyright (c) 2011, Pawel Jakub Dawidek +.\" Copyright (c) 2012, Bryan Drewery .\" .\" $FreeBSD$ .\" -.Dd August 12, 2012 +.Dd September 5, 2012 .Dt ZFS 8 .Os .Sh NAME @@ -1076,7 +1077,7 @@ bit is respected for the file system. Th .It Sy sharesmb Ns = Ns Cm on | off | Ar opts The .Sy sharesmb -property has currently no effect o +property currently has no effect on .Fx . .It Sy sharenfs Ns = Ns Cm on | off | Ar opts Controls whether the file system is shared via @@ -2022,7 +2023,7 @@ The default is .Pp The default can be changed to include group types. .It Fl i -Translate SID to POSIX ID. This flag has currently no effect on +Translate SID to POSIX ID. This flag currently has no effect on .Fx . .El .It Xo From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 11:34:22 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id BF7611065672; Sat, 8 Sep 2012 11:34:22 +0000 (UTC) (envelope-from dim@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id A8E448FC12; Sat, 8 Sep 2012 11:34:22 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q88BYMY8078292; Sat, 8 Sep 2012 11:34:22 GMT (envelope-from dim@svn.freebsd.org) Received: (from dim@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q88BYMLe078287; Sat, 8 Sep 2012 11:34:22 GMT (envelope-from dim@svn.freebsd.org) Message-Id: <201209081134.q88BYMLe078287@svn.freebsd.org> From: Dimitry Andric Date: Sat, 8 Sep 2012 11:34:22 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240236 - in stable/9: gnu/lib/libstdc++ gnu/lib/libsupc++ lib/libc++ share/mk X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 11:34:23 -0000 Author: dim Date: Sat Sep 8 11:34:22 2012 New Revision: 240236 URL: http://svn.freebsd.org/changeset/base/240236 Log: MFC r239680: Add libcxxrt's objects (prefixing them with cxxrt_ to avoid collisions) to libc++.a and libc++_p.a, to make static linking of C++ executables with libc++ easier. This is similar to the approach used in libstdc++. MFC r239686: When using -stdlib=libc++, add the correct dependency to .depend in bsd.prog.mk. Submitted by: Yamaya Takashi MFC r239695: For building libstdc++ and libsupc++, filter out any -stdlib=libc++ option from CXXFLAGS, otherwise these libraries will not build. Similarly, filter out any -std=xxx options that aren't supported. Submitted by: Yamaya Takashi Modified: stable/9/gnu/lib/libstdc++/Makefile stable/9/gnu/lib/libsupc++/Makefile stable/9/lib/libc++/Makefile stable/9/share/mk/bsd.prog.mk Directory Properties: stable/9/gnu/lib/libstdc++/ (props changed) stable/9/gnu/lib/libsupc++/ (props changed) stable/9/lib/libc++/ (props changed) stable/9/share/mk/ (props changed) Modified: stable/9/gnu/lib/libstdc++/Makefile ============================================================================== --- stable/9/gnu/lib/libstdc++/Makefile Sat Sep 8 08:46:43 2012 (r240235) +++ stable/9/gnu/lib/libstdc++/Makefile Sat Sep 8 11:34:22 2012 (r240236) @@ -22,6 +22,7 @@ CFLAGS+= -I${GCCLIB}/include -I${SRCDIR} CFLAGS+= -frandom-seed=RepeatabilityConsideredGood CXXFLAGS+= -fno-implicit-templates -ffunction-sections -fdata-sections \ -Wno-deprecated +CXXFLAGS:= ${CXXFLAGS:N-stdlib=libc++:N-std=c++[01][13x]:N-std=gnu++[01][13x]} PO_CXXFLAGS= ${CXXFLAGS:N-ffunction-sections} DPADD= ${LIBM} Modified: stable/9/gnu/lib/libsupc++/Makefile ============================================================================== --- stable/9/gnu/lib/libsupc++/Makefile Sat Sep 8 08:46:43 2012 (r240235) +++ stable/9/gnu/lib/libsupc++/Makefile Sat Sep 8 11:34:22 2012 (r240236) @@ -24,6 +24,7 @@ CFLAGS+= -I${GCCLIB}/include -I${SRCDIR} CFLAGS+= -I${.CURDIR}/../libstdc++ -I. CFLAGS+= -frandom-seed=RepeatabilityConsideredGood CXXFLAGS+= -fno-implicit-templates -ffunction-sections -fdata-sections +CXXFLAGS:= ${CXXFLAGS:N-stdlib=libc++:N-std=c++[01][13x]:N-std=gnu++[01][13x]} PO_CXXFLAGS= ${CXXFLAGS:N-ffunction-sections} HDRS= exception new typeinfo cxxabi.h exception_defines.h Modified: stable/9/lib/libc++/Makefile ============================================================================== --- stable/9/lib/libc++/Makefile Sat Sep 8 08:46:43 2012 (r240235) +++ stable/9/lib/libc++/Makefile Sat Sep 8 11:34:22 2012 (r240236) @@ -35,8 +35,25 @@ SRCS+= algorithm.cpp\ utility.cpp\ valarray.cpp +CXXRT_SRCS+= libelftc_dem_gnu3.c\ + terminate.cc\ + dynamic_cast.cc\ + memory.cc\ + auxhelper.cc\ + exception.cc\ + stdexcept.cc\ + typeinfo.cc\ + guard.cc + +.for _S in ${CXXRT_SRCS} +STATICOBJS+= cxxrt_${_S:R}.o +cxxrt_${_S}: + ln -sf ${LIBCXXRTDIR}/${_S} ${.TARGET} +.endfor + WARNS= 0 -CXXFLAGS+= -I${HDRDIR} -I${LIBCXXRTDIR} -std=c++0x -nostdlib -DLIBCXXRT +CFLAGS+= -I${HDRDIR} -I${LIBCXXRTDIR} -nostdlib -DLIBCXXRT +CXXFLAGS+= -std=c++0x DPADD= ${LIBCXXRT} LDADD= -lcxxrt Modified: stable/9/share/mk/bsd.prog.mk ============================================================================== --- stable/9/share/mk/bsd.prog.mk Sat Sep 8 08:46:43 2012 (r240235) +++ stable/9/share/mk/bsd.prog.mk Sat Sep 8 11:34:22 2012 (r240236) @@ -131,10 +131,14 @@ _EXTRADEPEND: .else echo ${PROG}: ${LIBC} ${DPADD} >> ${DEPENDFILE} .if defined(PROG_CXX) +.if !empty(CXXFLAGS:M-stdlib=libc++) + echo ${PROG}: ${LIBCPLUSPLUS} >> ${DEPENDFILE} +.else echo ${PROG}: ${LIBSTDCPLUSPLUS} >> ${DEPENDFILE} .endif .endif .endif +.endif .if !target(install) From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 16:40:19 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 9E9E3106568F; Sat, 8 Sep 2012 16:40:19 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 85D4F8FC14; Sat, 8 Sep 2012 16:40:19 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q88GeJ82021914; Sat, 8 Sep 2012 16:40:19 GMT (envelope-from kib@svn.freebsd.org) Received: (from kib@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q88GeJm1021891; Sat, 8 Sep 2012 16:40:19 GMT (envelope-from kib@svn.freebsd.org) Message-Id: <201209081640.q88GeJm1021891@svn.freebsd.org> From: Konstantin Belousov Date: Sat, 8 Sep 2012 16:40:19 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240238 - in stable/9/sys: arm/arm dev/agp dev/md fs/nfsclient fs/nwfs fs/smbfs fs/tmpfs ia64/ia64 kern net nfsclient ofed/include/linux ufs/ffs vm X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 16:40:19 -0000 Author: kib Date: Sat Sep 8 16:40:18 2012 New Revision: 240238 URL: http://svn.freebsd.org/changeset/base/240238 Log: MFC r239065: Stop including vm_param.h into vm_page.h. Include vm_param.h explicitely for the kernel code which needs it. Modified: stable/9/sys/arm/arm/pmap.c stable/9/sys/dev/agp/agp.c stable/9/sys/dev/agp/agp_i810.c stable/9/sys/dev/md/md.c stable/9/sys/fs/nfsclient/nfs_clbio.c stable/9/sys/fs/nwfs/nwfs_io.c stable/9/sys/fs/smbfs/smbfs_io.c stable/9/sys/fs/tmpfs/tmpfs_subr.c stable/9/sys/fs/tmpfs/tmpfs_vnops.c stable/9/sys/ia64/ia64/pmap.c stable/9/sys/kern/kern_proc.c stable/9/sys/kern/subr_uio.c stable/9/sys/kern/uipc_syscalls.c stable/9/sys/net/bpf_zerocopy.c stable/9/sys/nfsclient/nfs_bio.c stable/9/sys/ofed/include/linux/gfp.h stable/9/sys/ufs/ffs/ffs_vnops.c stable/9/sys/vm/device_pager.c stable/9/sys/vm/sg_pager.c stable/9/sys/vm/vm_page.h stable/9/sys/vm/vnode_pager.c Directory Properties: stable/9/sys/ (props changed) stable/9/sys/dev/ (props changed) stable/9/sys/fs/ (props changed) Modified: stable/9/sys/arm/arm/pmap.c ============================================================================== --- stable/9/sys/arm/arm/pmap.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/arm/arm/pmap.c Sat Sep 8 16:40:18 2012 (r240238) @@ -154,6 +154,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include @@ -165,7 +166,6 @@ __FBSDID("$FreeBSD$"); #include #include #include -#include #include #include #include Modified: stable/9/sys/dev/agp/agp.c ============================================================================== --- stable/9/sys/dev/agp/agp.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/dev/agp/agp.c Sat Sep 8 16:40:18 2012 (r240238) @@ -50,6 +50,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/dev/agp/agp_i810.c ============================================================================== --- stable/9/sys/dev/agp/agp_i810.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/dev/agp/agp_i810.c Sat Sep 8 16:40:18 2012 (r240238) @@ -67,6 +67,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/dev/md/md.c ============================================================================== --- stable/9/sys/dev/md/md.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/dev/md/md.c Sat Sep 8 16:40:18 2012 (r240238) @@ -84,14 +84,13 @@ #include #include +#include #include #include #include #include #include -#include - #define MD_MODVER 1 #define MD_SHUTDOWN 0x10000 /* Tell worker thread to terminate. */ Modified: stable/9/sys/fs/nfsclient/nfs_clbio.c ============================================================================== --- stable/9/sys/fs/nfsclient/nfs_clbio.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/fs/nfsclient/nfs_clbio.c Sat Sep 8 16:40:18 2012 (r240238) @@ -47,6 +47,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/fs/nwfs/nwfs_io.c ============================================================================== --- stable/9/sys/fs/nwfs/nwfs_io.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/fs/nwfs/nwfs_io.c Sat Sep 8 16:40:18 2012 (r240238) @@ -38,6 +38,7 @@ #include #include +#include #include #include #include Modified: stable/9/sys/fs/smbfs/smbfs_io.c ============================================================================== --- stable/9/sys/fs/smbfs/smbfs_io.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/fs/smbfs/smbfs_io.c Sat Sep 8 16:40:18 2012 (r240238) @@ -41,6 +41,7 @@ #include #include +#include #include #include #include Modified: stable/9/sys/fs/tmpfs/tmpfs_subr.c ============================================================================== --- stable/9/sys/fs/tmpfs/tmpfs_subr.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/fs/tmpfs/tmpfs_subr.c Sat Sep 8 16:40:18 2012 (r240238) @@ -47,6 +47,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/fs/tmpfs/tmpfs_vnops.c ============================================================================== --- stable/9/sys/fs/tmpfs/tmpfs_vnops.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/fs/tmpfs/tmpfs_vnops.c Sat Sep 8 16:40:18 2012 (r240238) @@ -51,6 +51,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/ia64/ia64/pmap.c ============================================================================== --- stable/9/sys/ia64/ia64/pmap.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/ia64/ia64/pmap.c Sat Sep 8 16:40:18 2012 (r240238) @@ -59,6 +59,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/kern/kern_proc.c ============================================================================== --- stable/9/sys/kern/kern_proc.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/kern/kern_proc.c Sat Sep 8 16:40:18 2012 (r240238) @@ -77,6 +77,7 @@ __FBSDID("$FreeBSD$"); #endif #include +#include #include #include #include Modified: stable/9/sys/kern/subr_uio.c ============================================================================== --- stable/9/sys/kern/subr_uio.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/kern/subr_uio.c Sat Sep 8 16:40:18 2012 (r240238) @@ -53,11 +53,11 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include #ifdef ZERO_COPY_SOCKETS -#include #include #endif Modified: stable/9/sys/kern/uipc_syscalls.c ============================================================================== --- stable/9/sys/kern/uipc_syscalls.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/kern/uipc_syscalls.c Sat Sep 8 16:40:18 2012 (r240238) @@ -82,6 +82,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/net/bpf_zerocopy.c ============================================================================== --- stable/9/sys/net/bpf_zerocopy.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/net/bpf_zerocopy.c Sat Sep 8 16:40:18 2012 (r240238) @@ -50,6 +50,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/nfsclient/nfs_bio.c ============================================================================== --- stable/9/sys/nfsclient/nfs_bio.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/nfsclient/nfs_bio.c Sat Sep 8 16:40:18 2012 (r240238) @@ -49,6 +49,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/ofed/include/linux/gfp.h ============================================================================== --- stable/9/sys/ofed/include/linux/gfp.h Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/ofed/include/linux/gfp.h Sat Sep 8 16:40:18 2012 (r240238) @@ -34,6 +34,7 @@ #include +#include #include #include #include Modified: stable/9/sys/ufs/ffs/ffs_vnops.c ============================================================================== --- stable/9/sys/ufs/ffs/ffs_vnops.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/ufs/ffs/ffs_vnops.c Sat Sep 8 16:40:18 2012 (r240238) @@ -80,6 +80,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/vm/device_pager.c ============================================================================== --- stable/9/sys/vm/device_pager.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/vm/device_pager.c Sat Sep 8 16:40:18 2012 (r240238) @@ -47,6 +47,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include Modified: stable/9/sys/vm/sg_pager.c ============================================================================== --- stable/9/sys/vm/sg_pager.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/vm/sg_pager.c Sat Sep 8 16:40:18 2012 (r240238) @@ -38,6 +38,7 @@ __FBSDID("$FreeBSD$"); #include #include #include +#include #include #include #include Modified: stable/9/sys/vm/vm_page.h ============================================================================== --- stable/9/sys/vm/vm_page.h Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/vm/vm_page.h Sat Sep 8 16:40:18 2012 (r240238) @@ -279,8 +279,6 @@ extern struct vpglocks pa_lock[]; #ifdef _KERNEL -#include - /* * Each pageable resident page falls into one of five lists: * Modified: stable/9/sys/vm/vnode_pager.c ============================================================================== --- stable/9/sys/vm/vnode_pager.c Sat Sep 8 12:45:47 2012 (r240237) +++ stable/9/sys/vm/vnode_pager.c Sat Sep 8 16:40:18 2012 (r240238) @@ -68,6 +68,7 @@ __FBSDID("$FreeBSD$"); #include #include +#include #include #include #include From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 18:06:18 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id D2A4F106566C; Sat, 8 Sep 2012 18:06:18 +0000 (UTC) (envelope-from zont@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BD35C8FC15; Sat, 8 Sep 2012 18:06:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q88I6Iwb032338; Sat, 8 Sep 2012 18:06:18 GMT (envelope-from zont@svn.freebsd.org) Received: (from zont@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q88I6I0M032336; Sat, 8 Sep 2012 18:06:18 GMT (envelope-from zont@svn.freebsd.org) Message-Id: <201209081806.q88I6I0M032336@svn.freebsd.org> From: Andrey Zonov Date: Sat, 8 Sep 2012 18:06:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-9@freebsd.org X-SVN-Group: stable-9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r240242 - stable/9/usr.sbin/watchdogd X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 18:06:19 -0000 Author: zont Date: Sat Sep 8 18:06:18 2012 New Revision: 240242 URL: http://svn.freebsd.org/changeset/base/240242 Log: MFC r239769: - Don't allow watchdogd(8) to be swapped out. On machines with huge amount of swap and high IO activity, watchdogd(8) may wait for a swap memory longer than timeout and sometimes fires. MFC r239896: - It's also need to lock current memory. Modified: stable/9/usr.sbin/watchdogd/watchdogd.c Directory Properties: stable/9/usr.sbin/watchdogd/ (props changed) Modified: stable/9/usr.sbin/watchdogd/watchdogd.c ============================================================================== --- stable/9/usr.sbin/watchdogd/watchdogd.c Sat Sep 8 17:43:20 2012 (r240241) +++ stable/9/usr.sbin/watchdogd/watchdogd.c Sat Sep 8 18:06:18 2012 (r240242) @@ -118,6 +118,8 @@ main(int argc, char *argv[]) pidfile_write(pfh); if (madvise(0, 0, MADV_PROTECT) != 0) warn("madvise failed"); + if (mlockall(MCL_CURRENT | MCL_FUTURE) != 0) + warn("mlockall failed"); watchdog_loop(); From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 18:34:19 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 6D7321065677 for ; Sat, 8 Sep 2012 18:34:19 +0000 (UTC) (envelope-from bryan@shatow.net) Received: from secure.xzibition.com (secure.xzibition.com [173.160.118.92]) by mx1.freebsd.org (Postfix) with ESMTP id E9A858FC15 for ; Sat, 8 Sep 2012 18:34:18 +0000 (UTC) DomainKey-Signature: a=rsa-sha1; c=nofws; d=shatow.net; h=message-id :date:from:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; q=dns; s=sweb; b=lupBVY xNIu3bk/bEFZb1+nQW3mwLjtSqe4rLpc/js4haRQci7VQAXxPklTmRGu59vV8jD6 Z+lZNWgrl+rSubV+aLz7PArbUXbT9255cPbh9doO93TqXsgswhveV/CUnhIzYda9 wq4BwFffxIyyUVPpUOBvSfFH4EagsYVcr1Jb0= DKIM-Signature: v=1; a=rsa-sha256; c=simple; d=shatow.net; h=message-id :date:from:mime-version:to:cc:subject:references:in-reply-to :content-type:content-transfer-encoding; s=sweb; bh=06SRc30sHMZe AuqNbXBi16vekEOE41OmXavqYnMgLxI=; b=g2g1YgCoX8Vt4U+XMpHyWH3GMP0E ujxXaPXXRVdpD8LRAoPzjL0KYgCHnD98TAi+TzNFEzuV7Ai3V1nFBIyutT7GODnZ bRreZXX8QYWp4DVbGdt23OPCt+Dn+XGj9XvmfxTiTrUlam0ZwkFzU+dUApTcrtIm pCUoNg/rx5jx/Qs= Received: (qmail 29130 invoked from network); 8 Sep 2012 13:34:15 -0500 Received: from unknown (HELO ?10.10.0.115?) (bryan@shatow.net@10.10.0.115) by sweb.xzibition.com with ESMTPA; 8 Sep 2012 13:34:15 -0500 Message-ID: <504B8F9A.80809@shatow.net> Date: Sat, 08 Sep 2012 13:34:02 -0500 From: Bryan Drewery User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:15.0) Gecko/20120824 Thunderbird/15.0 MIME-Version: 1.0 To: Eitan Adler References: <201209080241.q882foC1005948@svn.freebsd.org> In-Reply-To: <201209080241.q882foC1005948@svn.freebsd.org> X-Enigmail-Version: 1.4.4 OpenPGP: id=3C9B0CF9; url=http://www.shatow.net/bryan/bryan.asc Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240225 - stable/9/sys/cddl/compat/opensolaris/sys X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 18:34:19 -0000 On 9/7/2012 9:41 PM, Eitan Adler wrote: > Author: eadler > Date: Sat Sep 8 02:41:50 2012 > New Revision: 240225 > URL: http://svn.freebsd.org/changeset/base/240225 > > Log: > MFC r230454: > Use provided name when allocating ksid domain. It isn't really used on FreeBSD, > but should fix a panic when pool is imported from another OS that is using this. > > No objections from; pjd > Approved by: cperciva (implicit) > Thanks! > Modified: > stable/9/sys/cddl/compat/opensolaris/sys/sid.h > Directory Properties: > stable/9/sys/ (props changed) > > Modified: stable/9/sys/cddl/compat/opensolaris/sys/sid.h > ============================================================================== > --- stable/9/sys/cddl/compat/opensolaris/sys/sid.h Sat Sep 8 01:26:52 2012 (r240224) > +++ stable/9/sys/cddl/compat/opensolaris/sys/sid.h Sat Sep 8 02:41:50 2012 (r240225) > @@ -30,7 +30,7 @@ > #define _OPENSOLARIS_SYS_SID_H_ > > typedef struct ksiddomain { > - char kd_name[16]; /* Domain part of SID */ > + char kd_name[1]; /* Domain part of SID */ > } ksiddomain_t; > typedef void ksid_t; > > @@ -39,8 +39,8 @@ ksid_lookupdomain(const char *domain) > { > ksiddomain_t *kd; > > - kd = kmem_alloc(sizeof(*kd), KM_SLEEP); > - strlcpy(kd->kd_name, "FreeBSD", sizeof(kd->kd_name)); > + kd = kmem_alloc(sizeof(*kd) + strlen(domain), KM_SLEEP); > + strcpy(kd->kd_name, domain); > return (kd); > } > > _______________________________________________ > svn-src-all@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/svn-src-all > To unsubscribe, send any mail to "svn-src-all-unsubscribe@freebsd.org" > -- Regards, Bryan Drewery bdrewery@freenode/EFNet From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 19:21:41 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D1A39106566C; Sat, 8 Sep 2012 19:21:41 +0000 (UTC) (envelope-from mm@FreeBSD.org) Received: from mail.vx.sk (mail.vx.sk [IPv6:2a01:4f8:150:6101::4]) by mx1.freebsd.org (Postfix) with ESMTP id 8C0C68FC08; Sat, 8 Sep 2012 19:21:41 +0000 (UTC) Received: from core.vx.sk (localhost [127.0.0.2]) by mail.vx.sk (Postfix) with ESMTP id EBE2B3A8F3; Sat, 8 Sep 2012 21:21:40 +0200 (CEST) X-Virus-Scanned: amavisd-new at mail.vx.sk Received: from mail.vx.sk by core.vx.sk (amavisd-new, unix socket) with LMTP id CjEanHvDLAd3; Sat, 8 Sep 2012 21:21:39 +0200 (CEST) Received: from [10.9.8.1] (188-167-78-15.dynamic.chello.sk [188.167.78.15]) by mail.vx.sk (Postfix) with ESMTPSA id CD4CD3A8E2; Sat, 8 Sep 2012 21:21:38 +0200 (CEST) Message-ID: <504B9AC3.2070705@FreeBSD.org> Date: Sat, 08 Sep 2012 21:21:39 +0200 From: Martin Matuska User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:15.0) Gecko/20120824 Thunderbird/15.0 MIME-Version: 1.0 To: Eitan Adler References: <201209080241.q882foC1005948@svn.freebsd.org> In-Reply-To: <201209080241.q882foC1005948@svn.freebsd.org> X-Enigmail-Version: 1.4.4 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240225 - stable/9/sys/cddl/compat/opensolaris/sys X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 19:21:42 -0000 This commit is missing the PR number (kern/171380) and should be MFCed together with r230454. I was planning to MFC these two tomorrow. On 8.9.2012 4:41, Eitan Adler wrote: > Author: eadler > Date: Sat Sep 8 02:41:50 2012 > New Revision: 240225 > URL: http://svn.freebsd.org/changeset/base/240225 > > Log: > MFC r230454: > Use provided name when allocating ksid domain. It isn't really used on FreeBSD, > but should fix a panic when pool is imported from another OS that is using this. > > No objections from; pjd > Approved by: cperciva (implicit) > > Modified: > stable/9/sys/cddl/compat/opensolaris/sys/sid.h > Directory Properties: > stable/9/sys/ (props changed) > > Modified: stable/9/sys/cddl/compat/opensolaris/sys/sid.h > ============================================================================== > --- stable/9/sys/cddl/compat/opensolaris/sys/sid.h Sat Sep 8 01:26:52 2012 (r240224) > +++ stable/9/sys/cddl/compat/opensolaris/sys/sid.h Sat Sep 8 02:41:50 2012 (r240225) > @@ -30,7 +30,7 @@ > #define _OPENSOLARIS_SYS_SID_H_ > > typedef struct ksiddomain { > - char kd_name[16]; /* Domain part of SID */ > + char kd_name[1]; /* Domain part of SID */ > } ksiddomain_t; > typedef void ksid_t; > > @@ -39,8 +39,8 @@ ksid_lookupdomain(const char *domain) > { > ksiddomain_t *kd; > > - kd = kmem_alloc(sizeof(*kd), KM_SLEEP); > - strlcpy(kd->kd_name, "FreeBSD", sizeof(kd->kd_name)); > + kd = kmem_alloc(sizeof(*kd) + strlen(domain), KM_SLEEP); > + strcpy(kd->kd_name, domain); > return (kd); > } > -- Martin Matuska FreeBSD committer http://blog.vx.sk From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 19:36:58 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx2.freebsd.org (mx2.freebsd.org [IPv6:2001:4f8:fff6::35]) by hub.freebsd.org (Postfix) with ESMTP id 95A19106566C; Sat, 8 Sep 2012 19:36:58 +0000 (UTC) (envelope-from dougb@FreeBSD.org) Received: from opti.dougb.net (hub.freebsd.org [IPv6:2001:4f8:fff6::36]) by mx2.freebsd.org (Postfix) with ESMTP id 6BF28150D26; Sat, 8 Sep 2012 19:36:44 +0000 (UTC) Message-ID: <504B9E4C.6030301@FreeBSD.org> Date: Sat, 08 Sep 2012 12:36:44 -0700 From: Doug Barton Organization: http://SupersetSolutions.com/ User-Agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:15.0) Gecko/20120907 Thunderbird/15.0 MIME-Version: 1.0 To: Martin Matuska References: <201209080241.q882foC1005948@svn.freebsd.org> <504B9AC3.2070705@FreeBSD.org> In-Reply-To: <504B9AC3.2070705@FreeBSD.org> X-Enigmail-Version: 1.4.4 OpenPGP: id=1A1ABC84 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Eitan Adler , svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240225 - stable/9/sys/cddl/compat/opensolaris/sys X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 19:36:58 -0000 On 09/08/2012 12:21, Martin Matuska wrote: > This commit is missing the PR number It's actually pretty common to summarize the commit message in an MFC, rather than reproducing it verbatim. -- I am only one, but I am one. I cannot do everything, but I can do something. And I will not let what I cannot do interfere with what I can do. -- Edward Everett Hale, (1822 - 1909) From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 19:39:29 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 5DE9A1065673 for ; Sat, 8 Sep 2012 19:39:29 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 248B68FC0C for ; Sat, 8 Sep 2012 19:39:28 +0000 (UTC) Received: by pbbrp2 with SMTP id rp2so1174767pbb.13 for ; Sat, 08 Sep 2012 12:39:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=ZPG5tLqJA+tLmd+29HNeVjheqm0lXnrpxzzPbEvKDDA=; b=npx84QNBJU6KTI1dGAd4thxK8S1w2xJ29dZi6FZdYd/gNiPjlA/4FWvyKPUqoLkU+I OOFd8qtigycoFT1zP0d/oNWJSFZ4ucIRBHXza8M0TjFNCSIOOvVlXlX6njAjoMTMscy7 x7TIcf8Pt4w9n45zzGQRrFUdvM60IhGKjgdTI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :x-gm-message-state; bh=ZPG5tLqJA+tLmd+29HNeVjheqm0lXnrpxzzPbEvKDDA=; b=ndVgjijUEj6JyJg1g8EKVsxo5UeTGWhh3a2xRE52qDuKgYlgSoY2xICNt/CjRA55f0 +GTnOg9z0n+ivRyDiZGRMQHyRDgUQ0Wbet6KWCi1D0gWLkvR0mJl5/DCQyeW952X8ZPW W4jYZNSPbESi+D0OQHYI46iDj/QvpXdNWhjnO12odqLMhVkYgciJBtuYEMSN+lfn31lE 6eZ0G2rIolfV7H6i2H/Qp72C4s+x6cs9Wa8Eut+FRq2dIWyyTqZ9hVwigrjwDk3APe+A 07RHG30/ktZF0qFFmuNVAi47AIW1i95WYdmuPwf/vO43s0pU3Wy4A9VYdx1fDwrjOpfP Qgog== Received: by 10.66.83.129 with SMTP id q1mr15128193pay.4.1347133167713; Sat, 08 Sep 2012 12:39:27 -0700 (PDT) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.66.193.101 with HTTP; Sat, 8 Sep 2012 12:38:56 -0700 (PDT) In-Reply-To: <504B9AC3.2070705@FreeBSD.org> References: <201209080241.q882foC1005948@svn.freebsd.org> <504B9AC3.2070705@FreeBSD.org> From: Eitan Adler Date: Sat, 8 Sep 2012 15:38:56 -0400 X-Google-Sender-Auth: C4di3U_jd6yHw8B9RgTzHGoOhFg Message-ID: To: Martin Matuska Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQkzVvrsnhvpPpnbChbJqzestTHTOGzqQid6BDE60xJln34C34PwFp2vns4uadTlpIk/MmlL Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240225 - stable/9/sys/cddl/compat/opensolaris/sys X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 19:39:29 -0000 On 8 September 2012 15:21, Martin Matuska wrote: > This commit is missing the PR number (kern/171380) and should be MFCed > together with r230454. > I was planning to MFC these two tomorrow. I had already MFCed r230454 to 8 and 7 so I was just finishing that off. I was not aware of r240162. -- Eitan Adler Source & Ports committer X11, Bugbusting teams From owner-svn-src-stable-9@FreeBSD.ORG Sat Sep 8 19:40:04 2012 Return-Path: Delivered-To: svn-src-stable-9@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 153331065673 for ; Sat, 8 Sep 2012 19:40:04 +0000 (UTC) (envelope-from lists@eitanadler.com) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx1.freebsd.org (Postfix) with ESMTP id 931E68FC12 for ; Sat, 8 Sep 2012 19:40:03 +0000 (UTC) Received: by pbbrp2 with SMTP id rp2so1175079pbb.13 for ; Sat, 08 Sep 2012 12:40:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=eitanadler.com; s=0xdeadbeef; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type; bh=uUUAjS4WMq++oUYQ+j0R7ee5GQ+Z4iB78Yny+plv4Zg=; b=JHXjvLLLyIoth4juhAoEb/X2gA/NNhBiz0/m870IfJYY5epU1pS+qdfRUb6ubSE7hj mT/enRK3pULMyhfhzvHYVTefbb2EI10uNEhljp/Il3pnEcLq0oUM2f4VoZv/UMFCqy2M nusY9GU3K3TsLKQpw5aSXXaNQrxqMCqTxHzxM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date :x-google-sender-auth:message-id:subject:to:cc:content-type :x-gm-message-state; bh=uUUAjS4WMq++oUYQ+j0R7ee5GQ+Z4iB78Yny+plv4Zg=; b=dC0mqtmf9NAyIP3lNHLxwSGpvvDQuBda8j4URV5DmeioTk+aayAbCAp8YnfB9l1zjw DoRwgp2Pbp06F+Y0f0eLuc4ap/iNyr7jTKOJsdZWG7y3Rabc9uC2SNTrc+7rGigU0PpE B5NnSV6X7Kif0ich8lo1Q/lMgf9qptnJg3zv61MMFAfqEiq1wc0D+IW7a8q25JRpipZu 7zdTkEwRiVqSMNWSzqxWA41YteMdHQ4bgVrLYrpxQm++nujut3jaIlre1nmmhgUGAQH5 g2Rjv0rMGK/AX5NnA/YqIZaNReVgHObk4NvTXp4f2bv+gWDlEWWuCdxBymmsYWC7s0DV mzbQ== Received: by 10.68.242.231 with SMTP id wt7mr16930688pbc.99.1347133203327; Sat, 08 Sep 2012 12:40:03 -0700 (PDT) MIME-Version: 1.0 Sender: lists@eitanadler.com Received: by 10.66.193.101 with HTTP; Sat, 8 Sep 2012 12:39:32 -0700 (PDT) In-Reply-To: <504B9E4C.6030301@FreeBSD.org> References: <201209080241.q882foC1005948@svn.freebsd.org> <504B9AC3.2070705@FreeBSD.org> <504B9E4C.6030301@FreeBSD.org> From: Eitan Adler Date: Sat, 8 Sep 2012 15:39:32 -0400 X-Google-Sender-Auth: JrfVb4_jHUv9fjCOm2l4TuP-lFM Message-ID: To: Doug Barton Content-Type: text/plain; charset=UTF-8 X-Gm-Message-State: ALoCoQnyCG3XYFRGYSXIJK8p28nxkZpckmvKwDxSwlZcZmwHzDt95J/Ttkpw9scT9DHroPOU6yMk Cc: svn-src-stable@freebsd.org, svn-src-all@freebsd.org, src-committers@freebsd.org, Martin Matuska , svn-src-stable-9@freebsd.org Subject: Re: svn commit: r240225 - stable/9/sys/cddl/compat/opensolaris/sys X-BeenThere: svn-src-stable-9@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 9-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 08 Sep 2012 19:40:04 -0000 On 8 September 2012 15:36, Doug Barton wrote: > On 09/08/2012 12:21, Martin Matuska wrote: >> This commit is missing the PR number > > It's actually pretty common to summarize the commit message in an MFC, > rather than reproducing it verbatim. The PR number is still important in order for dfilter to act correctly. I forgot to include it -- Eitan Adler Source & Ports committer X11, Bugbusting teams