]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rbd: recognize rxbounce map option
authorIlya Dryomov <idryomov@gmail.com>
Wed, 26 Jan 2022 18:36:26 +0000 (19:36 +0100)
committerIlya Dryomov <idryomov@gmail.com>
Sun, 13 Feb 2022 16:17:08 +0000 (17:17 +0100)
Fixes: https://tracker.ceph.com/issues/54063
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit 8d2a456d7055cfb64e6bb9927187e2240b8c4d2a)

doc/man/8/rbd.rst
src/tools/rbd/action/Kernel.cc

index 407bf36b70b81bad4f70f4f8d63ab0ed889c4e09..b5705ee04ad06dfa8d17c0ae43dc54ff4770024f 100644 (file)
@@ -871,6 +871,15 @@ Per mapping (block device) `rbd device map` options:
   mode (since 5.11).  If the daemon denies 'secure' mode in favor of 'crc'
   mode, agree to 'crc' mode.
 
+* rxbounce - Use a bounce buffer when receiving data (since 5.17).  The default
+  behaviour is to read directly into the destination buffer.  A bounce buffer
+  is needed if the destination buffer isn't guaranteed to be stable (i.e. remain
+  unchanged while it is being read to).  In particular this is the case for
+  Windows where a system-wide "dummy" (throwaway) page may be mapped into the
+  destination buffer in order to generate a single large I/O.  Otherwise,
+  "libceph: ... bad crc/signature" or "libceph: ... integrity error, bad crc"
+  errors and associated performance degradation are expected.
+
 * udev - Wait for udev device manager to finish executing all matching
   "add" rules and release the device before exiting (default).  This option
   is not passed to the kernel.
index 6f967f9086ad9d6c3a5328b1081669157e7b3aa0..a39c132ad4e0c023727ba543bd87a39f00f50ec9 100644 (file)
@@ -210,6 +210,8 @@ static int parse_map_options(const std::string &options_string,
       if (put_map_option_value("ms_mode", value_char, map_option_ms_mode_cb,
                                map_options))
         return -EINVAL;
+    } else if (!strcmp(this_char, "rxbounce")) {
+      put_map_option("rxbounce", this_char, map_options);
     } else if (!strcmp(this_char, "udev") || !strcmp(this_char, "noudev")) {
       put_map_option("udev", this_char, map_options);
     } else {