Re: [PATCH] ipv6_skip_exthdr: use ipv6_authlen for AH hdrlen

2017-09-20 Thread Xiang Gao
Hi David, Thanks for your time and all your suggestions. I will resend a new patch soon. Xiang Gao Xiang Gao 2017-09-19 18:32 GMT-04:00 David Miller : > From: Xiang Gao > Date: Tue, 19 Sep 2017 08:59:50 -0400 > >> In ipv6_skip_exthdr, the lengh of AH header is computed manually >> as (hp->hdrl

Re: [PATCH] ipv6_skip_exthdr: use ipv6_authlen for AH hdrlen

2017-09-19 Thread Tom Herbert
On Tue, Sep 19, 2017 at 5:59 AM, Xiang Gao wrote: > In ipv6_skip_exthdr, the lengh of AH header is computed manually > as (hp->hdrlen+2)<<2. However, in include/linux/ipv6.h, a macro > named ipv6_authlen is already defined for exactly the same job. This > commit replaces the manual computation cod

Re: [PATCH] ipv6_skip_exthdr: use ipv6_authlen for AH hdrlen

2017-09-19 Thread David Miller
From: Xiang Gao Date: Tue, 19 Sep 2017 08:59:50 -0400 > In ipv6_skip_exthdr, the lengh of AH header is computed manually > as (hp->hdrlen+2)<<2. However, in include/linux/ipv6.h, a macro > named ipv6_authlen is already defined for exactly the same job. This > commit replaces the manual computatio

[PATCH] ipv6_skip_exthdr: use ipv6_authlen for AH hdrlen

2017-09-19 Thread Xiang Gao
In ipv6_skip_exthdr, the lengh of AH header is computed manually as (hp->hdrlen+2)<<2. However, in include/linux/ipv6.h, a macro named ipv6_authlen is already defined for exactly the same job. This commit replaces the manual computation code with the macro. --- net/ipv6/exthdrs_core.c | 2 +- 1 fi