search for: error_config

Displaying 14 results from an estimated 14 matches for "error_config".

2019 Mar 26
0
[PATCH nbdkit v4 07/15] error: Extend the error filter so it can inject errors into block status extents requests.
...sed when holding the lock (except for load). @@ -83,6 +84,7 @@ error_unload (void) free (pwrite_settings.file); free (trim_settings.file); free (zero_settings.file); + free (extents_settings.file); } static const struct { const char *name; int error; } errors[] = { @@ -162,7 +164,8 @@ error_config (nbdkit_next_config *next, void *nxdata, if (parse_error (key, value, &i) == -1) return -1; pread_settings.error = pwrite_settings.error = - trim_settings.error = zero_settings.error = i; + trim_settings.error = zero_settings.error = + extents_settings.error = i;...
2019 Mar 28
0
[PATCH nbdkit v5 FINAL 08/19] error: Extend the error filter so it can inject errors into block status extents requests.
...sed when holding the lock (except for load). @@ -83,6 +84,7 @@ error_unload (void) free (pwrite_settings.file); free (trim_settings.file); free (zero_settings.file); + free (extents_settings.file); } static const struct { const char *name; int error; } errors[] = { @@ -162,7 +164,8 @@ error_config (nbdkit_next_config *next, void *nxdata, if (parse_error (key, value, &i) == -1) return -1; pread_settings.error = pwrite_settings.error = - trim_settings.error = zero_settings.error = i; + trim_settings.error = zero_settings.error = + extents_settings.error = i;...
2019 Apr 27
0
[nbdkit PATCH 1/4] filters: Drop useless .open callbacks
...= cache_open, .prepare = cache_prepare, .get_size = cache_get_size, .pread = cache_pread, diff --git a/filters/error/error.c b/filters/error/error.c index add7566..8932292 100644 --- a/filters/error/error.c +++ b/filters/error/error.c @@ -252,15 +252,6 @@ error_config (nbdkit_next_config *next, void *nxdata, "error-pread*, error-pwrite*, error-trim*, error-zero*, error-extents*\n" \ " Apply settings only to read/write/etc" -static void * -error_open (nbdkit_next_open *next, void *nxdata, int readonly) -{ -...
2019 Apr 01
0
[PATCH nbdkit] error: Fix all error-*-file parameters.
...a07f067d624. Thanks: Martin Kletzander --- filters/error/error.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/filters/error/error.c b/filters/error/error.c index bf7b442..0f84f12 100644 --- a/filters/error/error.c +++ b/filters/error/error.c @@ -213,27 +213,27 @@ error_config (nbdkit_next_config *next, void *nxdata, extents_settings.file = nbdkit_absolute_path (value); return 0; } - else if (strcmp (key, "error-pread-rate") == 0) { + else if (strcmp (key, "error-pread-file") == 0) { free (pread_settings.file); pread_settings....
2019 Mar 28
32
[PATCH nbdkit v5 FINAL 00/19] Implement extents.
This has already been pushed upstream. I am simply posting these here so we have a reference in the mailing list in case we find bugs later (as I'm sure we will - it's a complex patch series). Great thanks to Eric Blake for tireless review on this one. It also seems to have identified a few minor bugs in qemu along the way. Rich.
2019 Apr 27
8
[nbdkit PATCH 0/4] Fix truncate handling of real_size
While working on adding assertions to pthread_mutex_lock calls, I noticed that the truncate filter's use of mutex didn't really protect us, and isn't really necessary. Cleaning that up also spotted a couple of other potential cleanups. Eric Blake (4): filters: Drop useless .open callbacks truncate: Fix corruption when plugin changes per-connection size truncate: Test for safe
2019 Mar 26
21
[PATCH nbdkit v4 00/15] Implement Block Status.
I'm not sure exactly which version we're up to, but let's say it's version 4. I'm a lot happier with this version: - all filters have been reviewed and changed where I think that's necessary - can_extents is properly defined and implemented now - NBD protocol is followed - I believe it addresses all previous review points where possible The "only" thing
2019 Jan 01
0
[PATCH nbdkit] plugins, filters: Define and use NBDKIT_HANDLE_NOT_NEEDED.
...- return &handle; + return NBDKIT_HANDLE_NOT_NEEDED; } /* Get the file size and ensure the overlay is the correct size. */ diff --git a/filters/error/error.c b/filters/error/error.c index c897c76..598bd1f 100644 --- a/filters/error/error.c +++ b/filters/error/error.c @@ -240,12 +240,10 @@ error_config (nbdkit_next_config *next, void *nxdata, static void * error_open (nbdkit_next_open *next, void *nxdata, int readonly) { - static int handle; - if (next (nxdata, readonly) == -1) return NULL; - return &handle; + return NBDKIT_HANDLE_NOT_NEEDED; } /* This function injects a r...
2018 Dec 28
1
[PATCH nbdkit] common: Improve pseudo-random number generation.
...b/filters/error/error.c index 8509a16..6d305b3 100644 --- a/filters/error/error.c +++ b/filters/error/error.c @@ -44,6 +44,8 @@ #include <nbdkit-filter.h> +#include "random.h" + #define THREAD_MODEL NBDKIT_THREAD_MODEL_PARALLEL struct error_settings { @@ -222,17 +224,13 @@ error_config (nbdkit_next_config *next, void *nxdata, " Apply settings only to read/write/trim/zero" struct handle { -#ifdef __GNU_LIBRARY__ - struct random_data rd; - char rd_state[32]; -#endif + struct random_state random_state; }; static void * error_open...
2018 Dec 28
0
[PATCH v2 nbdkit] common: Improve pseudo-random number generation.
...b/filters/error/error.c index 8509a16..9f33910 100644 --- a/filters/error/error.c +++ b/filters/error/error.c @@ -44,6 +44,8 @@ #include <nbdkit-filter.h> +#include "random.h" + #define THREAD_MODEL NBDKIT_THREAD_MODEL_PARALLEL struct error_settings { @@ -222,17 +224,13 @@ error_config (nbdkit_next_config *next, void *nxdata, " Apply settings only to read/write/trim/zero" struct handle { -#ifdef __GNU_LIBRARY__ - struct random_data rd; - char rd_state[32]; -#endif + struct random_state random_state; }; static void * error_open...
2018 Dec 28
2
[PATCH v2 nbdkit] common: Improve pseudo-random number generation.
v2: - Fix seeding. - Add a test that nbdkit-random-plugin is producing something which looks at least somewhat random. Rich.
2019 Aug 30
1
[nbdkit PATCH v2] filters: Stronger version match requirements
...t_ops, void *nxdata, static struct nbdkit_filter filter = { .name = "error", .longname = "nbdkit error filter", - .version = PACKAGE_VERSION, .load = error_load, .unload = error_unload, .config = error_config, diff --git a/filters/fua/fua.c b/filters/fua/fua.c index 9d0e561e..83f7a1a7 100644 --- a/filters/fua/fua.c +++ b/filters/fua/fua.c @@ -233,7 +233,6 @@ fua_zero (struct nbdkit_next_ops *next_ops, void *nxdata, static struct nbdkit_filter filter = { .name = "fua", .long...
2019 May 16
27
[nbdkit PATCH v2 00/24] implement NBD_CMD_CACHE
Since v1: - rework .can_cache to be tri-state, with default of no advertisement (ripple effect through other patches) - add a lot more patches in order to round out filter support And in the meantime, Rich pushed NBD_CMD_CACHE support into libnbd, so in theory we now have a way to test cache commands through the entire stack. Eric Blake (24): server: Internal hooks for implementing
2018 Aug 12
13
[PATCH nbdkit 00/10] FreeBSD support.
With these patches, a majority of tests pass. The notable things which are still broken: - Because FreeBSD links /home -> /usr/home, $(pwd) gives a different result from realpath(2). Therefore some tests which implicitly rely on (eg) a plugin which calls nbdkit_realpath internally and then checking that path against $(pwd) fail. - Shebangs (#!) don't seem to work the same way