From nobody@FreeBSD.org  Fri Sep  3 09:40:54 2010
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34])
	by hub.freebsd.org (Postfix) with ESMTP id 3486310656DD
	for <freebsd-gnats-submit@FreeBSD.org>; Fri,  3 Sep 2010 09:40:54 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from www.freebsd.org (www.freebsd.org [IPv6:2001:4f8:fff6::21])
	by mx1.freebsd.org (Postfix) with ESMTP id 245D78FC23
	for <freebsd-gnats-submit@FreeBSD.org>; Fri,  3 Sep 2010 09:40:54 +0000 (UTC)
Received: from www.freebsd.org (localhost [127.0.0.1])
	by www.freebsd.org (8.14.3/8.14.3) with ESMTP id o839erKi088297
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 3 Sep 2010 09:40:53 GMT
	(envelope-from nobody@www.freebsd.org)
Received: (from nobody@localhost)
	by www.freebsd.org (8.14.3/8.14.3/Submit) id o839er2R088274;
	Fri, 3 Sep 2010 09:40:53 GMT
	(envelope-from nobody)
Message-Id: <201009030940.o839er2R088274@www.freebsd.org>
Date: Fri, 3 Sep 2010 09:40:53 GMT
From: Roddi <roddi@me.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: gpart bootcode displays highly ambiguous message
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         150239
>Category:       bin
>Synopsis:       [geom_part] [patch] gpart(8) bootcode displays highly ambiguous message
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pjd
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Sep 03 09:50:05 UTC 2010
>Closed-Date:    Sat Oct 02 22:27:10 UTC 2010
>Last-Modified:  Sat Oct 02 22:27:10 UTC 2010
>Originator:     Roddi
>Release:        8.1 i386
>Organization:
>Environment:
>Description:
# gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ad10

returns

"ad10s1 has bootcode"

Which could either mean 

(1) "ad10s1 already has bootcode. I wont overwrite that!"

or

(2) "bootcode was written to ad10s1"

It's not very obvious that (2) is the case. 

Please change the return string to (2)

>How-To-Repeat:
# gpart bootcode -b /boot/pmbr -p /boot/gptzfsboot -i 1 ad10

>Fix:
Change the return string to "bootcode was written to %s"


>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-bugs->freebsd-geom 
Responsible-Changed-By: arundel 
Responsible-Changed-When: Fri Sep 3 17:01:01 UTC 2010 
Responsible-Changed-Why:  
Assign to maintainer(s). 
+1 from me on this PR. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=150239 
State-Changed-From-To: open->analyzed 
State-Changed-By: arundel 
State-Changed-When: Sun Sep 5 15:43:27 UTC 2010 
State-Changed-Why:  
Wording in g_part.c isn't precise enough. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=150239 

