From patchwork Wed Sep 27 12:32:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tim Gardner X-Patchwork-Id: 1840200 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=185.125.189.65; helo=lists.ubuntu.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=patchwork.ozlabs.org) Received: from lists.ubuntu.com (lists.ubuntu.com [185.125.189.65]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Rwbcc1jn0z1ypS for ; Wed, 27 Sep 2023 22:33:19 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=lists.ubuntu.com) by lists.ubuntu.com with esmtp (Exim 4.86_2) (envelope-from ) id 1qlTj4-0001cV-5w; Wed, 27 Sep 2023 12:33:10 +0000 Received: from smtp-relay-internal-0.internal ([10.131.114.225] helo=smtp-relay-internal-0.canonical.com) by lists.ubuntu.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1qlTiz-0001bv-6l for kernel-team@lists.ubuntu.com; Wed, 27 Sep 2023 12:33:05 +0000 Received: from mail-pl1-f197.google.com (mail-pl1-f197.google.com [209.85.214.197]) (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 E08833F67A for ; Wed, 27 Sep 2023 12:33:04 +0000 (UTC) Received: by mail-pl1-f197.google.com with SMTP id d9443c01a7336-1c5b80fe118so150502255ad.3 for ; Wed, 27 Sep 2023 05:33:04 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1695817983; x=1696422783; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=ggUMzLTY8NkP0tzzciU/h8YXz0TW/Dz8NMK5n9DwCBk=; b=Umee1eP0nZandF4smxZh76r7Fm8roItbOh9sP9MjIFKW/NMKXwSyeCRfGQq/bAA8m/ JzaZY9EHWRryn27Ye80HigO60O6I/WT6ljxaOykgAfBgqLrOmsFgyphK4li9B+AxmvvO p1kFnLoZslxxNV44xwjXtgUZsOoqW0LFO8OwsURCY2nvaap9Gr36IYMq7yMYfxd5O3xk m22E0+TFjkQNGLCrDP/3kZcdLTgUTTwLrdOr1rZcZATI5DdRzNeElGlKRpOHZbVWM9Q4 winaT5ABG+8jZi4vBm3ZTKtIBn7xdJ2ap7fLSfW0/fSQ9WMKqvs3k9ouVPCMGfqAWIP7 4w1w== X-Gm-Message-State: AOJu0YwW2nzQsRGH8jqKwn0DLSuDUKn9bIN83e3drhyrDzCyvk8s3maP QiH8aXVUYTAfqoItATT1AjPKdOKj0/q4uM/LncOW+saZe6z4PrO8XE4AXlHVDcuo7la/4Dw5p2h tilGEs+OVf4U73C0wGki5mLcKpY20/zO3F/oqVTgkxjvAoHgWmg== X-Received: by 2002:a17:903:244d:b0:1c2:1068:1f4f with SMTP id l13-20020a170903244d00b001c210681f4fmr1944920pls.17.1695817983258; Wed, 27 Sep 2023 05:33:03 -0700 (PDT) X-Google-Smtp-Source: AGHT+IGH3jjldJQjt20TkhxputUNhDKbUrCoGu98up0etWAINkbXr0Ps9Eb7EH+0SivMsqDszE+aqQ== X-Received: by 2002:a17:903:244d:b0:1c2:1068:1f4f with SMTP id l13-20020a170903244d00b001c210681f4fmr1944906pls.17.1695817982953; Wed, 27 Sep 2023 05:33:02 -0700 (PDT) Received: from smtp.gmail.com (174-045-099-030.res.spectrum.com. [174.45.99.30]) by smtp.gmail.com with ESMTPSA id c3-20020a170902d90300b001bbfa86ca3bsm13005805plz.78.2023.09.27.05.33.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 27 Sep 2023 05:33:01 -0700 (PDT) From: Tim Gardner To: kernel-team@lists.ubuntu.com Subject: [PATCH] UBUNTU: SAUCE: (no-up) hv: Fix supply vendor ID Date: Wed, 27 Sep 2023 06:32:55 -0600 Message-Id: <20230927123255.143447-2-tim.gardner@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230927123255.143447-1-tim.gardner@canonical.com> References: <20230927123255.143447-1-tim.gardner@canonical.com> 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/2036600 There is a mistake in the commit (https://git.launchpad.net/~canonical-kernel/ubuntu/+source/linux-azure/+git/jammy/commit/?id=5dd24f2df3280d4354641f4687dbb36e418e7de8) : Before the commit, the good guest_id is 0x8180000602100000. With the commit, the generated guest_id is incorrect: 0x0080000602100000, i.e. the 0x81 from bit 56~63 are dropped. See "include/asm-generic/hyperv-tlfs.h" for the definition of the bits: * Bit(s) * 63 - Indicates if the OS is Open Source or not; 1 is Open Source * 62:56 - Os Type; Linux is 0x100 !!!!! Dexuan: this should be 0x1. I'll post a patch to LKML to fix this typo. * 55:48 - Distro specific identification * 47:16 - Linux kernel version number * 15:0 - Distro specific identification See https://learn.microsoft.com/en-us/virtualization/hyper-v-on-windows/tlfs/tlfs ("February, 2020: Released Version 6.0b", page 15) As a result, the host thinks that the VM is not an open-source OS, and it's not Linux. Consequently, the "VM Availability" fron Azure portal is 0 (unhealthy): some users rely on the info to manage their VMs, e.g. if the VM is erroneously reported "unhealthy", the VM may be killed and re-created, and the new VM is still "unhealthy", and the VM may be killed and re-created again... Fixes commit df072c70a5aecc5f3beac8b8ceb16e6633fcb6c2 ('UBUNTU: SAUCE: (no-up) hv: Supply vendor ID and package ABI') Signed-off-by: Tim Gardner --- include/asm-generic/hyperv-tlfs.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/asm-generic/hyperv-tlfs.h b/include/asm-generic/hyperv-tlfs.h index 770b776e9697..9dea4b320368 100644 --- a/include/asm-generic/hyperv-tlfs.h +++ b/include/asm-generic/hyperv-tlfs.h @@ -135,7 +135,7 @@ union hv_reference_tsc_msr { * */ -#define HV_LINUX_VENDOR_ID 0x80 /* Canonical */ +#define HV_LINUX_VENDOR_ID 0x8180 /* Canonical */ /* * Crash notification flags.