Displaying 20 results from an estimated 56 matches for "0_l".
Did you mean:
0_
2019 Aug 10
1
Re: [PATCH libnbd 2/9] generator: Generalize OFlags.
...(nbd_can_df) before you can use it. So any further restrictions we
decide to encode in the generator rather (or in addition) to
restrictions in lib/rw.c can be a later patch.
> +++ b/ocaml/tests/test_405_pread_structured.ml
> @@ -54,11 +54,13 @@ let () =
> NBD.pread_structured nbd buf 0_L (f 42);
> assert (buf = expected);
>
> - NBD.pread_structured nbd buf 0_L (f 42) ~flags:[NBD.cmd_flag_df];
> + let flags = let open NBD.CMD_FLAG in [DF] in
> +
> + NBD.pread_structured nbd buf 0_L (f 42) ~flags;
blank line here...
> +++ b/ocaml/tests/test_410_pwrite....
2019 Aug 13
0
[PATCH libnbd 6/6] lib: Make all completion callbacks into OClosures.
...57 100644
--- a/ocaml/tests/test_505_aio_pread_structured_callback.ml
+++ b/ocaml/tests/test_505_aio_pread_structured_callback.ml
@@ -60,7 +60,8 @@ let () =
(* First try: succeed in both callbacks *)
let buf = NBD.Buffer.alloc 512 in
- let cookie = NBD.aio_pread_structured_callback nbd buf 0_L (chunk 42) (callback 42) in
+ let cookie = NBD.aio_pread_structured_callback nbd buf 0_L (chunk 42)
+ ~completion:(callback 42) in
while not (NBD.aio_command_completed nbd cookie) do
ignore (NBD.poll nbd (-1))
done;
@@ -71,7 +72,8 @@ let () =
(* Second try: fail onl...
2019 Aug 13
0
[PATCH libnbd v2 2/3] lib: Make all completion callbacks into OClosures.
...57 100644
--- a/ocaml/tests/test_505_aio_pread_structured_callback.ml
+++ b/ocaml/tests/test_505_aio_pread_structured_callback.ml
@@ -60,7 +60,8 @@ let () =
(* First try: succeed in both callbacks *)
let buf = NBD.Buffer.alloc 512 in
- let cookie = NBD.aio_pread_structured_callback nbd buf 0_L (chunk 42) (callback 42) in
+ let cookie = NBD.aio_pread_structured_callback nbd buf 0_L (chunk 42)
+ ~completion:(callback 42) in
while not (NBD.aio_command_completed nbd cookie) do
ignore (NBD.poll nbd (-1))
done;
@@ -71,7 +72,8 @@ let () =
(* Second try: fail onl...
2019 Aug 14
0
[libnbd PATCH 2/2] ocaml: Fix test 505
...sert (!err = 0)
else
assert (!err = 100);
err := 101;
- assert (user_data = 42);
+ assert (snd user_data = 42);
0
let () =
@@ -61,7 +61,7 @@ let () =
(* First try: succeed in both callbacks *)
let buf = NBD.Buffer.alloc 512 in
let cookie = NBD.aio_pread_structured nbd buf 0_L (chunk 42)
- ~completion:(callback 42) in
+ ~completion:(callback (42, 42)) in
while not (NBD.aio_command_completed nbd cookie) do
ignore (NBD.poll nbd (-1))
done;
@@ -73,7 +73,7 @@ let () =
(* Second try: fail only during callback *)
let buf = NBD.B...
2015 Jan 22
3
[PATCH 1/2] configure: look for the oUnit OCaml module
It will be used for the OCaml unit tests.
---
configure.ac | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/configure.ac b/configure.ac
index e0fb481..e360bbb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1120,6 +1120,7 @@ AS_IF([test "x$OCAMLC" != "xno"],[
])
OCAML_PKG_gettext=no
+OCAML_PKG_oUnit=no
AS_IF([test "x$OCAMLC" != "xno"],[
#
2015 Jan 22
0
[PATCH 2/2] mllib: convert common_utils_tests to oUnit
...l_int64 0x20406080L (int_of_le32 "\x80\x60\x40\x20");
+ assert_equal_string "\x80\x60\x40\x20" (le32_of_int 0x20406080L)
(* Test Common_utils.parse_size. *)
-let () =
+let test_parse_resize () =
(* For absolute sizes, oldsize is ignored. *)
- assert (parse_resize ~prog 100_L "100b" = 100_L);
- assert (parse_resize ~prog 1000_L "100b" = 100_L);
- assert (parse_resize ~prog 10000_L "100b" = 100_L);
- assert (parse_resize ~prog 100_L "100K" = 102400_L);
+ assert_equal_int64 100_L (parse_resize ~prog 100_L "100b");
+ a...
2019 Aug 10
0
[PATCH libnbd 2/9] generator: Generalize OFlags.
...;
value *data;
diff --git a/ocaml/tests/test_405_pread_structured.ml b/ocaml/tests/test_405_pread_structured.ml
index d226af0..e6a3b15 100644
--- a/ocaml/tests/test_405_pread_structured.ml
+++ b/ocaml/tests/test_405_pread_structured.ml
@@ -54,11 +54,13 @@ let () =
NBD.pread_structured nbd buf 0_L (f 42);
assert (buf = expected);
- NBD.pread_structured nbd buf 0_L (f 42) ~flags:[NBD.cmd_flag_df];
+ let flags = let open NBD.CMD_FLAG in [DF] in
+
+ NBD.pread_structured nbd buf 0_L (f 42) ~flags;
assert (buf = expected);
try
- NBD.pread_structured nbd buf 0_L (f 43) ~flags:[N...
2019 Aug 14
4
[libnbd PATCH 0/2] Fix test 505
Rich found that I had been using bogus logic, but it was hidden by
other bugs in our language bindings until recently.
Eric Blake (2):
python: Fix test 505
ocaml: Fix test 505
python/t/505-aio-pread-callback.py | 14 +++++++-------
.../test_505_aio_pread_structured_callback.ml | 14 +++++++-------
2 files changed, 14 insertions(+), 14 deletions(-)
--
2.20.1
2019 Aug 13
7
[PATCH libnbd v2 0/3] Implement OClosures.
v1 was here:
https://www.redhat.com/archives/libguestfs/2019-August/msg00168.html
I pushed uncontroversial patches 1-4
v2:
- The implementation of OClosure (new patch 1) in Python is fixed.
- Patch 2 (old patch 5) is unchanged.
- I added a new API for removing debug callbacks. I think this
approach has some advantages over using OClosure.
- I didn't yet do any work on changing the
2016 Apr 06
8
[PATCH 0/4] v2v: simplify Windows registry patching
The way we patch the Windows registry in order to allow it to boot off a
virtio-blk drive was initially conceived by comparing the state with
virtio-blk driver properly installed, to that without.
However, we don't want to replicate the Windows PnP system; rather we
need to apply just enough edits to make the system boot, and then let
the Windows PnP manager figure out the rest.
This series
2016 Apr 05
0
[PATCH 1/7] v2v: check next free oem%d.inf in /Windows/Inf
...ot;cannot find HKLM\\SYSTEM\\DriverDatabase\\DeviceIds\\%s in the guest registry") scsi_adapter_guid
- | Some node ->
- let rec loop node i =
- let oem_inf = sprintf "oem%d.inf" i in
- let value = g#hivex_node_get_value node oem_inf in
- if value = 0_L then oem_inf else loop node (i+1)
- in
- let oem_inf = loop node 1 in
- (* Create the key. *)
- g#hivex_node_set_value node oem_inf (* REG_NONE *) 0_L "";
- oem_inf in
+ let oem_inf = set_free_oem_inf g root scsi_adapter_guid "viostor.inf" driverdi...
2018 Dec 04
2
[PATCH FOR DISCUSSION ONLY 0/2] v2v: Copy static IP address information over for Windows guests (RHBZ#1626503).
This patch is just for discussion. There are still a couple of issues
that I'm trying to fix.
One is that all of the test guests I have, even ones with static IPs,
have multiple interfaces, some using DHCP, so the conditions for
adding the Powershell script don't kick in. This makes testing very
awkward.
However a bigger issue is that I think the premise is wrong. In some
registries
2018 Dec 11
2
[PATCH v2 2/2] v2v: Copy static IP address information over for Windows guests (RHBZ#1626503).
v1 was here with much discussion:
https://www.redhat.com/archives/libguestfs/2018-December/msg00048.html
v2:
- Fix the case where there are multiple interfaces. Note this does
not preserve order correctly (see patch for comment on why that
is a hard problem).
- Preserve name servers.
This patch is still for discussion only. I'd like to see what might
be done to get this upstream
2016 Apr 05
0
[PATCH 2/7] v2v: extract controller offset discovery as a function
...in the guest registry")
- (String.concat "\\" controller_path)
- | Some node ->
- let rec loop node i =
- let controller_offset = sprintf "%04d" i in
- let child = g#hivex_node_get_child node controller_offset in
- if child = 0_L then controller_offset else loop node (i+1)
- in
- loop node 0 in
+ let controller_offset = get_controller_offset g root controller_path in
let regedits = [
controller_path @ [ controller_offset ],
@@ -400,6 +389,19 @@ and set_free_oem_inf g root guid driver_inf driverdir =...
2016 Apr 05
0
[PATCH 4/7] v2v: extract reusable parts of viostor regedits
..."ClassGUID", REG_SZ "{4D36E97B-E325-11CE-BFC1-08002BE10318}" ];
- [ current_cs; "Services"; "viostor" ],
+ [ current_cs; "Services"; driver_name ],
[ "Type", REG_DWORD 0x1_l;
"Start", REG_DWORD 0x0_l;
"Group", REG_SZ "SCSI miniport";
"ErrorControl", REG_DWORD 0x1_l;
- "ImagePath", REG_EXPAND_SZ "system32\\drivers\\viostor.sys";
+ "ImagePath", REG_EXPAND_SZ ("system32\\drivers\\" ^ driver);...
2019 Aug 13
0
[PATCH libnbd] api: Rename nbd_aio_*_callback to nbd_aio_*.
...85 100644
--- a/ocaml/tests/test_505_aio_pread_structured_callback.ml
+++ b/ocaml/tests/test_505_aio_pread_structured_callback.ml
@@ -60,7 +60,7 @@ let () =
(* First try: succeed in both callbacks *)
let buf = NBD.Buffer.alloc 512 in
- let cookie = NBD.aio_pread_structured_callback nbd buf 0_L (chunk 42)
+ let cookie = NBD.aio_pread_structured nbd buf 0_L (chunk 42)
~completion:(callback 42) in
while not (NBD.aio_command_completed nbd cookie) do
ignore (NBD.poll nbd (-1))
@@ -72,7 +72,7 @@ let () =
(* Second try: fail only during callback *)
let buf = N...
2019 Aug 10
17
[PATCH libnbd 0/9] Add Enum and Flags types.
This largish series adds several new features to the generator.
Enum maps to enumerated types (like enum in C). The only current use
for this is replacing the nbd_set_tls (nbd, 0/1/2) parameter with
LIBNBD_TLS_DISABLE, LIBNBD_TLS_ALLOW, LIBNBD_TLS_REQUIRE (and natural
equivalents in other programming languages).
Flags maps to any uint32_t bitmask. It is basically a non-optional,
generalized
2019 Aug 13
2
[PATCH libnbd] api: Rename nbd_aio_*_callback to nbd_aio_*.
This applies on top of the OClosure v2 series posted a few
minutes ago.
Rich.
2015 Jan 29
3
[PATCH 1/2] sparsify: ignore read-only btrfs snapshots (RHBZ#1079625)
In copy mode, make sure to not zero-free-space read-only btrfs
snapshots, as we cannot write to them.
---
sparsify/copying.ml | 28 +++++++++++++++++++++++++---
1 file changed, 25 insertions(+), 3 deletions(-)
diff --git a/sparsify/copying.ml b/sparsify/copying.ml
index 8d77964..4c23939 100644
--- a/sparsify/copying.ml
+++ b/sparsify/copying.ml
@@ -208,6 +208,11 @@ You can ignore this warning or
2019 Jan 30
1
[PATCH v3] v2v: linux: use NEVR for querying RPM packages (RHBZ#1669395)
...ith Not_found ->
+ (* 'rpm' not installed? Hmm... *)
+ (0, 0) in
+ ver < (4, 11)
+ in
let pkg_name =
- sprintf "%s-%s-%s" app.G.app2_name
- app.G.app2_version app.G.app2_release in
- let pkg_name =
- if app.G.app2_epoch > 0_l then (
- (* RHEL 3/4 'rpm' does not support using the epoch prefix.
- * (RHBZ#1170685).
- *)
- let is_rhel_lt_5 =
- match inspect with
- | { i_type = "linux";
- i_distro = "rhel" | "centos" | "sc...