Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp2250741ybd; Mon, 24 Jun 2019 03:18:48 -0700 (PDT) X-Google-Smtp-Source: APXvYqzdwNpdXk4IotOeoxQ0PBT0Xef8AmvR+vKyozeJGgGexMv+T7gZvnodvYsE/DxcpKvd1ZsZ X-Received: by 2002:a17:902:748c:: with SMTP id h12mr33722170pll.208.1561371528214; Mon, 24 Jun 2019 03:18:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561371528; cv=none; d=google.com; s=arc-20160816; b=vF5dpkYSwr5GueHRKZIyXHDkd3IUB4P39hx/nN99ae8SZ2SeUPjsl+ysuV6eV05Exb rUX93n9MQVTZdYByO/DZh3FL3Rmx5EizaR9LR12bx/VAKct4QW35SXIJWvPF29ynwP9k lNqiOlg7jnMYNACDlfa2f9p3arSnNkQnC5NHk7uETZcjpV/Un2wGVD4cytJYe+91Adbd uRYquvtBuXd1cCfnnxgvQ570tEQa3pbFrzHhtaMTm+yaKnw/6Yumx6H/XY2XKtHAl+/7 aoOHXXXK/sHJQFOW4rMdGFu2eS68koTFJRJRzyeQtYbvUxUOnNMc4llU1fLG31CDBLv2 /KBg== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=IXa9gxKQ8HfZI8yM7kaKOvHlce4uRNJX5M8fN4+YmiY=; b=v/k4vz/F6kj2Kyw3UxrVleDf/Tjv3so6PizflynXxSMh6o6oHl3w4RkSrjAYtCmpoW 0ghUSXbes7pY17a+uqchAC1cWQGf/qIJV23WjlsKkVoSEA0+iDD0n9Je0xcTlTjywzjc afFgtw+NBQAKgkPZVT/5oChVT1jtcjV2rkXJpiqH2w1hH9ZUxlKT3DQaq9Cy8Tcx9M8Z u7AhD4IbprAetUZ1PkaAFImItkapmrbeAOvKUNbwuqolarQ21wbmQO3NSxjt20xagnau /H02TiMErtGyuRnTVUXCYlP4cSLo1f4mhkgfNMnTyX52d3720iCR/ivIUPeEYES6OWtH 1w3g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=jtKCFtaq; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id a2si9231742pgt.217.2019.06.24.03.18.32; Mon, 24 Jun 2019 03:18:48 -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=@kernel.org header.s=default header.b=jtKCFtaq; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730888AbfFXKRK (ORCPT + 99 others); Mon, 24 Jun 2019 06:17:10 -0400 Received: from mail.kernel.org ([198.145.29.99]:54522 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730840AbfFXKQ5 (ORCPT ); Mon, 24 Jun 2019 06:16:57 -0400 Received: from localhost (f4.8f.5177.ip4.static.sl-reverse.com [119.81.143.244]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 3A4E120645; Mon, 24 Jun 2019 10:16:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1561371416; bh=sLCeOjCrzZWFX3mgX9qYm4q7YOx5AuqolYxd8ZsyC4k=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=jtKCFtaqhzMWShFyMYmC8lodbPYW3S4qKPJ0IxLyzyKlnZo8Jye7If0E5q/gRHjLs U9dsLE8yFERA3XOaaBaCTuld6ZeBHlglveTD6rXTO+7IEVVS+mXcjvKae00zIqnzMy EvJTWdK6MyZYo2BoZOZrRLspuTr8CAxTi8sdHyf0= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, syzbot+a90604060cb40f5bdd16@syzkaller.appspotmail.com, Willem de Bruijn , Marc Kleine-Budde Subject: [PATCH 5.1 095/121] can: purge socket error queue on sock destruct Date: Mon, 24 Jun 2019 17:57:07 +0800 Message-Id: <20190624092325.617532146@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190624092320.652599624@linuxfoundation.org> References: <20190624092320.652599624@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Willem de Bruijn commit fd704bd5ee749d560e86c4f1fd2ef486d8abf7cf upstream. CAN supports software tx timestamps as of the below commit. Purge any queued timestamp packets on socket destroy. Fixes: 51f31cabe3ce ("ip: support for TX timestamps on UDP and RAW sockets") Reported-by: syzbot+a90604060cb40f5bdd16@syzkaller.appspotmail.com Signed-off-by: Willem de Bruijn Cc: linux-stable Signed-off-by: Marc Kleine-Budde Signed-off-by: Greg Kroah-Hartman --- net/can/af_can.c | 1 + 1 file changed, 1 insertion(+) --- a/net/can/af_can.c +++ b/net/can/af_can.c @@ -105,6 +105,7 @@ EXPORT_SYMBOL(can_ioctl); static void can_sock_destruct(struct sock *sk) { skb_queue_purge(&sk->sk_receive_queue); + skb_queue_purge(&sk->sk_error_queue); } static const struct can_proto *can_get_proto(int protocol)