diff --git a/devices/gl-ar750/default.nix b/devices/gl-ar750/default.nix
index 77dbaa0..0d4b762 100644
--- a/devices/gl-ar750/default.nix
+++ b/devices/gl-ar750/default.nix
@@ -87,6 +87,7 @@
         flash = {
           address = "0x9F060000";
           size ="0xfa0000";
+          eraseBlockSize = "65536";
         };
         rootDevice = "1f05";
         dts = {
@@ -163,12 +164,15 @@
           AR8216_PHY = "y";         # eth1 is behind a switch
 
           MTD_SPI_NOR = "y";
+          MTD_SPI_NOR_USE_4K_SECTORS = "n";  # jffs2 needs min 8k erase block
+
           SPI_ATH79 = "y";      # these are copied from OpenWrt.
           SPI_MASTER= "y";      # At least one of them is necessary
           SPI_MEM= "y";
           SPI_AR934X= "y";
           SPI_BITBANG= "y";
           SPI_GPIO= "y";
+
           GPIO_ATH79 = "y";
           GPIOLIB = "y";
           EXPERT="y";
diff --git a/modules/hardware.nix b/modules/hardware.nix
index faa70a9..d985261 100644
--- a/modules/hardware.nix
+++ b/modules/hardware.nix
@@ -24,6 +24,7 @@ in {
         # for wireless devices, etc
         address = mkOption { type = types.str; };
         size = mkOption { type = types.str; };
+        eraseBlockSize = mkOption { type = types.str; };
       };
       loadAddress = mkOption { default = null; };
       entryPoint = mkOption { };
diff --git a/modules/jffs2.nix b/modules/jffs2.nix
index deca6fd..7ceaff6 100644
--- a/modules/jffs2.nix
+++ b/modules/jffs2.nix
@@ -33,7 +33,7 @@ in
            }}
           cp $pkgClosure/registration nix-path-registration
           grafts=$(sed < $pkgClosure/store-paths 's/^\(.*\)$/--graft \1:\1/g')
-          mkfs.jffs2 ${endian} --pad --root $TMPDIR/empty --output $out  $grafts
+          mkfs.jffs2 ${endian} -e ${config.hardware.flash.eraseBlockSize} --pad --root $TMPDIR/empty --output $out  $grafts
         '';
       jffs2boot =
         let o = config.outputs; in