diff --git a/src/dma.rs b/src/dma.rs
index 6ebbd2566ced04462b0ef251e608e21f2690436a..71a27885e1848bad201b5c7b2dc5020f4bae531d 100644
--- a/src/dma.rs
+++ b/src/dma.rs
@@ -73,6 +73,7 @@ pub struct Dma2Channel6 {
 // NOTE(packed) workaround for rust-lang/rust#41315
 #[repr(packed)]
 pub struct Buffer<T, CHANNEL> {
+    #[repr(align(32))]
     data: UnsafeCell<T>,
     flag: Cell<BorrowFlag>,
     state: Cell<State>,
@@ -195,7 +196,9 @@ impl<T, CHANNEL> Buffer<T, CHANNEL> {
         }
     }
 
-    pub(crate) fn lock(&self) -> &T {
+    // shuould be pub(crate)
+    ///
+    pub fn lock(&self) -> &T {
         assert_eq!(self.state.get(), State::Unlocked);
         assert_ne!(self.flag.get(), WRITING);
 
diff --git a/src/lib.rs b/src/lib.rs
index 5db97ddc42764501e846e12f1310cf8857b8729d..72d1e8b6c43632247c9efa59c643d2470419b307 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -23,6 +23,8 @@
 #![feature(get_type_id)]
 #![feature(never_type)]
 #![feature(unsize)]
+#![feature(repr_align)]
+#![feature(attr_literals)]
 #![no_std]
 
 extern crate cast;