On 7/30/2020 1:00 AM, Kurt Kanzenbach wrote:
> In order to reduce code duplication between ptp drivers, generic helper
> functions were introduced. Use them.
> 
> Signed-off-by: Kurt Kanzenbach <[email protected]>
> ---
[snip]
> -     if (unlikely(ptp_class & PTP_CLASS_V1))
> -             msgtype = data + offset + OFF_PTP_CONTROL;
> -     else
> -             msgtype = data + offset;
> +     msgtype = ptp_get_msgtype(hdr, ptp_class);
> +     seqid   = be16_to_cpu(hdr->sequence_id);

Same comment as patch 5 would probably apply here as well, with using
ntohs():

Reviewed-by: Florian Fainelli <[email protected]>
--
Florian

Reply via email to