mirror of
git://nv-tegra.nvidia.com/linux-nv-oot.git
synced 2025-12-23 09:42:19 +03:00
This patch moves T264 files to nvidia-oot repo and adds support to to Halify HSP functions for T239. Jira TDS-15438 Change-Id: Ie42d15ab27f9a71312063a4067629030be6869c8 Signed-off-by: Mahesh Kumar <mahkumar@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3233122 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
55 lines
1.8 KiB
C
55 lines
1.8 KiB
C
/* SPDX-License-Identifier: GPL-2.0-only */
|
|
/*
|
|
* Copyright (c) 2024, NVIDIA CORPORATION. All rights reserved.
|
|
*/
|
|
|
|
#ifndef DCE_HSP_T264_H
|
|
#define DCE_HSP_T264_H
|
|
|
|
#include <linux/types.h> // TODO: use dce-types
|
|
|
|
struct tegra_dce;
|
|
|
|
#define DCE_MAX_HSP_T264 2
|
|
#define DCE_MAX_NO_SS_T264 4
|
|
#define DCE_MAX_NO_SMB_T264 8
|
|
#define DCE_MAX_HSP_IE_T264 8
|
|
|
|
/**
|
|
* DCE HSP Shared Semaphore Utility functions. Description
|
|
* can be found with function definitions.
|
|
*/
|
|
u32 dce_ss_get_state_t264(struct tegra_dce *d, u8 hsp_id, u8 id);
|
|
void dce_ss_set_t264(struct tegra_dce *d, u8 bpos, u8 hsp_id, u8 id);
|
|
void dce_ss_clear_t264(struct tegra_dce *d, u8 bpos, u8 hsp_id, u8 id);
|
|
|
|
/**
|
|
* DCE HSP Shared Mailbox Utility functions. Description
|
|
* can be found with function definitions.
|
|
*/
|
|
void dce_smb_set_t264(struct tegra_dce *d, u32 val, u8 hsp_id, u8 id);
|
|
void dce_smb_set_full_ie_t264(struct tegra_dce *d, bool en, u8 hsp_id, u8 id);
|
|
u32 dce_smb_read_full_ie_t264(struct tegra_dce *d, u8 hsp_id, u8 id);
|
|
void dce_smb_set_empty_ie_t264(struct tegra_dce *d, bool en, u8 hsp_id, u8 id);
|
|
u32 dce_smb_read_t264(struct tegra_dce *d, u8 hsp_id, u8 id);
|
|
u32 dce_hsp_ie_read_t264(struct tegra_dce *d, u8 hsp_id, u8 id);
|
|
void dce_hsp_ie_write_t264(struct tegra_dce *d, u32 val, u8 hsp_id, u8 id);
|
|
u32 dce_hsp_ir_read_t264(struct tegra_dce *d, u8 hsp_id);
|
|
|
|
#define DCE_HSP_INIT_T264(hsp) \
|
|
({ \
|
|
hsp.ss_get_state = dce_ss_get_state_t264; \
|
|
hsp.ss_set = dce_ss_set_t264; \
|
|
hsp.ss_clear = dce_ss_clear_t264; \
|
|
hsp.smb_set = dce_smb_set_t264; \
|
|
hsp.smb_set_full_ie = dce_smb_set_full_ie_t264; \
|
|
hsp.smb_read_full_ie = dce_smb_read_full_ie_t264; \
|
|
hsp.smb_set_empty_ie = dce_smb_set_empty_ie_t264; \
|
|
hsp.smb_read = dce_smb_read_t264; \
|
|
hsp.hsp_ie_read = dce_hsp_ie_read_t264; \
|
|
hsp.hsp_ie_write = dce_hsp_ie_write_t264; \
|
|
hsp.hsp_ir_read = dce_hsp_ir_read_t264; \
|
|
})
|
|
|
|
#endif
|