On Monday, February 04, 2013 3:56:22 pm Andriy Gapon wrote: > on 04/02/2013 21:29 John Baldwin said the following: > > On Sunday, February 03, 2013 4:57:39 am Andriy Gapon wrote: > >> Author: avg > >> Date: Sun Feb 3 09:57:39 2013 > >> New Revision: 246282 > >> URL: http://svnweb.freebsd.org/changeset/base/246282 > >> > >> Log: > >> allow for large KTR_ENTRIES values by allocating ktr_buf using malloc(9) > >> > >> Only during very early boot, before malloc(9) is functional > >> (SI_SUB_KMEM), > >> the static ktr_buf_init is used. Size of the static buffer is determined > >> by a new kernel option KTR_BOOT_ENTRIES. Its default value is 1024. > >> > >> This commit builds on top of r243046. > > > > Does this lose "early" entries once the SYSINIT runs? It doesn't seem to > > make > > any effort to copy the existing entries over to the new buffer? > > Yes, this is true and glebius has also noticed that... > I think that a simple bcopy should be fine here?
Almost. To handle the case where the boot buffer might have wrapped I think you should copy the entries at the "end" into the head of the KTR buffer first, then the entries from the front to the current index, and then update the index to point at the end (it should effectively be KTR_BOOT_ENTRIES I think). -- John Baldwin _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"