linux/drivers/gpu/drm/msm/msm_perf.c

// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (C) 2013 Red Hat
 * Author: Rob Clark <[email protected]>
 */

/* For profiling, userspace can:
 *
 *   tail -f /sys/kernel/debug/dri/<minor>/gpu
 *
 * This will enable performance counters/profiling to track the busy time
 * and any gpu specific performance counters that are supported.
 */

#ifdef CONFIG_DEBUG_FS

#include <linux/debugfs.h>
#include <linux/uaccess.h>

#include <drm/drm_file.h>

#include "msm_drv.h"
#include "msm_gpu.h"

struct msm_perf_state {};

#define SAMPLE_TIME

/* wait for next sample time: */
static int wait_sample(struct msm_perf_state *perf)
{}

static int refill_buf(struct msm_perf_state *perf)
{}

static ssize_t perf_read(struct file *file, char __user *buf,
		size_t sz, loff_t *ppos)
{}

static int perf_open(struct inode *inode, struct file *file)
{}

static int perf_release(struct inode *inode, struct file *file)
{}


static const struct file_operations perf_debugfs_fops =;

int msm_perf_debugfs_init(struct drm_minor *minor)
{}

void msm_perf_debugfs_cleanup(struct msm_drm_private *priv)
{}

#endif