#include <linux/device.h>
#include <linux/errno.h>
#include <linux/slab.h>
#include <linux/fsi-occ.h>
#include <linux/mm.h>
#include <linux/module.h>
#include <linux/mod_devicetable.h>
#include <linux/mutex.h>
#include <linux/platform_device.h>
#include <linux/string.h>
#include <linux/sysfs.h>
#include "common.h"
#define OCC_CHECKSUM_RETRIES …
struct p9_sbe_occ { … };
#define to_p9_sbe_occ(x) …
static ssize_t ffdc_read(struct file *filp, struct kobject *kobj,
struct bin_attribute *battr, char *buf, loff_t pos,
size_t count)
{ … }
static BIN_ATTR_RO(ffdc, OCC_MAX_RESP_WORDS * 4);
static bool p9_sbe_occ_save_ffdc(struct p9_sbe_occ *ctx, const void *resp,
size_t resp_len)
{ … }
static int p9_sbe_occ_send_cmd(struct occ *occ, u8 *cmd, size_t len,
void *resp, size_t resp_len)
{ … }
static int p9_sbe_occ_probe(struct platform_device *pdev)
{ … }
static void p9_sbe_occ_remove(struct platform_device *pdev)
{ … }
static const struct of_device_id p9_sbe_occ_of_match[] = …;
MODULE_DEVICE_TABLE(of, p9_sbe_occ_of_match);
static struct platform_driver p9_sbe_occ_driver = …;
module_platform_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;