Bug 28297

Summary: change request for sys/i386/conf/NOTES
Product: Base System Reporter: Giorgos Keramidas <keramida>
Component: kernAssignee: freebsd-bugs (Nobody) <bugs>
Status: Closed FIXED    
Severity: Affects Only Me    
Priority: Normal    
Version: 5.0-CURRENT   
Hardware: Any   
OS: Any   

Description Giorgos Keramidas 2001-06-20 19:10:06 UTC
The NOTES file of 5.0-CURRENT (CVSup'ed yesterday, Tue Jun 19 2001),
says the following in the description of NTIMECOUNTER

    # The default is 5, there is no upper limit but more than a couple
    # of hundred are not productive.

But the value of NTIMECOUNTER in NOTES a few lines below is 20.

    options	NTIMECOUNTER=20

Fix: 

Change either the description to match the default,
or the default to match the description.
How-To-Repeat: 
Well, look at the source of NOTES revision 1.926.
Comment 1 dima 2001-06-20 22:52:25 UTC
Giorgos Keramidas <keramida@ceid.upatras.gr> writes:
> 
> >Number:         28297
> >Category:       kern
> >Synopsis:       change request for sys/i386/conf/NOTES
> >Description:
> 
> The NOTES file of 5.0-CURRENT (CVSup'ed yesterday, Tue Jun 19 2001),
> says the following in the description of NTIMECOUNTER
> 
>     # The default is 5, there is no upper limit but more than a couple
>     # of hundred are not productive.
> 
> But the value of NTIMECOUNTER in NOTES a few lines below is 20.
> 
>     options	NTIMECOUNTER=20
> 
> >Fix:
> 
> Change either the description to match the default,
> or the default to match the description.

NOTES isn't supposed to set the variables to their defaults.  NOTES is
supposed to set variables to values *other* than the default to
potentially catch places where the default is hardcoded in (which
shouldn't be).

> 
> >Release-Note:
> >Audit-Trail:
> >Unformatted:
> 
> To Unsubscribe: send mail to majordomo@FreeBSD.org
> with "unsubscribe freebsd-bugs" in the body of the message
>
Comment 2 Bruce Evans 2001-06-21 06:58:17 UTC
On Thu, 21 Jun 2001, Giorgos Keramidas wrote:

> On Wed, Jun 20, 2001 at 03:20:03PM -0700, Dima Dorfman wrote:
> > NOTES isn't supposed to set the variables to their defaults.  NOTES is
> > supposed to set variables to values *other* than the default to
> > potentially catch places where the default is hardcoded in (which
> > shouldn't be).
> 
> Yes, if NOTES is not supposed to set variables to their defaults, this
> seems reasonable.  Am sure we can close this PR in that case.  The
> comment seemed to indicate that this is the default though.  Perhaps
> we should reword the comment to read something like:
> 
>     The default is 5, although you can set it to any other value (for
>     instance 20) as shown below.

Except the default isn't 5 in -current; it used to be 5; but was changed
to 45 in rev.1.109 of kern_tc.c (the SMPng megacommit).  The log message
for rev.1.09 of course didn't say anything about this change.  It
should have said something like "work around problems caused by extra
interrupt latency in SMPng by incrementing NTIMECOUNTER to 45").

There are many nearby bugs.  E.g, "sysctl -w kern.timecounter.method=1"
isn't a good strategy, and it doesn't exist in -current.

Bruce
Comment 3 Giorgos Keramidas 2001-06-21 17:18:10 UTC
On Thu, Jun 21, 2001 at 03:58:17PM +1000, Bruce Evans wrote:
> On Thu, 21 Jun 2001, Giorgos Keramidas wrote:
> > 
> > Yes, if NOTES is not supposed to set variables to their defaults, this
> > seems reasonable.  Am sure we can close this PR in that case.  The
> > comment seemed to indicate that this is the default though.  Perhaps
> > we should reword the comment to read something like:
> > 
> >     The default is 5, although you can set it to any other value (for
> >     instance 20) as shown below.
> 
> Except the default isn't 5 in -current; it used to be 5; but was changed
> to 45 in rev.1.109 of kern_tc.c (the SMPng megacommit).  The log message
> for rev.1.09 of course didn't say anything about this change.  It
> should have said something like "work around problems caused by extra
> interrupt latency in SMPng by incrementing NTIMECOUNTER to 45").
> 
> There are many nearby bugs.  E.g, "sysctl -w kern.timecounter.method=1"
> isn't a good strategy, and it doesn't exist in -current.

Ahem.  I just checked with `sysctl -a | grep timecounter' and you are
right, as I expected.  Well, if you ask me, NOTES needs to be updated
a bit, but I'm afraid that I dont have all the knowledge it takes.
All I can do is, when I come up with differences in what I see and
whats described in there, to file a PR and say so.

Well, any suggestions for the matter at hand?
The NTIMECOUNTER description in NOTES, I mean.

-giorgos
Comment 4 josef freebsd_committer freebsd_triage 2004-05-16 21:19:27 UTC
State Changed
From-To: open->closed

This option got removed.