diff options
author | Tushar Gohad <tushar.gohad@intel.com> | 2014-07-16 12:58:41 -0700 |
---|---|---|
committer | Tushar Gohad <tushar.gohad@intel.com> | 2014-07-16 12:58:41 -0700 |
commit | 05e65c3f96d54f7ddbbd0318ad6479011b6f02c6 (patch) | |
tree | 9d5cb85bad8416b754ec7696dd5bbd0ea36b7d83 /include/erasurecode/erasurecode.h | |
parent | 1c632ec72c04b7fcc34cefc4809f8e6293ef290a (diff) | |
download | liberasurecode-05e65c3f96d54f7ddbbd0318ad6479011b6f02c6.tar.gz |
Fix liberasurecode main routines for new API (take 2)
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com>
Diffstat (limited to 'include/erasurecode/erasurecode.h')
-rw-r--r-- | include/erasurecode/erasurecode.h | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/include/erasurecode/erasurecode.h b/include/erasurecode/erasurecode.h index 20f819b..ff4b05a 100644 --- a/include/erasurecode/erasurecode.h +++ b/include/erasurecode/erasurecode.h @@ -39,7 +39,6 @@ extern "C" { /* =~=*=~==~=*=~==~=*=~= Supported EC backends =~=*=~==~=*=~==~=*=~==~=*=~== */ -/* Supported EC backends */ typedef enum { EC_BACKEND_NULL = 0, EC_BACKEND_JERASURE_RS_VAND = 1, @@ -48,11 +47,16 @@ typedef enum { EC_BACKENDS_MAX, } ec_backend_id_t; -const char *ec_backend_names[EC_BACKENDS_MAX] = +#ifdef EC_BACKENDS_SUPPORTED +#define EC_BACKENDS_SUPPORTED +/* Supported EC backends */ +const char *ec_backend_names[EC_BACKENDS_MAX] = { "null", "jerasure_rs_vand", "jerasure_rs_cauchy", - "flat_xor_hd"; + "flat_xor_hd", +}; +#endif // EC_BACKENDS_SUPPORTED /* =~=*=~==~=*=~== EC Arguments - Common and backend-specific =~=*=~==~=*=~== */ @@ -82,7 +86,7 @@ struct ec_args { int inline_chksum; /* embedded fragment checksums (yes/no), type */ int algsig_chksum; /* use algorithmic signature checksums */ -} +}; /* =~=*=~==~=*=~== liberasurecode frontend API functions =~=*=~==~=~=*=~==~= */ @@ -169,7 +173,8 @@ int liberasurecode_reconstruct_fragment(int desc, /** * Determine which fragments are needed to reconstruct some subset - * of missing fragments. + * of missing fragments. Returns a list of lists (as bitmaps) + * of fragments required to reconstruct missing indexes. */ int liberasurecode_fragments_needed(int desc, int *missing_idxs, int *fragments_needed); |