linux/drivers/gpu/drm/xe/xe_vram_freq.c

// SPDX-License-Identifier: MIT
/*
 * Copyright © 2024 Intel Corporation
 */
#include <linux/sysfs.h>
#include <drm/drm_managed.h>

#include "xe_gt_types.h"
#include "xe_pcode.h"
#include "xe_pcode_api.h"
#include "xe_tile.h"
#include "xe_tile_sysfs.h"
#include "xe_vram_freq.h"

/**
 * DOC: Xe VRAM freq
 *
 * Provides sysfs entries for vram frequency in tile
 *
 * device/tile#/memory/freq0/max_freq - This is maximum frequency. This value is read-only as it
 *					is the fixed fuse point P0. It is not the system
 *					configuration.
 * device/tile#/memory/freq0/min_freq - This is minimum frequency. This value is read-only as it
 *					is the fixed fuse point PN. It is not the system
 *					configuration.
 */

static struct xe_tile *dev_to_tile(struct device *dev)
{}

static ssize_t max_freq_show(struct device *dev, struct device_attribute *attr,
			     char *buf)
{}
static DEVICE_ATTR_RO(max_freq);

static ssize_t min_freq_show(struct device *dev, struct device_attribute *attr,
			     char *buf)
{}
static DEVICE_ATTR_RO(min_freq);

static struct attribute *freq_attrs[] =;

static const struct attribute_group freq_group_attrs =;

static void vram_freq_sysfs_fini(void *arg)
{}

/**
 * xe_vram_freq_sysfs_init - Initialize vram frequency sysfs component
 * @tile: Xe Tile object
 *
 * It needs to be initialized after the main tile component is ready
 *
 * Returns: 0 on success, negative error code on error.
 */
int xe_vram_freq_sysfs_init(struct xe_tile *tile)
{}