gen_probe.h 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. /*
  2. * Copyright © 2001 Red Hat UK Limited
  3. * Copyright © 2001-2010 David Woodhouse <dwmw2@infradead.org>
  4. *
  5. * This program is free software; you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License as published by
  7. * the Free Software Foundation; either version 2 of the License, or
  8. * (at your option) any later version.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. *
  15. * You should have received a copy of the GNU General Public License
  16. * along with this program; if not, write to the Free Software
  17. * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
  18. *
  19. */
  20. #ifndef __LINUX_MTD_GEN_PROBE_H__
  21. #define __LINUX_MTD_GEN_PROBE_H__
  22. #include <linux/mtd/flashchip.h>
  23. #include <linux/mtd/map.h>
  24. #include <linux/mtd/cfi.h>
  25. #include <linux/bitops.h>
  26. struct chip_probe {
  27. char *name;
  28. int (*probe_chip)(struct map_info *map, __u32 base,
  29. unsigned long *chip_map, struct cfi_private *cfi);
  30. };
  31. struct mtd_info *mtd_do_chip_probe(struct map_info *map, struct chip_probe *cp);
  32. #endif /* __LINUX_MTD_GEN_PROBE_H__ */