020-backports-do-not-add-debugfs_create_devm_seqfile-on-.patch 1.1 KB

123456789101112131415161718192021222324252627282930313233
  1. From e15e9231e7a9f81f5264d294fd3fd96a20d92516 Mon Sep 17 00:00:00 2001
  2. From: Hauke Mehrtens <[email protected]>
  3. Date: Sat, 25 Jul 2015 15:19:17 +0200
  4. Subject: [PATCH 3/3] backports: do not add debugfs_create_devm_seqfile() on
  5. recent kernel versions
  6. An #ifdef for the kernel version was missing around the header of
  7. debugfs_create_devm_seqfile() and the LINUX_BACKPORT() was also not
  8. done.
  9. Signed-off-by: Hauke Mehrtens <[email protected]>
  10. ---
  11. backport/backport-include/linux/debugfs.h | 3 +++
  12. 1 file changed, 3 insertions(+)
  13. --- a/backport-include/linux/debugfs.h
  14. +++ b/backport-include/linux/debugfs.h
  15. @@ -5,6 +5,8 @@
  16. #include <linux/device.h>
  17. #include <generated/utsrelease.h>
  18. +#if LINUX_VERSION_CODE < KERNEL_VERSION(3,19,0)
  19. +#define debugfs_create_devm_seqfile LINUX_BACKPORT(debugfs_create_devm_seqfile)
  20. #if defined(CONFIG_DEBUG_FS)
  21. struct dentry *debugfs_create_devm_seqfile(struct device *dev, const char *name,
  22. struct dentry *parent,
  23. @@ -20,5 +22,6 @@ static inline struct dentry *debugfs_cre
  24. return ERR_PTR(-ENODEV);
  25. }
  26. #endif /* CONFIG_DEBUG_FS */
  27. +#endif /* LINUX_VERSION_CODE < KERNEL_VERSION(3,19,0) */
  28. #endif /* __BACKPORT_DEBUGFS_H_ */