From: Alexander Best <arundel@freebsd.org>
To: bug-followup@freebsd.org
Cc:  
Subject: Re: bin/150239: gpart bootcode displays highly ambiguous message
Date: Sun, 5 Sep 2010 15:42:33 +0000

 --lrZ03NoBR/3+SXJZ
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: inline
 
 this patch changes the output like you suggested. also my editor discovered an
 unnecessary space in g_part.c ;)
 
 cheers.
 alex
 
 -- 
 a13x
 
 --lrZ03NoBR/3+SXJZ
 Content-Type: text/plain; charset=us-ascii
 Content-Disposition: attachment; filename="g_part.c.diff"
 
 diff --git a/sys/geom/part/g_part.c b/sys/geom/part/g_part.c
 index b9fca08..5efe7ef 100644
 --- a/sys/geom/part/g_part.c
 +++ b/sys/geom/part/g_part.c
 @@ -571,7 +571,7 @@ g_part_ctl_bootcode(struct gctl_req *req, struct g_part_parms *gpp)
  	/* Provide feedback if so requested. */
  	if (gpp->gpp_parms & G_PART_PARM_OUTPUT) {
  		sb = sbuf_new_auto();
 -		sbuf_printf(sb, "%s has bootcode\n", gp->name);
 +		sbuf_printf(sb, "bootcode was written to %s\n", gp->name);
  		sbuf_finish(sb);
  		gctl_set_param(req, "output", sbuf_data(sb), sbuf_len(sb) + 1);
  		sbuf_delete(sb);
 @@ -967,7 +967,7 @@ g_part_ctl_move(struct gctl_req *req, struct g_part_parms *gpp)
  {
  	gctl_error(req, "%d verb 'move'", ENOSYS);
  	return (ENOSYS);
 -} 
 +}
  
  static int
  g_part_ctl_recover(struct gctl_req *req, struct g_part_parms *gpp)
 
 --lrZ03NoBR/3+SXJZ--

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/150239: commit references a PR
Date: Wed, 15 Sep 2010 20:59:21 +0000 (UTC)

 Author: pjd
 Date: Wed Sep 15 20:59:13 2010
 New Revision: 212703
 URL: http://svn.freebsd.org/changeset/base/212703
 
 Log:
   Make the message that informs about bootcode being written to disk less
   confusing.
   
   Note there is still no information about 'partcode' being written to disk
   (gpart bootcode -p <partcode> <disk>).
   
   Maybe in the future all the messages printed by gpart(8) on success could be
   hidden under -v?
   
   PR:		bin/150239
   Reported by:	Roddi <roddi@me.com>
   Submitted by:	arundel
   MFC after:	2 weeks
 
 Modified:
   head/sys/geom/part/g_part.c
 
 Modified: head/sys/geom/part/g_part.c
 ==============================================================================
 --- head/sys/geom/part/g_part.c	Wed Sep 15 20:53:20 2010	(r212702)
 +++ head/sys/geom/part/g_part.c	Wed Sep 15 20:59:13 2010	(r212703)
 @@ -636,7 +636,7 @@ g_part_ctl_bootcode(struct gctl_req *req
  	/* Provide feedback if so requested. */
  	if (gpp->gpp_parms & G_PART_PARM_OUTPUT) {
  		sb = sbuf_new_auto();
 -		sbuf_printf(sb, "%s has bootcode\n", gp->name);
 +		sbuf_printf(sb, "bootcode written to %s\n", gp->name);
  		sbuf_finish(sb);
  		gctl_set_param(req, "output", sbuf_data(sb), sbuf_len(sb) + 1);
  		sbuf_delete(sb);
 @@ -1032,7 +1032,7 @@ g_part_ctl_move(struct gctl_req *req, st
  {
  	gctl_error(req, "%d verb 'move'", ENOSYS);
  	return (ENOSYS);
 -} 
 +}
  
  static int
  g_part_ctl_recover(struct gctl_req *req, struct g_part_parms *gpp)
 _______________________________________________
 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"
 
State-Changed-From-To: analyzed->patched 
State-Changed-By: arundel 
State-Changed-When: Thu Sep 16 19:00:23 UTC 2010 
State-Changed-Why:  
Patched in HEAD (r212703). 


Responsible-Changed-From-To: freebsd-geom->pjd 
Responsible-Changed-By: arundel 
Responsible-Changed-When: Thu Sep 16 19:00:23 UTC 2010 
Responsible-Changed-Why:  
Assign to committer as MFC reminder. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=150239 

From: dfilter@FreeBSD.ORG (dfilter service)
To: bug-followup@FreeBSD.org
Cc:  
Subject: Re: bin/150239: commit references a PR
Date: Sat,  2 Oct 2010 22:16:02 +0000 (UTC)

 Author: ae
 Date: Sat Oct  2 22:15:57 2010
 New Revision: 213374
 URL: http://svn.freebsd.org/changeset/base/213374
 
 Log:
   MFC r212703 (by pjd):
     Make the message that informs about bootcode being written to disk less
     confusing.
   
     Note there is still no information about 'partcode' being written to disk
     (gpart bootcode -p <partcode> <disk>).
   
     Maybe in the future all the messages printed by gpart(8) on success could
     be hidden under -v?
   
     PR:		bin/150239
     Reported by:	Roddi <roddi@me.com>
     Submitted by:	arundel
   
   Approved by:	kib (mentor)
 
 Modified:
   stable/8/sys/geom/part/g_part.c
 Directory Properties:
   stable/8/sys/   (props changed)
   stable/8/sys/amd64/include/xen/   (props changed)
   stable/8/sys/cddl/contrib/opensolaris/   (props changed)
   stable/8/sys/contrib/dev/acpica/   (props changed)
   stable/8/sys/contrib/pf/   (props changed)
   stable/8/sys/dev/xen/xenpci/   (props changed)
 
 Modified: stable/8/sys/geom/part/g_part.c
 ==============================================================================
 --- stable/8/sys/geom/part/g_part.c	Sat Oct  2 22:14:01 2010	(r213373)
 +++ stable/8/sys/geom/part/g_part.c	Sat Oct  2 22:15:57 2010	(r213374)
 @@ -567,7 +567,7 @@ g_part_ctl_bootcode(struct gctl_req *req
  	/* Provide feedback if so requested. */
  	if (gpp->gpp_parms & G_PART_PARM_OUTPUT) {
  		sb = sbuf_new_auto();
 -		sbuf_printf(sb, "%s has bootcode\n", gp->name);
 +		sbuf_printf(sb, "bootcode written to %s\n", gp->name);
  		sbuf_finish(sb);
  		gctl_set_param(req, "output", sbuf_data(sb), sbuf_len(sb) + 1);
  		sbuf_delete(sb);
 @@ -963,7 +963,7 @@ g_part_ctl_move(struct gctl_req *req, st
  {
  	gctl_error(req, "%d verb 'move'", ENOSYS);
  	return (ENOSYS);
 -} 
 +}
  
  static int
  g_part_ctl_recover(struct gctl_req *req, struct g_part_parms *gpp)
 _______________________________________________
 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"
 
State-Changed-From-To: patched->closed 
State-Changed-By: ae 
State-Changed-When: Sat Oct 2 22:25:11 UTC 2010 
State-Changed-Why:  
Merged to stable/8. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=150239 
>Unformatted:
