Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 1 | /* |
| 2 | * drivers/mtd/nand/gpio.c |
| 3 | * |
| 4 | * Updated, and converted to generic GPIO based driver by Russell King. |
| 5 | * |
| 6 | * Written by Ben Dooks <ben@simtec.co.uk> |
| 7 | * Based on 2.4 version by Mark Whittaker |
| 8 | * |
| 9 | * © 2004 Simtec Electronics |
| 10 | * |
| 11 | * Device driver for NAND connected via GPIO |
| 12 | * |
| 13 | * This program is free software; you can redistribute it and/or modify |
| 14 | * it under the terms of the GNU General Public License version 2 as |
| 15 | * published by the Free Software Foundation. |
| 16 | * |
| 17 | */ |
| 18 | |
| 19 | #include <linux/kernel.h> |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 20 | #include <linux/err.h> |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 21 | #include <linux/init.h> |
| 22 | #include <linux/slab.h> |
| 23 | #include <linux/module.h> |
| 24 | #include <linux/platform_device.h> |
| 25 | #include <linux/gpio.h> |
| 26 | #include <linux/io.h> |
| 27 | #include <linux/mtd/mtd.h> |
| 28 | #include <linux/mtd/nand.h> |
| 29 | #include <linux/mtd/partitions.h> |
| 30 | #include <linux/mtd/nand-gpio.h> |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 31 | #include <linux/of.h> |
| 32 | #include <linux/of_address.h> |
| 33 | #include <linux/of_gpio.h> |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 34 | |
| 35 | struct gpiomtd { |
| 36 | void __iomem *io_sync; |
| 37 | struct mtd_info mtd_info; |
| 38 | struct nand_chip nand_chip; |
| 39 | struct gpio_nand_platdata plat; |
| 40 | }; |
| 41 | |
| 42 | #define gpio_nand_getpriv(x) container_of(x, struct gpiomtd, mtd_info) |
| 43 | |
| 44 | |
| 45 | #ifdef CONFIG_ARM |
| 46 | /* gpio_nand_dosync() |
| 47 | * |
| 48 | * Make sure the GPIO state changes occur in-order with writes to NAND |
| 49 | * memory region. |
| 50 | * Needed on PXA due to bus-reordering within the SoC itself (see section on |
| 51 | * I/O ordering in PXA manual (section 2.3, p35) |
| 52 | */ |
| 53 | static void gpio_nand_dosync(struct gpiomtd *gpiomtd) |
| 54 | { |
| 55 | unsigned long tmp; |
| 56 | |
| 57 | if (gpiomtd->io_sync) { |
| 58 | /* |
| 59 | * Linux memory barriers don't cater for what's required here. |
| 60 | * What's required is what's here - a read from a separate |
| 61 | * region with a dependency on that read. |
| 62 | */ |
| 63 | tmp = readl(gpiomtd->io_sync); |
| 64 | asm volatile("mov %1, %0\n" : "=r" (tmp) : "r" (tmp)); |
| 65 | } |
| 66 | } |
| 67 | #else |
| 68 | static inline void gpio_nand_dosync(struct gpiomtd *gpiomtd) {} |
| 69 | #endif |
| 70 | |
| 71 | static void gpio_nand_cmd_ctrl(struct mtd_info *mtd, int cmd, unsigned int ctrl) |
| 72 | { |
| 73 | struct gpiomtd *gpiomtd = gpio_nand_getpriv(mtd); |
| 74 | |
| 75 | gpio_nand_dosync(gpiomtd); |
| 76 | |
| 77 | if (ctrl & NAND_CTRL_CHANGE) { |
| 78 | gpio_set_value(gpiomtd->plat.gpio_nce, !(ctrl & NAND_NCE)); |
| 79 | gpio_set_value(gpiomtd->plat.gpio_cle, !!(ctrl & NAND_CLE)); |
| 80 | gpio_set_value(gpiomtd->plat.gpio_ale, !!(ctrl & NAND_ALE)); |
| 81 | gpio_nand_dosync(gpiomtd); |
| 82 | } |
| 83 | if (cmd == NAND_CMD_NONE) |
| 84 | return; |
| 85 | |
| 86 | writeb(cmd, gpiomtd->nand_chip.IO_ADDR_W); |
| 87 | gpio_nand_dosync(gpiomtd); |
| 88 | } |
| 89 | |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 90 | static int gpio_nand_devready(struct mtd_info *mtd) |
| 91 | { |
| 92 | struct gpiomtd *gpiomtd = gpio_nand_getpriv(mtd); |
Alexander Shiyan | 18afbc5 | 2012-10-17 10:08:27 +0400 | [diff] [blame] | 93 | |
Alexander Shiyan | c85d32d5 | 2013-05-06 17:53:49 +0400 | [diff] [blame] | 94 | return gpio_get_value(gpiomtd->plat.gpio_rdy); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 95 | } |
| 96 | |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 97 | #ifdef CONFIG_OF |
| 98 | static const struct of_device_id gpio_nand_id_table[] = { |
| 99 | { .compatible = "gpio-control-nand" }, |
| 100 | {} |
| 101 | }; |
| 102 | MODULE_DEVICE_TABLE(of, gpio_nand_id_table); |
| 103 | |
| 104 | static int gpio_nand_get_config_of(const struct device *dev, |
| 105 | struct gpio_nand_platdata *plat) |
| 106 | { |
| 107 | u32 val; |
| 108 | |
Alexander Shiyan | ee4f366 | 2013-05-06 17:53:50 +0400 | [diff] [blame] | 109 | if (!dev->of_node) |
| 110 | return -ENODEV; |
| 111 | |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 112 | if (!of_property_read_u32(dev->of_node, "bank-width", &val)) { |
| 113 | if (val == 2) { |
| 114 | plat->options |= NAND_BUSWIDTH_16; |
| 115 | } else if (val != 1) { |
| 116 | dev_err(dev, "invalid bank-width %u\n", val); |
| 117 | return -EINVAL; |
| 118 | } |
| 119 | } |
| 120 | |
| 121 | plat->gpio_rdy = of_get_gpio(dev->of_node, 0); |
| 122 | plat->gpio_nce = of_get_gpio(dev->of_node, 1); |
| 123 | plat->gpio_ale = of_get_gpio(dev->of_node, 2); |
| 124 | plat->gpio_cle = of_get_gpio(dev->of_node, 3); |
| 125 | plat->gpio_nwp = of_get_gpio(dev->of_node, 4); |
| 126 | |
| 127 | if (!of_property_read_u32(dev->of_node, "chip-delay", &val)) |
| 128 | plat->chip_delay = val; |
| 129 | |
| 130 | return 0; |
| 131 | } |
| 132 | |
| 133 | static struct resource *gpio_nand_get_io_sync_of(struct platform_device *pdev) |
| 134 | { |
| 135 | struct resource *r = devm_kzalloc(&pdev->dev, sizeof(*r), GFP_KERNEL); |
| 136 | u64 addr; |
| 137 | |
| 138 | if (!r || of_property_read_u64(pdev->dev.of_node, |
| 139 | "gpio-control-nand,io-sync-reg", &addr)) |
| 140 | return NULL; |
| 141 | |
| 142 | r->start = addr; |
| 143 | r->end = r->start + 0x3; |
| 144 | r->flags = IORESOURCE_MEM; |
| 145 | |
| 146 | return r; |
| 147 | } |
| 148 | #else /* CONFIG_OF */ |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 149 | static inline int gpio_nand_get_config_of(const struct device *dev, |
| 150 | struct gpio_nand_platdata *plat) |
| 151 | { |
| 152 | return -ENOSYS; |
| 153 | } |
| 154 | |
| 155 | static inline struct resource * |
| 156 | gpio_nand_get_io_sync_of(struct platform_device *pdev) |
| 157 | { |
| 158 | return NULL; |
| 159 | } |
| 160 | #endif /* CONFIG_OF */ |
| 161 | |
| 162 | static inline int gpio_nand_get_config(const struct device *dev, |
| 163 | struct gpio_nand_platdata *plat) |
| 164 | { |
| 165 | int ret = gpio_nand_get_config_of(dev, plat); |
| 166 | |
| 167 | if (!ret) |
| 168 | return ret; |
| 169 | |
Jingoo Han | 453810b | 2013-07-30 17:18:33 +0900 | [diff] [blame] | 170 | if (dev_get_platdata(dev)) { |
| 171 | memcpy(plat, dev_get_platdata(dev), sizeof(*plat)); |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 172 | return 0; |
| 173 | } |
| 174 | |
| 175 | return -EINVAL; |
| 176 | } |
| 177 | |
| 178 | static inline struct resource * |
| 179 | gpio_nand_get_io_sync(struct platform_device *pdev) |
| 180 | { |
| 181 | struct resource *r = gpio_nand_get_io_sync_of(pdev); |
| 182 | |
| 183 | if (r) |
| 184 | return r; |
| 185 | |
| 186 | return platform_get_resource(pdev, IORESOURCE_MEM, 1); |
| 187 | } |
| 188 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 189 | static int gpio_nand_remove(struct platform_device *pdev) |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 190 | { |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 191 | struct gpiomtd *gpiomtd = platform_get_drvdata(pdev); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 192 | |
| 193 | nand_release(&gpiomtd->mtd_info); |
| 194 | |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 195 | if (gpio_is_valid(gpiomtd->plat.gpio_nwp)) |
| 196 | gpio_set_value(gpiomtd->plat.gpio_nwp, 0); |
| 197 | gpio_set_value(gpiomtd->plat.gpio_nce, 1); |
| 198 | |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 199 | return 0; |
| 200 | } |
| 201 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 202 | static int gpio_nand_probe(struct platform_device *pdev) |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 203 | { |
| 204 | struct gpiomtd *gpiomtd; |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 205 | struct nand_chip *chip; |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 206 | struct resource *res; |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 207 | struct mtd_part_parser_data ppdata = {}; |
| 208 | int ret = 0; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 209 | |
Jingoo Han | 453810b | 2013-07-30 17:18:33 +0900 | [diff] [blame] | 210 | if (!pdev->dev.of_node && !dev_get_platdata(&pdev->dev)) |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 211 | return -EINVAL; |
| 212 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 213 | gpiomtd = devm_kzalloc(&pdev->dev, sizeof(*gpiomtd), GFP_KERNEL); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 214 | if (!gpiomtd) { |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 215 | dev_err(&pdev->dev, "failed to create NAND MTD\n"); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 216 | return -ENOMEM; |
| 217 | } |
| 218 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 219 | chip = &gpiomtd->nand_chip; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 220 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 221 | res = platform_get_resource(pdev, IORESOURCE_MEM, 0); |
| 222 | chip->IO_ADDR_R = devm_ioremap_resource(&pdev->dev, res); |
| 223 | if (IS_ERR(chip->IO_ADDR_R)) |
| 224 | return PTR_ERR(chip->IO_ADDR_R); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 225 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 226 | res = gpio_nand_get_io_sync(pdev); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 227 | if (res) { |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 228 | gpiomtd->io_sync = devm_ioremap_resource(&pdev->dev, res); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 229 | if (IS_ERR(gpiomtd->io_sync)) |
| 230 | return PTR_ERR(gpiomtd->io_sync); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 231 | } |
| 232 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 233 | ret = gpio_nand_get_config(&pdev->dev, &gpiomtd->plat); |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 234 | if (ret) |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 235 | return ret; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 236 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 237 | ret = devm_gpio_request(&pdev->dev, gpiomtd->plat.gpio_nce, "NAND NCE"); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 238 | if (ret) |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 239 | return ret; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 240 | gpio_direction_output(gpiomtd->plat.gpio_nce, 1); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 241 | |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 242 | if (gpio_is_valid(gpiomtd->plat.gpio_nwp)) { |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 243 | ret = devm_gpio_request(&pdev->dev, gpiomtd->plat.gpio_nwp, |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 244 | "NAND NWP"); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 245 | if (ret) |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 246 | return ret; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 247 | } |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 248 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 249 | ret = devm_gpio_request(&pdev->dev, gpiomtd->plat.gpio_ale, "NAND ALE"); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 250 | if (ret) |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 251 | return ret; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 252 | gpio_direction_output(gpiomtd->plat.gpio_ale, 0); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 253 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 254 | ret = devm_gpio_request(&pdev->dev, gpiomtd->plat.gpio_cle, "NAND CLE"); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 255 | if (ret) |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 256 | return ret; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 257 | gpio_direction_output(gpiomtd->plat.gpio_cle, 0); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 258 | |
Alexander Shiyan | 18afbc5 | 2012-10-17 10:08:27 +0400 | [diff] [blame] | 259 | if (gpio_is_valid(gpiomtd->plat.gpio_rdy)) { |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 260 | ret = devm_gpio_request(&pdev->dev, gpiomtd->plat.gpio_rdy, |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 261 | "NAND RDY"); |
Alexander Shiyan | 18afbc5 | 2012-10-17 10:08:27 +0400 | [diff] [blame] | 262 | if (ret) |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 263 | return ret; |
Alexander Shiyan | 18afbc5 | 2012-10-17 10:08:27 +0400 | [diff] [blame] | 264 | gpio_direction_input(gpiomtd->plat.gpio_rdy); |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 265 | chip->dev_ready = gpio_nand_devready; |
Alexander Shiyan | 18afbc5 | 2012-10-17 10:08:27 +0400 | [diff] [blame] | 266 | } |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 267 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 268 | chip->IO_ADDR_W = chip->IO_ADDR_R; |
| 269 | chip->ecc.mode = NAND_ECC_SOFT; |
| 270 | chip->options = gpiomtd->plat.options; |
| 271 | chip->chip_delay = gpiomtd->plat.chip_delay; |
| 272 | chip->cmd_ctrl = gpio_nand_cmd_ctrl; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 273 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 274 | gpiomtd->mtd_info.priv = chip; |
| 275 | gpiomtd->mtd_info.owner = THIS_MODULE; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 276 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 277 | platform_set_drvdata(pdev, gpiomtd); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 278 | |
| 279 | if (gpio_is_valid(gpiomtd->plat.gpio_nwp)) |
| 280 | gpio_direction_output(gpiomtd->plat.gpio_nwp, 1); |
| 281 | |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 282 | if (nand_scan(&gpiomtd->mtd_info, 1)) { |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 283 | ret = -ENXIO; |
| 284 | goto err_wp; |
| 285 | } |
| 286 | |
| 287 | if (gpiomtd->plat.adjust_parts) |
| 288 | gpiomtd->plat.adjust_parts(&gpiomtd->plat, |
| 289 | gpiomtd->mtd_info.size); |
| 290 | |
Alexander Shiyan | f8e81c2 | 2013-05-06 17:53:53 +0400 | [diff] [blame] | 291 | ppdata.of_node = pdev->dev.of_node; |
Jamie Iles | 775c3220 | 2011-12-18 10:00:49 +0000 | [diff] [blame] | 292 | ret = mtd_device_parse_register(&gpiomtd->mtd_info, NULL, &ppdata, |
| 293 | gpiomtd->plat.parts, |
| 294 | gpiomtd->plat.num_parts); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 295 | if (!ret) |
| 296 | return 0; |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 297 | |
| 298 | err_wp: |
| 299 | if (gpio_is_valid(gpiomtd->plat.gpio_nwp)) |
| 300 | gpio_set_value(gpiomtd->plat.gpio_nwp, 0); |
Alexander Shiyan | 283df42 | 2013-05-06 17:53:48 +0400 | [diff] [blame] | 301 | |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 302 | return ret; |
| 303 | } |
| 304 | |
| 305 | static struct platform_driver gpio_nand_driver = { |
| 306 | .probe = gpio_nand_probe, |
| 307 | .remove = gpio_nand_remove, |
| 308 | .driver = { |
| 309 | .name = "gpio-nand", |
Alexander Shiyan | 65c972a | 2013-05-06 17:53:54 +0400 | [diff] [blame] | 310 | .owner = THIS_MODULE, |
Sachin Kamat | b57d43f | 2013-03-14 15:37:03 +0530 | [diff] [blame] | 311 | .of_match_table = of_match_ptr(gpio_nand_id_table), |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 312 | }, |
| 313 | }; |
| 314 | |
Sachin Kamat | 2fe87ae | 2012-09-05 15:31:32 +0530 | [diff] [blame] | 315 | module_platform_driver(gpio_nand_driver); |
Mike Rapoport | aaf7ea2 | 2008-10-15 08:38:49 +0200 | [diff] [blame] | 316 | |
| 317 | MODULE_LICENSE("GPL"); |
| 318 | MODULE_AUTHOR("Ben Dooks <ben@simtec.co.uk>"); |
| 319 | MODULE_DESCRIPTION("GPIO NAND Driver"); |