Lines Matching refs:mqd
35 static inline struct v10_compute_mqd *get_mqd(void *mqd) in get_mqd() argument
37 return (struct v10_compute_mqd *)mqd; in get_mqd()
40 static inline struct v10_sdma_mqd *get_sdma_mqd(void *mqd) in get_sdma_mqd() argument
42 return (struct v10_sdma_mqd *)mqd; in get_sdma_mqd()
45 static void update_cu_mask(struct mqd_manager *mm, void *mqd, in update_cu_mask() argument
58 m = get_mqd(mqd); in update_cu_mask()
89 static void init_mqd(struct mqd_manager *mm, void **mqd, in init_mqd() argument
138 *mqd = m; in init_mqd()
144 static int load_mqd(struct mqd_manager *mm, void *mqd, in load_mqd() argument
152 r = mm->dev->kfd2kgd->hqd_load(mm->dev->adev, mqd, pipe_id, queue_id, in load_mqd()
158 static void update_mqd(struct mqd_manager *mm, void *mqd, in update_mqd() argument
164 m = get_mqd(mqd); in update_mqd()
216 update_cu_mask(mm, mqd, minfo); in update_mqd()
222 static uint32_t read_doorbell_id(void *mqd) in read_doorbell_id() argument
224 struct v10_compute_mqd *m = (struct v10_compute_mqd *)mqd; in read_doorbell_id()
229 static int get_wave_state(struct mqd_manager *mm, void *mqd, in get_wave_state() argument
236 m = get_mqd(mqd); in get_wave_state()
256 static void checkpoint_mqd(struct mqd_manager *mm, void *mqd, void *mqd_dst, void *ctl_stack_dst) in checkpoint_mqd() argument
260 m = get_mqd(mqd); in checkpoint_mqd()
265 static void restore_mqd(struct mqd_manager *mm, void **mqd, in restore_mqd() argument
279 *mqd = m; in restore_mqd()
292 static void init_mqd_hiq(struct mqd_manager *mm, void **mqd, in init_mqd_hiq() argument
298 init_mqd(mm, mqd, mqd_mem_obj, gart_addr, q); in init_mqd_hiq()
300 m = get_mqd(*mqd); in init_mqd_hiq()
306 static void init_mqd_sdma(struct mqd_manager *mm, void **mqd, in init_mqd_sdma() argument
316 *mqd = m; in init_mqd_sdma()
325 static void update_mqd_sdma(struct mqd_manager *mm, void *mqd, in update_mqd_sdma() argument
331 m = get_sdma_mqd(mqd); in update_mqd_sdma()
353 void *mqd, in checkpoint_mqd_sdma() argument
359 m = get_sdma_mqd(mqd); in checkpoint_mqd_sdma()
364 static void restore_mqd_sdma(struct mqd_manager *mm, void **mqd, in restore_mqd_sdma() argument
382 *mqd = m; in restore_mqd_sdma()
410 struct mqd_manager *mqd; in mqd_manager_init_v10() local
415 mqd = kzalloc(sizeof(*mqd), GFP_KERNEL); in mqd_manager_init_v10()
416 if (!mqd) in mqd_manager_init_v10()
419 mqd->dev = dev; in mqd_manager_init_v10()
424 mqd->allocate_mqd = allocate_mqd; in mqd_manager_init_v10()
425 mqd->init_mqd = init_mqd; in mqd_manager_init_v10()
426 mqd->free_mqd = kfd_free_mqd_cp; in mqd_manager_init_v10()
427 mqd->load_mqd = load_mqd; in mqd_manager_init_v10()
428 mqd->update_mqd = update_mqd; in mqd_manager_init_v10()
429 mqd->destroy_mqd = kfd_destroy_mqd_cp; in mqd_manager_init_v10()
430 mqd->is_occupied = kfd_is_occupied_cp; in mqd_manager_init_v10()
431 mqd->mqd_size = sizeof(struct v10_compute_mqd); in mqd_manager_init_v10()
432 mqd->get_wave_state = get_wave_state; in mqd_manager_init_v10()
433 mqd->checkpoint_mqd = checkpoint_mqd; in mqd_manager_init_v10()
434 mqd->restore_mqd = restore_mqd; in mqd_manager_init_v10()
436 mqd->debugfs_show_mqd = debugfs_show_mqd; in mqd_manager_init_v10()
442 mqd->allocate_mqd = allocate_hiq_mqd; in mqd_manager_init_v10()
443 mqd->init_mqd = init_mqd_hiq; in mqd_manager_init_v10()
444 mqd->free_mqd = free_mqd_hiq_sdma; in mqd_manager_init_v10()
445 mqd->load_mqd = kfd_hiq_load_mqd_kiq; in mqd_manager_init_v10()
446 mqd->update_mqd = update_mqd; in mqd_manager_init_v10()
447 mqd->destroy_mqd = kfd_destroy_mqd_cp; in mqd_manager_init_v10()
448 mqd->is_occupied = kfd_is_occupied_cp; in mqd_manager_init_v10()
449 mqd->mqd_size = sizeof(struct v10_compute_mqd); in mqd_manager_init_v10()
451 mqd->debugfs_show_mqd = debugfs_show_mqd; in mqd_manager_init_v10()
453 mqd->read_doorbell_id = read_doorbell_id; in mqd_manager_init_v10()
457 mqd->allocate_mqd = allocate_mqd; in mqd_manager_init_v10()
458 mqd->init_mqd = init_mqd_hiq; in mqd_manager_init_v10()
459 mqd->free_mqd = kfd_free_mqd_cp; in mqd_manager_init_v10()
460 mqd->load_mqd = load_mqd; in mqd_manager_init_v10()
461 mqd->update_mqd = update_mqd; in mqd_manager_init_v10()
462 mqd->destroy_mqd = kfd_destroy_mqd_cp; in mqd_manager_init_v10()
463 mqd->is_occupied = kfd_is_occupied_cp; in mqd_manager_init_v10()
464 mqd->mqd_size = sizeof(struct v10_compute_mqd); in mqd_manager_init_v10()
466 mqd->debugfs_show_mqd = debugfs_show_mqd; in mqd_manager_init_v10()
471 mqd->allocate_mqd = allocate_sdma_mqd; in mqd_manager_init_v10()
472 mqd->init_mqd = init_mqd_sdma; in mqd_manager_init_v10()
473 mqd->free_mqd = free_mqd_hiq_sdma; in mqd_manager_init_v10()
474 mqd->load_mqd = kfd_load_mqd_sdma; in mqd_manager_init_v10()
475 mqd->update_mqd = update_mqd_sdma; in mqd_manager_init_v10()
476 mqd->destroy_mqd = kfd_destroy_mqd_sdma; in mqd_manager_init_v10()
477 mqd->is_occupied = kfd_is_occupied_sdma; in mqd_manager_init_v10()
478 mqd->checkpoint_mqd = checkpoint_mqd_sdma; in mqd_manager_init_v10()
479 mqd->restore_mqd = restore_mqd_sdma; in mqd_manager_init_v10()
480 mqd->mqd_size = sizeof(struct v10_sdma_mqd); in mqd_manager_init_v10()
482 mqd->debugfs_show_mqd = debugfs_show_mqd_sdma; in mqd_manager_init_v10()
487 kfree(mqd); in mqd_manager_init_v10()
491 return mqd; in mqd_manager_init_v10()