#include <drm/drm_managed.h>
#include <regs/xe_gt_regs.h>
#include "xe_device.h"
#include "xe_gt.h"
#include "xe_gt_sysfs.h"
#include "xe_gt_throttle.h"
#include "xe_mmio.h"
#include "xe_pm.h"
static struct xe_gt *
dev_to_gt(struct device *dev)
{ … }
u32 xe_gt_throttle_get_limit_reasons(struct xe_gt *gt)
{ … }
static u32 read_status(struct xe_gt *gt)
{ … }
static u32 read_reason_pl1(struct xe_gt *gt)
{ … }
static u32 read_reason_pl2(struct xe_gt *gt)
{ … }
static u32 read_reason_pl4(struct xe_gt *gt)
{ … }
static u32 read_reason_thermal(struct xe_gt *gt)
{ … }
static u32 read_reason_prochot(struct xe_gt *gt)
{ … }
static u32 read_reason_ratl(struct xe_gt *gt)
{ … }
static u32 read_reason_vr_thermalert(struct xe_gt *gt)
{ … }
static u32 read_reason_vr_tdc(struct xe_gt *gt)
{ … }
static ssize_t status_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(status);
static ssize_t reason_pl1_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_pl1);
static ssize_t reason_pl2_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_pl2);
static ssize_t reason_pl4_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_pl4);
static ssize_t reason_thermal_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_thermal);
static ssize_t reason_prochot_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_prochot);
static ssize_t reason_ratl_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_ratl);
static ssize_t reason_vr_thermalert_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_vr_thermalert);
static ssize_t reason_vr_tdc_show(struct device *dev,
struct device_attribute *attr,
char *buff)
{ … }
static DEVICE_ATTR_RO(reason_vr_tdc);
static struct attribute *throttle_attrs[] = …;
static const struct attribute_group throttle_group_attrs = …;
static void gt_throttle_sysfs_fini(void *arg)
{ … }
int xe_gt_throttle_init(struct xe_gt *gt)
{ … }