Received: by 10.192.165.148 with SMTP id m20csp1687838imm; Sat, 28 Apr 2018 03:22:14 -0700 (PDT) X-Google-Smtp-Source: AB8JxZpeXj/AASkx8t27j3zc5opbXLLf6/K4laonkF/maOrwdxRBRU3I02p8VRxGXIUQUFOGZBHL X-Received: by 2002:a65:5288:: with SMTP id y8-v6mr4855316pgp.69.1524910934184; Sat, 28 Apr 2018 03:22:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524910934; cv=none; d=google.com; s=arc-20160816; b=uEOW6VSMONGCl41mixlVtGvpRty0sRkpv7ksukyH+KddEEsbEUi46t2fezbrAVmL9P 1lqtLzqYRJV8f6GdDsjl5VVjEOM6hw1tSgRSJU9y4KRXOmBIKoOJUgN7XAyaM7V5vTxo sg2vz0KoHHzieBy1YekPaImmTfNjH4DuamKoRCmicZLeR60JAjpRI3zSeQs6MpgDtHR7 A80BVE7tZRTNTq5vekpHRPn7Lo0p5APJiNMWVQ3y0Fph59dthMwH1ijFBVVEfjqLUL9b 6sbOzVrDwXjeLe+ygtiECqB41o0oMMEkBWE+SLHkuzvGDd/ZwmAIeN0hpzhSuVh18czN wYng== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature:arc-authentication-results; bh=iodWsdGgGCEGqSKY3T24/gpGAfY5KmMvs4VPUp+l34g=; b=y6gmniIohlOfz7fZGFHlYQA2pcwX1qtZu3OnkN7H57SSodRcnbMFhaoOU063Z6WNNF ljJGF3GB7dU8fLjEheZzNVPJMzHXlutBKIegimJwNQgyGvjkDnPQaG4ThfBbk1OZnEe+ X+zibqQDuVDhjI2z+DoVSHzvuBpL17W/cTQmhKF6pmx/bri84y6QiXh0xYBgAlBGYK3j FO9hKlWErjqyzx/QCvgFdkH7t8jOWFpoNQrwKowipDxkLZOcYbNvvv43SYnQawutCSBZ hHYO1hwJgx1XZesBtQCz/kRb2DieW4paCP5cwUZEkeLIvvs0GZoGUFR/bBU0uwRjtSx4 vKDg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Trv7iXNI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id u21si3247371pfl.143.2018.04.28.03.21.59; Sat, 28 Apr 2018 03:22:14 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Trv7iXNI; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1759856AbeD1KUw (ORCPT + 99 others); Sat, 28 Apr 2018 06:20:52 -0400 Received: from mail-wr0-f174.google.com ([209.85.128.174]:40625 "EHLO mail-wr0-f174.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1759752AbeD1KUu (ORCPT ); Sat, 28 Apr 2018 06:20:50 -0400 Received: by mail-wr0-f174.google.com with SMTP id v60-v6so3885782wrc.7; Sat, 28 Apr 2018 03:20:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=iodWsdGgGCEGqSKY3T24/gpGAfY5KmMvs4VPUp+l34g=; b=Trv7iXNIoQ5ZC4Sgcbk0gcmSLWFDLGfwyYwQfJLfZxNH6LP7QZid6WQQRqWQnupMjE YLC8w7KzcrnsLSnhCQD2XekKykOgsLezhN5dyO3LgsLDNjZGpaZyc85u6lI1c9XZ6Bkv iJBUdWTyxzsfmIcQVNeMBJbF0bEhOBXVODriohBgiPdlMDn3HFgwbtIYdkryXJc+QYtG pMHpH8h09GcOwTAqphv5e9fqVZNS8BhI9blvzuejWPIyhGSHDFQxAjvRr2Zdf7P3poob 04d8TzkfbBd2Zmc1K+PrXae0Z6m0K+yWOHMEaXe8UM4kpvkUODgdX0PaziB/uf2In/ZW yFEA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=iodWsdGgGCEGqSKY3T24/gpGAfY5KmMvs4VPUp+l34g=; b=JD6oLWqsH2qwYGtZS0IbQ9FGVUQWfnrGUr7GzFiOI5KrVwq3Z5EsofdIHu0DcOYl0N dYa8fs6PIJFa/AxVqb7nVNaHsiVvZN+FoxoSjRtBb3+gvv/CAXaapgjfEvxKKQ65WpKL Ut9/qrgimZGfaClxpOOOSu63GZF8vx1IV2ConH/z6tbuIHar4v8fnO8fuEjGxZZgjV5R DSPoovXEd05JCSRZ9MfsQV+gtRiA0+tmo7xF3kxwV9qVDWNz9q9lsuc5ztsoYe4iOY3t VDegly1IlwX8PubJN8//lk51mXEbXJDbgO02/0UF8oQXQYbeZkLI9OWgZ5Gk3m9G8cHo J8Yg== X-Gm-Message-State: ALQs6tA2g2s4eLNV6KCYjnETpOwsS0a0oSmqoNrYuO1gu2dxEJ/Dd3yV N2LU0hXJ9WhYnf0zrKvCJ7Q= X-Received: by 2002:adf:d0cb:: with SMTP id z11-v6mr3734921wrh.281.1524910849485; Sat, 28 Apr 2018 03:20:49 -0700 (PDT) Received: from AHABDELS-M-M2VD (wifi-guest-target.gssi.infn.it. [192.135.27.147]) by smtp.gmail.com with ESMTPSA id n23-v6sm3346548wra.39.2018.04.28.03.20.48 (version=TLS1 cipher=AES128-SHA bits=128/128); Sat, 28 Apr 2018 03:20:48 -0700 (PDT) Date: Sat, 28 Apr 2018 12:20:47 +0200 From: Ahmed Abdelsalam To: David Miller Cc: dav.lebrun@gmail.com, netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [net-next] ipv6: sr: Extract the right key values for "seg6_make_flowlabel" Message-Id: <20180428122047.ede46582a46d87139e09eea1@gmail.com> In-Reply-To: <20180427.135907.1528151032821602074.davem@davemloft.net> References: <1524751871-1353-1-git-send-email-amsalam20@gmail.com> <20180427.135907.1528151032821602074.davem@davemloft.net> X-Mailer: Sylpheed 3.4.1 (GTK+ 2.24.21; x86_64-apple-darwin10.8.0) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 27 Apr 2018 13:59:07 -0400 (EDT) David Miller wrote: > From: Ahmed Abdelsalam > Date: Thu, 26 Apr 2018 16:11:11 +0200 > > > @@ -119,6 +119,9 @@ int seg6_do_srh_encap(struct sk_buff *skb, struct ipv6_sr_hdr *osrh, int proto) > > int hdrlen, tot_len, err; > > __be32 flowlabel; > > > > + inner_hdr = ipv6_hdr(skb); > > You have to make this assignment after, not before, the skb_cow_header() > call. Otherwise this point can be pointing to freed up memory. Ok! I fixed and sent you a v2 of the patch. -- Ahmed Abdelsalam