search for: mut

Displaying 20 results from an estimated 122 matches for "mut".

Did you mean: but
2019 Jun 11
3
[nbdkit PATCH 0/2] Few rust plugin fixups/nitpicks
There are few more things that could be cleaned up related to the coding style and other things, like explicitly specifying the abi style after "extern" (i.e. `extern "C" fn` instead of `extern fn`), but since those are configurable in rustfmt config, I'm not sure whether the config needs to be added or complying with the defaults should be the priority. But this was just
2024 Jun 18
1
[PATCH v2 3/8] rust: drm: add driver abstractions
...feature_DRIVER_SYNCOBJ; +/// Driver supports the timeline flavor of DRM sync objects for explicit synchronization of command +/// submission. +pub const FEAT_SYNCOBJ_TIMELINE: u32 = bindings::drm_driver_feature_DRIVER_SYNCOBJ_TIMELINE; +/// Driver supports compute acceleration devices. This flag is mutually exclusive with `FEAT_RENDER` +/// and `FEAT_MODESET`. Devices that support both graphics and compute acceleration should be +/// handled by two drivers that are connected using auxiliary bus. +pub const FEAT_COMPUTE_ACCEL: u32 = bindings::drm_driver_feature_DRIVER_COMPUTE_ACCEL; +/// Driver su...
2013 Apr 25
1
problem with geom_point in ggplot using a different column
I want to draw boxplot where the geom_points are displayed based on "ERBB2.MUT" subset and they should be displayed in the right box (based both on the "ERBB2.2064" field and "ERBB2_Status"). However, given my command I currently only see "red" points corresponding to "MUT" subset in one straight line corresponding to only "E...
2024 Sep 02
2
[PATCH v2 3/8] rust: drm: add driver abstractions
...BJ; > +/// Driver supports the timeline flavor of DRM sync objects for explicit synchronization of command > +/// submission. > +pub const FEAT_SYNCOBJ_TIMELINE: u32 = bindings::drm_driver_feature_DRIVER_SYNCOBJ_TIMELINE; > +/// Driver supports compute acceleration devices. This flag is mutually exclusive with `FEAT_RENDER` > +/// and `FEAT_MODESET`. Devices that support both graphics and compute acceleration should be > +/// handled by two drivers that are connected using auxiliary bus. > +pub const FEAT_COMPUTE_ACCEL: u32 = bindings::drm_driver_feature_DRIVER_COMPUTE_ACCEL;...
2019 Feb 08
0
[PATCH nbdkit] Add support for writing plugins in Rust.
...+// OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT +// OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF +// SUCH DAMAGE. + +extern crate nbdkit; + +#[macro_use] +extern crate lazy_static; + +use libc::*; +use std::ptr; +use std::os::raw::c_int; +use std::sync::Mutex; + +use nbdkit::*; +use nbdkit::ThreadModel::*; + +// The RAM disk. +lazy_static! { + static ref DISK: Mutex<Vec<u8>> = Mutex::new (vec![0; 100 * 1024 * 1024]); +} + +struct Handle { + // Box::new doesn't allocate anything unless we put some dummy + // fields here. In a...
2014 Mar 13
3
FTS solr : body search gives mysql error
Hello, I've recently setup FTS solr plugin, following http://wiki2.dovecot.org/Plugins/FTS/Solr, and I have this error in logs when I do a body search : Mar 13 01:46:40 mut-mx-1 dovecot: auth-worker(5808): Warning: mysql: Query failed, retrying: Unknown column 'disableindexer' in 'where clause' Mar 13 01:46:40 mut-mx-1 dovecot: auth-worker(5808): Error: sql(user at domain.com): User query failed: Unknown column 'disableindexer' in 'where cl...
2023 Apr 05
3
[PATCH v2 0/2] rust: virtio: add virtio support
This used to be a single patch, but I split it into two with the addition of struct Scatterlist. Again a bit new with Rust submissions. I was told by Gary Guo to rebase on top of rust-next, but it seems *very* behind? The first patch does not build on its own due to a dead_code warning. It is hard to not have dead code when one is adding infrastructure to be used by others at a later
2019 Feb 08
3
[PATCH nbdkit] Add support for writing plugins in Rust.
This adds very rough support for writing nbdkit plugins in Rust. This is not very idiomatic -- essentially we're handling the direct C calls from nbdkit in Rust. We have to use ‘unsafe’ in a few places because there's no way to tell the Rust code that nbdkit satisfies guarantees (eg. around thread safety, always returning leaked pointers back to the close function, always doing bounds
2016 Sep 02
2
call_once and TSan
Same problem exists, thread A can still be within REAL(call_once), but after it ran user code and set the flag to ~0. Roughly, call_once does: __call_once(flag, arg, func) { mutex_lock(mut); if (flag == BEING_INITIALIZED) { wait } else if (flag == NOT_INITIALIZED_AT_ALL) { flag = BEING_INITIALIZED; mutex_unlock(mut); func(arg); // <=== user code callback mutex_lock(mut); atomic_store(&flag, FULLY_INITIALIZED, mo_release); // "releas...
2019 Jun 27
0
[PATCH 2/9] Rust bindings: Add create / close functions
...or/rust.ml @@ -31,4 +31,86 @@ open Events let generate_rust () = - generate_header CStyle LGPLv2plus; \ No newline at end of file + generate_header CStyle LGPLv2plus; + + pr " +#[allow(non_camel_case_types)] +enum guestfs_h {} + +extern \"C\" { + fn guestfs_create() -> *mut guestfs_h; + fn guestfs_create_flags(flags: i64) -> *mut guestfs_h; + fn guestfs_close(g: *mut guestfs_h); + static GUESTFS_CREATE_NO_ENVIRONMENT: i64; + static GUESTFS_CREATE_NO_CLOSE_ON_EXIT: i64; +} + +pub struct Handle { + g: *mut guestfs_h, +} + +impl Drop for Handle { + f...
2019 Aug 16
7
[nbdkit PATCH 0/2] rust: Implement some missing v2 callbacks
Similar to what I just did for OCaml (this IS an API break, requiring recompilation of any existing Rust plugin), and done because I want to add fast_zero support to both languages as part of my upcoming fast zero series. Figuring out how to get extents working was hard enough that I punted that, still. Eric Blake (2): rust: Implement can_cache rust: Add support for dynamic .thread_model
2019 Jun 27
0
[PATCH 7/9] Rust bindings: Complete actions
...et generate_rust () = pr " use std::collections; +use std::convert; use std::ffi; use std::slice; use std::ptr; -use std::os::raw::c_char; +use std::os::raw::{c_char, c_int}; #[allow(non_camel_case_types)] @@ -74,6 +75,8 @@ extern \"C\" { fn guestfs_create() -> *mut guestfs_h; fn guestfs_create_flags(flags: i64) -> *mut guestfs_h; fn guestfs_close(g: *mut guestfs_h); + fn guestfs_last_error(g: *mut guestfs_h) -> *const c_char; + fn guestfs_last_errno(g: *mut guestfs_h) -> c_int; } const GUESTFS_CREATE_NO_ENVIRONMENT: i64 = 1; @@ -1...
2019 Aug 31
1
[PATCH libnbd] Add bindings for Rust language
Still not working, but I took the latest patch and: - rebased it against libnbd 1.0 - fixed it so it handles new args and cbargs The generator now runs without warnings. This patch doesn't handle optargs at all. In C these are converted to non-optional parameter. Rust doesn't (AFAIK) have optional or labelled arguments unfortunately. Rich.
2019 Jul 07
2
[libnbd PATCH] RFC: Add bindings for Rust language
...ndent = function + | 0 -> () + | n -> pr " "; pr_indent (n - 1) + +let rec print_rust_ffi_arg_list ?(handle = false) indent args = + let pri () = pr_indent indent in + let pri2 () = pr_indent (indent + 1) in + pr "(\n"; + if handle then ( + pri (); pr "h: *mut nbd_handle,\n"; + ); + List.iter ( + fun arg -> + (match arg with + | ArrayAndLen (UInt32 n, len) -> + pri (); pr "%s: *mut u32,\n" n; + pri (); pr "%s: usize,\n" len + | ArrayAndLen _ -> assert false + | Bool n -> p...
2019 Aug 16
0
[nbdkit PATCH 2/2] rust: Add support for dynamic .thread_model
...rn fn myplugin_thread_model () -> ThreadModel { + Serialize_AllRequests + } + + //... more functions + pub extern fn plugin_init () -> *const Plugin { // Plugin name. let name = "myplugin\0" as *const str as *const [c_char] as *const c_char; - // Create a mutable plugin, setting the 5 required fields. + // Create a mutable plugin, setting the 4 required fields. let mut plugin = Plugin::new ( - Serialize_All_Requests, name, myplugin_open, myplugin_get_size, @@ -53,6 +58,7 @@ compatible with the C struct used by C...
2019 Jul 30
4
[PATCH] Rust bindings: Implement Event features
...se std::collections; +use std::sync; #[allow(non_camel_case_types)] #[repr(C)] @@ -34,31 +38,37 @@ extern "C" { const GUESTFS_CREATE_NO_ENVIRONMENT: i64 = 1; const GUESTFS_CREATE_NO_CLOSE_ON_EXIT: i64 = 2; -pub struct Handle { +pub struct Handle<'a> { pub(crate) g: *mut guestfs_h, + pub(crate) callbacks: collections::HashMap< + event::EventHandle, + sync::Arc<Fn(guestfs::Event, event::EventHandle, &[u8], &[u64]) + 'a>, + >, } -impl Handle { - pub fn create() -> Result<Handle, error::Error> { +impl<'...
2019 Aug 16
1
Re: [nbdkit PATCH 2/2] rust: Add support for dynamic .thread_model
...+ Serialize_AllRequests > + } > + > + //... more functions > + > pub extern fn plugin_init () -> *const Plugin { > // Plugin name. > let name = "myplugin\0" > as *const str as *const [c_char] as *const c_char; > > - // Create a mutable plugin, setting the 5 required fields. > + // Create a mutable plugin, setting the 4 required fields. > let mut plugin = Plugin::new ( > - Serialize_All_Requests, > name, > myplugin_open, > myplugin_get_size, > @@ -53,6 +58,7 @@ com...
2006 Mar 31
1
mutual information for two time series
Hi I hope this is going to the right place. I am trying to write a program which uses KernSmooth library to estimate mutual information between two time series at various different lags. At the moment it’s producing negative values, which is supposed to be impossible (something is fishy). I am summing across one row of the matrix to get p(value is in bin x) and summing across the columns to get p(value is in y), and...
2014 Mar 13
0
FTS solr : body search gives mysql error
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Thu, 13 Mar 2014, Alexandre Ellert wrote: > I've recently setup FTS solr plugin, following http://wiki2.dovecot.org/Plugins/FTS/Solr, and I have this error in logs when I do a body search : > > Mar 13 01:46:40 mut-mx-1 dovecot: auth-worker(5808): Warning: mysql: Query failed, retrying: Unknown column 'disableindexer' in 'where clause' > Mar 13 01:46:40 mut-mx-1 dovecot: auth-worker(5808): Error: sql(user at domain.com): User query failed: Unknown column 'disableindexer' in 'whe...
2010 Feb 11
2
Oblivion sound effects mutted on wine-1.1.38
I have tested wine-1.1.38 with Oblivion on Gentoo and I found that the sound effects are no more being played. I`m new to wine bugzilla and I don`t know a proper way to report bugs and regressions. Please if someone is able to report this bug or help me find a way to fix it, I will be glad.