linux/drivers/virt/acrn/hsm.c

// SPDX-License-Identifier: GPL-2.0
/*
 * ACRN Hypervisor Service Module (HSM)
 *
 * Copyright (C) 2020 Intel Corporation. All rights reserved.
 *
 * Authors:
 *	Fengwei Yin <[email protected]>
 *	Yakui Zhao <[email protected]>
 */

#include <linux/cpu.h>
#include <linux/io.h>
#include <linux/mm.h>
#include <linux/module.h>
#include <linux/slab.h>

#include <asm/acrn.h>
#include <asm/hypervisor.h>

#include "acrn_drv.h"

/*
 * When /dev/acrn_hsm is opened, a 'struct acrn_vm' object is created to
 * represent a VM instance and continues to be associated with the opened file
 * descriptor. All ioctl operations on this file descriptor will be targeted to
 * the VM instance. Release of this file descriptor will destroy the object.
 */
static int acrn_dev_open(struct inode *inode, struct file *filp)
{}

static int pmcmd_ioctl(u64 cmd, void __user *uptr)
{}

/*
 * HSM relies on hypercall layer of the ACRN hypervisor to do the
 * sanity check against the input parameters.
 */
static long acrn_dev_ioctl(struct file *filp, unsigned int cmd,
			   unsigned long ioctl_param)
{}

static int acrn_dev_release(struct inode *inode, struct file *filp)
{}

static ssize_t remove_cpu_store(struct device *dev,
				struct device_attribute *attr,
				const char *buf, size_t count)
{}
static DEVICE_ATTR_WO(remove_cpu);

static umode_t acrn_attr_visible(struct kobject *kobj, struct attribute *a, int n)
{}

static struct attribute *acrn_attrs[] =;

static struct attribute_group acrn_attr_group =;

static const struct attribute_group *acrn_attr_groups[] =;

static const struct file_operations acrn_fops =;

struct miscdevice acrn_dev =;

static int __init hsm_init(void)
{}

static void __exit hsm_exit(void)
{}
module_init();
module_exit(hsm_exit);

MODULE_AUTHOR();
MODULE_LICENSE();
MODULE_DESCRIPTION();