Commit Graph

4 Commits

Author SHA1 Message Date
Daniel Golle 0bdf2fcbe9 uvol: add support for detecting fitblk boot device
Auto-detect LVM2 volume on boot device used with fitblk uImage.FIT
sub-image driver.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2024-02-26 05:14:10 +00:00
Daniel Golle 74caff0d59
uvol: fixes and adapt to in-tree ucode
Don't use features which are not yet present in the version of ucode
currently shipped with OpenWrt (such as `fs.access()` or assuming raw
mode by default).
Fix syntax error in main executable.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2022-04-04 11:29:12 +01:00
Daniel Golle 22d202e3a5
uvol: unbreak build and adapt to updated ucode
* Fix build which was broken by a wrong path in the Makefile.

Adapt to ucode commit 4618807 ("main: rework CLI frontend"):
 * ucode now no longer needs the {% %} around each code file, remove
   that and safe one level of indentation.
 * ARGV now no longer includes ucode executable and script itself

Fixes: 6350c7bc6 ("uvol: replace with re-write in ucode")
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2022-03-31 22:28:27 +01:00
Daniel Golle 6350c7bc63
uvol: replace with re-write in ucode
Replace previous Shell draft-quality implementation of uvol with a
rewrite in ucode[1].
While the new code is slightly larger, it performs much better (as
we no longer fork() for parsing strings like in Shell with grep, sed
and friends).

Before:
  time uvol list -j
  [ ... ]
  real	0m 0.82s
  user	0m 0.13s
  sys	0m 0.10s

After:
  time uvol list -j
  [ ... ]
  real	0m 0.47s
  user	0m 0.05s
  sys	0m 0.05s

[1]: https://github.com/jow-/ucode
Signed-off-by: Daniel Golle <daniel@makrotopia.org>
2022-03-31 18:45:22 +01:00