diff --git a/video/dav1d/Cargo.toml b/video/dav1d/Cargo.toml
index 2db21cdf2..9c489c163 100644
--- a/video/dav1d/Cargo.toml
+++ b/video/dav1d/Cargo.toml
@@ -9,7 +9,6 @@ license = "MIT OR Apache-2.0"
description = "Dav1d Plugin"
[dependencies]
-atomic_refcell = "0.1"
dav1d = "0.8"
gst = { package = "gstreamer", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" }
gst-base = { package = "gstreamer-base", git = "https://gitlab.freedesktop.org/gstreamer/gstreamer-rs" }
diff --git a/video/dav1d/src/dav1ddec/imp.rs b/video/dav1d/src/dav1ddec/imp.rs
index d31a21717..3de493e2c 100644
--- a/video/dav1d/src/dav1ddec/imp.rs
+++ b/video/dav1d/src/dav1ddec/imp.rs
@@ -16,9 +16,8 @@ use gst_video::subclass::prelude::*;
use once_cell::sync::Lazy;
-use atomic_refcell::{AtomicRefCell, AtomicRefMut};
use std::i32;
-use std::sync::Mutex;
+use std::sync::{Mutex, MutexGuard};
const DEFAULT_N_THREADS: u32 = 0;
const DEFAULT_MAX_FRAME_DELAY: i64 = -1;
@@ -48,7 +47,7 @@ impl Default for Settings {
#[derive(Default)]
pub struct Dav1dDec {
- state: AtomicRefCell