• Simon Horman's avatar
    ipvs: Use network byte order for sync message size · 38561437
    Simon Horman authored
    struct ip_vs_sync_mesg and ip_vs_sync_mesg_v0 are both sent across the wire
    and used internally to store IPVS synchronisation messages.
    
    Up until now the scheme used has been to convert the size field
    to network byte order before sending a message on the wire and
    convert it to host byte order when sending a message.
    
    This patch changes that scheme to always treat the field
    as being network byte order. This seems appropriate as
    the structure is sent across the wire. And by consistently
    treating the field has network byte order it is now possible
    to take advantage of sparse to flag any future miss-use.
    Acked-by: default avatarJulian Anastasov <ja@ssi.bg>
    Acked-by: default avatarHans Schillstrom <hans@schillstrom.com>
    Signed-off-by: default avatarSimon Horman <horms@verge.net.au>
    38561437
ip_vs_sync.c 51.4 KB