Received: by 2002:a05:622a:251a:b0:39a:b4a2:e86 with SMTP id cm26csp527353qtb; Wed, 19 Oct 2022 08:09:10 -0700 (PDT) X-Google-Smtp-Source: AMsMyM4h+99gF8Fpu6914zCV6yi26wAltkY+YYtdApkbFoXNzwdw3NpGzPcUeg+DjaJ4LhwqwkY+ X-Received: by 2002:a05:6402:1bc6:b0:45c:7611:d86e with SMTP id ch6-20020a0564021bc600b0045c7611d86emr7892885edb.194.1666192150079; Wed, 19 Oct 2022 08:09:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1666192150; cv=none; d=google.com; s=arc-20160816; b=eOTrnYJauQNu3SNj3YJCfh4g2BhLcT073XlzGVzNM7wM9a7NegTG6zhc8CyLiob9dm jMuiRvo1CNF5FT9BtvTms1esYb52pixFBVONFDzNOpDWmWj/vB8Ol4ctjJ3IbJoljvNW 8YgVIvWcc56A47TlOJwlR09RtIXrqUTvZ0Anur4cVGjTpQGaRfB+UcGAmgEKxCXoGaUp vNX9gLFeTR4+0iR0q/7MRZL2stHkcn2L89ZwzWalKpkj6Li7BIVRD5LWPSQHFSJrslEe xQUTUkJAFk++lhEyL9HES9JUGkhqnptC9XZ7j3HtuH7vltb75/7gprXnQjJRAlNZJCX4 KqAA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:dkim-signature :dkim-signature:from; bh=6uEJOM0caPrcvNJcHiErtW6cO4rX4lvkgAL5ZPoAngE=; b=ZvwCpncD8XzBcL9H4b1h7ZEl//Cg5TuvHjEkIfVfM1RC9NYHYN1clqYg3T8G4wco+2 uDmc/HW0yN0tsNqZuzZcTCFfXcSqPCd8bpkqgjbP/K3mfbzcfNIygUEm3rrYVCUH4+Cu GCiCwAVgiDpggqcdW/0kdmZbg4P/jXQLP2CdFKzyFtyFr3Cn4x3OT0S34RQ9ZGmFGL5M fEwJDz/dar0yXoiXr/HRNdtXJmHLxzrAarf1HG1y0THB8PmT/rfWpK2/pVMQWIdlQcBD gl6H5rU1ZuiDXVIU0mfWZaiHzNTQGniSfBCQgBK7+RANSx4Y9SxvV/7Ionk2EqeeAu7S q/pg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=CapeSp4l; dkim=neutral (no key) header.i=@linutronix.de header.b=ZQecdyT7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id gs19-20020a1709072d1300b00783d5a93880si14237860ejc.503.2022.10.19.08.08.32; Wed, 19 Oct 2022 08:09:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=CapeSp4l; dkim=neutral (no key) header.i=@linutronix.de header.b=ZQecdyT7; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231566AbiJSPEl (ORCPT + 99 others); Wed, 19 Oct 2022 11:04:41 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60680 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232013AbiJSPEA (ORCPT ); Wed, 19 Oct 2022 11:04:00 -0400 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3A1AF189C3E; Wed, 19 Oct 2022 07:58:32 -0700 (PDT) From: John Ogness DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1666191366; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=6uEJOM0caPrcvNJcHiErtW6cO4rX4lvkgAL5ZPoAngE=; b=CapeSp4lIuUCMT3A2F+Nh1MiAgJLkP2QvT6kPUMQDmJJFQsukbmY9zgoaeE4Mq6UuBqXXb FrZc++ZOPgsuLs9l7PcPyG4j8PgQByAcFR2QTb5ZOiIdmXyyFYqlRtydfmDmoK5yA3OP78 U0XmnXaelSW/V/NwDwJUqlWqX2IcrI2b9QoB5wTOni/8eC59uwoJspmELM/0AK/+2z5J0G bd1oHF0zuZVLDhAFAcJJT5y3CPqV4fXZIaKcBDHjVUzgpVkWqsTRUcD5J9GUYo05fhBIDg fYj1DxyE3Wu0F0Ede8aUNYGFTPayP73PEUKd+FQ5qnHfrV5Nu/mSQTYm2wS3RQ== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1666191366; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=6uEJOM0caPrcvNJcHiErtW6cO4rX4lvkgAL5ZPoAngE=; b=ZQecdyT7PQky3Pel/Hzc+4qBo3aS7NXlfHW9v7oMg/iE63aGG0BcneUC9VkDNd/cxE1gob fBX8kx6iiefyiNCg== To: Petr Mladek Cc: Sergey Senozhatsky , Steven Rostedt , Thomas Gleixner , linux-kernel@vger.kernel.org, "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , netdev@vger.kernel.org Subject: [PATCH printk v2 09/38] netconsole: use console_is_enabled() Date: Wed, 19 Oct 2022 17:01:31 +0206 Message-Id: <20221019145600.1282823-10-john.ogness@linutronix.de> In-Reply-To: <20221019145600.1282823-1-john.ogness@linutronix.de> References: <20221019145600.1282823-1-john.ogness@linutronix.de> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-3.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,INVALID_DATE_TZ_ABSURD, RCVD_IN_DNSWL_MED,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Replace (console->flags & CON_ENABLED) usage with console_is_enabled(). Signed-off-by: John Ogness --- drivers/net/netconsole.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/netconsole.c b/drivers/net/netconsole.c index bdff9ac5056d..073e59a06f21 100644 --- a/drivers/net/netconsole.c +++ b/drivers/net/netconsole.c @@ -332,7 +332,7 @@ static ssize_t enabled_store(struct config_item *item, } if (enabled) { /* true */ - if (nt->extended && !(netconsole_ext.flags & CON_ENABLED)) { + if (nt->extended && !console_is_enabled(&netconsole_ext)) { netconsole_ext.flags |= CON_ENABLED; register_console(&netconsole_ext); } @@ -915,7 +915,7 @@ static int __init init_netconsole(void) if (err) goto undonotifier; - if (netconsole_ext.flags & CON_ENABLED) + if (console_is_enabled(&netconsole_ext)) register_console(&netconsole_ext); register_console(&netconsole); pr_info("network logging started\n"); -- 2.30.2