aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/drm/amd')
-rw-r--r--drivers/gpu/drm/amd/include/kgd_kfd_interface.h22
1 files changed, 19 insertions, 3 deletions
diff --git a/drivers/gpu/drm/amd/include/kgd_kfd_interface.h b/drivers/gpu/drm/amd/include/kgd_kfd_interface.h
index 47b551970a14..094631f61339 100644
--- a/drivers/gpu/drm/amd/include/kgd_kfd_interface.h
+++ b/drivers/gpu/drm/amd/include/kgd_kfd_interface.h
@@ -144,10 +144,18 @@ struct kgd2kfd_calls {
144 * @hqd_load: Loads the mqd structure to a H/W hqd slot. used only for no cp 144 * @hqd_load: Loads the mqd structure to a H/W hqd slot. used only for no cp
145 * sceduling mode. 145 * sceduling mode.
146 * 146 *
147 * @hqd_sdma_load: Loads the SDMA mqd structure to a H/W SDMA hqd slot.
148 * used only for no HWS mode.
149 *
147 * @hqd_is_occupies: Checks if a hqd slot is occupied. 150 * @hqd_is_occupies: Checks if a hqd slot is occupied.
148 * 151 *
149 * @hqd_destroy: Destructs and preempts the queue assigned to that hqd slot. 152 * @hqd_destroy: Destructs and preempts the queue assigned to that hqd slot.
150 * 153 *
154 * @hqd_sdma_is_occupied: Checks if an SDMA hqd slot is occupied.
155 *
156 * @hqd_sdma_destroy: Destructs and preempts the SDMA queue assigned to that
157 * SDMA hqd slot.
158 *
151 * @get_fw_version: Returns FW versions from the header 159 * @get_fw_version: Returns FW versions from the header
152 * 160 *
153 * This structure contains function pointers to services that the kgd driver 161 * This structure contains function pointers to services that the kgd driver
@@ -183,18 +191,26 @@ struct kfd2kgd_calls {
183 int (*hqd_load)(struct kgd_dev *kgd, void *mqd, uint32_t pipe_id, 191 int (*hqd_load)(struct kgd_dev *kgd, void *mqd, uint32_t pipe_id,
184 uint32_t queue_id, uint32_t __user *wptr); 192 uint32_t queue_id, uint32_t __user *wptr);
185 193
194 int (*hqd_sdma_load)(struct kgd_dev *kgd, void *mqd);
195
186 bool (*hqd_is_occupies)(struct kgd_dev *kgd, uint64_t queue_address, 196 bool (*hqd_is_occupies)(struct kgd_dev *kgd, uint64_t queue_address,
187 uint32_t pipe_id, uint32_t queue_id); 197 uint32_t pipe_id, uint32_t queue_id);
188 198
189 int (*hqd_destroy)(struct kgd_dev *kgd, uint32_t reset_type, 199 int (*hqd_destroy)(struct kgd_dev *kgd, uint32_t reset_type,
190 unsigned int timeout, uint32_t pipe_id, 200 unsigned int timeout, uint32_t pipe_id,
191 uint32_t queue_id); 201 uint32_t queue_id);
202
203 bool (*hqd_sdma_is_occupied)(struct kgd_dev *kgd, void *mqd);
204
205 int (*hqd_sdma_destroy)(struct kgd_dev *kgd, void *mqd,
206 unsigned int timeout);
207
192 uint16_t (*get_fw_version)(struct kgd_dev *kgd, 208 uint16_t (*get_fw_version)(struct kgd_dev *kgd,
193 enum kgd_engine_type type); 209 enum kgd_engine_type type);
194}; 210};
195 211
196bool kgd2kfd_init(unsigned interface_version, 212bool kgd2kfd_init(unsigned interface_version,
197 const struct kfd2kgd_calls *f2g, 213 const struct kfd2kgd_calls *f2g,
198 const struct kgd2kfd_calls **g2f); 214 const struct kgd2kfd_calls **g2f);
199 215
200#endif /* KGD_KFD_INTERFACE_H_INCLUDED */ 216#endif /* KGD_KFD_INTERFACE_H_INCLUDED */