get:
Show a patch.

patch:
Update a patch.

put:
Update a patch.

GET /api/1.2/patches/805197/?format=api
HTTP 200 OK
Allow: GET, PUT, PATCH, HEAD, OPTIONS
Content-Type: application/json
Vary: Accept

{
    "id": 805197,
    "url": "http://patchwork.ozlabs.org/api/1.2/patches/805197/?format=api",
    "web_url": "http://patchwork.ozlabs.org/project/linux-ext4/patch/20170823232351.643l4wg7pvnnxyts@thunk.org/",
    "project": {
        "id": 8,
        "url": "http://patchwork.ozlabs.org/api/1.2/projects/8/?format=api",
        "name": "Linux ext4 filesystem development",
        "link_name": "linux-ext4",
        "list_id": "linux-ext4.vger.kernel.org",
        "list_email": "linux-ext4@vger.kernel.org",
        "web_url": null,
        "scm_url": null,
        "webscm_url": null,
        "list_archive_url": "",
        "list_archive_url_format": "",
        "commit_url_format": ""
    },
    "msgid": "<20170823232351.643l4wg7pvnnxyts@thunk.org>",
    "list_archive_url": null,
    "date": "2017-08-23T23:23:51",
    "name": "e2fsck: add optimization for heavily hard-linked file systems",
    "commit_ref": null,
    "pull_url": null,
    "state": "accepted",
    "archived": true,
    "hash": "02c8fb2f19d0dc214b4e5e139cf9421737d84b13",
    "submitter": {
        "id": 350,
        "url": "http://patchwork.ozlabs.org/api/1.2/people/350/?format=api",
        "name": "Theodore Tso",
        "email": "tytso@mit.edu"
    },
    "delegate": null,
    "mbox": "http://patchwork.ozlabs.org/project/linux-ext4/patch/20170823232351.643l4wg7pvnnxyts@thunk.org/mbox/",
    "series": [],
    "comments": "http://patchwork.ozlabs.org/api/patches/805197/comments/",
    "check": "pending",
    "checks": "http://patchwork.ozlabs.org/api/patches/805197/checks/",
    "tags": {},
    "related": [],
    "headers": {
        "Return-Path": "<linux-ext4-owner@vger.kernel.org>",
        "X-Original-To": "patchwork-incoming@ozlabs.org",
        "Delivered-To": "patchwork-incoming@ozlabs.org",
        "Authentication-Results": [
            "ozlabs.org;\n\tspf=none (mailfrom) smtp.mailfrom=vger.kernel.org\n\t(client-ip=209.132.180.67; helo=vger.kernel.org;\n\tenvelope-from=linux-ext4-owner@vger.kernel.org;\n\treceiver=<UNKNOWN>)",
            "ozlabs.org; dkim=pass (1024-bit key;\n\tunprotected) header.d=thunk.org header.i=@thunk.org\n\theader.b=\"wcCrBgk2\"; dkim-atps=neutral"
        ],
        "Received": [
            "from vger.kernel.org (vger.kernel.org [209.132.180.67])\n\tby ozlabs.org (Postfix) with ESMTP id 3xd3Qf4FBdz9ryv\n\tfor <patchwork-incoming@ozlabs.org>;\n\tThu, 24 Aug 2017 09:23:54 +1000 (AEST)",
            "(majordomo@vger.kernel.org) by vger.kernel.org via listexpand\n\tid S1751156AbdHWXXx (ORCPT <rfc822;patchwork-incoming@ozlabs.org>);\n\tWed, 23 Aug 2017 19:23:53 -0400",
            "from imap.thunk.org ([74.207.234.97]:47518 \"EHLO imap.thunk.org\"\n\trhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP\n\tid S1751038AbdHWXXx (ORCPT <rfc822;linux-ext4@vger.kernel.org>);\n\tWed, 23 Aug 2017 19:23:53 -0400",
            "from root (helo=callcc.thunk.org)\n\tby imap.thunk.org with local-esmtp (Exim 4.84_2)\n\t(envelope-from <tytso@thunk.org>)\n\tid 1dkf03-0005HS-M2; Wed, 23 Aug 2017 23:23:51 +0000",
            "by callcc.thunk.org (Postfix, from userid 15806)\n\tid 20A72C00CD3; Wed, 23 Aug 2017 19:23:51 -0400 (EDT)"
        ],
        "DKIM-Signature": "v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=thunk.org;\n\ts=ef5046eb; \n\th=In-Reply-To:Content-Type:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date;\n\tbh=qFHuwmDq0HF/Hs+0qulgxbFUvGXnsZSH0Pl4QNEmdFE=; \n\tb=wcCrBgk2/4uDrY0b9+vYPQH5+Qs9tNIM0hBt23o1lizvgMdjNaUICPeXPJZZTO46BSsXxXP+lqxz+A9qxfkcNw8fVkpc0SHsUY3Q5HOi/m18JFvv83yYXEMQWoGWgR6H9LCMQITEYqAIUDJ1as74zrw5vySsSetue8X4ieTmeC8=;",
        "Date": "Wed, 23 Aug 2017 19:23:51 -0400",
        "From": "Theodore Ts'o <tytso@mit.edu>",
        "To": "Jaco Kroon <jaco@uls.co.za>",
        "Cc": "Doug Porter <dsp@fb.com>, linux-ext4@vger.kernel.org,\n\tOmar Sandoval <osandov@fb.com>",
        "Subject": "[PATCH] e2fsck: add optimization for heavily hard-linked file\n\tsystems",
        "Message-ID": "<20170823232351.643l4wg7pvnnxyts@thunk.org>",
        "References": "<20170819011635.1815929-1-dsp@fb.com>\n\t<20170822022948.nyn6fessudjaj5xh@thunk.org>\n\t<a4b31ace-3a54-051d-75df-b47452c789cb@uls.co.za>\n\t<20170822124505.xr7wnxonsbml3mgh@thunk.org>\n\t<00f408c1-215e-39e2-dec4-8f05eb604f97@uls.co.za>",
        "MIME-Version": "1.0",
        "Content-Type": "text/plain; charset=us-ascii",
        "Content-Disposition": "inline",
        "In-Reply-To": "<00f408c1-215e-39e2-dec4-8f05eb604f97@uls.co.za>",
        "User-Agent": "NeoMutt/20170609 (1.8.3)",
        "X-SA-Exim-Connect-IP": "<locally generated>",
        "X-SA-Exim-Mail-From": "tytso@thunk.org",
        "X-SA-Exim-Scanned": "No (on imap.thunk.org); SAEximRunCond expanded to false",
        "Sender": "linux-ext4-owner@vger.kernel.org",
        "Precedence": "bulk",
        "List-ID": "<linux-ext4.vger.kernel.org>",
        "X-Mailing-List": "linux-ext4@vger.kernel.org"
    },
    "content": "Jaco,\n\nHere's my revised version of your patch.  The main differences are in\nhow to enable this optimization, and the fact that this optimizatoin\nis disabled by default.  Users will have to either explicitly request\nit by using e2fsck -E inode_count_fullmap or via /etc/e2fsck.conf.\n\nPlease take a look and let me know what you think.  (And again, if you\ncould give me permission to add your Signed-off-by, I would appreciate\nit.)\n\nThanks,\n\n\t\t\t\t\t- Ted\n\ncommit 75941780c27190c6507aa7ca813caa79638926c8\nAuthor: Jaco Kroon <jaco@uls.co.za>\nDate:   Wed Aug 23 14:21:43 2017 -0400\n\n    e2fsck: add optimization for heavily hard-linked file systems\n    \n    In the case of file system with large number of hard links, e2fsck can\n    take a large amount of time in pass 2 due to binary search lookup of\n    inode numbers.  This implements a memory trade-off (storing 2 bytes\n    in-memory for each inode to store inode counts).\n    \n    For a 40TB filesystem with 2.8bn inodes this map alone requires 5.7GB\n    of RAM.  For this reason, we don't enable this optimization by\n    default.  It can be enabled using either an extended option to e2fsck\n    or via a seting in e2fsck.conf.\n    \n    Even when the fullmap optimization is enabled, we don't use this for\n    the icount structure in pass 1.  This is because the gain CPU gain is\n    nearly nil for that pass and the sacrificed memory does not justify\n    the increase in RAM.\n    \n    (It could be that during pass 1, if more than 17% if possible inodes\n    has link_count>1 (466m inodes in the 40TB with 2.8bn possible inodes\n    case) then it becomes more memory efficient to use the full map\n    implementation in terms of memory.  However, this is extremely\n    unlikely given that most file systems are heavily over-provisioned in\n    terms of the number of inodes in the system.)\n    \n    Signed-off-by: Theodore Ts'o <tytso@mit.edu>",
    "diff": "diff --git a/e2fsck/e2fsck.8.in b/e2fsck/e2fsck.8.in\nindex 786eb15e7..4c29943d3 100644\n--- a/e2fsck/e2fsck.8.in\n+++ b/e2fsck/e2fsck.8.in\n@@ -228,7 +228,29 @@ exactly the opposite of discard option. This is set as default.\n .TP\n .BI no_optimize_extents\n Do not offer to optimize the extent tree by eliminating unnecessary\n-width or depth.\n+width or depth.  This can also be enabled in the options section of\n+.BR /etc/e2fsck.conf .\n+.TP\n+.BI optimize_extents\n+Offer to optimize the extent tree by eliminating unnecessary\n+width or depth.  This is the default unless otherwise specified in\n+.BR /etc/e2fsck.conf .\n+.TP\n+.BI inode_count_fullmap\n+Trade off using memory for speed when checking a file system with a\n+large number of hard-linked files.  The amount of memory required is\n+proportional to the number of inodes in the file system.  For large file\n+systems, this can be gigabytes of memory.  (For example, a 40TB file system\n+with 2.8 billion inodes will consume an additional 5.7 GB memory if this\n+optimization is enabled.)  This optimization can also be enabled in the\n+options section of\n+.BR /etc/e2fsck.conf .\n+.TP\n+.BI no_inode_count_fullmap\n+Disable the\n+.B inode_count_fullmap\n+optimization.  This is the default unless otherwise specified in\n+.BR /etc/e2fsck.conf .\n .TP\n .BI readahead_kb\n Use this many KiB of memory to pre-fetch metadata in the hopes of reducing\ndiff --git a/e2fsck/e2fsck.conf.5.in b/e2fsck/e2fsck.conf.5.in\nindex fbde7ef0b..d8205bcf1 100644\n--- a/e2fsck/e2fsck.conf.5.in\n+++ b/e2fsck/e2fsck.conf.5.in\n@@ -157,6 +157,15 @@ the average fill ratio of directories can be maintained at a\n higher, more efficient level.  This relation defaults to 20\n percent.\n .TP\n+.I inode_count_fullmap\n+If this boolean relation is true, trade off using memory for speed when\n+checking a file system with a large number of hard-linked files.  The\n+amount of memory required is proportional to the number of inodes in the\n+file system.  For large file systems, this can be gigabytes of memory.\n+(For example a 40TB file system with 2.8 billion inodes will consume an\n+additional 5.7 GB memory if this optimization is enabled.)  This setting\n+defaults to false.\n+.TP\n .I log_dir\n If the\n .I log_filename\n@@ -206,8 +215,8 @@ of that type are squelched.  This can be useful if the console is slow\n end up delaying the boot process for a long time (potentially hours).\n .TP\n .I no_optimize_extents\n-Do not offer to optimize the extent tree by eliminating unnecessary\n-width or depth.\n+If this boolean relation is true, do not offer to optimize the extent\n+tree by reducing the tree's width or depth.  This setting defaults to false.\n .TP\n .I readahead_mem_pct\n Use this percentage of memory to try to read in metadata blocks ahead of the\ndiff --git a/e2fsck/e2fsck.h b/e2fsck/e2fsck.h\nindex 81c09d7eb..12855453d 100644\n--- a/e2fsck/e2fsck.h\n+++ b/e2fsck/e2fsck.h\n@@ -170,6 +170,7 @@ struct resource_track {\n #define E2F_OPT_CONVERT_BMAP\t0x4000 /* convert blockmap to extent */\n #define E2F_OPT_FIXES_ONLY\t0x8000 /* skip all optimizations */\n #define E2F_OPT_NOOPT_EXTENTS\t0x10000 /* don't optimize extents */\n+#define E2F_OPT_ICOUNT_FULLMAP\t0x20000 /* don't optimize extents */\n \n /*\n  * E2fsck flags\ndiff --git a/e2fsck/pass1.c b/e2fsck/pass1.c\nindex bc26beb99..6442c9449 100644\n--- a/e2fsck/pass1.c\n+++ b/e2fsck/pass1.c\n@@ -711,6 +711,7 @@ extern errcode_t e2fsck_setup_icount(e2fsck_t ctx, const char *icount_name,\n \terrcode_t\t\tretval;\n \tchar\t\t\t*tdb_dir;\n \tint\t\t\tenable;\n+\tint\t\t\tfull_map;\n \n \t*ret = 0;\n \n@@ -734,6 +735,8 @@ extern errcode_t e2fsck_setup_icount(e2fsck_t ctx, const char *icount_name,\n \t}\n \te2fsck_set_bitmap_type(ctx->fs, EXT2FS_BMAP64_RBTREE, icount_name,\n \t\t\t       &save_type);\n+\tif (ctx->options & E2F_OPT_ICOUNT_FULLMAP)\n+\t\tflags |= EXT2_ICOUNT_OPT_FULLMAP;\n \tretval = ext2fs_create_icount2(ctx->fs, flags, 0, hint, ret);\n \tctx->fs->default_bitmap_type = save_type;\n \treturn retval;\ndiff --git a/e2fsck/unix.c b/e2fsck/unix.c\nindex ff961483b..939862f1a 100644\n--- a/e2fsck/unix.c\n+++ b/e2fsck/unix.c\n@@ -709,9 +709,18 @@ static void parse_extended_opts(e2fsck_t ctx, const char *opts)\n \t\t} else if (strcmp(token, \"nodiscard\") == 0) {\n \t\t\tctx->options &= ~E2F_OPT_DISCARD;\n \t\t\tcontinue;\n+\t\t} else if (strcmp(token, \"optimize_extents\") == 0) {\n+\t\t\tctx->options &= ~E2F_OPT_NOOPT_EXTENTS;\n+\t\t\tcontinue;\n \t\t} else if (strcmp(token, \"no_optimize_extents\") == 0) {\n \t\t\tctx->options |= E2F_OPT_NOOPT_EXTENTS;\n \t\t\tcontinue;\n+\t\t} else if (strcmp(token, \"inode_count_fullmap\") == 0) {\n+\t\t\tctx->options |= E2F_OPT_ICOUNT_FULLMAP;\n+\t\t\tcontinue;\n+\t\t} else if (strcmp(token, \"no_inode_count_fullmap\") == 0) {\n+\t\t\tctx->options &= ~E2F_OPT_ICOUNT_FULLMAP;\n+\t\t\tcontinue;\n \t\t} else if (strcmp(token, \"log_filename\") == 0) {\n \t\t\tif (!arg)\n \t\t\t\textended_usage++;\n@@ -733,17 +742,21 @@ static void parse_extended_opts(e2fsck_t ctx, const char *opts)\n \tfree(buf);\n \n \tif (extended_usage) {\n-\t\tfputs((\"\\nExtended options are separated by commas, \"\n+\t\tfputs(_(\"\\nExtended options are separated by commas, \"\n \t\t       \"and may take an argument which\\n\"\n \t\t       \"is set off by an equals ('=') sign.  \"\n-\t\t       \"Valid extended options are:\\n\"), stderr);\n-\t\tfputs((\"\\tea_ver=<ea_version (1 or 2)>\\n\"), stderr);\n-\t\tfputs((\"\\tfragcheck\\n\"), stderr);\n-\t\tfputs((\"\\tjournal_only\\n\"), stderr);\n-\t\tfputs((\"\\tdiscard\\n\"), stderr);\n-\t\tfputs((\"\\tnodiscard\\n\"), stderr);\n-\t\tfputs((\"\\treadahead_kb=<buffer size>\\n\"), stderr);\n-\t\tfputs((\"\\tbmap2extent\\n\"), stderr);\n+\t\t       \"Valid extended options are:\\n\\n\"), stderr);\n+\t\tfputs(_(\"\\tea_ver=<ea_version (1 or 2)>\\n\"), stderr);\n+\t\tfputs(\"\\tfragcheck\\n\", stderr);\n+\t\tfputs(\"\\tjournal_only\\n\", stderr);\n+\t\tfputs(\"\\tdiscard\\n\", stderr);\n+\t\tfputs(\"\\tnodiscard\\n\", stderr);\n+\t\tfputs(\"\\toptimize_extents\\n\", stderr);\n+\t\tfputs(\"\\tno_optimize_extents\\n\", stderr);\n+\t\tfputs(\"\\tinode_count_fullmap\\n\", stderr);\n+\t\tfputs(\"\\tno_inode_count_fullmap\\n\", stderr);\n+\t\tfputs(_(\"\\treadahead_kb=<buffer size>\\n\"), stderr);\n+\t\tfputs(\"\\tbmap2extent\\n\", stderr);\n \t\tfputc('\\n', stderr);\n \t\texit(1);\n \t}\n@@ -1015,6 +1028,11 @@ static errcode_t PRS(int argc, char *argv[], e2fsck_t *ret_ctx)\n \tif (c)\n \t\tctx->options |= E2F_OPT_NOOPT_EXTENTS;\n \n+\tprofile_get_boolean(ctx->profile, \"options\", \"inode_count_fullmap\",\n+\t\t\t    0, 0, &c);\n+\tif (c)\n+\t\tctx->options |= E2F_OPT_ICOUNT_FULLMAP;\n+\n \tif (ctx->readahead_kb == ~0ULL) {\n \t\tprofile_get_integer(ctx->profile, \"options\",\n \t\t\t\t    \"readahead_mem_pct\", 0, -1, &c);\ndiff --git a/lib/ext2fs/ext2fs.h b/lib/ext2fs/ext2fs.h\nindex 8ff49ca66..68d0e2a57 100644\n--- a/lib/ext2fs/ext2fs.h\n+++ b/lib/ext2fs/ext2fs.h\n@@ -532,6 +532,7 @@ typedef struct ext2_struct_inode_scan *ext2_inode_scan;\n  * ext2_icount_t abstraction\n  */\n #define EXT2_ICOUNT_OPT_INCREMENT\t0x01\n+#define EXT2_ICOUNT_OPT_FULLMAP\t\t0x02\n \n typedef struct ext2_icount *ext2_icount_t;\n \ndiff --git a/lib/ext2fs/icount.c b/lib/ext2fs/icount.c\nindex 594b1cc2b..65420e9f3 100644\n--- a/lib/ext2fs/icount.c\n+++ b/lib/ext2fs/icount.c\n@@ -61,6 +61,7 @@ struct ext2_icount {\n \tchar\t\t\t*tdb_fn;\n \tTDB_CONTEXT\t\t*tdb;\n #endif\n+\t__u16\t\t\t*fullmap;\n };\n \n /*\n@@ -93,6 +94,9 @@ void ext2fs_free_icount(ext2_icount_t icount)\n \t}\n #endif\n \n+\tif (icount->fullmap)\n+\t\text2fs_free_mem(&icount->fullmap);\n+\n \text2fs_free_mem(&icount);\n }\n \n@@ -108,10 +112,24 @@ static errcode_t alloc_icount(ext2_filsys fs, int flags, ext2_icount_t *ret)\n \t\treturn retval;\n \tmemset(icount, 0, sizeof(struct ext2_icount));\n \n+\tif ((flags & EXT2_ICOUNT_OPT_FULLMAP) &&\n+\t    (flags & EXT2_ICOUNT_OPT_INCREMENT)) {\n+\t\tretval = ext2fs_get_mem((sizeof(__u32) *\n+\t\t\t\t\t fs->super->s_inodes_count),\n+\t\t\t\t\t&icount->fullmap);\n+\t\t/* If we can't allocate, fall back */\n+\t\tif (!retval) {\n+\t\t\tmemset(icount->fullmap, 0,\n+\t\t\t       sizeof(__u32) * fs->super->s_inodes_count);\n+\t\t\tgoto successout;\n+\t\t}\n+\t}\n+\n \tretval = ext2fs_allocate_inode_bitmap(fs, \"icount\", &icount->single);\n \tif (retval)\n \t\tgoto errout;\n \n+\n \tif (flags & EXT2_ICOUNT_OPT_INCREMENT) {\n \t\tretval = ext2fs_allocate_inode_bitmap(fs, \"icount_inc\",\n \t\t\t\t\t\t      &icount->multiple);\n@@ -120,6 +138,7 @@ static errcode_t alloc_icount(ext2_filsys fs, int flags, ext2_icount_t *ret)\n \t} else\n \t\ticount->multiple = 0;\n \n+successout:\n \ticount->magic = EXT2_ET_MAGIC_ICOUNT;\n \ticount->num_inodes = fs->super->s_inodes_count;\n \n@@ -256,6 +275,9 @@ errcode_t ext2fs_create_icount2(ext2_filsys fs, int flags, unsigned int size,\n \tif (retval)\n \t\treturn retval;\n \n+\tif (icount->fullmap)\n+\t\tgoto successout;\n+\n \tif (size) {\n \t\ticount->size = size;\n \t} else {\n@@ -295,6 +317,7 @@ errcode_t ext2fs_create_icount2(ext2_filsys fs, int flags, unsigned int size,\n \t\ticount->count = hint->count;\n \t}\n \n+successout:\n \t*ret = icount;\n \treturn 0;\n \n@@ -433,6 +456,11 @@ static errcode_t set_inode_count(ext2_icount_t icount, ext2_ino_t ino,\n \t\treturn 0;\n \t}\n #endif\n+\tif (icount->fullmap) {\n+\t\ticount->fullmap[ino] = icount_16_xlate(count);\n+\t\treturn 0;\n+\t}\n+\n \tel = get_icount_el(icount, ino, 1);\n \tif (!el)\n \t\treturn EXT2_ET_NO_MEMORY;\n@@ -463,6 +491,11 @@ static errcode_t get_inode_count(ext2_icount_t icount, ext2_ino_t ino,\n \t\treturn 0;\n \t}\n #endif\n+\tif (icount->fullmap) {\n+\t\t*count = icount->fullmap[ino];\n+\t\treturn 0;\n+\t}\n+\n \tel = get_icount_el(icount, ino, 0);\n \tif (!el) {\n \t\t*count = 0;\n@@ -504,14 +537,16 @@ errcode_t ext2fs_icount_fetch(ext2_icount_t icount, ext2_ino_t ino, __u16 *ret)\n \tif (!ino || (ino > icount->num_inodes))\n \t\treturn EXT2_ET_INVALID_ARGUMENT;\n \n-\tif (ext2fs_test_inode_bitmap2(icount->single, ino)) {\n-\t\t*ret = 1;\n-\t\treturn 0;\n-\t}\n-\tif (icount->multiple &&\n-\t    !ext2fs_test_inode_bitmap2(icount->multiple, ino)) {\n-\t\t*ret = 0;\n-\t\treturn 0;\n+\tif (!icount->fullmap) {\n+\t\tif (ext2fs_test_inode_bitmap2(icount->single, ino)) {\n+\t\t\t*ret = 1;\n+\t\t\treturn 0;\n+\t\t}\n+\t\tif (icount->multiple &&\n+\t\t\t!ext2fs_test_inode_bitmap2(icount->multiple, ino)) {\n+\t\t\t*ret = 0;\n+\t\t\treturn 0;\n+\t\t}\n \t}\n \tget_inode_count(icount, ino, &val);\n \t*ret = icount_16_xlate(val);\n@@ -528,7 +563,10 @@ errcode_t ext2fs_icount_increment(ext2_icount_t icount, ext2_ino_t ino,\n \tif (!ino || (ino > icount->num_inodes))\n \t\treturn EXT2_ET_INVALID_ARGUMENT;\n \n-\tif (ext2fs_test_inode_bitmap2(icount->single, ino)) {\n+\tif (icount->fullmap) {\n+\t\tcurr_value = icount_16_xlate(icount->fullmap[ino] + 1);\n+\t\ticount->fullmap[ino] = curr_value;\n+\t} else if (ext2fs_test_inode_bitmap2(icount->single, ino)) {\n \t\t/*\n \t\t * If the existing count is 1, then we know there is\n \t\t * no entry in the list.\n@@ -585,6 +623,16 @@ errcode_t ext2fs_icount_decrement(ext2_icount_t icount, ext2_ino_t ino,\n \n \tEXT2_CHECK_MAGIC(icount, EXT2_ET_MAGIC_ICOUNT);\n \n+\tif (icount->fullmap) {\n+\t\tif (!icount->fullmap[ino])\n+\t\t\treturn EXT2_ET_INVALID_ARGUMENT;\n+\n+\t\tcurr_value = --icount->fullmap[ino];\n+\t\tif (ret)\n+\t\t\t*ret = icount_16_xlate(curr_value);\n+\t\treturn 0;\n+\t}\n+\n \tif (ext2fs_test_inode_bitmap2(icount->single, ino)) {\n \t\text2fs_unmark_inode_bitmap2(icount->single, ino);\n \t\tif (icount->multiple)\n@@ -626,6 +674,9 @@ errcode_t ext2fs_icount_store(ext2_icount_t icount, ext2_ino_t ino,\n \n \tEXT2_CHECK_MAGIC(icount, EXT2_ET_MAGIC_ICOUNT);\n \n+\tif (icount->fullmap)\n+\t\treturn set_inode_count(icount, ino, count);\n+\n \tif (count == 1) {\n \t\text2fs_mark_inode_bitmap2(icount->single, ino);\n \t\tif (icount->multiple)\n",
    "prefixes": []
}