[dpdk-dev] [PATCH 05/11] examples/ipsec-secgw: Fixed transport

Sergio Gonzalez Monroy sergio.gonzalez.monroy at intel.com
Mon Oct 16 11:30:27 CEST 2017


On 14/10/2017 14:27, aviadye at dev.mellanox.co.il wrote:
> From: Aviad Yehezkel <aviadye at mellanox.com>
>
> Seems like transport was broken for a long time

Commit message needs to be improved. Just mentioned what is wrong or how 
do you fix it.
Given that it is a fix, you should start the commit title with "fix ..." 
then also add the 'fixes' line with commit that added the bug.
That way you can easily see since when it was introduced.

Thanks,
Sergio

> Signed-off-by: Aviad Yehezkel <aviadye at mellanox.com>
> ---
>   examples/ipsec-secgw/esp.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/examples/ipsec-secgw/esp.c b/examples/ipsec-secgw/esp.c
> index 70bb81f..56ad7a0 100644
> --- a/examples/ipsec-secgw/esp.c
> +++ b/examples/ipsec-secgw/esp.c
> @@ -306,8 +306,8 @@ esp_outbound(struct rte_mbuf *m, struct ipsec_sa *sa,
>   				sizeof(struct esp_hdr) + sa->iv_len);
>   		memmove(new_ip, ip4, ip_hdr_len);
>   		esp = (struct esp_hdr *)(new_ip + ip_hdr_len);
> +		ip4 = (struct ip *)new_ip;
>   		if (likely(ip4->ip_v == IPVERSION)) {
> -			ip4 = (struct ip *)new_ip;
>   			ip4->ip_p = IPPROTO_ESP;
>   			ip4->ip_len = htons(rte_pktmbuf_data_len(m));
>   		} else {




More information about the dev mailing list