Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp4768030pxv; Tue, 6 Jul 2021 08:41:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyFtv9Nl3WfFp5s+r5XwiLTQL6dzmV8GbTee4TgMlDiOOaXcRAxI+iPoGsKBdmINGbFtmz9 X-Received: by 2002:a05:6638:190e:: with SMTP id p14mr17261798jal.70.1625586104486; Tue, 06 Jul 2021 08:41:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1625586104; cv=none; d=google.com; s=arc-20160816; b=MYncyf7bZYb3HSlCjaRSlaKiM+vcX5vmWkIarjaGvLZQhy63jQ+wwKXsQJLlpnTB1X NO/dCb2f6rmYLEv5UkENsWDwhH7KWJCbfhSGlDwrC4wZWdyncGN9aTxZF56htkFfDyJn t6tT4oyCpL5XkiIPv4OCt8cjINjMYGgubAqomLyraPgf7p8zCFfyhZPqtkm7E1TZtNkj aLOkwNhp8o19zkLDnUxftM48cxK2L0++at792F4LJs4OoesEQxDp5t69yBeChzgwBBxc ewlVV4pXZ2E5o0+8CeQCCYkmw+gj+jhZKQa1EYFoLuDXlq4CDTRlBqb4s9HpZSAf6owz CLyg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature:dkim-filter; bh=FXa3SB2i+RiGoeKML7scN56hG2dTps93chghEwKXFwI=; b=sSm80mnPHcbYdHUYyISWnl9PbY5HHzC2cYovbAjfTg/Jno2BYFMpPwg4XiSx8/zZFP FlcCiFgWCLqHMHorJeTiiGdBh9bhu+CRHhDGtIEa1fvIn0otRJARo37OAI9os5Iq3Tn9 mLUW/2Ef/LD1EF6EoCetNXw6G3j9SXDbNH/FWDMOyLlMaqWgi9a5yC9anOIx/FhLAFzn qt5oskLpv653BcDVDB28sJl0kNO8ZF9TuFHkwRIZvRqDqQ6ICzrLbmGyQ/d5N0aMlxBW lTFMiBXMeOXWALhaJs2uSW+mlL6xdiTXUVTu2PsGHC0lH503cEstAtfEOiPBQPEm4RRT yWqA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=ZT1tH4M9; 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=linux.microsoft.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y17si11564756iod.32.2021.07.06.08.41.32; Tue, 06 Jul 2021 08:41:44 -0700 (PDT) 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; dkim=pass header.i=@linux.microsoft.com header.s=default header.b=ZT1tH4M9; 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=linux.microsoft.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232568AbhGFPnn (ORCPT + 99 others); Tue, 6 Jul 2021 11:43:43 -0400 Received: from linux.microsoft.com ([13.77.154.182]:43014 "EHLO linux.microsoft.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231689AbhGFPnm (ORCPT ); Tue, 6 Jul 2021 11:43:42 -0400 Received: from [10.0.0.178] (c-67-168-106-253.hsd1.wa.comcast.net [67.168.106.253]) by linux.microsoft.com (Postfix) with ESMTPSA id 8DB0120B7188; Tue, 6 Jul 2021 08:41:03 -0700 (PDT) DKIM-Filter: OpenDKIM Filter v2.11.0 linux.microsoft.com 8DB0120B7188 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.microsoft.com; s=default; t=1625586063; bh=FXa3SB2i+RiGoeKML7scN56hG2dTps93chghEwKXFwI=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=ZT1tH4M9oi2ubnBW4DEEpT8Z1Qsiz2HpOHFXUAasnsqb8a8E4fO6QIAfnGMIXbwuu Me7tmy0hrMR1sOtDy2BHvEi5ilk5QRL1Huv+bVMc/ze3DkbfUSLb563At1Dy+pKHLf 3o7CZfb29iboGM9nvDyllpxt12otjAENKhGrp6x0= Subject: Re: [PATCH 03/19] drivers/hv: minimal mshv module (/dev/mshv/) To: Wei Liu Cc: linux-hyperv@vger.kernel.org, linux-kernel@vger.kernel.org, virtualization@lists.linux-foundation.org, mikelley@microsoft.com, viremana@linux.microsoft.com, sunilmut@microsoft.com, vkuznets@redhat.com, ligrassi@microsoft.com, kys@microsoft.com References: <1622241819-21155-1-git-send-email-nunodasneves@linux.microsoft.com> <1622241819-21155-4-git-send-email-nunodasneves@linux.microsoft.com> <20210627120004.u4pn3stgcny2zl4i@liuwe-devbox-debian-v2> From: Nuno Das Neves Message-ID: Date: Tue, 6 Jul 2021 08:41:03 -0700 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <20210627120004.u4pn3stgcny2zl4i@liuwe-devbox-debian-v2> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 6/27/2021 5:00 AM, Wei Liu wrote: > On Fri, May 28, 2021 at 03:43:23PM -0700, Nuno Das Neves wrote: > [...] >> + >> +static int >> +__init mshv_init(void) >> +{ >> + int ret; > > Please check if Linux is running on Microsoft Hypervisor here. If not, > this module should not be loaded. > > Something like: > > if (!hv_is_hyperv_initialized()) > return -ENODEV; Good point - will do. > > Wei. >