From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-10.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 81F36C2B9F7 for ; Wed, 26 May 2021 07:31:09 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 5365A613F6 for ; Wed, 26 May 2021 07:31:09 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233037AbhEZHcj (ORCPT ); Wed, 26 May 2021 03:32:39 -0400 Received: from mx2.suse.de ([195.135.220.15]:43636 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232844AbhEZHch (ORCPT ); Wed, 26 May 2021 03:32:37 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.com; s=susede1; t=1622014266; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=DgjVnjQwWuIMJN9gyvKXhozYyF2i1dVc9TYfJdlrbtE=; b=h4gWB7lfvFS/Wvp3M3kfScyIXDNlL/5VoJdi0lJxVM+8Iht0rEQHMcSJNAvqIuvCDVk8vZ Y9oBahyRtkDVyGyD8xW0wQW3i1epb3E0GxVfgCNPNPQONUIcgbalgLZtqCrCJyPjOEAV09 cnRzNGhiHzeb+arduQz4kdhpOt/MVts= Received: from relay2.suse.de (unknown [195.135.221.27]) by mx2.suse.de (Postfix) with ESMTP id E5DB1AD54; Wed, 26 May 2021 07:31:05 +0000 (UTC) Date: Wed, 26 May 2021 09:31:05 +0200 From: Petr Mladek To: John Ogness Cc: Chris Down , linux-kernel@vger.kernel.org, Jessica Yu , Sergey Senozhatsky , Steven Rostedt , Greg Kroah-Hartman , Johannes Weiner , Kees Cook , Andy Shevchenko , Rasmus Villemoes , kernel-team@fb.com Subject: Re: [PATCH v6 2/4] printk: Straighten out log_flags into printk_info_flags Message-ID: References: <0b4f0e60960217ac36462316cf43497a9fad1747.1621338324.git.chris@chrisdown.name> <87tumr82ri.fsf@jogness.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87tumr82ri.fsf@jogness.linutronix.de> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 2021-05-25 13:35:29, John Ogness wrote: > On 2021-05-25, Petr Mladek wrote: > >> diff --git a/kernel/printk/printk_ringbuffer.h b/kernel/printk/printk_ringbuffer.h > >> index 73cc80e01cef..71918d47ca95 100644 > >> --- a/kernel/printk/printk_ringbuffer.h > >> +++ b/kernel/printk/printk_ringbuffer.h > >> @@ -50,6 +50,12 @@ struct prb_data_blk_lpos { > >> unsigned long next; > >> }; > >> > >> +/* Flags for a single printk record. */ > >> +enum printk_info_flags { > >> + LOG_NEWLINE = 2, /* text ended with a newline */ > >> + LOG_CONT = 8, /* text is a fragment of a continuation line */ > >> +}; > > > > Nit: Could you please move this after "enum desc_state" declaration? > > Is there a reason that this enum is moved into printk_ringbuffer.h? The > ringbuffer does not use this enum. We want to use it in two source files: printk.c and index.c Alternative solution would be to move it to kernel/printk/internal.h. Well, will internal.h still be needed after we remove printk_safe? Anyway, I do not have strong opinion about it. Best Regards, Petr