mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-07-22 02:17:36 -04:00
Expose the command doorbell register to userspace on a per-hardware context basis, enabling applications to notify the firmware of pending commands via doorbell writes. Introduce DRM_IOCTL_AMDXDNA_WAIT_CMD to allow userspace to wait for completion of individual commands. Co-developed-by: Hayden Laccabue <Hayden.Laccabue@amd.com> Signed-off-by: Hayden Laccabue <Hayden.Laccabue@amd.com> Signed-off-by: David Zhang <yidong.zhang@amd.com> Reviewed-by: Mario Limonciello (AMD) <superm1@kernel.org> Signed-off-by: Lizhi Hou <lizhi.hou@amd.com> Link: https://patch.msgid.link/20260505160936.3917732-5-lizhi.hou@amd.com
25 lines
500 B
C
25 lines
500 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* Copyright (C) 2026, Advanced Micro Devices, Inc.
|
|
*/
|
|
|
|
#ifndef _AIE4_HOST_QUEUE_H_
|
|
#define _AIE4_HOST_QUEUE_H_
|
|
|
|
#include <linux/types.h>
|
|
|
|
#define CTX_MAX_CMDS 32
|
|
|
|
struct host_queue_header {
|
|
__u64 read_index;
|
|
struct {
|
|
__u16 major;
|
|
__u16 minor;
|
|
} version;
|
|
__u32 capacity; /* Queue capacity, must be power of two. */
|
|
__u64 write_index;
|
|
__u64 data_address; /* The xdna dev addr for payload. */
|
|
};
|
|
|
|
#endif /* _AIE4_HOST_QUEUE_H_ */
|