Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1802831pxu; Tue, 24 Nov 2020 09:14:43 -0800 (PST) X-Google-Smtp-Source: ABdhPJyznUwu/gf29j6P9hhzPa/JeyfGLGjvV+44yQ7SJRZT0XJYrWeqP7HHe7XuBptA7AfUTfwe X-Received: by 2002:a50:bc04:: with SMTP id j4mr4725644edh.316.1606238083022; Tue, 24 Nov 2020 09:14:43 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606238083; cv=none; d=google.com; s=arc-20160816; b=EA2AHSGV1Cv6Wx3tAaJBQRIflJNkaAyJpNEW4oHy2wkXUZhFAF0WKw7KKNBW7z5cTy rHOyYjFKqNrGZ/2LjBnN21Lll0fF4toKTrPN4xZQEN3xCrfERMr/tBbRZZ8HExgJcg7B 6t6jPtdsY6Q1eAoXZusJzWS5ve4B+Zl6BYTzE0sdgl8SSzr9A108SDFO2tr/d9m/ZElX POxoyHXKF22kKVlYGG5LLI5biJr9pcdyk6AAXLrx1Dh4S6SlDVucaTBAttVX9wt+B2WY OtSDtcBPxOe0RjlaoL9XDmu/2b+m+JHdecVDnQHDTO/D3DvKzM3fxD/HEOUG4RiRxz5M YsRQ== 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:from; bh=ZKmhSPX4j4dhn/f/ifRtYGYc7hU6N0WJ35NAyU50tx8=; b=Stx7InkdTLuBybe9kT0k8+5NcNhWQeFrPaj6sGoNgR2f9peWe2cQmHCyYpAiEMWtqb H46cfkhIhcjyh+lp1UHTo+9BBEWTpNJWB07ZtgAm5vpQJGh861IzT2X700tnBiVobzTn qXeD5FLb6/6leCZRSKgTZ8shpjVSHlSyF34vDgzbEC4Gdv2ZiYu/kp6jmrjp3EuavMFt XO3jY0ACQVfp7a4/qroaFsCXBPYYeXADIygCNpTRWZ0TvxMM2zhNpz7M9zdN4L8TAP92 KoQuxDolKy6GtuRMdetOIjVoMvd/w3prUBA3YFsYasaY0BPXSsMiUUt2eshgyUe3T4Ym UnjA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h14si7900201eje.368.2020.11.24.09.14.18; Tue, 24 Nov 2020 09:14:43 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2390590AbgKXRHw (ORCPT + 99 others); Tue, 24 Nov 2020 12:07:52 -0500 Received: from mail-wm1-f68.google.com ([209.85.128.68]:55035 "EHLO mail-wm1-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729093AbgKXRHw (ORCPT ); Tue, 24 Nov 2020 12:07:52 -0500 Received: by mail-wm1-f68.google.com with SMTP id d142so3036657wmd.4; Tue, 24 Nov 2020 09:07:51 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=ZKmhSPX4j4dhn/f/ifRtYGYc7hU6N0WJ35NAyU50tx8=; b=ubvJUyXZgExMGkDj9NyqODg9lcM1egAGNq5ivdxFOViKf0UjdT7qAM2/Y6b/8RVgE1 iuSRDo3bpDWqF4N8xpkD0/XXHMvXqunCczfdKjJcxv7rfNtrxgwS7Ctfks7pYrC2Xgge Eu/EsU1q8wkokctDEVYuyfm4CUfZmjHA1JK50xBxf9nRGM8U877k4h9ItrhPxbAcj5dQ od4fT/CAUPR8zq7jZfOPApcYU6MJ+UNMNTRMxwYyvstz76FzSfuHUpvfVUIFYwlhUIgj IULJbGtOZvpK3QZ57P3KmMpgzQHi39JXP6DaqHxdSGfvd/u9ZvGuFRGK8swX/q/za1y2 j66w== X-Gm-Message-State: AOAM5327g5KfipNXj9TtIERLODylEEA9NQHCbOnM0aBdtKFEM86pNVTA uzBTHGOSbzSvCRFrQiHNOPmjlt++/bE= X-Received: by 2002:a7b:c11a:: with SMTP id w26mr5368181wmi.131.1606237671003; Tue, 24 Nov 2020 09:07:51 -0800 (PST) Received: from liuwe-devbox-debian-v2.j3c5onc20sse1dnehy4noqpfcg.zx.internal.cloudapp.net ([51.145.34.42]) by smtp.gmail.com with ESMTPSA id v20sm6419874wmh.44.2020.11.24.09.07.50 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 24 Nov 2020 09:07:50 -0800 (PST) From: Wei Liu To: Linux on Hyper-V List Cc: virtualization@lists.linux-foundation.org, Linux Kernel List , Michael Kelley , Vineeth Pillai , Sunil Muthuswamy , Nuno Das Neves , Wei Liu , "K. Y. Srinivasan" , Haiyang Zhang , Stephen Hemminger Subject: [PATCH v3 03/17] Drivers: hv: vmbus: skip VMBus initialization if Linux is root Date: Tue, 24 Nov 2020 17:07:30 +0000 Message-Id: <20201124170744.112180-4-wei.liu@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20201124170744.112180-1-wei.liu@kernel.org> References: <20201124170744.112180-1-wei.liu@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org There is no VMBus and the other infrastructures initialized in hv_acpi_init when Linux is running as the root partition. Signed-off-by: Wei Liu --- v3: Return 0 instead of -ENODEV. --- drivers/hv/vmbus_drv.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/hv/vmbus_drv.c b/drivers/hv/vmbus_drv.c index 4fad3e6745e5..23f5bce8f242 100644 --- a/drivers/hv/vmbus_drv.c +++ b/drivers/hv/vmbus_drv.c @@ -2612,6 +2612,9 @@ static int __init hv_acpi_init(void) if (!hv_is_hyperv_initialized()) return -ENODEV; + if (hv_root_partition) + return 0; + init_completion(&probe_event); /* -- 2.20.1