Whamcloud - gitweb
libext2fs: delete unused "handle" variable
[tools/e2fsprogs.git] / lib / e2p / feature.c
index 1da3c7d..1d3e689 100644 (file)
@@ -3,11 +3,13 @@
  *
  * Copyright (C) 1999  Theodore Ts'o <tytso@mit.edu>
  *
- * This file can be redistributed under the terms of the GNU Library General
- * Public License
- *
+ * %Begin-Header%
+ * This file may be redistributed under the terms of the GNU Library
+ * General Public License, version 2.
+ * %End-Header%
  */
 
+#include "config.h"
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
@@ -39,6 +41,10 @@ static struct feature feature_list[] = {
                        "resize_inode" },
        {       E2P_FEATURE_COMPAT, EXT2_FEATURE_COMPAT_LAZY_BG,
                        "lazy_bg" },
+       {       E2P_FEATURE_COMPAT, EXT2_FEATURE_COMPAT_EXCLUDE_BITMAP,
+                       "snapshot_bitmap" },
+       {       E2P_FEATURE_COMPAT, EXT4_FEATURE_COMPAT_SPARSE_SUPER2,
+                       "sparse_super2" },
 
        {       E2P_FEATURE_RO_INCOMPAT, EXT2_FEATURE_RO_COMPAT_SPARSE_SUPER,
                        "sparse_super" },
@@ -54,6 +60,14 @@ static struct feature feature_list[] = {
                        "dir_nlink" },
        {       E2P_FEATURE_RO_INCOMPAT, EXT4_FEATURE_RO_COMPAT_EXTRA_ISIZE,
                        "extra_isize" },
+       {       E2P_FEATURE_RO_INCOMPAT, EXT4_FEATURE_RO_COMPAT_QUOTA,
+                       "quota" },
+       {       E2P_FEATURE_RO_INCOMPAT, EXT4_FEATURE_RO_COMPAT_BIGALLOC,
+                       "bigalloc"},
+       {       E2P_FEATURE_RO_INCOMPAT, EXT4_FEATURE_RO_COMPAT_METADATA_CSUM,
+                       "metadata_csum"},
+       {       E2P_FEATURE_RO_INCOMPAT, EXT4_FEATURE_RO_COMPAT_REPLICA,
+                       "replica" },
 
        {       E2P_FEATURE_INCOMPAT, EXT2_FEATURE_INCOMPAT_COMPRESSION,
                        "compression" },
@@ -71,8 +85,18 @@ static struct feature feature_list[] = {
                        "meta_bg" },
        {       E2P_FEATURE_INCOMPAT, EXT4_FEATURE_INCOMPAT_64BIT,
                        "64bit" },
+       {       E2P_FEATURE_INCOMPAT, EXT4_FEATURE_INCOMPAT_MMP,
+                       "mmp" },
        {       E2P_FEATURE_INCOMPAT, EXT4_FEATURE_INCOMPAT_FLEX_BG,
-                        "flex_bg"},
+                       "flex_bg"},
+       {       E2P_FEATURE_INCOMPAT, EXT4_FEATURE_INCOMPAT_EA_INODE,
+                       "ea_inode"},
+       {       E2P_FEATURE_INCOMPAT, EXT4_FEATURE_INCOMPAT_DIRDATA,
+                       "dirdata"},
+       {       E2P_FEATURE_INCOMPAT, EXT4_FEATURE_INCOMPAT_LARGEDIR,
+                       "large_dir"},
+       {       E2P_FEATURE_INCOMPAT, EXT4_FEATURE_INCOMPAT_INLINEDATA,
+                       "inline_data"},
        {       0, 0, 0 },
 };
 
@@ -82,6 +106,8 @@ static struct feature jrnl_feature_list[] = {
 
        {       E2P_FEATURE_INCOMPAT, JFS_FEATURE_INCOMPAT_REVOKE,
                        "journal_incompat_revoke" },
+       {       E2P_FEATURE_INCOMPAT, JFS_FEATURE_INCOMPAT_64BIT,
+                       "journal_64bit" },
        {       E2P_FEATURE_INCOMPAT, JFS_FEATURE_INCOMPAT_ASYNC_COMMIT,
                        "journal_async_commit" },
        {       0, 0, 0 },
@@ -298,6 +324,7 @@ int e2p_edit_feature2(const char *str, __u32 *compat_array, __u32 *ok_array,
                case '-':
                case '^':
                        neg++;
+                       /* fallthrough */
                case '+':
                        cp++;
                        break;