Squashed backup commit (no shallow-clone history issues) of xiaomi-mt6833-dev/kernel_xiaomi_mt6833 (lineage-23.2 branch, upstream commit 9eece662e) plus all fixes applied to get everpal_defconfig building clean against a modern (GCC 15.2.0) toolchain -- see the previous commit message on the lineage-23.2 branch (also in this repo history is not available here since this is a squashed snapshot; full incremental history lives in the local DL380 checkout and the upstream GitHub remote). Upstream: https://github.com/xiaomi-mt6833-dev/kernel_xiaomi_mt6833 (lineage-23.2)
44 lines
1.3 KiB
C
44 lines
1.3 KiB
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#ifndef __NVKM_LTC_H__
|
|
#define __NVKM_LTC_H__
|
|
#include <core/subdev.h>
|
|
#include <core/mm.h>
|
|
|
|
#define NVKM_LTC_MAX_ZBC_CNT 16
|
|
|
|
struct nvkm_ltc {
|
|
const struct nvkm_ltc_func *func;
|
|
struct nvkm_subdev subdev;
|
|
|
|
u32 ltc_nr;
|
|
u32 lts_nr;
|
|
|
|
u32 num_tags;
|
|
u32 tag_base;
|
|
struct nvkm_mm tags;
|
|
struct nvkm_mm_node *tag_ram;
|
|
|
|
int zbc_min;
|
|
int zbc_max;
|
|
u32 zbc_color[NVKM_LTC_MAX_ZBC_CNT][4];
|
|
u32 zbc_depth[NVKM_LTC_MAX_ZBC_CNT];
|
|
};
|
|
|
|
int nvkm_ltc_tags_alloc(struct nvkm_ltc *, u32 count, struct nvkm_mm_node **);
|
|
void nvkm_ltc_tags_free(struct nvkm_ltc *, struct nvkm_mm_node **);
|
|
void nvkm_ltc_tags_clear(struct nvkm_ltc *, u32 first, u32 count);
|
|
|
|
int nvkm_ltc_zbc_color_get(struct nvkm_ltc *, int index, const u32[4]);
|
|
int nvkm_ltc_zbc_depth_get(struct nvkm_ltc *, int index, const u32);
|
|
|
|
void nvkm_ltc_invalidate(struct nvkm_ltc *);
|
|
void nvkm_ltc_flush(struct nvkm_ltc *);
|
|
|
|
int gf100_ltc_new(struct nvkm_device *, int, struct nvkm_ltc **);
|
|
int gk104_ltc_new(struct nvkm_device *, int, struct nvkm_ltc **);
|
|
int gk20a_ltc_new(struct nvkm_device *, int, struct nvkm_ltc **);
|
|
int gm107_ltc_new(struct nvkm_device *, int, struct nvkm_ltc **);
|
|
int gm200_ltc_new(struct nvkm_device *, int, struct nvkm_ltc **);
|
|
int gp100_ltc_new(struct nvkm_device *, int, struct nvkm_ltc **);
|
|
#endif
|