From owner-svn-src-stable-7@FreeBSD.ORG Sun Jan 2 13:31:10 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D960C106564A; Sun, 2 Jan 2011 13:31:10 +0000 (UTC) (envelope-from lstewart@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C69308FC0A; Sun, 2 Jan 2011 13:31:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p02DVA9l047150; Sun, 2 Jan 2011 13:31:10 GMT (envelope-from lstewart@svn.freebsd.org) Received: (from lstewart@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p02DVAV8047146; Sun, 2 Jan 2011 13:31:10 GMT (envelope-from lstewart@svn.freebsd.org) Message-Id: <201101021331.p02DVAV8047146@svn.freebsd.org> From: Lawrence Stewart Date: Sun, 2 Jan 2011 13:31:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216890 - stable/7/usr.sbin/config X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 02 Jan 2011 13:31:11 -0000 Author: lstewart Date: Sun Jan 2 13:31:10 2011 New Revision: 216890 URL: http://svn.freebsd.org/changeset/base/216890 Log: MFC r210144 (originally committed by imp): Put warnings out to stderr rather than stdout. Modified: stable/7/usr.sbin/config/config.y stable/7/usr.sbin/config/mkmakefile.c stable/7/usr.sbin/config/mkoptions.c Directory Properties: stable/7/usr.sbin/config/ (props changed) stable/7/usr.sbin/config/SMM.doc/ (props changed) Modified: stable/7/usr.sbin/config/config.y ============================================================================== --- stable/7/usr.sbin/config/config.y Sun Jan 2 13:12:24 2011 (r216889) +++ stable/7/usr.sbin/config/config.y Sun Jan 2 13:31:10 2011 (r216890) @@ -384,7 +384,8 @@ newdev(char *name) struct device *np; if (finddev(&dtab, name)) { - printf("WARNING: duplicate device `%s' encountered.\n", name); + fprintf(stderr, + "WARNING: duplicate device `%s' encountered.\n", name); return; } @@ -444,7 +445,8 @@ newopt(struct opt_head *list, char *name op2 = findopt(list, name); if (op2 != NULL && !append) { - printf("WARNING: duplicate option `%s' encountered.\n", name); + fprintf(stderr, + "WARNING: duplicate option `%s' encountered.\n", name); return; } Modified: stable/7/usr.sbin/config/mkmakefile.c ============================================================================== --- stable/7/usr.sbin/config/mkmakefile.c Sun Jan 2 13:12:24 2011 (r216889) +++ stable/7/usr.sbin/config/mkmakefile.c Sun Jan 2 13:31:10 2011 (r216890) @@ -341,7 +341,8 @@ next: if (eq(wd, "include")) { next_quoted_word(fp, wd); if (wd == 0) { - printf("%s: missing include filename.\n", fname); + fprintf(stderr, "%s: missing include filename.\n", + fname); exit(1); } (void) snprintf(ifname, sizeof(ifname), "../../%s", wd); @@ -353,8 +354,7 @@ next: this = ns(wd); next_word(fp, wd); if (wd == 0) { - printf("%s: No type for %s.\n", - fname, this); + fprintf(stderr, "%s: No type for %s.\n", fname, this); exit(1); } tp = fl_lookup(this); @@ -381,8 +381,9 @@ next: } else if (eq(wd, "mandatory")) { mandatory = 1; } else if (!eq(wd, "optional")) { - printf("%s: %s must be optional, mandatory or standard\n", - fname, this); + fprintf(stderr, + "%s: %s must be optional, mandatory or standard\n", + fname, this); exit(1); } nextparam: @@ -395,7 +396,7 @@ nextparam: } if (eq(wd, "|")) { if (nreqs == 0) { - printf("%s: syntax error describing %s\n", + fprintf(stderr, "%s: syntax error describing %s\n", fname, this); exit(1); } @@ -410,9 +411,9 @@ nextparam: } if (eq(wd, "no-implicit-rule")) { if (compilewith == 0) { - printf("%s: alternate rule required when " - "\"no-implicit-rule\" is specified.\n", - fname); + fprintf(stderr, "%s: alternate rule required when " + "\"no-implicit-rule\" is specified.\n", + fname); } imp_rule++; goto nextparam; @@ -424,8 +425,9 @@ nextparam: if (eq(wd, "dependency")) { next_quoted_word(fp, wd); if (wd == 0) { - printf("%s: %s missing compile command string.\n", - fname, this); + fprintf(stderr, + "%s: %s missing compile command string.\n", + fname, this); exit(1); } depends = ns(wd); @@ -434,8 +436,8 @@ nextparam: if (eq(wd, "clean")) { next_quoted_word(fp, wd); if (wd == 0) { - printf("%s: %s missing clean file list.\n", - fname, this); + fprintf(stderr, "%s: %s missing clean file list.\n", + fname, this); exit(1); } clean = ns(wd); @@ -444,8 +446,9 @@ nextparam: if (eq(wd, "compile-with")) { next_quoted_word(fp, wd); if (wd == 0) { - printf("%s: %s missing compile command string.\n", - fname, this); + fprintf(stderr, + "%s: %s missing compile command string.\n", + fname, this); exit(1); } compilewith = ns(wd); @@ -454,8 +457,9 @@ nextparam: if (eq(wd, "warning")) { next_quoted_word(fp, wd); if (wd == 0) { - printf("%s: %s missing warning text string.\n", - fname, this); + fprintf(stderr, + "%s: %s missing warning text string.\n", + fname, this); exit(1); } warning = ns(wd); @@ -484,13 +488,14 @@ nextparam: goto nextparam; } if (mandatory) { - printf("%s: mandatory device \"%s\" not found\n", + fprintf(stderr, "%s: mandatory device \"%s\" not found\n", fname, wd); exit(1); } if (std) { - printf("standard entry %s has a device keyword - %s!\n", - this, wd); + fprintf(stderr, + "standard entry %s has a device keyword - %s!\n", + this, wd); exit(1); } SLIST_FOREACH(op, &opt, op_next) @@ -501,13 +506,13 @@ nextparam: doneparam: if (std == 0 && nreqs == 0) { - printf("%s: what is %s optional on?\n", + fprintf(stderr, "%s: what is %s optional on?\n", fname, this); exit(1); } if (wd) { - printf("%s: syntax error describing %s\n", + fprintf(stderr, "%s: syntax error describing %s\n", fname, this); exit(1); } @@ -687,7 +692,7 @@ do_rules(FILE *f) STAILQ_FOREACH(ftp, &ftab, f_next) { if (ftp->f_warn) - printf("WARNING: %s\n", ftp->f_warn); + fprintf(stderr, "WARNING: %s\n", ftp->f_warn); cp = (np = ftp->f_fn) + strlen(ftp->f_fn) - 1; och = *cp; if (ftp->f_flags & NO_IMPLCT_RULE) { @@ -732,7 +737,8 @@ do_rules(FILE *f) ftype = "PROFILE"; break; default: - printf("config: don't know rules for %s\n", np); + fprintf(stderr, + "config: don't know rules for %s\n", np); break; } snprintf(cmd, sizeof(cmd), "${%s_%c%s}\n" Modified: stable/7/usr.sbin/config/mkoptions.c ============================================================================== --- stable/7/usr.sbin/config/mkoptions.c Sun Jan 2 13:12:24 2011 (r216889) +++ stable/7/usr.sbin/config/mkoptions.c Sun Jan 2 13:31:10 2011 (r216890) @@ -77,12 +77,14 @@ options(void) } if (maxusers == 0) { - /* printf("maxusers not specified; will auto-size\n"); */ + /* fprintf(stderr, "maxusers not specified; will auto-size\n"); */ } else if (maxusers < users.u_min) { - printf("minimum of %d maxusers assumed\n", users.u_min); + fprintf(stderr, "minimum of %d maxusers assumed\n", + users.u_min); maxusers = users.u_min; } else if (maxusers > users.u_max) - printf("warning: maxusers > %d (%d)\n", users.u_max, maxusers); + fprintf(stderr, "warning: maxusers > %d (%d)\n", + users.u_max, maxusers); /* Fake MAXUSERS as an option. */ op = (struct opt *)calloc(1, sizeof(*op)); @@ -112,7 +114,7 @@ options(void) SLIST_FOREACH(ol, &otab, o_next) { if (eq(op->op_name, ol->o_name) && (ol->o_flags & OL_ALIAS)) { - printf("Mapping option %s to %s.\n", + fprintf(stderr, "Mapping option %s to %s.\n", op->op_name, ol->o_file); op->op_name = ol->o_file; break; @@ -123,7 +125,7 @@ options(void) do_option(ol->o_name); SLIST_FOREACH(op, &opt, op_next) { if (!op->op_ownfile && strncmp(op->op_name, "DEV_", 4)) { - printf("%s: unknown option \"%s\"\n", + fprintf(stderr, "%s: unknown option \"%s\"\n", PREFIX, op->op_name); exit(1); } @@ -160,7 +162,7 @@ do_option(char *name) if (value == NULL) value = ns("1"); if (oldvalue != NULL && !eq(value, oldvalue)) - printf( + fprintf(stderr, "%s: option \"%s\" redefined from %s to %s\n", PREFIX, op->op_name, oldvalue, value); @@ -218,12 +220,14 @@ do_option(char *name) if (eq(inw, ol->o_name)) break; if (!eq(inw, name) && !ol) { - printf("WARNING: unknown option `%s' removed from %s\n", - inw, file); + fprintf(stderr, + "WARNING: unknown option `%s' removed from %s\n", + inw, file); tidy++; } else if (ol != NULL && !eq(basefile, ol->o_file)) { - printf("WARNING: option `%s' moved from %s to %s\n", - inw, basefile, ol->o_file); + fprintf(stderr, + "WARNING: option `%s' moved from %s to %s\n", + inw, basefile, ol->o_file); tidy++; } else { op = (struct opt *) calloc(1, sizeof *op); @@ -312,8 +316,8 @@ check_duplicate(const char *fname, const SLIST_FOREACH(po, &otab, o_next) { if (eq(po->o_name, this)) { - printf("%s: Duplicate option %s.\n", - fname, this); + fprintf(stderr, "%s: Duplicate option %s.\n", + fname, this); exit(1); } } @@ -347,7 +351,8 @@ update_option(const char *this, char *va return; } } - printf("Compat option %s not listed in options file.\n", this); + fprintf(stderr, "Compat option %s not listed in options file.\n", + this); exit(1); } @@ -375,8 +380,8 @@ read_option_file(const char *fname, int return (1); if (val == 0) { if (flags) { - printf("%s: compat file requires two words " - "per line at %s\n", fname, this); + fprintf(stderr, "%s: compat file requires two" + " words per line at %s\n", fname, this); exit(1); } char *s = ns(this); From owner-svn-src-stable-7@FreeBSD.ORG Tue Jan 4 15:11:09 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 035651065679; Tue, 4 Jan 2011 15:11:09 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id E64F98FC0C; Tue, 4 Jan 2011 15:11:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04FB8EQ039903; Tue, 4 Jan 2011 15:11:08 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04FB8rQ039901; Tue, 4 Jan 2011 15:11:08 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201101041511.p04FB8rQ039901@svn.freebsd.org> From: John Baldwin Date: Tue, 4 Jan 2011 15:11:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216958 - stable/7/usr.bin/gcore X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 15:11:09 -0000 Author: jhb Date: Tue Jan 4 15:11:08 2011 New Revision: 216958 URL: http://svn.freebsd.org/changeset/base/216958 Log: MFC 216769: Start sentences on a new line to ease life for translators. Tweak the wording in a few places. Modified: stable/7/usr.bin/gcore/gcore.1 Directory Properties: stable/7/usr.bin/gcore/ (props changed) Modified: stable/7/usr.bin/gcore/gcore.1 ============================================================================== --- stable/7/usr.bin/gcore/gcore.1 Tue Jan 4 15:09:42 2011 (r216957) +++ stable/7/usr.bin/gcore/gcore.1 Tue Jan 4 15:11:08 2011 (r216958) @@ -63,12 +63,13 @@ The following options are available: Write the core file to the specified file instead of .Dq Pa core. . .It Fl f -Dumps all the available segments, excluding only the malformed ones and -un-dumpable ones. Unlike the default invocation, it also dumps -device- and sglist-mapped areas that may invalidate the state of -some transactions. This flag must be used very carefully, when the -behavior of the application is fully understood and the fallouts can -be easily controlled. +Dumps all available segments, excluding only malformed and undumpable segments. +Unlike the default invocation, this flag dumps mappings of devices which +may invalidate the state of device transactions or trigger other unexpected +behavior. +As a result, this flag should only be used when the behavior of the +application and any devices it has mapped is fully understood and any side +effects can be controlled or tolerated. .It Fl s Stop the process while gathering the core image, and resume it when done. @@ -94,7 +95,7 @@ Because of the .Xr ptrace 2 usage .Nm -may not work with processes which are actively investigated with +may not work with processes which are actively being investigated with .Xr truss 1 or .Xr gdb 1 . From owner-svn-src-stable-7@FreeBSD.ORG Tue Jan 4 20:38:52 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7F43E106566B; Tue, 4 Jan 2011 20:38:52 +0000 (UTC) (envelope-from gavin@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6E0278FC12; Tue, 4 Jan 2011 20:38:52 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p04KcqWd054244; Tue, 4 Jan 2011 20:38:52 GMT (envelope-from gavin@svn.freebsd.org) Received: (from gavin@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p04KcqUf054241; Tue, 4 Jan 2011 20:38:52 GMT (envelope-from gavin@svn.freebsd.org) Message-Id: <201101042038.p04KcqUf054241@svn.freebsd.org> From: Gavin Atkinson Date: Tue, 4 Jan 2011 20:38:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216976 - stable/7/sys/dev/usb X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jan 2011 20:38:52 -0000 Author: gavin Date: Tue Jan 4 20:38:52 2011 New Revision: 216976 URL: http://svn.freebsd.org/changeset/base/216976 Log: Merge r216045 from head (by hand, due to code changes): Support the Falcom Twist USB GSM/GPRS modem in uftdi(4) PR: usb/151862 Submitted by: Alessandro de Manzano Modified: stable/7/sys/dev/usb/uftdi.c stable/7/sys/dev/usb/usbdevs Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/dev/usb/uftdi.c ============================================================================== --- stable/7/sys/dev/usb/uftdi.c Tue Jan 4 20:26:41 2011 (r216975) +++ stable/7/sys/dev/usb/uftdi.c Tue Jan 4 20:38:52 2011 (r216976) @@ -190,6 +190,9 @@ uftdi_match(device_t self) if (uaa->vendor == USB_VENDOR_MATRIXORBITAL && (uaa->product == USB_PRODUCT_MATRIXORBITAL_MOUA)) return (UMATCH_VENDOR_PRODUCT); + if (uaa->vendor == USB_VENDOR_FALCOM && + (uaa->product == USB_PRODUCT_FALCOM_TWIST)) + return (UMATCH_VENDOR_PRODUCT); return (UMATCH_NONE); } Modified: stable/7/sys/dev/usb/usbdevs ============================================================================== --- stable/7/sys/dev/usb/usbdevs Tue Jan 4 20:26:41 2011 (r216975) +++ stable/7/sys/dev/usb/usbdevs Tue Jan 4 20:38:52 2011 (r216976) @@ -1280,6 +1280,9 @@ product ETEK 1COM 0x8007 Serial /* Extended Systems products */ product EXTENDED XTNDACCESS 0x0100 XTNDAccess IrDA +/* Falcom products */ +product FALCOM TWIST 0x0001 USB GSM/GPRS modem + /* FEIYA products */ product FEIYA 5IN1 0x1132 5-in-1 Card Reader From owner-svn-src-stable-7@FreeBSD.ORG Wed Jan 5 11:29:11 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id B799B10656C0; Wed, 5 Jan 2011 11:29:10 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 531788FC14; Wed, 5 Jan 2011 11:29:10 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05BTAIR076200; Wed, 5 Jan 2011 11:29:10 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05BTAVs076198; Wed, 5 Jan 2011 11:29:10 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051129.p05BTAVs076198@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 11:29:10 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216990 - stable/7/sys/sparc64/sparc64 X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 11:29:11 -0000 Author: marius Date: Wed Jan 5 11:29:10 2011 New Revision: 216990 URL: http://svn.freebsd.org/changeset/base/216990 Log: MFC: r216891 Extend the section in which interrupts are disabled in the TLB demap functions, otherwise if we get preempted after checking whether a certain pmap is active on the current CPU but before disabling interrupts we might operate on an outdated state as the pmap might have been deactivated in the meantime. As the same issue may arises when the TLB demap function is interrupted by a TLB demap IPI, just entering a critical section before the check isn't sufficient so we have to fully disable interrupts instead. Modified: stable/7/sys/sparc64/sparc64/tlb.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/sparc64/sparc64/tlb.c ============================================================================== --- stable/7/sys/sparc64/sparc64/tlb.c Wed Jan 5 11:29:07 2011 (r216989) +++ stable/7/sys/sparc64/sparc64/tlb.c Wed Jan 5 11:29:10 2011 (r216990) @@ -80,15 +80,15 @@ tlb_context_demap(struct pmap *pm) */ PMAP_STATS_INC(tlb_ncontext_demap); cookie = ipi_tlb_context_demap(pm); + s = intr_disable(); if (pm->pm_active & PCPU_GET(cpumask)) { KASSERT(pm->pm_context[curcpu] != -1, ("tlb_context_demap: inactive pmap?")); - s = intr_disable(); stxa(TLB_DEMAP_PRIMARY | TLB_DEMAP_CONTEXT, ASI_DMMU_DEMAP, 0); stxa(TLB_DEMAP_PRIMARY | TLB_DEMAP_CONTEXT, ASI_IMMU_DEMAP, 0); flush(KERNBASE); - intr_restore(s); } + intr_restore(s); ipi_wait(cookie); } @@ -101,6 +101,7 @@ tlb_page_demap(struct pmap *pm, vm_offse PMAP_STATS_INC(tlb_npage_demap); cookie = ipi_tlb_page_demap(pm, va); + s = intr_disable(); if (pm->pm_active & PCPU_GET(cpumask)) { KASSERT(pm->pm_context[curcpu] != -1, ("tlb_page_demap: inactive pmap?")); @@ -109,12 +110,11 @@ tlb_page_demap(struct pmap *pm, vm_offse else flags = TLB_DEMAP_PRIMARY | TLB_DEMAP_PAGE; - s = intr_disable(); stxa(TLB_DEMAP_VA(va) | flags, ASI_DMMU_DEMAP, 0); stxa(TLB_DEMAP_VA(va) | flags, ASI_IMMU_DEMAP, 0); flush(KERNBASE); - intr_restore(s); } + intr_restore(s); ipi_wait(cookie); } @@ -128,6 +128,7 @@ tlb_range_demap(struct pmap *pm, vm_offs PMAP_STATS_INC(tlb_nrange_demap); cookie = ipi_tlb_range_demap(pm, start, end); + s = intr_disable(); if (pm->pm_active & PCPU_GET(cpumask)) { KASSERT(pm->pm_context[curcpu] != -1, ("tlb_range_demap: inactive pmap?")); @@ -136,13 +137,12 @@ tlb_range_demap(struct pmap *pm, vm_offs else flags = TLB_DEMAP_PRIMARY | TLB_DEMAP_PAGE; - s = intr_disable(); for (va = start; va < end; va += PAGE_SIZE) { stxa(TLB_DEMAP_VA(va) | flags, ASI_DMMU_DEMAP, 0); stxa(TLB_DEMAP_VA(va) | flags, ASI_IMMU_DEMAP, 0); flush(KERNBASE); } - intr_restore(s); } + intr_restore(s); ipi_wait(cookie); } From owner-svn-src-stable-7@FreeBSD.ORG Wed Jan 5 11:43:18 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 4D657106566C; Wed, 5 Jan 2011 11:43:18 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 24C698FC18; Wed, 5 Jan 2011 11:43:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05BhI8V076570; Wed, 5 Jan 2011 11:43:18 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05BhIBk076568; Wed, 5 Jan 2011 11:43:18 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051143.p05BhIBk076568@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 11:43:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216992 - stable/7/sys/dev/bge X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 11:43:18 -0000 Author: marius Date: Wed Jan 5 11:43:17 2011 New Revision: 216992 URL: http://svn.freebsd.org/changeset/base/216992 Log: MFC: r216085 - Remove the remaining support for older (in this case pre-7.0-RELEASE) versions of FreeBSD. In fact we are already missing a lot of conditional code necessary to support older versions of FreeBSD, including alternatives for vital functionality not yet provided by the respective subsystem back then (see for example r199663). So this change shouldn't actually break this driver on versions of FreeBSD that were supported before. Besides, this driver also isn't maintained as an multi-release version outside of the main repository, so removing the conditional code shouldn't be a problem in that regard either. - Sprinkle some more const on tables. Modified: stable/7/sys/dev/bge/if_bge.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/dev/bge/if_bge.c ============================================================================== --- stable/7/sys/dev/bge/if_bge.c Wed Jan 5 11:43:17 2011 (r216991) +++ stable/7/sys/dev/bge/if_bge.c Wed Jan 5 11:43:17 2011 (r216992) @@ -139,7 +139,7 @@ MODULE_DEPEND(bge, miibus, 1, 1, 1); static const struct bge_type { uint16_t bge_vid; uint16_t bge_did; -} bge_devs[] = { +} const bge_devs[] = { { ALTEON_VENDORID, ALTEON_DEVICEID_BCM5700 }, { ALTEON_VENDORID, ALTEON_DEVICEID_BCM5701 }, @@ -232,7 +232,7 @@ static const struct bge_type { static const struct bge_vendor { uint16_t v_id; const char *v_name; -} bge_vendors[] = { +} const bge_vendors[] = { { ALTEON_VENDORID, "Alteon" }, { ALTIMA_VENDORID, "Altima" }, { APPLE_VENDORID, "Apple" }, @@ -247,7 +247,7 @@ static const struct bge_vendor { static const struct bge_revision { uint32_t br_chipid; const char *br_name; -} bge_revisions[] = { +} const bge_revisions[] = { { BGE_CHIPID_BCM5700_A0, "BCM5700 A0" }, { BGE_CHIPID_BCM5700_A1, "BCM5700 A1" }, { BGE_CHIPID_BCM5700_B0, "BCM5700 B0" }, @@ -317,7 +317,7 @@ static const struct bge_revision { * Some defaults for major revisions, so that newer steppings * that we don't know about have a shot at working. */ -static const struct bge_revision bge_majorrevs[] = { +static const struct bge_revision const bge_majorrevs[] = { { BGE_ASICREV_BCM5700, "unknown BCM5700" }, { BGE_ASICREV_BCM5701, "unknown BCM5701" }, { BGE_ASICREV_BCM5703, "unknown BCM5703" }, @@ -2143,20 +2143,21 @@ bge_lookup_vendor(uint16_t vid) static int bge_probe(device_t dev) { - const struct bge_type *t = bge_devs; + char buf[96]; + char model[64]; + const struct bge_revision *br; + const char *pname; struct bge_softc *sc = device_get_softc(dev); - uint16_t vid, did; + const struct bge_type *t = bge_devs; + const struct bge_vendor *v; + uint32_t id; + uint16_t did, vid; sc->bge_dev = dev; vid = pci_get_vendor(dev); did = pci_get_device(dev); while(t->bge_vid != 0) { if ((vid == t->bge_vid) && (did == t->bge_did)) { - char model[64], buf[96]; - const struct bge_revision *br; - const struct bge_vendor *v; - uint32_t id; - id = pci_read_config(dev, BGE_PCI_MISC_CTL, 4) >> BGE_PCIMISCCTL_ASICREV_SHIFT; if (BGE_ASICREV(id) == BGE_ASICREV_USE_PRODID_REG) { @@ -2177,20 +2178,13 @@ bge_probe(device_t dev) } br = bge_lookup_rev(id); v = bge_lookup_vendor(vid); - { -#if __FreeBSD_version > 700024 - const char *pname; - - if (bge_has_eaddr(sc) && - pci_get_vpd_ident(dev, &pname) == 0) - snprintf(model, 64, "%s", pname); - else -#endif - snprintf(model, 64, "%s %s", - v->v_name, - br != NULL ? br->br_name : - "NetXtreme Ethernet Controller"); - } + if (bge_has_eaddr(sc) && + pci_get_vpd_ident(dev, &pname) == 0) + snprintf(model, 64, "%s", pname); + else + snprintf(model, 64, "%s %s", v->v_name, + br != NULL ? br->br_name : + "NetXtreme Ethernet Controller"); snprintf(buf, 96, "%s, %sASIC rev. %#08x", model, br != NULL ? "" : "unknown ", id); device_set_desc_copy(dev, buf); @@ -3167,7 +3161,6 @@ again: /* * Hookup IRQ last. */ -#if __FreeBSD_version > 700030 if (BGE_IS_5755_PLUS(sc) && sc->bge_flags & BGE_FLAG_MSI) { /* Take advantage of single-shot MSI. */ CSR_WRITE_4(sc, BGE_MSI_MODE, CSR_READ_4(sc, BGE_MSI_MODE) & @@ -3191,10 +3184,6 @@ again: error = bus_setup_intr(dev, sc->bge_irq, INTR_TYPE_NET | INTR_MPSAFE, NULL, bge_intr, sc, &sc->bge_intrhand); -#else - error = bus_setup_intr(dev, sc->bge_irq, INTR_TYPE_NET | INTR_MPSAFE, - bge_intr, sc, &sc->bge_intrhand); -#endif if (error) { bge_detach(dev); @@ -3643,14 +3632,8 @@ bge_rxeof(struct bge_softc *sc, uint16_t * attach that information to the packet. */ if (have_tag) { -#if __FreeBSD_version > 700022 m->m_pkthdr.ether_vtag = vlan_tag; m->m_flags |= M_VLANTAG; -#else - VLAN_INPUT_TAG_NEW(ifp, m, vlan_tag); - if (m == NULL) - continue; -#endif } if (holdlck != 0) { @@ -4452,21 +4435,10 @@ bge_encap(struct bge_softc *sc, struct m bus_dmamap_sync(sc->bge_cdata.bge_tx_mtag, map, BUS_DMASYNC_PREWRITE); -#if __FreeBSD_version > 700022 if (m->m_flags & M_VLANTAG) { csum_flags |= BGE_TXBDFLAG_VLAN_TAG; vlan_tag = m->m_pkthdr.ether_vtag; } -#else - { - struct m_tag *mtag; - - if ((mtag = VLAN_OUTPUT_TAG(sc->bge_ifp, m)) != NULL) { - csum_flags |= BGE_TXBDFLAG_VLAN_TAG; - vlan_tag = VLAN_TAG_VALUE(mtag); - } - } -#endif for (i = 0; ; i++) { d = &sc->bge_ldata.bge_tx_ring[idx]; d->bge_addr.bge_addr_lo = BGE_ADDR_LO(segs[i].ds_addr); From owner-svn-src-stable-7@FreeBSD.ORG Wed Jan 5 11:46:18 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 60D88106566C; Wed, 5 Jan 2011 11:46:18 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4F5A68FC12; Wed, 5 Jan 2011 11:46:18 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05BkId1076742; Wed, 5 Jan 2011 11:46:18 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05BkIop076740; Wed, 5 Jan 2011 11:46:18 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051146.p05BkIop076740@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 11:46:18 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216994 - stable/7/sys/dev/mii X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 11:46:18 -0000 Author: marius Date: Wed Jan 5 11:46:18 2011 New Revision: 216994 URL: http://svn.freebsd.org/changeset/base/216994 Log: MFC: r216623 - Add a comment regarding the fact that as documented in the datasheet manual 1000BASE-T modes of DP83865 only work together with other National Semiconductor PHYs. - Spell 10BASE-T correctly - Remove some redundant braces. Modified: stable/7/sys/dev/mii/nsgphy.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/dev/mii/nsgphy.c ============================================================================== --- stable/7/sys/dev/mii/nsgphy.c Wed Jan 5 11:46:17 2011 (r216993) +++ stable/7/sys/dev/mii/nsgphy.c Wed Jan 5 11:46:18 2011 (r216994) @@ -140,11 +140,15 @@ nsgphy_attach(device_t dev) mii_phy_reset(sc); /* - * NB: the PHY has the 10baseT BMSR bits hard-wired to 0, - * even though it supports 10baseT. + * NB: the PHY has the 10BASE-T BMSR bits hard-wired to 0, + * even though it supports 10BASE-T. */ sc->mii_capabilities = (PHY_READ(sc, MII_BMSR) | - (BMSR_10TFDX | BMSR_10THDX)) & ma->mii_capmask; + BMSR_10TFDX | BMSR_10THDX) & ma->mii_capmask; + /* + * Note that as documented manual 1000BASE-T modes of DP83865 only + * work together with other National Semiconductor PHYs. + */ if (sc->mii_capabilities & BMSR_EXTSTAT) sc->mii_extcapabilities = PHY_READ(sc, MII_EXTSR); From owner-svn-src-stable-7@FreeBSD.ORG Wed Jan 5 12:05:31 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id E463A106564A; Wed, 5 Jan 2011 12:05:31 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B31118FC15; Wed, 5 Jan 2011 12:05:31 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05C5VBK077309; Wed, 5 Jan 2011 12:05:31 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05C5VUq077306; Wed, 5 Jan 2011 12:05:31 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051205.p05C5VUq077306@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 12:05:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216997 - in stable/7/sys/sparc64: include sparc64 X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 12:05:32 -0000 Author: marius Date: Wed Jan 5 12:05:31 2011 New Revision: 216997 URL: http://svn.freebsd.org/changeset/base/216997 Log: MFC: r216628 Extend the hack of r182730 (MFC'ed to stable/7 in r190033) to trick GAS/GCC into compiling access to STICK/STICK_COMPARE independently of the selected instruction set by TICK_COMPARE so tick.c once again can be compiled with gcc -mcpu=v9 for reference purposes. Modified: stable/7/sys/sparc64/include/cpufunc.h stable/7/sys/sparc64/sparc64/tick.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/sparc64/include/cpufunc.h ============================================================================== --- stable/7/sys/sparc64/include/cpufunc.h Wed Jan 5 12:05:27 2011 (r216996) +++ stable/7/sys/sparc64/include/cpufunc.h Wed Jan 5 12:05:31 2011 (r216997) @@ -174,11 +174,13 @@ int fasword32(u_long asi, void *addr, ui } while (0) /* - * Trick GAS/GCC into compiling access to STICK/STICK_COMPARE independently + * Trick GAS/GCC into compiling access to TICK/(S)TICK_COMPARE independently * of the selected instruction set. */ +#define rdtickcmpr() rd(asr23) #define rdstick() rd(asr24) #define rdstickcmpr() rd(asr25) +#define wrtickcmpr(val, xor) wr(asr23, (val), (xor)) #define wrstick(val, xor) wr(asr24, (val), (xor)) #define wrstickcmpr(val, xor) wr(asr25, (val), (xor)) @@ -191,7 +193,7 @@ int fasword32(u_long asi, void *addr, ui * aligned to a quadword boundary in order to ensure that I$ misses won't * split them up. */ -#define wrtickcmpr(val, xor) ({ \ +#define wrtickcmpr_bbwar(val, xor) ({ \ __asm __volatile( \ " ba,pt %%xcc, 1f ; " \ " nop ; " \ Modified: stable/7/sys/sparc64/sparc64/tick.c ============================================================================== --- stable/7/sys/sparc64/sparc64/tick.c Wed Jan 5 12:05:27 2011 (r216996) +++ stable/7/sys/sparc64/sparc64/tick.c Wed Jan 5 12:05:31 2011 (r216997) @@ -222,7 +222,7 @@ tick_hardclock(struct trapframe *tf) adj = PCPU_GET(tickadj); s = intr_disable(); tick = rd(tick); - wr(tick_cmpr, tick + tick_increment - adj, 0); + wrtickcmpr(tick + tick_increment - adj, 0); intr_restore(s); tick_hardclock_common(tf, tick, adj); critical_exit(); @@ -238,7 +238,7 @@ tick_hardclock_bbwar(struct trapframe *t adj = PCPU_GET(tickadj); s = intr_disable(); tick = rd(tick); - wrtickcmpr(tick + tick_increment - adj, 0); + wrtickcmpr_bbwar(tick + tick_increment - adj, 0); intr_restore(s); tick_hardclock_common(tf, tick, adj); critical_exit(); From owner-svn-src-stable-7@FreeBSD.ORG Wed Jan 5 12:20:56 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 3227210656F6; Wed, 5 Jan 2011 12:20:55 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 7BEC18FC18; Wed, 5 Jan 2011 12:20:55 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05CKttS077792; Wed, 5 Jan 2011 12:20:55 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05CKtqs077790; Wed, 5 Jan 2011 12:20:55 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051220.p05CKtqs077790@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 12:20:55 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r216999 - stable/7/sys/sparc64/include X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 12:20:56 -0000 Author: marius Date: Wed Jan 5 12:20:55 2011 New Revision: 216999 URL: http://svn.freebsd.org/changeset/base/216999 Log: MFC: r216801 Rename the "xor" parameter to "xorval" as the former is a reserved keyword in C++. Submitted by: gahr Modified: stable/7/sys/sparc64/include/cpufunc.h Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/sparc64/include/cpufunc.h ============================================================================== --- stable/7/sys/sparc64/include/cpufunc.h Wed Jan 5 12:20:53 2011 (r216998) +++ stable/7/sys/sparc64/include/cpufunc.h Wed Jan 5 12:20:55 2011 (r216999) @@ -157,9 +157,9 @@ int fasword32(u_long asi, void *addr, ui __sr; \ }) -#define wr(name, val, xor) do { \ +#define wr(name, val, xorval) do { \ __asm __volatile("wr %0, %1, %%" #name \ - : : "r" (val), "rI" (xor)); \ + : : "r" (val), "rI" (xorval)); \ } while (0) #define rdpr(name) ({ \ @@ -168,24 +168,24 @@ int fasword32(u_long asi, void *addr, ui __pr; \ }) -#define wrpr(name, val, xor) do { \ +#define wrpr(name, val, xorval) do { \ __asm __volatile("wrpr %0, %1, %%" #name \ - : : "r" (val), "rI" (xor)); \ + : : "r" (val), "rI" (xorval)); \ } while (0) /* * Trick GAS/GCC into compiling access to TICK/(S)TICK_COMPARE independently * of the selected instruction set. */ -#define rdtickcmpr() rd(asr23) -#define rdstick() rd(asr24) -#define rdstickcmpr() rd(asr25) -#define wrtickcmpr(val, xor) wr(asr23, (val), (xor)) -#define wrstick(val, xor) wr(asr24, (val), (xor)) -#define wrstickcmpr(val, xor) wr(asr25, (val), (xor)) +#define rdtickcmpr() rd(asr23) +#define rdstick() rd(asr24) +#define rdstickcmpr() rd(asr25) +#define wrtickcmpr(val, xorval) wr(asr23, (val), (xorval)) +#define wrstick(val, xorval) wr(asr24, (val), (xorval)) +#define wrstickcmpr(val, xorval) wr(asr25, (val), (xorval)) /* - * Macro intended to be used instead of wr(asr23, val, xor) for writing to + * Macro intended to be used instead of wr(asr23, val, xorval) for writing to * the TICK_COMPARE register in order to avoid a bug in BlackBird CPUs that * can cause these writes to fail under certain condidtions which in turn * causes the hardclock to stop. The workaround is to read the TICK_COMPARE @@ -193,14 +193,14 @@ int fasword32(u_long asi, void *addr, ui * aligned to a quadword boundary in order to ensure that I$ misses won't * split them up. */ -#define wrtickcmpr_bbwar(val, xor) ({ \ +#define wrtickcmpr_bbwar(val, xorval) ({ \ __asm __volatile( \ " ba,pt %%xcc, 1f ; " \ " nop ; " \ " .align 128 ; " \ "1: wr %0, %1, %%asr23 ; " \ " rd %%asr23, %%g0 ; " \ - : : "r" (val), "rI" (xor)); \ + : : "r" (val), "rI" (xorval)); \ }) static __inline void From owner-svn-src-stable-7@FreeBSD.ORG Wed Jan 5 12:27:57 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 7E83510657C3; Wed, 5 Jan 2011 12:27:57 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 6BCCD8FC14; Wed, 5 Jan 2011 12:27:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05CRvfm078074; Wed, 5 Jan 2011 12:27:57 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05CRvAF078071; Wed, 5 Jan 2011 12:27:57 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051227.p05CRvAF078071@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 12:27:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217001 - in stable/7/sys/sparc64: include sparc64 X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 12:27:57 -0000 Author: marius Date: Wed Jan 5 12:27:57 2011 New Revision: 217001 URL: http://svn.freebsd.org/changeset/base/217001 Log: MFC: r216802 - Move the macros for generating load and store instructions to asmacros.h so they can be shared by different source files and extend them by a variant for atomic compare and swap. - Consistently use EMPTY. Modified: stable/7/sys/sparc64/include/asmacros.h stable/7/sys/sparc64/sparc64/support.S Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/sparc64/include/asmacros.h ============================================================================== --- stable/7/sys/sparc64/include/asmacros.h Wed Jan 5 12:27:52 2011 (r217000) +++ stable/7/sys/sparc64/include/asmacros.h Wed Jan 5 12:27:57 2011 (r217001) @@ -33,7 +33,7 @@ /* * Normal and alternate %g6 point to the pcb of the current process. Normal, - & alternate and interrupt %g7 point to per-cpu data. + * alternate and interrupt %g7 point to per-cpu data. */ #define PCB_REG %g6 #define PCPU_REG %g7 @@ -134,6 +134,19 @@ name: #define EMPTY +/* + * Generate atomic compare and swap, load and store instructions for the + * corresponding width and ASI (or not). Note that we want to evaluate the + * macro args before concatenating, so that EMPTY really turns into nothing. + */ +#define _LD(w, a) ld ## w ## a +#define _ST(w, a) st ## w ## a +#define _CAS(w, a) cas ## w ## a + +#define LD(w, a) _LD(w, a) +#define ST(w, a) _ST(w, a) +#define CAS(w, a) _CAS(w, a) + #endif /* LOCORE */ #endif /* _KERNEL */ Modified: stable/7/sys/sparc64/sparc64/support.S ============================================================================== --- stable/7/sys/sparc64/sparc64/support.S Wed Jan 5 12:27:52 2011 (r217000) +++ stable/7/sys/sparc64/sparc64/support.S Wed Jan 5 12:27:57 2011 (r217001) @@ -44,19 +44,6 @@ __FBSDID("$FreeBSD$"); .register %g3, #ignore .register %g6, #ignore -#define E /* empty */ - -/* - * Generate load and store instructions for the corresponding width and asi - * (or not). Note that we want to evaluate the macro args before - * concatenating, so that E really turns into nothing. - */ -#define _LD(w, a) ld ## w ## a -#define _ST(w, a) st ## w ## a - -#define LD(w, a) _LD(w, a) -#define ST(w, a) _ST(w, a) - /* * Common code for copy routines. * @@ -233,7 +220,7 @@ END(ascopy) */ ENTRY(ascopyfrom) wr %o0, 0, %asi - _MEMCPY(%o2, %o1, %o3, E, E, a, %asi) + _MEMCPY(%o2, %o1, %o3, EMPTY, EMPTY, a, %asi) retl nop END(ascopyfrom) @@ -243,7 +230,7 @@ END(ascopyfrom) */ ENTRY(ascopyto) wr %o1, 0, %asi - _MEMCPY(%o2, %o0, %o3, a, %asi, E, E) + _MEMCPY(%o2, %o0, %o3, a, %asi, EMPTY, EMPTY) retl nop END(ascopyto) @@ -307,7 +294,7 @@ ENTRY(bcopy) /* * Do the fast version. */ -3: _MEMCPY(%o1, %o0, %o2, E, E, E, E) +3: _MEMCPY(%o1, %o0, %o2, EMPTY, EMPTY, EMPTY, EMPTY) retl nop END(bcopy) @@ -316,7 +303,7 @@ END(bcopy) * void bzero(void *b, size_t len) */ ENTRY(bzero) - _MEMSET(%o0, %g0, %o1, E, E) + _MEMSET(%o0, %g0, %o1, EMPTY, EMPTY) retl nop END(bzero) @@ -325,7 +312,7 @@ END(bzero) * int copystr(const void *src, void *dst, size_t len, size_t *done) */ ENTRY(copystr) - _COPYSTR(%o0, %o1, %o2, %o3, E, E, E, E) + _COPYSTR(%o0, %o1, %o2, %o3, EMPTY, EMPTY, EMPTY, EMPTY) retl mov %g1, %o0 END(copystr) @@ -335,7 +322,7 @@ END(copystr) */ ENTRY(memcpy) mov %o0, %o3 - _MEMCPY(%o3, %o1, %o2, E, E, E, E) + _MEMCPY(%o3, %o1, %o2, EMPTY, EMPTY, EMPTY, EMPTY) retl nop END(memcpy) @@ -345,7 +332,7 @@ END(memcpy) */ ENTRY(memset) mov %o0, %o3 - _MEMSET(%o3, %o1, %o2, E, E) + _MEMSET(%o3, %o1, %o2, EMPTY, EMPTY) retl nop END(memset) @@ -359,7 +346,7 @@ copy_nofault_begin: */ ENTRY(copyin) wr %g0, ASI_AIUP, %asi - _MEMCPY(%o1, %o0, %o2, E, E, a, %asi) + _MEMCPY(%o1, %o0, %o2, EMPTY, EMPTY, a, %asi) retl clr %o0 END(copyin) @@ -369,7 +356,7 @@ END(copyin) */ ENTRY(copyinstr) wr %g0, ASI_AIUP, %asi - _COPYSTR(%o0, %o1, %o2, %o3, a, %asi, E, E) + _COPYSTR(%o0, %o1, %o2, %o3, a, %asi, EMPTY, EMPTY) retl mov %g1, %o0 END(copyinstr) @@ -379,7 +366,7 @@ END(copyinstr) */ ENTRY(copyout) wr %g0, ASI_AIUP, %asi - _MEMCPY(%o1, %o0, %o2, a, %asi, E, E) + _MEMCPY(%o1, %o0, %o2, a, %asi, EMPTY, EMPTY) retl clr %o0 END(copyout) From owner-svn-src-stable-7@FreeBSD.ORG Wed Jan 5 13:36:59 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D4BC41065674; Wed, 5 Jan 2011 13:36:59 +0000 (UTC) (envelope-from marius@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B9D358FC0C; Wed, 5 Jan 2011 13:36:59 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p05Dax45079723; Wed, 5 Jan 2011 13:36:59 GMT (envelope-from marius@svn.freebsd.org) Received: (from marius@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p05Dax6W079720; Wed, 5 Jan 2011 13:36:59 GMT (envelope-from marius@svn.freebsd.org) Message-Id: <201101051336.p05Dax6W079720@svn.freebsd.org> From: Marius Strobl Date: Wed, 5 Jan 2011 13:36:59 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217005 - in stable/7/share: examples/etc mk X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 05 Jan 2011 13:37:00 -0000 Author: marius Date: Wed Jan 5 13:36:59 2011 New Revision: 217005 URL: http://svn.freebsd.org/changeset/base/217005 Log: MFC: r216820 (partial) Add CPUTYPE support for sparc64. The net result is that it's now possible to let the compiler optimize for the famility of UltraSPARC-III CPUs as the default already was to optimize for UltraSPARC-I/II and generating generic 64-bit V9 is mainly for reference purposes. At least for SPARC64-V CPUs code optimized for UltraSPARC-I/II still is the most performant one. Thanks go to Michael Moll for testing SPARC64-V. Modified: stable/7/share/examples/etc/make.conf stable/7/share/mk/bsd.cpu.mk Directory Properties: stable/7/share/examples/ (props changed) stable/7/share/mk/ (props changed) Modified: stable/7/share/examples/etc/make.conf ============================================================================== --- stable/7/share/examples/etc/make.conf Wed Jan 5 13:26:26 2011 (r217004) +++ stable/7/share/examples/etc/make.conf Wed Jan 5 13:36:59 2011 (r217005) @@ -39,6 +39,8 @@ # Alpha/AXP architecture: ev67 ev6 pca56 ev56 ev5 ev45 ev4 # AMD64 architecture: opteron, athlon64, nocona, prescott, core2 # Intel ia64 architecture: itanium2, itanium +# SPARC-V9 architecture: v9 (generic 64-bit V9), ultrasparc (default +# if omitted), ultrasparc3 # # (?= allows to buildworld for a different CPUTYPE.) # Modified: stable/7/share/mk/bsd.cpu.mk ============================================================================== --- stable/7/share/mk/bsd.cpu.mk Wed Jan 5 13:26:26 2011 (r217004) +++ stable/7/share/mk/bsd.cpu.mk Wed Jan 5 13:36:59 2011 (r217005) @@ -13,6 +13,7 @@ MACHINE_CPU = amd64 sse2 sse mmx . elif ${MACHINE_ARCH} == "ia64" MACHINE_CPU = itanium . elif ${MACHINE_ARCH} == "sparc64" +MACHINE_CPU = ultrasparc . elif ${MACHINE_ARCH} == "arm" MACHINE_CPU = arm . endif @@ -54,6 +55,12 @@ CPUTYPE = athlon . if ${CPUTYPE} == "prescott" || ${CPUTYPE} == "core2" CPUTYPE = nocona . endif +. elif ${MACHINE_ARCH} == "sparc64" +. if ${CPUTYPE} == "us" +CPUTYPE = ultrasparc +. elif ${CPUTYPE} == "us3" +CPUTYPE = ultrasparc3 +. endif . endif ############################################################################### @@ -111,6 +118,14 @@ _CPUCFLAGS = -mcpu=${CPUTYPE} . endif . elif ${MACHINE_ARCH} == "powerpc" _CPUCFLAGS = -mcpu=${CPUTYPE} +. elif ${MACHINE_ARCH} == "sparc64" +. if ${CPUTYPE} == "v9" +_CPUCFLAGS = -mcpu=v9 +. elif ${CPUTYPE} == "ultrasparc" +_CPUCFLAGS = -mcpu=ultrasparc +. elif ${CPUTYPE} == "ultrasparc3" +_CPUCFLAGS = -mcpu=ultrasparc3 +. endif . endif # Set up the list of CPU features based on the CPU type. This is an @@ -167,6 +182,14 @@ MACHINE_CPU += amd64 sse2 sse mmx . if ${CPUTYPE} == "itanium" MACHINE_CPU = itanium . endif +. elif ${MACHINE_ARCH} == "sparc64" +. if ${CPUTYPE} == "v9" +MACHINE_CPU = v9 +. elif ${CPUTYPE} == "ultrasparc" +MACHINE_CPU = v9 ultrasparc +. elif ${CPUTYPE} == "ultrasparc3" +MACHINE_CPU = v9 ultrasparc ultrasparc3 +. endif . endif .endif From owner-svn-src-stable-7@FreeBSD.ORG Fri Jan 7 08:45:57 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 34C5E106564A; Fri, 7 Jan 2011 08:45:57 +0000 (UTC) (envelope-from brian@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 235F88FC13; Fri, 7 Jan 2011 08:45:57 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p078jvdE044829; Fri, 7 Jan 2011 08:45:57 GMT (envelope-from brian@svn.freebsd.org) Received: (from brian@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p078jv2f044827; Fri, 7 Jan 2011 08:45:57 GMT (envelope-from brian@svn.freebsd.org) Message-Id: <201101070845.p078jv2f044827@svn.freebsd.org> From: Brian Somers Date: Fri, 7 Jan 2011 08:45:57 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217089 - stable/7/usr.sbin/newsyslog X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 08:45:57 -0000 Author: brian Date: Fri Jan 7 08:45:56 2011 New Revision: 217089 URL: http://svn.freebsd.org/changeset/base/217089 Log: MFC r216832: Make -S functional Modified: stable/7/usr.sbin/newsyslog/newsyslog.c Directory Properties: stable/7/usr.sbin/newsyslog/ (props changed) Modified: stable/7/usr.sbin/newsyslog/newsyslog.c ============================================================================== --- stable/7/usr.sbin/newsyslog/newsyslog.c Fri Jan 7 08:42:58 2011 (r217088) +++ stable/7/usr.sbin/newsyslog/newsyslog.c Fri Jan 7 08:45:56 2011 (r217089) @@ -583,7 +583,7 @@ parse_args(int argc, char **argv) *p = '\0'; /* Parse command line options. */ - while ((ch = getopt(argc, argv, "a:d:f:nrsvCD:FNPR:")) != -1) + while ((ch = getopt(argc, argv, "a:d:f:nrsvCD:FNPR:S:")) != -1) switch (ch) { case 'a': archtodir++; From owner-svn-src-stable-7@FreeBSD.ORG Fri Jan 7 18:41:32 2011 Return-Path: Delivered-To: svn-src-stable-7@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 74DF01065673; Fri, 7 Jan 2011 18:41:32 +0000 (UTC) (envelope-from jpaetzel@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 63C528FC1F; Fri, 7 Jan 2011 18:41:32 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id p07IfW8j061818; Fri, 7 Jan 2011 18:41:32 GMT (envelope-from jpaetzel@svn.freebsd.org) Received: (from jpaetzel@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p07IfWMG061816; Fri, 7 Jan 2011 18:41:32 GMT (envelope-from jpaetzel@svn.freebsd.org) Message-Id: <201101071841.p07IfWMG061816@svn.freebsd.org> From: Josh Paetzel Date: Fri, 7 Jan 2011 18:41:32 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r217117 - stable/7/etc X-BeenThere: svn-src-stable-7@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 7-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 07 Jan 2011 18:41:32 -0000 Author: jpaetzel (ports committer) Date: Fri Jan 7 18:41:32 2011 New Revision: 217117 URL: http://svn.freebsd.org/changeset/base/217117 Log: MFC 216983: Fix typo in comment. Approved by: Warner Losh Modified: stable/7/etc/devd.conf Directory Properties: stable/7/etc/ (props changed) Modified: stable/7/etc/devd.conf ============================================================================== --- stable/7/etc/devd.conf Fri Jan 7 18:34:09 2011 (r217116) +++ stable/7/etc/devd.conf Fri Jan 7 18:41:32 2011 (r217117) @@ -46,7 +46,7 @@ notify 0 { # # Try to start dhclient on Ethernet like interfaces when the link comes # up. Only devices that are configured to support DHCP will actually -# run it. No link down rule exists because dhclient automaticly exits +# run it. No link down rule exists because dhclient automatically exits # when the link goes down. # notify 0 {