From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1D4EE7-0001Au-KG for mharc-grub-devel@gnu.org; Thu, 24 Feb 2005 03:20:05 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1D4EDx-00016N-Lr for grub-devel@gnu.org; Thu, 24 Feb 2005 03:19:53 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1D4EDr-000127-AN for grub-devel@gnu.org; Thu, 24 Feb 2005 03:19:48 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1D4EDr-000112-36 for grub-devel@gnu.org; Thu, 24 Feb 2005 03:19:47 -0500 Received: from [217.12.11.33] (helo=smtp002.mail.ukl.yahoo.com) by monty-python.gnu.org with smtp (Exim 4.34) id 1D4Dwm-0006mD-F8 for grub-devel@gnu.org; Thu, 24 Feb 2005 03:02:08 -0500 Received: from unknown (HELO ?192.168.0.2?) (subdino2004@83.194.33.1 with plain) by smtp002.mail.ukl.yahoo.com with SMTP; 24 Feb 2005 08:02:07 -0000 Message-ID: <421D89FF.9010508@yahoo.fr> Date: Thu, 24 Feb 2005 09:02:07 +0100 From: Vincent Pelletier User-Agent: Debian Thunderbird 1.0 (X11/20050116) X-Accept-Language: en-us, en MIME-Version: 1.0 To: The development of GRUB 2 References: <421A4CEA.5030603@yahoo.fr> <4ecefea8af9852b4ed0a0b046d73e9ee@penguinppc.org> In-Reply-To: <4ecefea8af9852b4ed0a0b046d73e9ee@penguinppc.org> X-Enigmail-Version: 0.90.0.0 X-Enigmail-Supports: pgp-inline, pgp-mime Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [PATCH] dprintf implementation X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 24 Feb 2005 08:19:58 -0000 Hollis Blanchard wrote: > Your mailer did some bad stuff to this patch again... Argh. I wonder if it is because I sign my mails... > Weren't we going to have various flags to selectively enable debug > messages from particular components at runtime? Iirc there were differences of point of view on that matter. Okuji, what do you think about that idea ? What about something like : GRUB> DEBUG=D_PARTMAP|D_FS GRUB> DEBUG_OUTPUT=D_SCREEN GRUB> command_to_be_watched file.c,line (D_PARTMAP): Partmap of type 'foo' found. file2.c,line (D_FS): Superblock valid, fs 'bar'. [...] I see those points to be done : - define | operator - name-to-value conversion for constants (case-sensitive ?) - value-to-name conversion for constants What about modules ? It should be good to make them able to add new error constants (maybe only one per module ?) that would match their own dprintf. Here are some prototypes as I think of them: char *grub_debug_constants[sizeof(grub_debug_mask)*8]; int grub_debug_constant_request (const char *name); return value : -1 = no more available bit, -2 = duplicate name, otherwise 1<