From: Randy Dunlap <randy.dunlap@oracle.com>
To: Tejun Heo <htejun@gmail.com>
Cc: linux-kernel@vger.kernel.org, daniel.ritz-ml@swissonline.ch,
jeff@garzik.org, linux-ide@vger.kernel.org
Subject: Re: [PATCH 3/4] printk: implement merging printk
Date: Tue, 15 Jan 2008 19:02:57 -0800 [thread overview]
Message-ID: <20080115190257.f0546a63.randy.dunlap@oracle.com> (raw)
In-Reply-To: <12004452113770-git-send-email-htejun@gmail.com>
On Wed, 16 Jan 2008 10:00:09 +0900 Tejun Heo wrote:
> ---
> include/linux/kernel.h | 71 ++++++++++++++++
> kernel/printk.c | 215 ++++++++++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 286 insertions(+), 0 deletions(-)
>
> diff --git a/include/linux/kernel.h b/include/linux/kernel.h
> index ade3ac9..f92a4a1 100644
> --- a/include/linux/kernel.h
> +++ b/include/linux/kernel.h
> @@ -175,6 +175,29 @@ extern struct pid *session_of_pgrp(struct pid *pgrp);
> extern void dump_thread(struct pt_regs *regs, struct user *dump);
>
> #ifdef CONFIG_PRINTK
> +struct mprintk {
> + char * header;
> + char * body;
> + char * cur;
> + char * prv;
> + char * end;
We aren't very consistent about this, but I think that we would prefer
char *header;
etc. there.
> + int overflowed;
> +};
> +
> +#define MPRINTK_INITIALIZER(_buf, _size) \
> + { \
> + .header = NULL, \
> + .body = _buf, \
> + .cur = _buf, \
> + .prv = NULL, \
> + .end = _buf + _size, \
> + .overflowed = 0, \
> + }
> +
> +#define DEFINE_MPRINTK(name, size) \
> + char __##name##_buf[size]; \
> + struct mprintk name = MPRINTK_INITIALIZER(__##name##_buf, size)
---
~Randy
next prev parent reply other threads:[~2008-01-16 3:05 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-16 1:00 [PATCHSET] printk: implement printk_header() and merging printk Tejun Heo
2008-01-16 1:00 ` [PATCH 1/4] printk: keep log level on multiline messages Tejun Heo
2008-01-16 1:00 ` [PATCH 2/4] printk: implement [v]printk_header() Tejun Heo
2008-01-16 1:00 ` [PATCH 3/4] printk: implement merging printk Tejun Heo
2008-01-16 3:02 ` Randy Dunlap [this message]
2008-01-16 3:08 ` Tejun Heo
2008-01-16 1:00 ` [PATCH 4/4] libata: make libata use printk_header() and mprintk Tejun Heo
2008-01-16 2:48 ` Randy Dunlap
2008-01-16 2:53 ` Tejun Heo
2008-01-16 1:07 ` [PATCHSET] printk: implement printk_header() and merging printk Tejun Heo
2008-01-16 2:48 ` Randy Dunlap
2008-01-16 2:58 ` Tejun Heo
2008-01-18 18:41 ` Matt Mackall
2008-01-18 18:44 ` Matthew Wilcox
2008-01-18 19:06 ` Matt Mackall
2008-01-18 22:58 ` Tejun Heo
2008-01-21 21:42 ` Matt Mackall
2008-01-22 1:00 ` Tejun Heo
2008-01-22 1:28 ` Matt Mackall
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20080115190257.f0546a63.randy.dunlap@oracle.com \
--to=randy.dunlap@oracle.com \
--cc=daniel.ritz-ml@swissonline.ch \
--cc=htejun@gmail.com \
--cc=jeff@garzik.org \
--cc=linux-ide@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox