From patchwork Wed Aug 14 19:59:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jon Mason X-Patchwork-Id: 47791 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8DEEAC52D7F for ; Wed, 14 Aug 2024 19:59:23 +0000 (UTC) Received: from mail-oi1-f181.google.com (mail-oi1-f181.google.com [209.85.167.181]) by mx.groups.io with SMTP id smtpd.web10.107390.1723665561085515288 for ; Wed, 14 Aug 2024 12:59:21 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@kudzu-us.20230601.gappssmtp.com header.s=20230601 header.b=GEm+l7tM; spf=none, err=permanent DNS error (domain: kudzu.us, ip: 209.85.167.181, mailfrom: jdmason@kudzu.us) Received: by mail-oi1-f181.google.com with SMTP id 5614622812f47-3db1e21b0e4so133663b6e.2 for ; Wed, 14 Aug 2024 12:59:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kudzu-us.20230601.gappssmtp.com; s=20230601; t=1723665560; x=1724270360; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:from:to:cc:subject:date:message-id:reply-to; bh=Tw7YT4x+/53twD3w5YQPxUBT7K/pyl3KGQ4lCRAqFic=; b=GEm+l7tMng8pkXTb3Lh3Ojj79DcTUX1SeN9C9fa5UQx0xK3IgHsmzqnf66jLw9utJu dPQHGfMdQCJ/rH6jAxmO4a89U9MhIAsbkP80DXAyF8IiBCvyuarm5sGRjKtiPCsQVp9f gXsLiAPq553f0cX5rX84+ZotVD/Lfki7MmfCgWo+XWQPT2iPXv+bZ1FbNG9nNl5JopR3 r0qiR/6TZtY6ZCvdUXjWROnFo1P37vEa0Emxd/KTG5yEzzu3xu0xmjklGAHxCNZGGADE 9vm3h1nz95xdkrQb8eeEtiwuMN91vu9uCNqxYZVit81D8DOFn1+8lKg88gEJsXS6dNGn Sdmg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723665560; x=1724270360; h=content-transfer-encoding:mime-version:message-id:date:subject:to :from:x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Tw7YT4x+/53twD3w5YQPxUBT7K/pyl3KGQ4lCRAqFic=; b=l7I5xQfC67Esa3ja2GVrIQ3kzFnOu6g2WYACExIP0/ROrwRG0LGeOlONE5dZfpEfaA aWjGgPbddQa+UXN8iTqUlmnZuM0sTQT+uFS3Yyq/Ob0iiP8LSSEkBw4Edriso9PSJ4n7 ZiQJzcOptIP28YnZdZo4a79fR60dqybxGeC+BNXtyuRi6/VpIEdi/1t9zoO8by9uX08s 7ZDQ42c0loH/qQp1PSCIuqZHTNOZXfErH39XKhj5LEeNCptG7Be/CoBWalurbjtbigju La6bgmkv5WutVBbJS6QyaAMMfUaNy3Z92sgPvDqXTka9AOt3QGdxayBSF/ugNW77YiDY TORA== X-Gm-Message-State: AOJu0YzhDjjF/EvCh4rsIgiDsOZfxHOyZftqXXznsRA6t5U6rulnj8gm XCqesCLGMIk8cAn7+PQHhxtaimVt9QJYqhQo9lNW+fZ5FVcldayE7mz529jhXXW7nszkIXVx4JA = X-Google-Smtp-Source: AGHT+IErPqnZ1yUDB2k2MUw2zpcvv8v9FNCOJCe68liHEvg4PKLfkM7/lLnjmDVn7dhe9zE5xU68/g== X-Received: by 2002:a05:6808:2383:b0:3d5:6312:a017 with SMTP id 5614622812f47-3dd299236f4mr4365912b6e.29.1723665560051; Wed, 14 Aug 2024 12:59:20 -0700 (PDT) Received: from localhost ([136.54.20.50]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-4531c1a7d0esm45146381cf.8.2024.08.14.12.59.19 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 12:59:19 -0700 (PDT) From: Jon Mason To: openembedded-core@lists.openembedded.org Subject: [PATCH 1/2] kernel.bbclass: remove unused CMDLINE_CONSOLE Date: Wed, 14 Aug 2024 15:59:18 -0400 Message-Id: <20240814195919.1079481-1-jdmason@kudzu.us> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Wed, 14 Aug 2024 19:59:23 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/203329 CMDLINE_CONSOLE appears to be a legacy variable that is unused anywhere, and has not been modified the creation of the git tree. Remove it and make life simpler. Signed-off-by: Jon Mason --- meta/classes-recipe/kernel.bbclass | 2 -- 1 file changed, 2 deletions(-) diff --git a/meta/classes-recipe/kernel.bbclass b/meta/classes-recipe/kernel.bbclass index 4464155b7304..cdcc5e003202 100644 --- a/meta/classes-recipe/kernel.bbclass +++ b/meta/classes-recipe/kernel.bbclass @@ -227,8 +227,6 @@ KERNEL_DTBVENDORED ?= "0" # # configuration # -export CMDLINE_CONSOLE = "console=${@d.getVar("KERNEL_CONSOLE") or "ttyS0"}" - KERNEL_VERSION = "${@get_kernelversion_headers('${B}')}" # kernels are generally machine specific From patchwork Wed Aug 14 19:59:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jon Mason X-Patchwork-Id: 47792 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8AAABC3DA4A for ; Wed, 14 Aug 2024 19:59:23 +0000 (UTC) Received: from mail-oi1-f181.google.com (mail-oi1-f181.google.com [209.85.167.181]) by mx.groups.io with SMTP id smtpd.web11.107584.1723665561956482066 for ; Wed, 14 Aug 2024 12:59:22 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@kudzu-us.20230601.gappssmtp.com header.s=20230601 header.b=KEvLDsmq; spf=none, err=permanent DNS error (domain: kudzu.us, ip: 209.85.167.181, mailfrom: jdmason@kudzu.us) Received: by mail-oi1-f181.google.com with SMTP id 5614622812f47-3db22c02a42so133551b6e.3 for ; Wed, 14 Aug 2024 12:59:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kudzu-us.20230601.gappssmtp.com; s=20230601; t=1723665561; x=1724270361; darn=lists.openembedded.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=zMVPEYnr0l4lllScV53LLDWysUrPWSRD9+XHY2h6XZ4=; b=KEvLDsmqwrOdf1VpzyC66rjDZFDTowqVuv4lgCUzVczKT0zEdXUEMG8gjm5+BKLfIA vbhqENXo6h55Tce8NOS7zrTxDxLFbfp7BsTFE2y+24o84ya7g1CZtWyJJfioHpsaahOB DK0Eq4iUwx/HFKcKgnr309t9QILCzswthd8v7f7thdnAQDTPsvI1vvLHqtNOlK2jfz2d IwQ2+clwCBnBtciY3elhgjsUY1zP8FHZAUHq5LmR04IRbyPmY+xzakkDj4sikaNXzrqq 9kLWoxAPIrpoPgUno1vNhQVR3MN9pbwdo8jh/Jd8XYlkJs5e6K0MSd5PPKyoKYLLI3do FDQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1723665561; x=1724270361; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=zMVPEYnr0l4lllScV53LLDWysUrPWSRD9+XHY2h6XZ4=; b=Ikc0d5pxIovygy0BnMmhTWsnsjWitpFWlE2bAjnDg1CBNr4msEJnj7rxeq94/tCh/X mhNYsKFb1RRst8fb9zL6elp8RYB3UltlwuggiyAwgZoX3mBQIYH7xJ4k1eXnfItKX1bg dwUHY72XXY2gIssTFX056dF1q9JAH1K1adJoWVwaY8abuW9zTyRVtNWI49pThmTFglir 2rSocD0sPa4cSal7YGtqKQsm4zOM0huKiNg8zvwmBZVL5wdh/W/UvBdzHgY6d3zGMtiT NrMspyd5k+RX1OwZ08fRzvKHFg3/GamA84XKsA3OaxQNmMGYqWZdwRcc68T0AmvmnLcy y3aA== X-Gm-Message-State: AOJu0YwmKh6aBhwOl5LfllLSNV9Wy5g6qhpT8JOgxauaMOrqZfNoY3I4 wCjsgK2vodUnx28rt1Tv3OahwitYC+icgNUEux81RyeCoNNkf7iE0ie2BXLrNqjDfZEqg7nKfIU = X-Google-Smtp-Source: AGHT+IG/tBxnhjiK5xf83yykLKJYwe8EBuE+FXUIF/gofAHdDhVB7IamFxLRByCggjLNUvXQoiDhOA== X-Received: by 2002:a05:6808:1403:b0:3dc:2878:c42 with SMTP id 5614622812f47-3dd2991550cmr4126761b6e.26.1723665560958; Wed, 14 Aug 2024 12:59:20 -0700 (PDT) Received: from localhost ([136.54.20.50]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-4531c271a22sm44615961cf.68.2024.08.14.12.59.20 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Aug 2024 12:59:20 -0700 (PDT) From: Jon Mason To: openembedded-core@lists.openembedded.org Subject: [PATCH 2/2] default-distrovars: Have KERNEL_CONSOLE reference SERIAL_CONSOLES Date: Wed, 14 Aug 2024 15:59:19 -0400 Message-Id: <20240814195919.1079481-2-jdmason@kudzu.us> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240814195919.1079481-1-jdmason@kudzu.us> References: <20240814195919.1079481-1-jdmason@kudzu.us> MIME-Version: 1.0 List-Id: X-Webhook-Received: from li982-79.members.linode.com [45.33.32.79] by aws-us-west-2-korg-lkml-1.web.codeaurora.org with HTTPS for ; Wed, 14 Aug 2024 19:59:23 -0000 X-Groupsio-URL: https://lists.openembedded.org/g/openembedded-core/message/203330 Currently, KERNEL_CONSOLE has a default value of "ttyS0". However, Arm machines and those using virtio serial prefer to use "ttyAMA0" or "hvc0" (or something else). These are usually defined by the machine config file as SERIAL_CONSOLES, which has one or more entries. Take the first one of those instead of ttyS0, but default back to ttyS0 if nothing is set. Also, use this variable in the efi wic file instead of "ttyS0". Signed-off-by: Jon Mason --- meta/conf/distro/include/default-distrovars.inc | 3 ++- scripts/lib/wic/canned-wks/mkefidisk.wks | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/meta/conf/distro/include/default-distrovars.inc b/meta/conf/distro/include/default-distrovars.inc index 7554081e8b1a..26fa26f80c31 100644 --- a/meta/conf/distro/include/default-distrovars.inc +++ b/meta/conf/distro/include/default-distrovars.inc @@ -1,7 +1,8 @@ QA_LOGFILE = "${TMPDIR}/qa.log" OEINCLUDELOGS ?= "yes" -KERNEL_CONSOLE ?= "ttyS0" +# if SERIAL_CONSOLES is set, take the first device entry. Otherwise use ttyS0 as the default +KERNEL_CONSOLE ?= "${@d.getVar('SERIAL_CONSOLES').split(' ')[0].split(';')[1] or 'ttyS0'}" KEEPUIMAGE ??= "yes" DEFAULT_IMAGE_LINGUAS = "en-us en-gb" diff --git a/scripts/lib/wic/canned-wks/mkefidisk.wks b/scripts/lib/wic/canned-wks/mkefidisk.wks index 9f534fe18471..1ab870805ed1 100644 --- a/scripts/lib/wic/canned-wks/mkefidisk.wks +++ b/scripts/lib/wic/canned-wks/mkefidisk.wks @@ -8,4 +8,4 @@ part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024 part swap --ondisk sda --size 44 --label swap1 --fstype=swap -bootloader --ptable gpt --timeout=5 --append="rootfstype=ext4 console=ttyS0,115200 console=tty0" +bootloader --ptable gpt --timeout=5 --append="rootfstype=ext4 console=${KERNEL_CONSOLE}"