From patchwork Wed Jun 27 08:39:53 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Ramalingam C X-Patchwork-Id: 10490853 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8A66460230 for ; Wed, 27 Jun 2018 08:50:25 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 79346289C5 for ; Wed, 27 Jun 2018 08:50:25 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6C7A1288F7; Wed, 27 Jun 2018 08:50:25 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00, MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=unavailable version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 7B35C28A05 for ; Wed, 27 Jun 2018 08:50:24 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 2136E6E74D; Wed, 27 Jun 2018 08:49:59 +0000 (UTC) X-Original-To: intel-gfx@lists.freedesktop.org Delivered-To: intel-gfx@lists.freedesktop.org Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by gabe.freedesktop.org (Postfix) with ESMTPS id 1C0406E71D; Wed, 27 Jun 2018 08:49:53 +0000 (UTC) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga004.jf.intel.com ([10.7.209.38]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 27 Jun 2018 01:49:52 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,278,1526367600"; d="scan'208";a="211535580" Received: from mint-dev.iind.intel.com ([10.223.25.164]) by orsmga004.jf.intel.com with ESMTP; 27 Jun 2018 01:49:48 -0700 From: Ramalingam C To: intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, daniel@ffwll.ch, tomas.winkler@intel.com, alexander.usyskin@intel.com, uma.shankar@intel.com Date: Wed, 27 Jun 2018 14:09:53 +0530 Message-Id: <1530088829-11730-5-git-send-email-ramalingam.c@intel.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1530088829-11730-1-git-send-email-ramalingam.c@intel.com> References: <1530088829-11730-1-git-send-email-ramalingam.c@intel.com> MIME-Version: 1.0 Subject: [Intel-gfx] [PATCH v5 04/40] linux/mei: Header for mei_hdcp driver interface X-BeenThere: intel-gfx@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Intel graphics driver community testing & development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: intel-gfx-bounces@lists.freedesktop.org Sender: "Intel-gfx" X-Virus-Scanned: ClamAV using ClamSMTP Data structures and Enum for the I915-MEI_HDCP interface are defined at v2: Rebased. v3: mei_cl_device is removed from mei_hdcp_data [Tomas] v4: Comment style and typo fixed [Uma] v5: Rebased. Signed-off-by: Ramalingam C --- include/linux/mei_hdcp.h | 100 +++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 100 insertions(+) create mode 100644 include/linux/mei_hdcp.h diff --git a/include/linux/mei_hdcp.h b/include/linux/mei_hdcp.h new file mode 100644 index 000000000000..f993e389d7cf --- /dev/null +++ b/include/linux/mei_hdcp.h @@ -0,0 +1,100 @@ +/* SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause) */ +/* + * Copyright © 2017-2018 Intel Corporation + * + * Permission to use, copy, modify, distribute, and sell this software and its + * documentation for any purpose is hereby granted without fee, provided that + * the above copyright notice appear in all copies and that both that copyright + * notice and this permission notice appear in supporting documentation, and + * that the name of the copyright holders not be used in advertising or + * publicity pertaining to distribution of the software without specific, + * written prior permission. The copyright holders make no representations + * about the suitability of this software for any purpose. It is provided "as + * is" without express or implied warranty. + * + * THE COPYRIGHT HOLDERS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, + * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO + * EVENT SHALL THE COPYRIGHT HOLDERS BE LIABLE FOR ANY SPECIAL, INDIRECT OR + * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, + * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER + * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE + * OF THIS SOFTWARE. + * + * Authors: + * Ramalingam C + */ + +#ifndef _LINUX_MEI_HDCP_H +#define _LINUX_MEI_HDCP_H + +#include + +/* + * Enumeration of the physical DDI available on the platform + */ +enum hdcp_physical_port { + INVALID_PORT = 0x00, /* Not a valid port */ + + DDI_RANGE_BEGIN = 0x01, /* Beginning of the valid DDI port range */ + DDI_B = 0x01, /* Port DDI B */ + DDI_C = 0x02, /* Port DDI C */ + DDI_D = 0x03, /* Port DDI D */ + DDI_E = 0x04, /* Port DDI E */ + DDI_F = 0x05, /* Port DDI F */ + DDI_A = 0x07, /* Port DDI A */ + DDI_RANGE_END = DDI_A,/* End of the valid DDI port range */ +}; + +/* The types of HDCP 2.2 ports supported */ +enum hdcp_integrated_port_type { + HDCP_INVALID_TYPE = 0x00, + + /* HDCP 2.x ports that are integrated into Intel HW */ + INTEGRATED = 0x01, + + /* HDCP2.2 discrete wired Tx port with LSPCON (HDMI 2.0) solution */ + LSPCON = 0x02, + + /* HDCP2.2 discrete wired Tx port using the CPDP (DP 1.3) solution */ + CPDP = 0x03, +}; + +/* + * wired_protocol: Supported integrated wired HDCP protocol. + * Based on this value, Minor difference needed between wired specifications + * are handled. + */ +enum hdcp_protocol { + HDCP_PROTOCOL_INVALID, + HDCP_PROTOCOL_HDMI, + HDCP_PROTOCOL_DP +}; + +/* + * mei_hdcp_data: Input data to the mei_hdcp APIs. + */ +struct mei_hdcp_data { + enum hdcp_physical_port port; + enum hdcp_integrated_port_type port_type; + enum hdcp_protocol protocol; + + /* + * No of streams transmitted on a port. + * In case of HDMI & DP SST, single stream will be + * transmitted on a port. + */ + uint16_t k; + + /* + * Count of RepeaterAuth_Stream_Manage msg propagated. + * Initialized to 0 on AKE_INIT. Incremented after every successful + * transmission of RepeaterAuth_Stream_Manage message. When it rolls + * over re-Auth has to be triggered. + */ + uint32_t seq_num_m; + + /* k(No of Streams per port) x structure of wired_streamid_type */ + struct hdcp2_streamid_type *streams; +}; + +#endif /* defined (_LINUX_MEI_HDCP_H) */