Giter VIP home page Giter VIP logo

Comments (9)

dlbeer avatar dlbeer commented on July 17, 2024

from dhara.

geky avatar geky commented on July 17, 2024

I think in a perfect world you wouldn't need Dhara with LittleFS. But for better or worse, LittleFS is far from perfect.

Two cases come to mind where you may want to use LittleFS+Dhara:

  1. Better wear-leveling.

    LittleFS provides dynamic wear-leveling, whereas Dhara provides static wear-leveling. There's some interesting tradeoffs here, static wear-leveling is more expensive, but guarantees consistent wear across all blocks.

  2. Possible better performance for devices with large blocks.

    LittleFS currently has performance issues with large block sizes (littlefs-project/littlefs#214). Metadata-compaction is currently O(block_size^2), and until this is fixed you may get better performance if you use Dhara to divide the blocks into smaller "blocks".

Dhara is nice in that it treats the underlying block device as one continuous log. This makes it more flexible and predictable than LittleFS, which uses the erase blocks as data structure elements.

from dhara.

TatChung68 avatar TatChung68 commented on July 17, 2024

So, we are trying to upgrade our existing Micron MT29 NAND flash from 2Gb to 4Gb on Atmel controller. The existing file system used is FAT32. But now we are in an need to change the file system to little file system(lfs). Will it be feasible to use this file system along with the file translation layer from dhara. I admire with @hchaudhary1 and @geky for thier insightful conversation.

Hello Mr.pavzz, currently I also use Micron MT29 NAND flash 2Gb and I wirte I/O interface with it which works good (It can be erase, write and read normally) but I still stuck on dhara layer. The problem is when I find journal.root, it always returns j->root = DHARA_PAGE_NONE (0xFFFFFFFF). I don't know what exactly problem is, should I tune some parameters from dhara like gc_ratio, or DHARA_META_SIZE (I use all as default values). So many thanks for helping me!!!

from dhara.

Atanukumardey avatar Atanukumardey commented on July 17, 2024

@TatChung68 did you solved the problem?

from dhara.

TatChung68 avatar TatChung68 commented on July 17, 2024

@TatChung68 did you solved the problem?

Yes, I did. I'm using FATFS + dhara but my littlefs porting on NAND flash be working well too!!! If you wanna use little fs on raw nand flash you must only write correctly 4 functions to glue between nand flash and littlefs. No trick needed!

from dhara.

Atanukumardey avatar Atanukumardey commented on July 17, 2024

@TatChung68 could you share what was the actual problem and how did you solved it? I have been stuck with the same problem "journal.root, it always returns j->root = DHARA_PAGE_NONE (0xFFFFFFFF)" or I am making some mistakes. It would be very helpful to have some insightful direction on what can I do or what should I keep in mind. I am trying to follow this flash_management work by @aloebs29 and using QSPI for communicating with the flash. I have check and confirmed the low level functions are working correctly.

from dhara.

TatChung68 avatar TatChung68 commented on July 17, 2024

from dhara.

TatChung68 avatar TatChung68 commented on July 17, 2024

I think the problem is on your write and read, copy functions directly from NAND flash!!! You can refer this link. It run properly!!!

from dhara.

Atanukumardey avatar Atanukumardey commented on July 17, 2024

I think the problem is on your write and read, copy functions directly from NAND flash!!! You can refer this link. It run properly!!!

You are right, there were some problem with our write function, and after solving it everything is working fine. Thank you, for your response.

from dhara.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.