Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp3041054pxa; Tue, 18 Aug 2020 05:12:58 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwqF4I5Msph4RxW6io5nStrx6Zm92hBVCoe2aVUgtTy2OBIO+aAPvGs9bqzvPRjzXGnWQsP X-Received: by 2002:a17:906:228a:: with SMTP id p10mr19584576eja.23.1597752778103; Tue, 18 Aug 2020 05:12:58 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597752778; cv=none; d=google.com; s=arc-20160816; b=AnHDLAMpeG7tFRMCWEEES4hdHh1dM7S29mbqpHeM6C2TEAZZZz/OqH8UXl2N26yRGE 8rgSix+qO8odvQ7MEFBjNliFIiWeffh4p0gh3dES7fEokZ/t/wSsr5mppHZfOAMJw72P 1h3eS5sxTcB0dzSHj6nw98eMTEH2c669V9SE5oxjxduvJHNJGGnXLp+e9YdCw+upbX5m m8ovfZmkkPBt1yzGGMHu73TE5F66twR3vHEwJssV4DZIdsVVj+9XRpAHj7OI0lcYKcYX Cck+/QxWGqDDKaE3QypKETKgDBf/7752vAm6lLZYSX6zTO+3cZzgG5DZCtdOIBYsYxGS /rlg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :ironport-sdr:ironport-sdr; bh=UAlI1SQ+c9V26Xa4tKCed+blXaKMDYt9rPttttKaDOI=; b=tXaCtK6UuIFzGrECeSVFE4gOccsUxTm/3eVaCIgdlZZV4q/XFZjkAoPDCy5S0kzM4z V/1cZey8OHMkiUw1AwLTqs0UlSihrMaYypiBHi3uGWfwh90slP2X93a93qDdx7zDSKXE ewMeh0pDJi8XF760Jo3GXNTwbUGdmmC0MdJl3uJlomqUXiwQs3qmIlNInQBYSDWxPgpf 3xxnPok2oPhZwi3jHilCvkG6RTw+a6kGHGjcRcye3YQ+FbH5meJwhDpTUngAmeJWZ/7y cjwVISm08HdBwi+SI+M0ja8q6tu+EpEu9/n/uVGMmp0qPcO9XsGaYo0om+LatdVP6gPh PiCQ== 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id n9si12478002eji.444.2020.08.18.05.12.34; Tue, 18 Aug 2020 05:12:58 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726871AbgHRMKz (ORCPT + 99 others); Tue, 18 Aug 2020 08:10:55 -0400 Received: from mga07.intel.com ([134.134.136.100]:58750 "EHLO mga07.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726841AbgHRMK3 (ORCPT ); Tue, 18 Aug 2020 08:10:29 -0400 IronPort-SDR: PpUKk64O8VP4ulg75Aj3Rq+UjTBe8ogrdWjLNlUoPd2HY+q5W2yj5nBDarRW95+R/n2F3XO9x3 /BRiTukV3cvQ== X-IronPort-AV: E=McAfee;i="6000,8403,9716"; a="219200414" X-IronPort-AV: E=Sophos;i="5.76,327,1592895600"; d="scan'208";a="219200414" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga105.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 18 Aug 2020 05:10:29 -0700 IronPort-SDR: X7ZBJ7bw4crp0cPJWmIkCio/vmUKSgiHhD5hfknXvffrccQdJzqdTchS7OecRodRBv8O98UeWJ G92PX9oYfViA== X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.76,327,1592895600"; d="scan'208";a="326713084" Received: from twinkler-lnx.jer.intel.com ([10.12.91.138]) by orsmga008.jf.intel.com with ESMTP; 18 Aug 2020 05:10:26 -0700 From: Tomas Winkler To: Greg Kroah-Hartman Cc: Alexander Usyskin , linux-kernel@vger.kernel.org, Tomas Winkler Subject: [char-misc-next 12/13] mei: docs: add vtag ioctl documentation Date: Tue, 18 Aug 2020 14:51:46 +0300 Message-Id: <20200818115147.2567012-13-tomas.winkler@intel.com> X-Mailer: git-send-email 2.25.4 In-Reply-To: <20200818115147.2567012-1-tomas.winkler@intel.com> References: <20200818115147.2567012-1-tomas.winkler@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add structured documenation for the new vtag ioctl Signed-off-by: Tomas Winkler --- Documentation/driver-api/mei/mei.rst | 37 ++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/Documentation/driver-api/mei/mei.rst b/Documentation/driver-api/mei/mei.rst index c800d8e5f422..cea0b69ec216 100644 --- a/Documentation/driver-api/mei/mei.rst +++ b/Documentation/driver-api/mei/mei.rst @@ -42,6 +42,11 @@ The session is terminated calling :c:func:`close(int fd)`. A code snippet for an application communicating with Intel AMTHI client: +In order to support virtualization or sandboxing a trusted supervisor +can use :c:macro:`MEI_CONNECT_CLIENT_IOCTL_VTAG` to create +virtual channels with an Intel ME feature. Not all features support +virtual channels such client with answer EOPNOTSUPP. + .. code-block:: C struct mei_connect_client_data data; @@ -110,6 +115,38 @@ Connect to firmware Feature/Client. data that can be sent or received. (e.g. if MTU=2K, can send requests up to bytes 2k and received responses up to 2k bytes). +IOCTL_MEI_CONNECT_CLIENT_VTAG: +------------------------------ + +.. code-block:: none + + Usage: + + struct mei_connect_client_data_vtag client_data_vtag; + + ioctl(fd, IOCTL_MEI_CONNECT_CLIENT_VTAG, &client_data_vtag); + + Inputs: + + struct mei_connect_client_data_vtag - contain the following + Input field: + + in_client_uuid - GUID of the FW Feature that needs + to connect to. + vtag - virtual tag [1, 255] + + Outputs: + out_client_properties - Client Properties: MTU and Protocol Version. + + Error returns: + + ENOTTY No such client (i.e. wrong GUID) or connection is not allowed. + EINVAL Wrong IOCTL Number or tag == 0 + ENODEV Device or Connection is not initialized or ready. + ENOMEM Unable to allocate memory to client internal data. + EFAULT Fatal Error (e.g. Unable to access user input data) + EBUSY Connection Already Open + EOPNOTSUPP Vtag is not supported IOCTL_MEI_NOTIFY_SET --------------------- -- 2.25.4