#include <linux/module.h>
#include <linux/slab.h>
#include <linux/platform_device.h>
#include <linux/mtd/mtd.h>
#include <linux/mtd/onenand.h>
#include <linux/mtd/partitions.h>
#include <linux/io.h>
#define DRIVER_NAME …
struct onenand_info { … };
static int generic_onenand_probe(struct platform_device *pdev)
{ … }
static void generic_onenand_remove(struct platform_device *pdev)
{ … }
static struct platform_driver generic_onenand_driver = …;
module_platform_driver(…) …;
MODULE_LICENSE(…) …;
MODULE_AUTHOR(…) …;
MODULE_DESCRIPTION(…) …;
MODULE_ALIAS(…) …;