[SeaBIOS] The cbfs header for a payloads dest addr is a u64, use ntohll instead of ntohl

Peter Stuge peter at stuge.se
Wed Aug 8 13:29:57 CEST 2012


Dave Frodin wrote:
> @@ -480,7 +491,7 @@ cbfs_run_payload(struct cbfs_file *file)
>      struct cbfs_payload_segment *seg = pay->segments;
>      for (;;) {
>          void *src = (void*)pay + ntohl(seg->offset);
> -        void *dest = (void*)ntohl((u32)seg->load_addr);
> +        void *dest = (void*)ntohll((u64)seg->load_addr);

Is the (u64) cast still needed? The less casts the better.


//Peter



More information about the SeaBIOS mailing list