vxfs_kcompat.h
上传用户:jlfgdled
上传日期:2013-04-10
资源大小:33168k
文件大小:0k
源码类别:

Linux/Unix编程

开发平台:

Unix_Linux

  1. #ifndef _VXFS_KCOMPAT_H
  2. #define _VXFS_KCOMPAT_H
  3. #include <linux/version.h>
  4. #if (LINUX_VERSION_CODE < KERNEL_VERSION(2,5,0))
  5. #include <linux/blkdev.h>
  6. typedef long sector_t;
  7. /* Dito.  */
  8. static inline void map_bh(struct buffer_head *bh, struct super_block *sb, int block)
  9. {
  10. bh->b_state |= 1 << BH_Mapped;
  11. bh->b_dev = sb->s_dev;
  12. bh->b_blocknr = block;
  13. }
  14. #endif /* Kernel 2.4 */
  15. #endif /* _VXFS_KCOMPAT_H */