Displaying 11 results from an estimated 11 matches for "nbdkit_extent_".
Did you mean:
nbdkit_extents
2019 Aug 15
3
[nbdkit PATCH] nbd: Another libnbd version bump
...e;
- if (!(valid_flag & LIBNBD_CALLBACK_VALID))
- return 0;
-
- assert (strcmp (metacontext, "base:allocation") == 0);
+ assert (strcmp (metacontext, LIBNBD_CONTEXT_BASE_ALLOCATION) == 0);
assert (nr_entries % 2 == 0);
while (nr_entries) {
/* We rely on the fact that NBDKIT_EXTENT_* match NBD_STATE_* */
@@ -797,14 +791,12 @@ nbdplug_extents (void *handle, uint32_t count, uint64_t offset,
struct handle *h = handle;
struct transaction s;
uint32_t f = flags & NBDKIT_FLAG_REQ_ONE ? LIBNBD_CMD_FLAG_REQ_ONE : 0;
+ nbd_extent_callback extcb = { nbdplug_extent, extents...
2019 Mar 19
0
[PATCH nbdkit 3/9] server: Implement Block Status requests to read allocation status.
...id *dv)
+{
+ struct copy_extents_data *data = dv;
+ uint32_t type_flags;
+
+ assert (data->i < data->nr_blocks);
+
+ /* Because the original request is limited to a 32 bit count, length
+ * can never be > 32 bits in size.
+ */
+ assert (length <= UINT32_MAX);
+
+ /* Convert NBDKIT_EXTENT_* flags to NBD_STATE_* flags. However
+ * since these are deliberately chosen to be the same binary values
+ * we only have to mask here.
+ */
+ type_flags = type & 3;
+
+ data->blocks[data->i].length = length;
+ data->blocks[data->i].status_flags = type_flags;
+
+ data-&g...
2019 May 30
0
[nbdkit PATCH 3/4] nbd: Use libnbd 0.1
...gt;count;
- if (nextents) {
- if (!trans->extents) {
- nbdkit_error ("block status response to a non-status command");
- return nbdplug_mark_dead (h);
- }
- offset = trans->offset;
- for (size_t i = 0; i < nextents; i++) {
- /* We rely on the fact that NBDKIT_EXTENT_* match NBD_STATE_* */
- if (nbdkit_add_extent (trans->extents, offset,
- be32toh (extents[i].length),
- be32toh (extents[i].status_flags)) == -1) {
- error = errno;
- break;
- }
- offset += be32toh (extents[i].l...
2019 Jun 12
0
[nbdkit PATCH v3 3/5] nbd: Use libnbd 0.1.3+
...gt;count;
- if (nextents) {
- if (!trans->extents) {
- nbdkit_error ("block status response to a non-status command");
- return nbdplug_mark_dead (h);
- }
- offset = trans->offset;
- for (size_t i = 0; i < nextents; i++) {
- /* We rely on the fact that NBDKIT_EXTENT_* match NBD_STATE_* */
- if (nbdkit_add_extent (trans->extents, offset,
- be32toh (extents[i].length),
- be32toh (extents[i].status_flags)) == -1) {
- error = errno;
- break;
- }
- offset += be32toh (extents[i].l...
2019 May 30
5
[nbdkit PATCH 0/4] Play with libnbd for nbdkit-add
Patch 1 played with an early draft of Rich's Fedora 30 libnbd package:
https://bugzilla.redhat.com/show_bug.cgi?id=1713767#c17
Note that comment 21 provides a newer package 0.1.1-1 with a different
API; and that libnbd has more unreleased API changes in the pipeline
(whether that will be called 0.2 or 0.1.2); so we'll have to tweak
things based on what is actually available in distros.
2019 Apr 25
6
[nbdkit PATCH v2 0/5] structured replies/.extents for nbd plugin
Updated based on other changes that have happened in the meantime:
- rely more on cleanup.h (throughout)
- split structured read for easier review (patch 2 and 3 were combined in v1)
- rely on nbdkit not leaking a server's partial answer (patch 3)
- add tests (patch 5)
- other bug fixes I found while testing it
- drop EOVERFLOW patch for now; it will be separate once upstream
NBD protocol
2019 Jun 02
5
[nbdkit PATCH v2 0/5] Play with libnbd for nbdkit-nbd
libnbd-0.1.2-1 is now available in Fedora 29/30 updates-testing,
although it was not compiled against libxml2 so it lacks uri support
(I ended up testing patch 4 with a self-built libnbd).
Diffs since v1 - rebase to master, bump from libnbd 0.1 to 0.1.2, add
URI support, better timing results
Still not done - patch 5 needs associated tests
Eric Blake (5):
nbd: Check for libnbd
nbd:
2020 Mar 19
1
[nbdkit PATCH] nbd: Drop nbd-standalone fallback
...ns->count;
- if (nextents) {
- if (!trans->extents) {
- nbdkit_error ("block status response to a non-status command");
- return nbd_mark_dead (h);
- }
- offset = trans->offset;
- for (size_t i = 0; i < nextents; i++) {
- /* We rely on the fact that NBDKIT_EXTENT_* match NBD_STATE_* */
- if (nbdkit_add_extent (trans->extents, offset,
- be32toh (extents[i].length),
- be32toh (extents[i].status_flags)) == -1) {
- error = errno;
- break;
- }
- offset += be32toh (extents[i].l...
2019 Jun 12
8
[nbdkit PATCH v3 0/5] Play with libnbd for nbdkit-nbd
libnbd-0.1.4-1 is now available in Fedora 29/30 updates testing.
Diffs since v2 - rebase to master, bump from libnbd 0.1.2 to 0.1.3+,
add tests to TLS usage which flushed out the need to turn relative
pathnames into absolute, doc tweaks
Now that the testsuite covers TLS and libnbd has been fixed to provide
the things I found lacking when developing v2, I'm leaning towards
pushing this on
2019 Apr 23
12
[nbdkit PATCH 0/7] Implement structured replies in nbd plugin
I'm hoping to implement .extents for the nbd plugin; this is a
prerequisite. I'm not sure about patch 3 - if we like it, I'll
squash it to 2, if we don't, I think we are okay just dropping
it. I'm also wondering if we have to worry about malicious
plugins that don't populate the entire .pread buffer in an
effort to get nbdkit to expose portions of the heap; my patch 7
loses
2019 Mar 19
15
[PATCH nbdkit 0/9] [mainly for discussion and early review] Implement extents.
I want to post this but mainly for discussion and early review. It's
not safe for these patches to all go upstream yet (because not all
filters have been checked/adjusted), but if any patches were to go
upstream then probably 1 & 2 only are safe.
File, VDDK, memory and data plugins all work, although I have only
done minimal testing on them.
The current tests, such as they are, all