summaryrefslogtreecommitdiff
path: root/lib/sqfs/blk_proc/fragtbl.c
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-09-25 06:03:36 +0200
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-09-25 06:35:01 +0200
commit3da78a56df43360520f8007bdb4e11fa25f712cc (patch)
treef1dfd2ca166909ac3a9c37d8ec5196b11a548bb0 /lib/sqfs/blk_proc/fragtbl.c
parentb6400d20cc64afff22d2805c58dc04f2234d38a5 (diff)
Refactor out common code of the block processors
Code that already is shared between the pthread and the serial processor as well as code that can be re-used by other threading API implementations. Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'lib/sqfs/blk_proc/fragtbl.c')
-rw-r--r--lib/sqfs/blk_proc/fragtbl.c28
1 files changed, 0 insertions, 28 deletions
diff --git a/lib/sqfs/blk_proc/fragtbl.c b/lib/sqfs/blk_proc/fragtbl.c
index 84f5ed6..c8a3397 100644
--- a/lib/sqfs/blk_proc/fragtbl.c
+++ b/lib/sqfs/blk_proc/fragtbl.c
@@ -7,34 +7,6 @@
#define SQFS_BUILDING_DLL
#include "internal.h"
-int sqfs_block_processor_write_fragment_table(sqfs_block_processor_t *proc,
- sqfs_super_t *super)
-{
- uint64_t start;
- size_t size;
- int ret;
-
- if (proc->num_fragments == 0) {
- super->fragment_entry_count = 0;
- super->fragment_table_start = 0xFFFFFFFFFFFFFFFFUL;
- super->flags &= ~SQFS_FLAG_ALWAYS_FRAGMENTS;
- super->flags |= SQFS_FLAG_NO_FRAGMENTS;
- return 0;
- }
-
- size = sizeof(proc->fragments[0]) * proc->num_fragments;
- ret = sqfs_write_table(proc->file, proc->cmp,
- proc->fragments, size, &start);
- if (ret)
- return ret;
-
- super->flags &= ~SQFS_FLAG_NO_FRAGMENTS;
- super->flags |= SQFS_FLAG_ALWAYS_FRAGMENTS;
- super->fragment_entry_count = proc->num_fragments;
- super->fragment_table_start = start;
- return 0;
-}
-
static int grow_fragment_table(sqfs_block_processor_t *proc)
{
size_t newsz;