On Wed, Nov 09, 2016 at 01:41:30PM +0100, Petr Mladek wrote:
> The commit 4bcc595ccd80decb4245096e ("printk: reinstate KERN_CONT for
> printing continuation lines") allows to define more message headers
> for a single message. The motivation is that continuous lines might
> get mixed. Therefore it make sense to define the right log level
> for every piece of a cont line.
> 
> The current btrfs_printk() macros do not support continuous lines
> at the moment. But better be prepared for a custom messages and
> avoid potential "lvl" buffer overflow.
> 
> This patch iterates over the entire message header. It is interested
> only into the message level like the original code.
> 
> This patch also introduces PRINTK_MAX_SINGLE_HEADER_LEN. Three bytes
> are enough for the message level header at the moment. But it used to
> be three, see the commit 04d2c8c83d0e3ac5f ("printk: convert the format
> for KERN_<LEVEL> to a 2 byte pattern").
> 
> Also I fixed the default ratelimit level. It looked very strange
> when it was different from the default log level.
> 
> Signed-off-by: Petr Mladek <pmla...@suse.com>

Acked-by: David Sterba <dste...@suse.com>

Reply via email to