summary refs log tree commit diff
path: root/pkgs
diff options
context:
space:
mode:
authorLluís Batlle i Rossell <viric@viric.name>2012-11-06 00:16:13 +0100
committerLluís Batlle i Rossell <viric@viric.name>2012-11-06 00:16:13 +0100
commitbb3b603ea70926816fdd8a803bccdcec846ff30d (patch)
tree7f65e889a3f547ab4cf7e6caf240f99c184ea30b /pkgs
parent11094a79607d37c08378f3b441b276a2ba93bf95 (diff)
downloadnixpkgs-bb3b603ea70926816fdd8a803bccdcec846ff30d.tar
nixpkgs-bb3b603ea70926816fdd8a803bccdcec846ff30d.tar.gz
nixpkgs-bb3b603ea70926816fdd8a803bccdcec846ff30d.tar.bz2
nixpkgs-bb3b603ea70926816fdd8a803bccdcec846ff30d.tar.lz
nixpkgs-bb3b603ea70926816fdd8a803bccdcec846ff30d.tar.xz
nixpkgs-bb3b603ea70926816fdd8a803bccdcec846ff30d.tar.zst
nixpkgs-bb3b603ea70926816fdd8a803bccdcec846ff30d.zip
mips linux: Adding a patch to fix an ext3 bug in 3.5 and 3.6
I made it apply to all Mips, although the bug works only for n32 and o32 ABIs.
We don't support any n64 by now.
Diffstat (limited to 'pkgs')
-rw-r--r--pkgs/os-specific/linux/kernel/mips-ext3-n32.patch17
-rw-r--r--pkgs/os-specific/linux/kernel/patches.nix5
-rw-r--r--pkgs/top-level/all-packages.nix2
3 files changed, 24 insertions, 0 deletions
diff --git a/pkgs/os-specific/linux/kernel/mips-ext3-n32.patch b/pkgs/os-specific/linux/kernel/mips-ext3-n32.patch
new file mode 100644
index 00000000000..fcb6f9177c7
--- /dev/null
+++ b/pkgs/os-specific/linux/kernel/mips-ext3-n32.patch
@@ -0,0 +1,17 @@
+Dirty patch that makes ext3 work again on 3.5 and 3.6 kernels,
+on mips n32.
+
+http://www.linux-mips.org/archives/linux-mips/2012-11/msg00030.html
+
+diff --git a/fs/ext3/dir.c b/fs/ext3/dir.c
+index 92490e9..bf63d7b 100644
+--- a/fs/ext3/dir.c
++++ b/fs/ext3/dir.c
+@@ -228,6 +228,7 @@ out:
+ 
+ static inline int is_32bit_api(void)
+ {
++	return 1;
+ #ifdef CONFIG_COMPAT
+ 	return is_compat_task();
+ #else
diff --git a/pkgs/os-specific/linux/kernel/patches.nix b/pkgs/os-specific/linux/kernel/patches.nix
index 4fb7563c9a1..0699f09c505 100644
--- a/pkgs/os-specific/linux/kernel/patches.nix
+++ b/pkgs/os-specific/linux/kernel/patches.nix
@@ -262,6 +262,11 @@ rec {
       patch = ./mips-fpu-sigill.patch;
     };
 
+  mips_ext3_n32 =
+    { name = "mips-ext3-n32";
+      patch = ./mips-ext3-n32.patch;
+    };
+
   guruplug_defconfig =
     { # Default configuration for the GuruPlug.  From
       # <http://www.openplug.org/plugwiki/images/c/c6/Guruplug-patchset-2.6.33.2.tar.bz2>.
diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix
index bb9359fd25c..49f0918faff 100644
--- a/pkgs/top-level/all-packages.nix
+++ b/pkgs/top-level/all-packages.nix
@@ -5871,6 +5871,7 @@ let
       ] ++ lib.optionals (platform.kernelArch == "mips")
       [ kernelPatches.mips_fpureg_emu
         kernelPatches.mips_fpu_sigill
+        kernelPatches.mips_ext3_n32
       ];
   };
 
@@ -5883,6 +5884,7 @@ let
       ] ++ lib.optionals (platform.kernelArch == "mips")
       [ kernelPatches.mips_fpureg_emu
         kernelPatches.mips_fpu_sigill
+        kernelPatches.mips_ext3_n32
       ];
   };