Displaying 15 results from an estimated 15 matches for "oili".
Did you mean:
oici
2020 Mar 19
5
[nbdkit PATCH 0/2] More caching of initial setup
When I added .can_FOO caching in 1.16, I missed the case that the sh
plugin itself was calling .can_flush twice in some situations (in
order to default .can_fua). Then right after, I regressed it to call
.can_zero twice (in order to default .can_fast_zero). I also missed
that .thread_model could use better caching, because at the time, I
did not add testsuite coverage. Fix that now.
Eric Blake
2019 Nov 22
0
[PATCH nbdkit v2 03/10] python: Implement nbdkit API version 2.
...e, void *buf,
PyErr_Clear ();
- r = PyObject_CallFunction (fn, "OiL", obj, count, offset, NULL);
+ switch (py_api_version) {
+ case 1:
+ r = PyObject_CallFunction (fn, "OiL", obj, count, offset, NULL);
+ break;
+ case 2:
+ r = PyObject_CallFunction (fn, "OiLI", obj, count, offset, flags, NULL);
+ break;
+ default: abort ();
+ }
Py_DECREF (fn);
if (check_python_failure ("pread") == -1)
return -1;
@@ -505,8 +536,8 @@ py_pread (void *handle, void *buf,
}
static int
-py_pwrite (void *handle, const void *buf,
- ui...
2019 Nov 23
0
[PATCH nbdkit v3 2/7] python: Implement nbdkit API version 2.
...e, void *buf,
PyErr_Clear ();
- r = PyObject_CallFunction (fn, "OiL", obj, count, offset, NULL);
+ switch (py_api_version) {
+ case 1:
+ r = PyObject_CallFunction (fn, "OiL", obj, count, offset, NULL);
+ break;
+ case 2:
+ r = PyObject_CallFunction (fn, "OiLI", obj, count, offset, flags, NULL);
+ break;
+ default: abort ();
+ }
Py_DECREF (fn);
if (check_python_failure ("pread") == -1)
return ret;
@@ -515,8 +560,8 @@ out:
}
static int
-py_pwrite (void *handle, const void *buf,
- uint32_t count, uint64_t offset...
2019 Nov 21
10
[PATCH nbdkit 0/8] Implement nbdkit API v2 for Python plugins.
And fill out most of the missing bits of the API.
Rich.
2019 Nov 22
0
[PATCH nbdkit v2 06/10] python: Implement cache.
...quot;cache", &fn)) {
+ PyErr_Clear ();
+
+ switch (py_api_version) {
+ case 1:
+ nbdkit_error ("%s can only be called when using api_version >= 2",
+ "cache");
+ return -1;
+ case 2:
+ r = PyObject_CallFunction (fn, "OiLI", obj, count, offset, flags, NULL);
+ break;
+ default: abort ();
+ }
+ Py_DECREF (fn);
+ if (check_python_failure ("cache") == -1)
+ return -1;
+ Py_DECREF (r);
+ }
+ else {
+ nbdkit_error ("%s not implemented", "cache");
+ return...
2019 Nov 21
0
[PATCH nbdkit 6/8] python: Implement cache, can_cache.
...quot;cache", &fn)) {
+ PyErr_Clear ();
+
+ switch (py_api_version) {
+ case 1:
+ nbdkit_error ("%s can only be called when using api_version >= 2",
+ "cache");
+ return -1;
+ case 2:
+ r = PyObject_CallFunction (fn, "OiLI", obj, count, offset, flags, NULL);
+ break;
+ default: abort ();
+ }
+ Py_DECREF (fn);
+ if (check_python_failure ("cache") == -1)
+ return -1;
+ Py_DECREF (r);
+ }
+ else {
+ nbdkit_error ("%s not implemented", "cache");
+ return...
2020 Aug 10
0
Re: [PATCH nbdkit] python: Implement can_extents + extents.
...t; + ACQUIRE_PYTHON_GIL_FOR_CURRENT_SCOPE;
> + struct handle *h = handle;
> + PyObject *fn;
> + PyObject *r;
> + Py_ssize_t i, size;
> +
> + if (callback_defined ("extents", &fn)) {
> + PyErr_Clear ();
> +
> + r = PyObject_CallFunction (fn, "OiLI", h->py_h, count, offset, flags);
> + Py_DECREF (fn);
> + if (check_python_failure ("extents") == -1)
> + return -1;
> +
> + /* We expect a list of extents to be returned. Each extent is a
> + * tuple (offset, length, type).
> + */
>...
2002 Oct 22
4
repeatedly crashing smbd when printing: broken pipe
for months, we keep fighting issues with smbd
(now at released 2.2.6), config is with spoolss,
domain logon, and the client in question is an
NT4 machine. server is a i386/linux 2.2.19
For a very long time, we thought it was related
to oplocks, but now after having them disabled,
it still is there.
Level 3 Log is as follows:
[2002/10/22 17:08:18, 3] smbd/ipc.c:reply_trans(480)
trans
2020 Aug 10
5
[PATCH nbdkit] python: Implement can_extents + extents.
...t32_t flags, struct nbdkit_extents *extents)
+{
+ ACQUIRE_PYTHON_GIL_FOR_CURRENT_SCOPE;
+ struct handle *h = handle;
+ PyObject *fn;
+ PyObject *r;
+ Py_ssize_t i, size;
+
+ if (callback_defined ("extents", &fn)) {
+ PyErr_Clear ();
+
+ r = PyObject_CallFunction (fn, "OiLI", h->py_h, count, offset, flags);
+ Py_DECREF (fn);
+ if (check_python_failure ("extents") == -1)
+ return -1;
+
+ /* We expect a list of extents to be returned. Each extent is a
+ * tuple (offset, length, type).
+ */
+ if (!PyList_Check (r)) {
+ nbd...
2019 Nov 25
7
[PATCH nbdkit v2 0/7] Implement nbdkit API v2 for Python plugins.
v3 was here:
https://www.redhat.com/archives/libguestfs/2019-November/msg00209.html
In v4:
- Rebase on top of current master. Includes various fixes and
updates required because of Nir's patches that went into master.
- Fix api_version() -> API_VERSION in patch 2 noted previously on the
mailing list.
Rich.
2019 Nov 23
8
[PATCH nbdkit v3 0/7] Implement nbdkit API v2 for Python plugins.
v2 was here:
https://www.redhat.com/archives/libguestfs/2019-November/msg00163.html
I pushed patch 1 (with spelling fix), patch 4 and patch 5 since those
were previously ACKed on the list.
Differences in v3:
- Add error checking to PyModule_AddIntConstant.
- Use API_VERSION constant instead of function.
- Add max API version supported to --dump-plugin output.
- Print API_VERSION selected by
2019 Nov 25
0
[PATCH nbdkit 1/2] python: For v2 API, avoid copy by passing a buffer to pread.
...100644
--- a/plugins/python/python.c
+++ b/plugins/python/python.c
@@ -527,7 +527,9 @@ py_pread (void *handle, void *buf, uint32_t count, uint64_t offset,
r = PyObject_CallFunction (fn, "OiL", obj, count, offset, NULL);
break;
case 2:
- r = PyObject_CallFunction (fn, "OiLI", obj, count, offset, flags, NULL);
+ r = PyObject_CallFunction (fn, "ONLI", obj,
+ PyMemoryView_FromMemory ((char *)buf, count, PyBUF_WRITE),
+ offset, flags, NULL);
break;
default: abort ();
}
@@ -535,19 +537,25 @@ py_pread (void *handle, void *buf,...
2020 Aug 10
0
Re: [PATCH nbdkit] python: Implement can_extents + extents.
...t; + ACQUIRE_PYTHON_GIL_FOR_CURRENT_SCOPE;
> + struct handle *h = handle;
> + PyObject *fn;
> + PyObject *r;
> + Py_ssize_t i, size;
> +
> + if (callback_defined ("extents", &fn)) {
> + PyErr_Clear ();
> +
> + r = PyObject_CallFunction (fn, "OiLI", h->py_h, count, offset, flags);
> + Py_DECREF (fn);
> + if (check_python_failure ("extents") == -1)
> + return -1;
> +
> + /* We expect a list of extents to be returned. Each extent is a
> + * tuple (offset, length, type).
> + */
>...
2019 Nov 25
3
[PATCH nbdkit 0/2] python: Implement pread passing buffer for v2 API.
As suggested by Nir, here:
https://www.redhat.com/archives/libguestfs/2019-November/thread.html#00220
2019 Nov 22
18
[PATCH nbdkit v2 00/10] Implement nbdkit API v2 for Python plugins.
v1:
https://www.redhat.com/archives/libguestfs/2019-November/msg00153.html
v2:
- Fix implementation of can_cache.
- Add implementation of can_fua.
- Add a very thorough test suite which tests every command + flag
combination.