blob: 0c29913b5a66fbed9dddec9320f19e1f21cb935f [file] [log] [blame]
// SPDX-License-Identifier: GPL-2.0-only
/*
* Copyright (c) 2022 Samsung Electronics Co., Ltd.
*
* Samsung DisplayPort driver.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 as
* published by the Free Software Foundation.
*/
#include <net/sock.h>
#include <linux/netlink.h>
#include <linux/skbuff.h>
#include <linux/delay.h>
#include <linux/module.h>
#include "exynos-hdcp-interface.h"
#include "dpcd.h"
#include "hdcp-log.h"
static void (*pdp_hdcp22_enable)(u32 en);
static int (*pdp_dpcd_read_for_hdcp22)(u32 address, u32 length, u8 *data);
static int (*pdp_dpcd_write_for_hdcp22)(u32 address, u32 length, u8 *data);
int hdcp_dplink_recv(uint32_t addr, uint8_t *data, uint32_t size)
{
return pdp_dpcd_read_for_hdcp22(addr, size, data);
}
int hdcp_dplink_send(uint32_t addr, uint8_t *data, uint32_t size)
{
return pdp_dpcd_write_for_hdcp22(addr, size, data);
}
void dp_register_func_for_hdcp22(void (*func0)(u32 en), int (*func1)(u32 address, u32 length, u8 *data), int (*func2)(u32 address, u32 length, u8 *data))
{
pdp_hdcp22_enable = func0;
pdp_dpcd_read_for_hdcp22 = func1;
pdp_dpcd_write_for_hdcp22 = func2;
}
EXPORT_SYMBOL_GPL(dp_register_func_for_hdcp22);