Date: Tue, 25 Aug 2009 09:30:57 +0200 From: Ed Schouten <ed@80386.nl> To: Marcel Moolenaar <xcllnt@mac.com> Cc: FreeBSD Arch <arch@freebsd.org> Subject: Re: mtx_lock_do_what_i_mean() Message-ID: <20090825073057.GK2829@hoeg.nl> In-Reply-To: <2678DC6C-3E91-420A-B43D-02E0F1F853C5@mac.com> References: <20090824174050.GI2829@hoeg.nl> <2678DC6C-3E91-420A-B43D-02E0F1F853C5@mac.com>
next in thread | previous in thread | raw e-mail | index | archive | help
--GvuyDaC2GNSBQusT Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable * Marcel Moolenaar <xcllnt@mac.com> wrote: > I would approach the problem differently: decouple printf() in the > kernel from anything to which we have a TTY attached. Instead, look > at printf() as a means to write to the message buffer only. Echoing > things that go into the message buffer to the console becomes 1) > optional (yay!), and 2) something you can do by going through the TTY > layer (use a kthread or use a process [syslog]). Yeah. That would be a lot better, but that means you still need to have a lot of code to make it work properly w.r.t. kernel panics: - When you're in the kernel debugger, you still need to have this synchronous programming interface to print data and read keyboard input. - In this context, you need to add extra code to flush the buffer before printing=20 I think we could look at this approach somewhere in the future, but better not now. I'd rather not debug debugging interfaces. ;-) --=20 Ed Schouten <ed@80386.nl> WWW: http://80386.nl/ --GvuyDaC2GNSBQusT Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iEYEARECAAYFAkqTkzEACgkQ52SDGA2eCwVHSgCeK3STy/if3spb2qUB2tVIiYsJ DhIAn3XXhGkASxQMDNjPlHQYWJSJp242 =Kjko -----END PGP SIGNATURE----- --GvuyDaC2GNSBQusT--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090825073057.GK2829>