[prev in list] [next in list] [prev in thread] [next in thread] 

List:       busybox
Subject:    Suggestion: use fallocate() on Linux to achieve "almost in-place" file extraction.
From:       Markus Gothe <nietzsche () lysator ! liu ! se>
Date:       2018-06-12 18:36:23
Message-ID: t0d5o2s7u3gjhcm17ambd7oc.1528828583205 () lysator ! liu ! se
[Download RAW message or body]

[Attachment #2 (text/html)]

<html><head><meta http-equiv="Content-Security-Policy" content="script-src 'self'; \
img-src * cid: data:;"></head><body contenteditable="false"><div \
id="response_container_BBPPID" style="outline:none;" dir="auto" \
contenteditable="false"> <div name="BB10" id="BB10_response_div_BBPPID" dir="auto" \
style="width:100%;"> RAM is rare and expensive in the embedded world. So for being \
able to handle a firmware format based on tar I did some trickery with tar.c and and \
finally in copyfd.c to punch holes in the tar file and freeing up memory from a tmpfs \
partition while extracting the files.</div><div name="BB10" \
id="BB10_response_div_BBPPID" dir="auto" style="width:100%;"><br></div><div \
name="BB10" id="BB10_response_div_BBPPID" dir="auto" style="width:100%;">Having a \
fallocate(src_fd, ..., total, rd) in copyfd.c just above the write and handle it via \
a command switch does actually works very well. However the command switch need to \
turn off sendfile().</div><div name="BB10" id="BB10_response_div_BBPPID" dir="auto" \
style="width:100%;"><br></div><div name="BB10" id="BB10_response_div_BBPPID" \
dir="auto" style="width:100%;">If there is interest I could make a much cleaner \
variant for submission later on.</div><div name="BB10" id="BB10_response_div_BBPPID" \
dir="auto" style="width:100%;"><br></div><div name="BB10" \
id="BB10_response_div_BBPPID" dir="auto" style="width:100%;">I think there are many \
more people beside me out there that find this really useful.</div><div name="BB10" \
id="BB10_response_div_BBPPID" dir="auto" style="width:100%;"><br></div><div \
name="BB10" id="BB10_response_div_BBPPID" dir="auto" style="width:100%;">//M</div>    \
<div name="BB10" id="response_div_spacer_BBPPID" dir="auto" style="width:100%;"> <br \
style="display:initial"></div>                            <div \
id="blackberry_signature_BBPPID" name="BB10" dir="auto">     <div \
id="_signaturePlaceholder_BBPPID" name="BB10" dir="auto">Sent from my BlackBerry — \
the most secure mobile device</div> </div></div></body></html>



_______________________________________________
busybox mailing list
busybox@busybox.net
http://lists.busybox.net/mailman/listinfo/busybox


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic