Displaying 13 results from an estimated 13 matches for "nbdkit_internal_h".
2020 Mar 26
0
[PATCH nbdkit 5/9 patch split 3/5] server: Move some definitions in server/internal.h to the top of the file.
...nnection *conn = threadlocal_get_conn (); \
assert (conn != NULL)
-/* Declare program_name. */
-#if HAVE_DECL_PROGRAM_INVOCATION_SHORT_NAME == 1
-#include <errno.h>
-#define program_name program_invocation_short_name
-#else
-#define program_name "nbdkit"
-#endif
-
#endif /* NBDKIT_INTERNAL_H */
--
2.25.0
2020 Aug 27
0
[nbdkit PATCH v2 2/8] api: Add nbdkit_add_default_export
...uct connection *threadlocal_get_conn (void);
struct connection *conn = threadlocal_get_conn (); \
assert (conn != NULL)
+/* exports.c */
+extern int exports_resolve_default (struct nbdkit_exports *exports,
+ struct backend *b, int readonly);
+
#endif /* NBDKIT_INTERNAL_H */
diff --git a/server/backend.c b/server/backend.c
index 00e65e3c..3e0a1d24 100644
--- a/server/backend.c
+++ b/server/backend.c
@@ -164,7 +164,7 @@ backend_list_exports (struct backend *b, int readonly, int default_only,
{
GET_CONN;
struct handle *h = get_handle (conn, b->i);
- int r;...
2020 Aug 27
2
Re: [nbdkit PATCH v2 2/8] api: Add nbdkit_add_default_export
...id);
> struct connection *conn = threadlocal_get_conn (); \
> assert (conn != NULL)
>
> +/* exports.c */
> +extern int exports_resolve_default (struct nbdkit_exports *exports,
> + struct backend *b, int readonly);
> +
> #endif /* NBDKIT_INTERNAL_H */
> diff --git a/server/backend.c b/server/backend.c
> index 00e65e3c..3e0a1d24 100644
> --- a/server/backend.c
> +++ b/server/backend.c
> @@ -164,7 +164,7 @@ backend_list_exports (struct backend *b, int readonly, int default_only,
> {
> GET_CONN;
> struct handle *h...
2018 Jan 17
0
[PATCH 2/9] Refactor plugin_* functions into a backend struct.
...amp; plugin_flush (conn) == -1)
+ if (flush_after_command && backend->flush (backend, conn) == -1)
return get_error (conn);
return 0;
diff --git a/src/internal.h b/src/internal.h
index 068204b..9c4993d 100644
--- a/src/internal.h
+++ b/src/internal.h
@@ -35,6 +35,7 @@
#define NBDKIT_INTERNAL_H
#include <stdbool.h>
+#include <stddef.h>
#include <stdarg.h>
#include <sys/socket.h>
#include <pthread.h>
@@ -91,6 +92,11 @@
# endif
#endif
+#define container_of(ptr, type, member) ({ \
+ const typeof (((type *) 0)->member) *__m...
2018 Jan 16
0
[PATCH nbdkit v2 2/3] Refactor plugin_* functions into a backend struct.
...amp; plugin_flush (conn) == -1)
+ if (flush_after_command && backend->flush (backend, conn) == -1)
return get_error (conn);
return 0;
diff --git a/src/internal.h b/src/internal.h
index 068204b..9c4993d 100644
--- a/src/internal.h
+++ b/src/internal.h
@@ -35,6 +35,7 @@
#define NBDKIT_INTERNAL_H
#include <stdbool.h>
+#include <stddef.h>
#include <stdarg.h>
#include <sys/socket.h>
#include <pthread.h>
@@ -91,6 +92,11 @@
# endif
#endif
+#define container_of(ptr, type, member) ({ \
+ const typeof (((type *) 0)->member) *__m...
2018 Jan 16
4
[PATCH nbdkit v2 2/3] Refactor plugin_* functions into a backend
v1 -> v2:
- Fixed everything mentioned in the review.
Rich.
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
2020 Mar 26
9
[PATCH nbdkit 5/9 patch split 1/5] Create libnbdkit.so.
This is the previous 5/9 patch posted earlier today, split into
reviewable chunks. This passes bisection with -x 'make && make
check', but I didn't work very hard on the commit messages, so I refer
you back to the original patch to explain how it works:
https://www.redhat.com/archives/libguestfs/2020-March/msg00248.html
Rich.
2020 Aug 27
10
[nbdkit PATCH v2 0/8] exportname filter
This is a revision of my .default_export work, plus new work on
.export_descriptions and a new exportname filter. I think it is
now ready to check in.
Things I'd still like in 1.22:
- the file plugin should implement .list_exports (patch already posted,
but it needs rebasing on this series)
- the ext2 filter should override .list_exports when in exportname mode
- the nbd plugin should be
2018 Jan 17
14
[PATCH 0/9] Add filters to nbdkit.
The first three patches are identical to:
https://www.redhat.com/archives/libguestfs/2018-January/msg00079.html
"[PATCH nbdkit v2 0/3] Refactor plugin_* functions into a backend"
The rest of the patches add filters using the new filter API
previously described here:
https://www.redhat.com/archives/libguestfs/2018-January/msg00073.html
This needs a lot more testing -- and tests --
2020 Mar 26
15
[PATCH nbdkit 0/9] Create libnbdkit.so
This creates libnbdkit.so as discussed in the following thread:
https://www.redhat.com/archives/libguestfs/2020-March/thread.html#00203
test-delay-shutdown.sh fails for unclear reasons.
This series starts by reverting "tests: Don't strand hung nbdkit
processes" which is because several other tests fail randomly unless I
revert this patch. I didn't investigate this yet so it
2018 Jan 19
16
[nbdkit PATCH v2 00/13] Add filters + FUA support to nbdkit
A combination of the work that both Rich and I have been doing
lately, where filters use only the new API with flags on every
command that the client can send over the wire (we can then
add support for more flags in nbdkit without having to add new
callbacks, as NBD adds more flags upstream).
Eric Blake (4):
protocol: Split flags from cmd field in requests
backend: Pass flags argument through
2020 Sep 21
18
[nbdkit PATCH v3 00/14] exportname filter
It's been several weeks since I posted v2 (I got distracted by
improving libnbd to better test things, which in turn surfaced some
major memory leak problems in nbdsh that are now fixed). Many of the
patches are minor rebases from v2, with the biggest changes being
fallout from:
- patch 2: rename nbdkit_add_default_export to nbdkit_use_default_export
- overall: this missed 1.22, so update