Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
[firefly-linux-kernel-4.4.55.git] / drivers / gpu / drm / amd / amdkfd / kfd_priv.h
index 2bc34aa1ad95d832dee12e72e59e3b4c7468d78e..f9fb81e3bb09b24edd7f8de6c22cf7e64a92391b 100644 (file)
@@ -279,7 +279,7 @@ struct queue_properties {
        uint32_t queue_percent;
        uint32_t *read_ptr;
        uint32_t *write_ptr;
-       uint32_t *doorbell_ptr;
+       uint32_t __iomem *doorbell_ptr;
        uint32_t doorbell_off;
        bool is_interop;
        bool is_active;
@@ -414,6 +414,8 @@ struct kfd_process_device {
        bool bound;
 };
 
+#define qpd_to_pdd(x) container_of(x, struct kfd_process_device, qpd)
+
 /* Process data */
 struct kfd_process {
        /*
@@ -473,6 +475,12 @@ struct kfd_process_device *kfd_get_process_device_data(struct kfd_dev *dev,
                                                        struct kfd_process *p,
                                                        int create_pdd);
 
+/* Process device data iterator */
+struct kfd_process_device *kfd_get_first_process_device_data(struct kfd_process *p);
+struct kfd_process_device *kfd_get_next_process_device_data(struct kfd_process *p,
+                                               struct kfd_process_device *pdd);
+bool kfd_has_process_device_data(struct kfd_process *p);
+
 /* PASIDs */
 int kfd_pasid_init(void);
 void kfd_pasid_exit(void);