Mark Storer
42870dff1f
Small fix to check the return code when malloc'ing temporary buffers.
2014-10-01 10:05:59 -04:00
Tushar Gohad
b6b3ffb60b
Add the ability for backends to specify
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-09-30 06:35:03 -07:00
Kevin Greenan
543d7e9923
Plugging-in the ISA-L backend... Still needs more documentation and a little clean-up, but the tests are passing...
2014-09-29 14:01:56 -07:00
Eric Lambert
be8dcbcc27
Char * backend names are no longer supported. They have been replaced with elements of the ec_backend_id_t enum.
2014-09-29 13:24:50 -07:00
Eric Lambert
3a108f751c
liberasurecode_backend_lookup_id now returns EC_BACKENDS_MAX, as
...
opposed to -1, when it can not locate the specified backend (-1
was a non-sensical return value since the function signature
called for a type of ec_backend_id_t). NOTE: with this change we
now successfully build and tests pass on OS X with clang.
2014-09-26 19:13:37 -07:00
Eric Lambert
06bb20ca1c
crc32 checksum now supported (prior to this commit checksum values were
...
not being placed into the fragment header).
2014-09-25 13:23:06 -07:00
Eric Lambert
295bbbd03e
A little bit of code clean up based on feedback/reviews
2014-09-15 08:27:25 -07:00
Eric Lambert
512353f8be
Compile in pedantic mode and fail compilation on warnings. Also cleanup all existing warnings.
2014-09-10 17:13:45 -07:00
Eric Lambert
6bbcfde657
added argument validation logic and tests for
...
liberasure_get_fragment_metadata and
liberasurecode_verify_stripe_metadata. In the process removed the
liberasure descriptor from the liberasure_get_fragment_metadata
function's signature as it was not being used in the function's
implementation.
2014-09-02 15:07:07 -07:00
Eric Lambert
fb8b798f18
Merge branch 'newapi' of https://bitbucket.org/tsg-/liberasurecode into newapi
2014-09-02 11:15:03 -07:00
Eric Lambert
81c47389ba
Added more tests (most of which test that the "public" functions
...
perform some argument validity checks). Also fixed some bugs exposed by
these new tests. NOTE: liberasurecode_test now *requires* that the null
provider be loadable by the test (meaning is on LD_LIBRARY_PATH).
2014-09-02 11:12:16 -07:00
Tushar Gohad
d03557c151
Add doxygen config. Update README, copyrights.
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-09-01 22:40:09 -07:00
Eric Lambert
39a45eac93
Fixed bug where null_init was not correctly setting w param (was relying on un-initialized memory which resulted in non-deterministic behavior).
2014-08-26 16:20:55 -07:00
Mark Storer
126897c816
Cleaned up the Cauchy backend. This has a bit more cleaned than the
...
other backends because Jerasure allocs more memory under the hood that
we need to check on init, and cleanup on exit.
Minor cleanup wise we do fewer memory derefs by saving the value of
k, m and w in a few places. This is, however, probably most effective
at just improving readability a bit.
2014-08-25 11:33:07 -07:00
Mark W. Storer
b25dd676fd
Minor cleanup to null backend. Mostly to the exit cases. Free checks for
...
null, so as long we intialize the pointers to NULL, we can be a little
terser (and cleaner?) in the exits.
Cleanup in the Jerasure Vandermonde backend. Primary change here was to
free the memory allocated by Jerasure in the erasures_to_erased method.
2014-08-23 00:38:50 +00:00
Kevin Greenan
c9af505400
Backend changes needed to honor "excluded fragments".
2014-08-21 13:05:59 -07:00
Tushar Gohad
29d7bda5f5
Make style consistent (formatting, variable defs)
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-08-20 17:32:31 -07:00
Kevin Greenan
d251ed8f98
API change for liberasurecode_fragments_needed
...
Still needed:
1.) RS and XOR backends need to honor the 'exclude' argument.
2.) Need to add tests.
2014-08-20 09:15:36 -07:00
Mark Storer
8af4f83e86
- Cleaned up the documentation in erasurecode.h to ensure that it
...
follows a common format and that it accurately reflects the code.
- Cleaned up liberasurecode_instance_destroy to ensure that the return
code is correct and that it is not trying to free data that has
not been removed from the open instances.
- Updated the tests to assert that the liberasurecode_instance_destroy
method is return correctly.
2014-08-18 10:44:19 -07:00
Kevin Greenan
3338e25b9f
Merged in lock_checks (pull request #2 )
...
Updated the backend instance register/unregister methods with lock
2014-08-16 17:10:26 -07:00
Mark Storer
9c6ba636ec
Updated the backend instance register/unregister methods with lock
...
status checking. This shouldn't be an issue, but technically, lock
requests can fail and so should check the return calls out of good
practice.
2014-08-16 14:53:12 -07:00
Mark Storer
4cfd3f535b
Updated liberasurecode_supported_checksum_types to accept a pointer
...
argument that holds the length of the list returned (i.e. the number of
supported checksum types).
2014-08-15 16:50:14 -07:00
Kevin Greenan
c22312f2d0
Added cleanup API
2014-08-13 21:41:38 -07:00
Tushar Gohad
5e2108722c
Split metadata handling into own routine, add crc32 support
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-08-07 14:19:43 -07:00
Eric Lambert
4a584ee5c2
Merge branch 'newapi' of https://bitbucket.org/tsg-/liberasurecode into newapi
2014-08-08 13:30:52 -07:00
Eric Lambert
9b92176b4e
Added ability to generate coverage data with configure --enable-gcov.
...
Currently only works on Linux (build/tests will run on OS X but
coverage data is not generated).
2014-08-08 13:29:01 -07:00
Kevin Greenan
3f6d2e7a71
Minor bug in getting the required fragments for jerasure
2014-08-08 08:30:35 -07:00
Kevin Greenan
1f39a2f7dc
Adding reconstruction for XOR codes.
2014-08-05 15:04:56 -07:00
Kevin Greenan
109e09fa9c
Fixed reconstruction.
2014-08-05 14:33:39 -07:00
Kevin Greenan
dbbc02d3db
Add HD parameter to generic params.
2014-08-05 14:33:39 -07:00
Eric Lambert
cc765ef92a
Fixed bug where when decoding with a missing data fragment, fragment header
...
reconstruction could occurr against the wrong fragment.
2014-08-01 10:58:23 -07:00
Eric Lambert
b62a45a854
Merge branch 'newapi' of https://bitbucket.org/tsg-/liberasurecode into newapi
2014-07-31 16:15:34 -07:00
Eric Lambert
009aa4e80b
In the erasurecode_preprocessing.c routines for decode/reconstruct, clearly
...
distinguish between the fragment and the data/parity buffers, ie
maintain data, parity pointer arrays separate from the fragment
pointers.
2014-07-31 16:02:28 -07:00
Kevin Greenan
1bb14c6a3a
Stubbing the metadata functions and updating their interfaces.
2014-07-30 23:06:30 -07:00
Eric Lambert
e39aaa3dd9
Created helper function to iterate over a set of data/parity fragments
...
and create an array of pointers to the data segments for each fragment
(this array can then be passed to backend decode functions).
2014-07-29 23:14:46 -07:00
Eric Lambert
d6613f4e90
Merge branch 'newapi' of https://bitbucket.org/tsg-/liberasurecode into newapi
2014-07-29 15:53:22 -07:00
Eric Lambert
7fe555b068
Buffers that hold missing indexes need to be '-1 terminated'
2014-07-29 15:51:57 -07:00
Tushar Gohad
6671c45b03
Add liberasurecode_supported_backends API implementation
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-25 22:18:37 -07:00
Eric Lambert
124a8c6196
Parity Fragment Headers now contain original data length (without them
...
the fragements_to_string function called by decode bails because of size
mismatch). Also update simple encode/decode test to pass all fragments
to decode.
2014-07-24 18:19:13 -07:00
Kevin Greenan
aab24dcc0b
Implemented fragments needed for jerasure backends
2014-07-23 13:24:34 -07:00
Kevin Greenan
ac9e113f43
Oops... Yet another build fix.
2014-07-23 12:53:42 -07:00
Kevin Greenan
5c54419755
Plugged-in Cauchy RS.
2014-07-23 12:47:52 -07:00
Tushar Gohad
7cc67fee9c
Minor API doc fixup (backend names)
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-22 22:20:07 -07:00
Tushar Gohad
779ff74024
null_code: First cut
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-22 22:07:17 -07:00
Tushar Gohad
f50e15dfa9
Add asserts to make sure buffer passed to helpers was not null
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-22 22:04:15 -07:00
Tushar Gohad
9069a7a33a
Fix data_size type, int -> uint64_t
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-22 20:45:24 -07:00
Tushar Gohad
6a49c02f9d
Mac OS X support in xor and jerasure backends
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-22 20:01:07 -07:00
Tushar Gohad
b288baafee
flat_xor_hd: Fix xor_desc pointer (encode/decodes tests pass now)
...
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-22 19:40:30 -07:00
Tushar Gohad
5b393fab81
algsig: Move jerasure backend dlopen up a level
...
.. also check for errors
Signed-off-by: Tushar Gohad <tushar.gohad@intel.com >
2014-07-22 18:25:30 -07:00
Kevin Greenan
59bec942cb
Ripping out galois.[ch] and dynamically pulling the multiplication functon from jerasure
2014-07-22 13:37:39 -07:00