Re: [PATCH] drm/mediatek/dp: Add the HDCP feature for DisplayPort

From: CK Hu (胡俊光)
Date: Thu Jan 04 2024 - 03:03:39 EST


Hi, Mac:

On Fri, 2023-11-24 at 16:53 +0800, mac.shen wrote:
> Add tee client application, HDCP 1.x and 2.x authentication for
> DisplayPort
> to support the HDCP feature.
>
> Signed-off-by: mac.shen <mac.shen@xxxxxxxxxxxx>
> ---

[snip]

> @@ -0,0 +1,154 @@
> +/* SPDX-License-Identifier: GPL-2.0 */
> +/*
> + * Copyright (c) 2019-2023 MediaTek Inc.
> + */
> +
> +#ifndef _MTK_DP_HDCP_H_
> +#define _MTK_DP_HDCP_H_
> +
> +#include <linux/types.h>
> +#include <drm/display/drm_dp_helper.h>
> +#include <linux/sched/clock.h>
> +
> +#define HDCP2_RXSTATUS_SIZE 1
> +#define HDCP2_RTX_SIZE 8
> +#define HDCP2_RRX_SIZE 8
> +#define HDCP2_TXCAPS_SIZE 3
> +#define HDCP2_RXCAPS_SIZE 3
> +#define HDCP2_M_SIZE 16
> +#define HDCP2_KD_SIZE 32
> +#define HDCP2_CERTRX_SIZE 522
> +#define HDCP2_EKPUBKM_SIZE 128
> +#define HDCP2_EKHKM_SIZE 16
> +#define HDCP2_KM_SIZE 16
> +#define HDCP2_KH_SIZE 16
> +#define HDCP2_RN_SIZE 8
> +#define HDCP2_LPRIME_SIZE 32
> +#define HDCP2_EDKEYKS_SIZE 16
> +#define HDCP2_KS_SIZE 16
> +#define HDCP2_RIV_SIZE 8
> +#define HDCP2_RXINFO_SIZE 2
> +#define HDCP2_SEQ_NUM_V_SIZE 3
> +#define HDCP2_RECVID_SIZE 5

Is this HDCP_2_2_RECEIVERID_LEN? If this is defined in HDCP
specification, move these definition to include/drm/drm_hdcp.h

Regards,
CK

> +#define HDCP2_VPRIME_SIZE 16
> +#define HDCP2_RECV_ID_LIST_SIZE 155
> +#define HDCP2_SEQ_NUM_M_SIZE 3
> +#define HDCP2_STREAMID_TYPE_SIZE 2
> +#define HDCP2_K_SIZE 2
> +#define HDCP2_REP_MPRIME_SIZE 32
> +#define HDCP2_HPRIME_SIZE 32
> +#define HDCP2_RX_ENCKEY_SIZE 104
> +#define HDCP2_TX_ENCKEY_SIZE 448
> +#define HDCP2_LC128_SIZE 16
> +#define HDCP2_KPUBRX_MODULUS_SIZE 128
> +#define HDCP2_KPUBRX_EXPONENT_SIZE 3
> +#define HDCP2_KPUBRX_RESERVED_SIZE 2
> +#define HDCP2_MAX_DEVICE_COUNT 31
> +#define HDCP2_MAX_DEPTH_LEVEL 4
> +#define HDCP2_KPUB_SIZE 384
> +