summaryrefslogtreecommitdiff
path: root/util/nvmutil/lib
AgeCommit message (Collapse)Author
23 hoursutil/nvmutil: buffered urandom readsLeah Rowe
also generally tidied the code and made it more robust e.g. retries Signed-off-by: Leah Rowe <leah@libreboot.org>
25 hourstidy some commentsLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
32 hoursnvmutil: make tmpdir string much more randomLeah Rowe
more random characters i added support for higher than the standard 6 characters so i can go nuts XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX Signed-off-by: Leah Rowe <leah@libreboot.org>
32 hoursutil/nvmutil: hardened mkstempLeah Rowe
200 retries, not 100. and open with O_NOFOLLOW and O_CLOEXEC check X on mkstemp support more than 6 X in mkstemp make PATH_LEN 4096 1024 is a bit low make default mkstemp length 4096 Signed-off-by: Leah Rowe <leah@libreboot.org>
33 hoursnvmutil: rename lseek_loop to lseek_on_eintrLeah Rowe
that's what it does! Signed-off-by: Leah Rowe <leah@libreboot.org>
33 hoursnvmutil: rename x_i_close to close_on_eintrLeah Rowe
that's what it does. waits for eintr to stop firing Signed-off-by: Leah Rowe <leah@libreboot.org>
33 hoursnvmutil: don't have finite eintr waitLeah Rowe
this is technically incorrect. we don't control faults in the hardware. Signed-off-by: Leah Rowe <leah@libreboot.org>
33 hoursnvmutil: rename x_i_fsync to fsync_on_eintrLeah Rowe
that's what it does. waits on eintr. Signed-off-by: Leah Rowe <leah@libreboot.org>
33 hoursutil/rename: rename x_i_fsyncLeah Rowe
rename to fsync_on_eintr, because that's what it does Signed-off-by: Leah Rowe <leah@libreboot.org>
33 hoursnvmutil: remove memcmp/memcpy/strrchr/renameLeah Rowe
i had this idea in my head of later porting this to k&r c for fun. but screw it. compiling on everything since 1989 is enough Signed-off-by: Leah Rowe <leah@libreboot.org>
33 hoursutil/nvmutil: tidy up includesLeah Rowe
Signed-off-by: Leah Rowe <leah@libreboot.org>
36 hoursutil/nvmutil: major cleanupLeah Rowe
handle init in xstatus() it's now a singleton design also tidied up some other code also removed todo.c. bloat. will do all those anyway. too much change. i just kept touching the code until it looked good Signed-off-by: Leah Rowe <leah@libreboot.org>
2 daysnvmutil: move lib files to lib/Leah Rowe
only keep nvmutil.c in main Signed-off-by: Leah Rowe <leah@libreboot.org>