OpenSDE Packages Database (without history before r20070)
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

146 lines
4.8 KiB

  1. # --- SDE-COPYRIGHT-NOTE-BEGIN ---
  2. # This copyright note is auto-generated by ./scripts/Create-CopyPatch.
  3. #
  4. # Filename: package/.../linux26/linux-2.6.git-b3a6ffe16b5cc48abe7db8d04882dc45280eb693.patch
  5. # Copyright (C) 2009 The OpenSDE Project
  6. #
  7. # More information can be found in the files COPYING and README.
  8. #
  9. # This patch file is dual-licensed. It is available under the license the
  10. # patched project is licensed under, as long as it is an OpenSource license
  11. # as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms
  12. # of the GNU General Public License as published by the Free Software
  13. # Foundation; either version 2 of the License, or (at your option) any later
  14. # version.
  15. # --- SDE-COPYRIGHT-NOTE-END ---
  16. From: Jens Axboe <jens.axboe@oracle.com>
  17. Date: Fri, 12 Dec 2008 08:51:16 +0000 (+0100)
  18. Subject: Get rid of CONFIG_LSF
  19. X-Git-Tag: v2.6.29-rc1~569^2~7
  20. X-Git-Url: http://git.kernel.org/?p=linux%2Fkernel%2Fgit%2Ftorvalds%2Flinux-2.6.git;a=commitdiff_plain;h=b3a6ffe16b5cc48abe7db8d04882dc45280eb693
  21. Get rid of CONFIG_LSF
  22. We have two seperate config entries for large devices/files. One
  23. is CONFIG_LBD that guards just the devices, the other is CONFIG_LSF
  24. that handles large files. This doesn't make a lot of sense, you typically
  25. want both or none. So get rid of CONFIG_LSF and change CONFIG_LBD wording
  26. to indicate that it covers both.
  27. Acked-by: Jean Delvare <khali@linux-fr.org>
  28. Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
  29. ---
  30. diff --git a/block/Kconfig b/block/Kconfig
  31. index 290b219..ac0956f 100644
  32. --- a/block/Kconfig
  33. +++ b/block/Kconfig
  34. @@ -24,21 +24,17 @@ menuconfig BLOCK
  35. if BLOCK
  36. config LBD
  37. - bool "Support for Large Block Devices"
  38. + bool "Support for large block devices and files"
  39. depends on !64BIT
  40. help
  41. - Enable block devices of size 2TB and larger.
  42. + Enable block devices or files of size 2TB and larger.
  43. This option is required to support the full capacity of large
  44. (2TB+) block devices, including RAID, disk, Network Block Device,
  45. Logical Volume Manager (LVM) and loopback.
  46. -
  47. - For example, RAID devices are frequently bigger than the capacity
  48. - of the largest individual hard drive.
  49. -
  50. - This option is not required if you have individual disk drives
  51. - which total 2TB+ and you are not aggregating the capacity into
  52. - a large block device (e.g. using RAID or LVM).
  53. +
  54. + This option also enables support for single files larger than
  55. + 2TB.
  56. If unsure, say N.
  57. @@ -58,15 +54,6 @@ config BLK_DEV_IO_TRACE
  58. If unsure, say N.
  59. -config LSF
  60. - bool "Support for Large Single Files"
  61. - depends on !64BIT
  62. - help
  63. - Say Y here if you want to be able to handle very large files (2TB
  64. - and larger), otherwise say N.
  65. -
  66. - If unsure, say Y.
  67. -
  68. config BLK_DEV_BSG
  69. bool "Block layer SG support v4 (EXPERIMENTAL)"
  70. depends on EXPERIMENTAL
  71. diff --git a/fs/ext4/super.c b/fs/ext4/super.c
  72. index e4a241c..04158ad 100644
  73. --- a/fs/ext4/super.c
  74. +++ b/fs/ext4/super.c
  75. @@ -1721,7 +1721,7 @@ static loff_t ext4_max_size(int blkbits, int has_huge_files)
  76. /* small i_blocks in vfs inode? */
  77. if (!has_huge_files || sizeof(blkcnt_t) < sizeof(u64)) {
  78. /*
  79. - * CONFIG_LSF is not enabled implies the inode
  80. + * CONFIG_LBD is not enabled implies the inode
  81. * i_block represent total blocks in 512 bytes
  82. * 32 == size of vfs inode i_blocks * 8
  83. */
  84. @@ -1764,7 +1764,7 @@ static loff_t ext4_max_bitmap_size(int bits, int has_huge_files)
  85. if (sizeof(blkcnt_t) < sizeof(u64)) {
  86. /*
  87. - * CONFIG_LSF is not enabled implies the inode
  88. + * CONFIG_LBD is not enabled implies the inode
  89. * i_block represent total blocks in 512 bytes
  90. * 32 == size of vfs inode i_blocks * 8
  91. */
  92. @@ -2021,13 +2021,13 @@ static int ext4_fill_super(struct super_block *sb, void *data, int silent)
  93. if (has_huge_files) {
  94. /*
  95. * Large file size enabled file system can only be
  96. - * mount if kernel is build with CONFIG_LSF
  97. + * mount if kernel is build with CONFIG_LBD
  98. */
  99. if (sizeof(root->i_blocks) < sizeof(u64) &&
  100. !(sb->s_flags & MS_RDONLY)) {
  101. printk(KERN_ERR "EXT4-fs: %s: Filesystem with huge "
  102. "files cannot be mounted read-write "
  103. - "without CONFIG_LSF.\n", sb->s_id);
  104. + "without CONFIG_LBD.\n", sb->s_id);
  105. goto failed_mount;
  106. }
  107. }
  108. diff --git a/include/linux/types.h b/include/linux/types.h
  109. index 1d98330..121f349 100644
  110. --- a/include/linux/types.h
  111. +++ b/include/linux/types.h
  112. @@ -135,19 +135,14 @@ typedef __s64 int64_t;
  113. *
  114. * Linux always considers sectors to be 512 bytes long independently
  115. * of the devices real block size.
  116. + *
  117. + * blkcnt_t is the type of the inode's block count.
  118. */
  119. #ifdef CONFIG_LBD
  120. typedef u64 sector_t;
  121. -#else
  122. -typedef unsigned long sector_t;
  123. -#endif
  124. -
  125. -/*
  126. - * The type of the inode's block count.
  127. - */
  128. -#ifdef CONFIG_LSF
  129. typedef u64 blkcnt_t;
  130. #else
  131. +typedef unsigned long sector_t;
  132. typedef unsigned long blkcnt_t;
  133. #endif