qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCHv2 2/5] net: introduce net_crc32_le() function


From: Eric Blake
Subject: Re: [Qemu-devel] [PATCHv2 2/5] net: introduce net_crc32_le() function
Date: Tue, 5 Dec 2017 08:31:50 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.4.0

On 12/05/2017 02:17 AM, Mark Cave-Ayland wrote:
> This provides a standard ethernet CRC32 little-endian implementation.
> 
> Signed-off-by: Mark Cave-Ayland <address@hidden>
> ---
>  include/net/net.h |  2 ++
>  net/net.c         | 22 ++++++++++++++++++++++
>  2 files changed, 24 insertions(+)

Reviewed-by: Eric Blake <address@hidden>

> +            if (carry) {
> +                crc = crc ^ POLYNOMIAL_LE;
> +            }

Worth writing as 'crc ^= POLYNOMIAL_LE;'?

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]