summaryrefslogtreecommitdiffstats
path: root/firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c
diff options
context:
space:
mode:
authorMichael Sparmann <theseven@rockbox.org>2010-03-14 17:26:06 +0000
committerMichael Sparmann <theseven@rockbox.org>2010-03-14 17:26:06 +0000
commit3e9222de387df622e014d4792199e50183c7cc73 (patch)
tree7689a6a275e01bc3b4a80275937ea54c3b03712d /firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c
parent1a38f380b8fbbcc6e9ff3fc1345f0ffeaed8c59d (diff)
downloadrockbox-3e9222de387df622e014d4792199e50183c7cc73.tar.gz
rockbox-3e9222de387df622e014d4792199e50183c7cc73.zip
Nano2G: switch over to slow writes at VFL level
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25176 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c')
-rw-r--r--firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c b/firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c
index 321495a321..9a06fbed86 100644
--- a/firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c
+++ b/firmware/target/arm/s5l8700/ipodnano2g/ftl-nano2g.c
@@ -864,9 +864,7 @@ uint32_t ftl_vfl_read_fast(uint32_t vpage, void* buffer, void* sparebuffer,
//return 4;
uint32_t bank = abspage % ftl_banks;
- uint32_t block = abspage / ((*ftl_nand_type).pagesperblock * ftl_banks);
- uint32_t page = (abspage / ftl_banks) % (*ftl_nand_type).pagesperblock;
- if (bank)
+// if (bank)
{
for (i = 0; i < ftl_banks; i++)
{
@@ -882,6 +880,8 @@ uint32_t ftl_vfl_read_fast(uint32_t vpage, void* buffer, void* sparebuffer,
}
return rc;
}
+ uint32_t block = abspage / ((*ftl_nand_type).pagesperblock * ftl_banks);
+ uint32_t page = (abspage / ftl_banks) % (*ftl_nand_type).pagesperblock;
uint32_t physblock = ftl_vfl_get_physical_block(bank, block);
uint32_t physpage = physblock * (*ftl_nand_type).pagesperblock + page;
@@ -891,7 +891,7 @@ uint32_t ftl_vfl_read_fast(uint32_t vpage, void* buffer, void* sparebuffer,
for (i = 0; i < ftl_banks; i++)
{
if ((rc >> (i << 2)) & 0x2) continue;
- if ((rc >> (i << 2)) & 0xf)
+ if ((rc >> (i << 2)) & 0xd)
{
rc &= ~(0xf << (i << 2));
nand_reset(i);