From owner-svn-src-stable-7@FreeBSD.ORG Sun Apr 12 23:10:02 2009 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 06988106566B; Sun, 12 Apr 2009 23:10:02 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C97848FC1B; Sun, 12 Apr 2009 23:10:01 +0000 (UTC) (envelope-from sobomax@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id n3CNA1Rx044139; Sun, 12 Apr 2009 23:10:01 GMT (envelope-from sobomax@svn.freebsd.org) Received: (from sobomax@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id n3CNA1Ei044138; Sun, 12 Apr 2009 23:10:01 GMT (envelope-from sobomax@svn.freebsd.org) Message-Id: <200904122310.n3CNA1Ei044138@svn.freebsd.org> From: Maxim Sobolev Date: Sun, 12 Apr 2009 23:10:01 +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: r190981 - in stable/7/sys: . boot/i386/btx/btxldr contrib/pf dev/cxgb 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, 12 Apr 2009 23:10:02 -0000 Author: sobomax Date: Sun Apr 12 23:10:01 2009 New Revision: 190981 URL: http://svn.freebsd.org/changeset/base/190981 Log: MFC: Respect RBX_MUTE flag from boot[012]. Approved by: re (kib) Modified: stable/7/sys/ (props changed) stable/7/sys/boot/i386/btx/btxldr/btxldr.S stable/7/sys/contrib/pf/ (props changed) stable/7/sys/dev/cxgb/ (props changed) Modified: stable/7/sys/boot/i386/btx/btxldr/btxldr.S ============================================================================== --- stable/7/sys/boot/i386/btx/btxldr/btxldr.S Sun Apr 12 23:06:23 2009 (r190980) +++ stable/7/sys/boot/i386/btx/btxldr/btxldr.S Sun Apr 12 23:10:01 2009 (r190981) @@ -15,6 +15,9 @@ * $FreeBSD$ */ +#define RBX_MUTE 0x10 /* -m */ +#define OPT_SET(opt) (1 << (opt)) + /* * Prototype BTX loader program, written in a couple of hours. The * real thing should probably be more flexible, and in C. @@ -64,6 +67,8 @@ * BTX program loader for ELF clients. */ start: cld # String ops inc + testl $OPT_SET(RBX_MUTE), 4(%esp) # Check first argument + setnz muted # for RBX_MUTE, set flag movl $m_logo,%esi # Identify call putstr # ourselves movzwl BDA_MEM,%eax # Get base memory @@ -288,7 +293,9 @@ putstr: lodsb # Load char /* * Output character AL to the console. */ -putchr: pusha # Save +putchr: testb $1,muted # Check muted + jnz putchr.5 # do a nop + pusha # Save xorl %ecx,%ecx # Zero for loops movb $SCR_MAT,%ah # Mode/attribute movl $BDA_POS,%ebx # BDA pointer @@ -325,7 +332,7 @@ putchr.3: cmpb $SCR_ROW,%dh # Beyond sc movb $SCR_ROW-1,%dh # Bottom line putchr.4: movw %dx,(%ebx) # Update position popa # Restore - ret # To caller +putchr.5: ret # To caller /* * Convert EAX, AX, or AL to hex, saving the result to [EDI]. */ @@ -390,6 +397,12 @@ m_segs: .asciz "text segment: offset=" .asciz " memsz=\0\n" m_done: .asciz "Loading complete\n" #endif + +/* + * Flags + */ +muted: .byte 0x0 + /* * Uninitialized data area. */