]> www.infradead.org Git - mtd-utils.git/commitdiff
Change multicast protocol to allow for a resending flag
authorDavid Woodhouse <dwmw2@infradead.org>
Thu, 9 Aug 2007 13:44:16 +0000 (21:44 +0800)
committerDavid Woodhouse <dwmw2@infradead.org>
Thu, 9 Aug 2007 13:44:16 +0000 (21:44 +0800)
Signed-off-by: David Woodhouse <dwmw2@infradead.org>
mcast_image.h
serve_image.c

index e2048b6391eca0d0245506ddaf8254080954d5a2..96aa75208c59a20019263db7daf7b824b6faae1d 100644 (file)
@@ -3,6 +3,7 @@
 #define PKT_SIZE 1400
 
 struct image_pkt_hdr {
+       uint32_t resend;
        uint32_t totcrc;
        uint32_t nr_blocks;
        uint32_t blocksize;
index b016d633f783ec5e79dfccf8a716349079449fff..b1875b1dec3e6a5489b47ebef0026b735940f578 100644 (file)
@@ -111,6 +111,7 @@ int main(int argc, char **argv)
 
        nr_blocks = st.st_size / erasesize;
 
+       pktbuf.hdr.resend = 0;
        pktbuf.hdr.totcrc = htonl(crc32(-1, image, st.st_size));
        pktbuf.hdr.nr_blocks = htonl(nr_blocks);
        pktbuf.hdr.blocksize = htonl(erasesize);