drm/vc4: Leverage the load tracker on the BCM2711
[sfrench/cifs-2.6.git] / drivers / gpu / drm / vc4 / vc4_debugfs.c
index 6da22af4ee911ccb51507308775d11f87c3b3138..ba2d8ea562af9031a7bdcc285dbb1e779992036e 100644 (file)
@@ -7,6 +7,7 @@
 #include <linux/circ_buf.h>
 #include <linux/ctype.h>
 #include <linux/debugfs.h>
+#include <linux/platform_device.h>
 
 #include "vc4_drv.h"
 #include "vc4_regs.h"
@@ -26,8 +27,10 @@ vc4_debugfs_init(struct drm_minor *minor)
        struct vc4_dev *vc4 = to_vc4_dev(minor->dev);
        struct vc4_debugfs_info_entry *entry;
 
-       debugfs_create_bool("hvs_load_tracker", S_IRUGO | S_IWUSR,
-                           minor->debugfs_root, &vc4->load_tracker_enabled);
+       if (!of_device_is_compatible(vc4->hvs->pdev->dev.of_node,
+                                    "brcm,bcm2711-vc5"))
+               debugfs_create_bool("hvs_load_tracker", S_IRUGO | S_IWUSR,
+                                   minor->debugfs_root, &vc4->load_tracker_enabled);
 
        list_for_each_entry(entry, &vc4->debugfs_list, link) {
                drm_debugfs_create_files(&entry->info, 1,