From patchwork Tue May 31 19:33:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tim Gardner X-Patchwork-Id: 1637554 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=nEIae12c; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=) Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4LCMsQ2g8nz9sBB for ; Wed, 1 Jun 2022 05:34:01 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from ) id 1nw7co-00048O-Aw; Tue, 31 May 2022 19:33:54 +0000 Received: from smtp-relay-internal-0.internal ([10.131.114.225] helo=smtp-relay-internal-0.canonical.com) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1nw7cm-00048A-6e for kernel-team@lists.ubuntu.com; Tue, 31 May 2022 19:33:52 +0000 Received: from mail-pl1-f198.google.com (mail-pl1-f198.google.com [209.85.214.198]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-0.canonical.com (Postfix) with ESMTPS id E7AEC3F6F1 for ; Tue, 31 May 2022 19:33:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1654025631; bh=0oOwS97yME9SM51PpYDwvGvoITatF1OUr6hQ2a1qmKc=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=nEIae12cxqPqKPTpiM90uivxlheVcEuA7PRMRfVTl//rpi/i3/lR57+uTC846c1ux jH15/YVqxniiUVf6JaoPo1io/VZh9ZlpfYVpCPZDco6vswMUrurVd/clYHKw2Aw8tL Pf1heGyukcYABKrVx3vQAlrsSoKxKz/H4H3Bp01CoVWvvQhp2yZoXop0yHuOOAbKqD sil3rgckB5NZ5N9zOao4wgcC1XU/GPnHgM7WuFqV67AHGaplTYmiWYr/W7qsdKx6SP OfhSFbhfttOzVmawGgfIhgrxjsaxqJSgoO541ThGGX+RSymVL1a99HBg/eO9sMbiah MEfHQpCJB5X0w== Received: by mail-pl1-f198.google.com with SMTP id u22-20020a170902a61600b0016363cdfe84so9348156plq.10 for ; Tue, 31 May 2022 12:33:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=0oOwS97yME9SM51PpYDwvGvoITatF1OUr6hQ2a1qmKc=; b=3k0Tl0OVMoTY7i67hhUHH9+M8GQeRGji4Pn0CYWm0oBs+7noJFK38H/pg2pmOrB/vj ZcbAnDw8w2jTeD6FmLBI3ul8Vbff+wW5+x8IrgVoYC0SG5d1e2jX3e8IzYs781PHRDUS lb+Yf4kjVR7LYLtZrhE/2O2fHomhZPiIg9mhmk+EsVeGClTSKtx1GA7gzET48IHvFBLI uVgF5e/MtGlW2VmSJ9bQBuGaEgLJi9OJMQ8XhTogZPEeLiYphJj537MEBYucG+dRKHG7 Y4zSSOKMVwZ2mSuH1gwt5cyM+OpJ8MQZvWSboKgMUTOZkIhrAznaOIhcuoZKCw+yWElB oYdw== X-Gm-Message-State: AOAM531OiZaqMfO/KlWec0x18nq3adFpSK+mCe6bLTQwVANH8xyA86iV 7STLpJwg2mNtISsS+sXPV0f1rDZFiTiR2ZWQIesh7Gj5QdKWAj9oHz9S3WanFY+34VZa9lKbkTB TPQrbXLWbhJngMUlabh4MzjtNBd+XDf4EIn/IYIIFig== X-Received: by 2002:a05:6a00:cc5:b0:518:a5e6:731e with SMTP id b5-20020a056a000cc500b00518a5e6731emr43608835pfv.19.1654025630302; Tue, 31 May 2022 12:33:50 -0700 (PDT) X-Google-Smtp-Source: ABdhPJySjltpP5z9ANzVhPGJrf2sEzVnCq7hjsm6FjZxvb9EzQxZlBEEQ87ewHLY7r2Z61hvRTHqeQ== X-Received: by 2002:a05:6a00:cc5:b0:518:a5e6:731e with SMTP id b5-20020a056a000cc500b00518a5e6731emr43608813pfv.19.1654025629914; Tue, 31 May 2022 12:33:49 -0700 (PDT) Received: from localhost.localdomain ([69.163.84.166]) by smtp.gmail.com with ESMTPSA id w187-20020a627bc4000000b005185407eda5sm11008393pfc.44.2022.05.31.12.33.49 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 31 May 2022 12:33:49 -0700 (PDT) From: Tim Gardner To: kernel-team@lists.ubuntu.com Subject: [PATCH 0/2][focal/linux-azure] The console log of ARM64 Ubuntu 18.04 has duplicate output Date: Tue, 31 May 2022 13:33:41 -0600 Message-Id: <20220531193343.5130-1-tim.gardner@canonical.com> X-Mailer: git-send-email 2.36.1 MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: https://bugs.launchpad.net/bugs/1976399 SRU Justification [Impact] There is duplicate output on the console . LSG team identify the root cause and suggested to apply two patches below. https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=ad8cd1db80cc33337bdbee63c453ef6d5132474b https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=e369d8227fd211be36242fc44a9dc2209e246b9a What we are hitting is exactly in the second commit's log. Ubuntu kernel also needs the following diff: Linux kernel: 5.4.0-1078-azure Tested in Azure Host version: 22477.1101-1-0 Image: Canonical 0002-com-ubuntu-server-arm-preview-bionic 18_04-lts 18.04.202205020 From Azure Serial Console, we can see duplicate output. Such as: [ 3.109140] Platform Keyring initialized [ 3.109140] Platform Keyring initialized [ 3.117148] Key type asymmetric registered [ 3.117148] Key type asymmetric registered [ 3.122303] Asymmetric key parser 'x509' registered [ 3.122303] Asymmetric key parser 'x509' registered [Test Plan] Microsoft tested [Where things could go wrong] The kernel log could get corrupted. [Other Info] SF: #00338148 Acked-by: Thadeu Lima de Souza Cascardo Signed-off-by: Joseph Salisbury diff --git a/kernel/printk/printk.c b/kernel/printk/printk.c index f07367100ece..dca15e27123a 100644 --- a/kernel/printk/printk.c +++ b/kernel/printk/printk.c @@ -2203,7 +2203,7 @@ static int __init console_setup(char *str) * for exacly this purpose. */ if (str[0] == 0 || strcmp(str, "null") == 0) { - __add_preferred_console("ttynull", 0, NULL, NULL); + __add_preferred_console("ttynull", 0, NULL, NULL, true); return 1; }