Skip to content

Instantly share code, notes, and snippets.

View erikcas's full-sized avatar

Erik Castricum erikcas

  • Castricum // Holland
View GitHub Profile
~ # cat proc/yaffs
YAFFS built:Apr 27 2013 14:55:22
Device 0 "cache"
start_block........... 0
end_block............. 115
total_bytes_per_chunk. 4096
use_nand_ecc.......... 1
no_tags_ecc........... 0
@erikcas
erikcas / gist:5474027
Created April 27, 2013 18:14
dmesg on flash_erase -N /dev/mtd/mtd13 0 0
<6>[ 1711.478603] =================================================================
<6>[ 1711.478639] msm_onenand_erase: addr 0x1d800000 len 0x40000
<6>[ 1711.479079]
<6>[ 1711.479084] msm_onenand_erase: sflash status 23 20 20 20
<6>[ 1711.479098] msm_onenand_erase: controller_status = 0
<6>[ 1711.479108] msm_onenand_erase: interrupt_status = 8080
<6>[ 1711.479119] msm_onenand_erase: ecc_status = 0
<6>[ 1711.479131]
<6>[ 1711.479136] msm_onenand_erase: ret 0
<6>[ 1711.479144] =================================================================
@erikcas
erikcas / gist:5474034
Created April 27, 2013 18:16
dmesg on mount -t yaffs2 /dev/block/mtdblock13 /cache
<6>[ 1861.469918]
<6>[ 1861.469923] msm_onenand_read_oob: sflash status 20 20 20 ffffffff ffffffff ffffffff ffffffffffffffff ffffffff ffffffff ffffffff 20 20 20
<6>[ 1861.469943] msm_onenand_read_oob: controller_status = 0
<6>[ 1861.469954] msm_onenand_read_oob: interrupt_status = 8080
<6>[ 1861.469964] msm_onenand_read_oob: ecc_status = 0
<6>[ 1861.469981]
<6>[ 1861.469984] msm_onenand_read_oob: ret 0, retlen 0 oobretlen 24
<6>[ 1861.469996] =================================================================
<6>[ 1861.470014] =================================================================
<6>[ 1861.470034] msm_onenand_read_oob: from 0x1dbc0000 mode 1
@erikcas
erikcas / gist:5474038
Created April 27, 2013 18:17
drivers/mtd/devices/msm_nand.c
/*
* Copyright (C) 2007 Google, Inc.
* Copyright (c) 2008-2011, Code Aurora Forum. All rights reserved.
*
* This software is licensed under the terms of the GNU General Public
* License version 2, as published by the Free Software Foundation, and
* may be copied, distributed, and modified under those terms.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
@erikcas
erikcas / gist:5474046
Created April 27, 2013 18:19
drivers/mtd/mtdpart.c
/*
* Simple MTD partitioning layer
*
* Copyright © 2000 Nicolas Pitre <nico@fluxnic.net>
* Copyright © 2002 Thomas Gleixner <gleixner@linutronix.de>
* Copyright © 2000-2010 David Woodhouse <dwmw2@infradead.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
@erikcas
erikcas / gist:5474056
Created April 27, 2013 18:22
dmesg touch cache/test
<6>[ 1861.546209] msm_onenand_read_oob: from 0x1f4c0000 mode 2
<6>[ 1861.546216] datbuf 0xd1378000 datlen 0x840
<6>[ 1861.546221] oobbuf 0x (null) ooblen 0x0
<3>[ 1861.546233] msm_onenand_read_oob: unsupported ops->len, 2112 for MTD_OOB_RAW
<3>[ 1861.546246] msm_onenand_block_isbad: Error in reading bad blk info
<7>[ 1861.546256] yaffs: block 116 is bad
<7>[ 1861.546473] yaffs: yaffs_read_super: is_checkpointed 0
<7>[ 2163.961406] yaffs: yaffs tragedy: no more erased blocks
<7>[ 2163.961469] yaffs: yaffs tragedy: no more erased blocks
<7>[ 2164.018971] yaffs: yaffs tragedy: no more erased blocks
@erikcas
erikcas / gist:5474123
Created April 27, 2013 18:37
Ouano's patch applied drivers/mtd/devices/msm_nand.c
@@ -17,7 +17,6 @@
17 17 #include <linux/kernel.h>
18 18 #include <linux/module.h>
19 19 #include <linux/mtd/mtd.h>
20 -#include <linux/mtd/nand.h>
21 20 #include <linux/mtd/partitions.h>
22 21 #include <linux/platform_device.h>
23 22 #include <linux/sched.h>
... ... @@ -62,7 +61,7 @@
62 61 #define FLASH_READ_ONFI_PARAMETERS_COMMAND 0xEC
@erikcas
erikcas / gist:5474135
Created April 27, 2013 18:41
dmesg VERBOSE 0
<6>[ 0.000000] Initializing cgroup subsys cpu
<5>[ 0.000000] Linux version 3.0.31-perf (erik@eriktopper) (gcc version 4.6.3 20120624 (prerelease) (Ubuntu/Linaro 4.6.3-8ubuntu1) ) #8 PREEMPT Sat Apr 27 20:31:25 CEST 2013
<4>[ 0.000000] CPU: ARMv6-compatible processor [4117b365] revision 5 (ARMv6TEJ), cr=00c5387d
<4>[ 0.000000] CPU: VIPT aliasing data cache, unknown instruction cache
<4>[ 0.000000] Machine: GT-S5660 Board
<6>[ 0.000000] Partition (from atag) mibib -- Offset:0 Size:6
<6>[ 0.000000] Partition (from atag) qcsbl -- Offset:6 Size:2
<6>[ 0.000000] Partition (from atag) oemsbl -- Offset:8 Size:3
<6>[ 0.000000] Partition (from atag) amss -- Offset:b Size:64
<6>[ 0.000000] Partition (from atag) efs2 -- Offset:6f Size:24
@erikcas
erikcas / gist:5474461
Created April 27, 2013 19:56
verbose 0 dmesg flash_erase -N /dev/mtd/mtd13 0 0
<6>[ 2.991466] adb_bind_config
<6>[ 2.991893] adb_release
<3>[ 2.992114] init: untracked pid 80 exited
<7>[ 2.992579] yaffs: yaffs tragedy: no more erased blocks
<7>[ 2.992623] yaffs: yaffs tragedy: no more erased blocks
<6>[ 3.002164] adb_open
<6>[ 3.002191] adb_bind_config
<7>[ 3.075453] yaffs: yaffs tragedy: no more erased blocks
<7>[ 3.075499] yaffs: yaffs tragedy: no more erased blocks
<7>[ 3.150073] yaffs: yaffs tragedy: no more erased blocks
@erikcas
erikcas / gist:5474505
Created April 27, 2013 20:09
verbose 0 dmesg flash_erase -N /dev/mtd/mtd13 0 0
<6>[ 0.000000] Initializing cgroup subsys cpu
<5>[ 0.000000] Linux version 3.0.31-perf (erik@eriktopper) (gcc version 4.6.3 20120624 (prerelease) (Ubuntu/Linaro 4.6.3-8ubuntu1) ) #4 PREEMPT Sat Apr 27 22:04:37 CEST 2013
<4>[ 0.000000] CPU: ARMv6-compatible processor [4117b365] revision 5 (ARMv6TEJ), cr=00c5387d
<4>[ 0.000000] CPU: VIPT aliasing data cache, unknown instruction cache
<4>[ 0.000000] Machine: GT-S5660 Board
<6>[ 0.000000] Partition (from atag) mibib -- Offset:0 Size:6
<6>[ 0.000000] Partition (from atag) qcsbl -- Offset:6 Size:2
<6>[ 0.000000] Partition (from atag) oemsbl -- Offset:8 Size:3
<6>[ 0.000000] Partition (from atag) amss -- Offset:b Size:64
<6>[ 0.000000] Partition (from atag) efs2 -- Offset:6f Size:24