Closed DaPa closed 11 years ago
Instead it has mtdblock0. I made a quick patch in SysUtils.java and now I can change noop, deadline or cfg:
@@ -46,5 +46,6 @@ private final static String scaling_stats_time_in_state = cpufreq_sys_dir + "stats/time_in_state"; - private final static String ioscheduler = "/sys/block/mmcblk0/queue/scheduler"; + private final static String ioscheduler1 = "/sys/block/mmcblk0/queue/scheduler"; + private final static String ioscheduler2 = "/sys/block/mtdblock0/queue/scheduler"; private final static String RE_FAKE_BLKDEV = "(loop|zram|dm-)[0-9]+"; @@ -235,4 +236,8 @@ public static String[] getAvailableIOSchedulers() { String[] schedulers = null; + String ioscheduler = ioscheduler1; + if (!new File(ioscheduler1).exists()) { + ioscheduler = ioscheduler2; + } String[] aux = readStringArray(ioscheduler); if (aux != null) { @@ -294,4 +299,8 @@ public static String getIOScheduler() { String scheduler = null; + String ioscheduler = ioscheduler1; + if (!new File(ioscheduler1).exists()) { + ioscheduler = ioscheduler2; + } String[] schedulers = readStringArray(ioscheduler); if (schedulers != null) {
Btw, thank you for this open source code!
Thank you for this patch as well! :)
Instead it has mtdblock0. I made a quick patch in SysUtils.java and now I can change noop, deadline or cfg:
Btw, thank you for this open source code!