linux/drivers/misc/mei/init.c

// SPDX-License-Identifier: GPL-2.0
/*
 * Copyright (c) 2012-2022, Intel Corporation. All rights reserved.
 * Intel Management Engine Interface (Intel MEI) Linux driver
 */

#include <linux/export.h>
#include <linux/sched.h>
#include <linux/wait.h>
#include <linux/delay.h>

#include <linux/mei.h>

#include "mei_dev.h"
#include "hbm.h"
#include "client.h"

const char *mei_dev_state_str(int state)
{}

const char *mei_pg_state_str(enum mei_pg_state state)
{}

/**
 * mei_fw_status2str - convert fw status registers to printable string
 *
 * @fw_status:  firmware status
 * @buf: string buffer at minimal size MEI_FW_STATUS_STR_SZ
 * @len: buffer len must be >= MEI_FW_STATUS_STR_SZ
 *
 * Return: number of bytes written or -EINVAL if buffer is to small
 */
ssize_t mei_fw_status2str(struct mei_fw_status *fw_status,
			  char *buf, size_t len)
{}
EXPORT_SYMBOL_GPL();

/**
 * mei_cancel_work - Cancel mei background jobs
 *
 * @dev: the device structure
 */
void mei_cancel_work(struct mei_device *dev)
{}
EXPORT_SYMBOL_GPL();

static void mei_save_fw_status(struct mei_device *dev)
{}

/**
 * mei_reset - resets host and fw.
 *
 * @dev: the device structure
 *
 * Return: 0 on success or < 0 if the reset hasn't succeeded
 */
int mei_reset(struct mei_device *dev)
{}
EXPORT_SYMBOL_GPL();

/**
 * mei_start - initializes host and fw to start work.
 *
 * @dev: the device structure
 *
 * Return: 0 on success, <0 on failure.
 */
int mei_start(struct mei_device *dev)
{}
EXPORT_SYMBOL_GPL();

/**
 * mei_restart - restart device after suspend
 *
 * @dev: the device structure
 *
 * Return: 0 on success or -ENODEV if the restart hasn't succeeded
 */
int mei_restart(struct mei_device *dev)
{}
EXPORT_SYMBOL_GPL();

static void mei_reset_work(struct work_struct *work)
{}

void mei_stop(struct mei_device *dev)
{}
EXPORT_SYMBOL_GPL();

/**
 * mei_write_is_idle - check if the write queues are idle
 *
 * @dev: the device structure
 *
 * Return: true of there is no pending write
 */
bool mei_write_is_idle(struct mei_device *dev)
{}
EXPORT_SYMBOL_GPL();

/**
 * mei_device_init - initialize mei_device structure
 *
 * @dev: the mei device
 * @device: the device structure
 * @slow_fw: configure longer timeouts as FW is slow
 * @hw_ops: hw operations
 */
void mei_device_init(struct mei_device *dev,
		     struct device *device,
		     bool slow_fw,
		     const struct mei_hw_ops *hw_ops)
{}
EXPORT_SYMBOL_GPL();