#include <linux/mod_devicetable.h>
#include <linux/module.h>
#include <linux/mtd/mtd.h>
#include <linux/nvmem-provider.h>
#include <linux/of.h>
#include <linux/platform_device.h>
#include <linux/slab.h>
#include "layouts/u-boot-env.h"
struct u_boot_env { … };
static int u_boot_env_read(void *context, unsigned int offset, void *val,
size_t bytes)
{ … }
static int u_boot_env_probe(struct platform_device *pdev)
{ … }
static const struct of_device_id u_boot_env_of_match_table[] = …;
static struct platform_driver u_boot_env_driver = …;
module_platform_driver(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;
MODULE_DEVICE_TABLE(of, u_boot_env_of_match_table);