Giter Club home page Giter Club logo

Comments (3)

fhunleth avatar fhunleth commented on September 3, 2024

Yes, a check could be added. I'll take a look next time I make a pass on fwup maintenance - probably in the next couple weeks.

Here are some other possibilities for now:

  1. Firmware metadata is stored at the very beginning of the .fw file, so you only need a little data run fwup -m. This unit test is an example: https://github.com/fhunleth/fwup/blob/master/tests/055_metadata_partial_file.test. You could still stream the whole file through fwup, but on the side, you'd have code that runs after 512 bytes (or 1K since it's not like this has to be as small as possible) is received, saves those first bytes to a file and then runs fwup -m on that file.

  2. If the currently running firmware's metadata can be stored in a uboot-formated environment block. You don't need U-Boot. This is just the format, you can check it with require-uboot-variable. Here's an example: https://github.com/nerves-project/nerves_system_rpi0/blob/master/fwup.conf#L329-L330. To give a nice error message when there's a mismatch, this code was added: https://github.com/nerves-project/nerves_system_rpi0/blob/master/fwup.conf#L391-L403.

from fwup.

davidepianca98 avatar davidepianca98 commented on September 3, 2024

Thank you very much, I think solution number 1 would be good enough for me, but the optimal solution would be to use uboot require as the board runs from U-Boot. I cannot currently use it as I have redundant env on the board, so I'm writing a patch to add support for it in fwup. When it's ready and tested I will send a pull request here. And I think you can close this issue unless you think the option I proposed should be added anyway.

from fwup.

fhunleth avatar fhunleth commented on September 3, 2024

Thanks - also, thanks for looking into redundant u-boot environment support. I had been putting that off. Even if you only have the updates for https://github.com/fhunleth/fwup/blob/master/src/uboot_env.c, I'd take it to slowly push things forward.

from fwup.

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.