From patchwork Mon Feb 10 12:33:55 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg Kroah-Hartman X-Patchwork-Id: 231798 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH, DKIM_SIGNED, DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI, SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,USER_AGENT_GIT autolearn=unavailable autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E1CC3C3F68F for ; Mon, 10 Feb 2020 13:12:13 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B17EA24676 for ; Mon, 10 Feb 2020 13:12:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581340333; bh=cuMIpdQ6frh5EBS3YjnBx5mISarMj9jt+9ERkJVG/ww=; h=From:To:Cc:Subject:Date:In-Reply-To:References:List-ID:From; b=ixZcOVRRWd+1Lw3hicnu7I6XxY7LJ+5sEZvFO5vDG3RRWl1NJC0o9GXTxV5vmQ9Ke fqa2fcxP/QXQ8amsfFWrhC5mmLeurjAXvseAHWdCJXlj8c+7BzIBmOgShCzfypJbav 2QrYjaYus4hddWYMRoumg1DCt2m3yJzFzUWlnXe0= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728206AbgBJMiy (ORCPT ); Mon, 10 Feb 2020 07:38:54 -0500 Received: from mail.kernel.org ([198.145.29.99]:35454 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729257AbgBJMiy (ORCPT ); Mon, 10 Feb 2020 07:38:54 -0500 Received: from localhost (unknown [209.37.97.194]) (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 954EB20873; Mon, 10 Feb 2020 12:38:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581338333; bh=cuMIpdQ6frh5EBS3YjnBx5mISarMj9jt+9ERkJVG/ww=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=p6FYQNbWcT83p4m6etuLEMBB7WsHMYvTmMO7cSHnz69pe3u76eEWYS3qkoPjgX8Sw dxAQTr/VOtLzz3qdbiIZgotXXDkqMyY82V3nRb8JQn4XffdRsfqco1W+0o7CaRa2dt UWhsWa3llQip6znzpIOSI/5ryleYOFnkNem3ceYM= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Vinicius Costa Gomes , "David S. Miller" Subject: [PATCH 5.4 279/309] taprio: Add missing policy validation for flags Date: Mon, 10 Feb 2020 04:33:55 -0800 Message-Id: <20200210122433.463284387@linuxfoundation.org> X-Mailer: git-send-email 2.25.0 In-Reply-To: <20200210122406.106356946@linuxfoundation.org> References: <20200210122406.106356946@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Vinicius Costa Gomes [ Upstream commit 49c684d79cfdc3032344bf6f3deeea81c4efedbf ] netlink policy validation for the 'flags' argument was missing. Fixes: 4cfd5779bd6e ("taprio: Add support for txtime-assist mode") Signed-off-by: Vinicius Costa Gomes Signed-off-by: David S. Miller Signed-off-by: Greg Kroah-Hartman --- net/sched/sch_taprio.c | 1 + 1 file changed, 1 insertion(+) --- a/net/sched/sch_taprio.c +++ b/net/sched/sch_taprio.c @@ -767,6 +767,7 @@ static const struct nla_policy taprio_po [TCA_TAPRIO_ATTR_SCHED_CLOCKID] = { .type = NLA_S32 }, [TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME] = { .type = NLA_S64 }, [TCA_TAPRIO_ATTR_SCHED_CYCLE_TIME_EXTENSION] = { .type = NLA_S64 }, + [TCA_TAPRIO_ATTR_FLAGS] = { .type = NLA_U32 }, }; static int fill_sched_entry(struct nlattr **tb, struct sched_entry *entry,