summarylogtreecommitdiffstats
path: root/use-mkinitcpio.patch
blob: e70bce44fb34bf145e342e6a301d564e7fba2d63 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
diff --git a/src/graphics.rs b/src/graphics.rs
index 4fecb8b..5974717 100644
--- a/src/graphics.rs
+++ b/src/graphics.rs
@@ -95,7 +95,7 @@ const EXTERNAL_DISPLAY_REQUIRES_NVIDIA: &[&str] = &[
 ];
 
 const SYSTEMCTL_CMD: &str = "systemctl";
-const UPDATE_INITRAMFS_CMD: &str = "update-initramfs";
+const UPDATE_INITRAMFS_CMD: &str = "mkinitcpio";
 
 #[derive(Debug, thiserror::Error)]
 pub enum GraphicsDeviceError {
@@ -127,7 +127,7 @@ pub enum GraphicsDeviceError {
     SysFs(io::Error),
     #[error("failed to unbind {} on PCI driver {}: {}", func, driver, why)]
     Unbind { func: String, driver: String, why: io::Error },
-    #[error("update-initramfs failed with {} status", _0)]
+    #[error("mkinitcpio failed with {} status", _0)]
     UpdateInitramfs(ExitStatus),
     #[error("failed to access Xserver config: {}", _0)]
     XserverConf(io::Error),
@@ -535,7 +535,7 @@ impl Graphics {
 
         log::info!("Updating initramfs");
         let status = process::Command::new(UPDATE_INITRAMFS_CMD)
-            .arg("-u")
+            .arg("-P")
             .status()
             .map_err(|why| GraphicsDeviceError::Command { cmd: UPDATE_INITRAMFS_CMD, why })?;