Received: by 2002:a05:6a10:a0d1:0:0:0:0 with SMTP id j17csp4413827pxa; Mon, 10 Aug 2020 08:31:46 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyO6tqAU66TVfZ0WteKrHxx7O3/pNxeiGGy8NJJ2YXvbG4a+cmCxRw6JZ3T/0PM7C2zhk6O X-Received: by 2002:a05:6402:1427:: with SMTP id c7mr22282009edx.245.1597073506280; Mon, 10 Aug 2020 08:31:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1597073506; cv=none; d=google.com; s=arc-20160816; b=ffpVKqqflbSlFD1ptaRaSV4YVflEQK+VNK45NzNpr+rL7XB4tm/jQixJeFI+5Blsru AgQHAyI86VtWetktIQMkxCsw+8EEjF7BD6Ww3DXoFNEZtI7xR21sqhN5k+zJxX9w2R2l vXCatT+cru5XDNATF4hm9A/YuymAixMFxRvNeQs46B95vVVayTYcUdbs+9GozOdlxmo8 g95L4FrGM/UkQ+Ojwt1GniWuQWyiSGSxfEr6OywUzSwBmauHcusIAUJfCI8vo67a4KHk UteLqv0ucWxI7f+shVbQmGDqxAWWEpGbRX/k3Jo71xkdnw10gbsZSr/P4NmZBFWyQYry 5Fyg== 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=cJRWbAD87OlUuheRDBFhVAJfLl8gRDu/HLpWeHKsAkw=; b=fIPWyDp3oemjQD2GfkZHRZu+MVnFVZzBhn/UJZa/O/MtHbW4X+Hks30hLw9evafnjC QouTm3FaTyJ9DeuthohvLXqh1ImXj8nmm93VwW5trQ5tQ73LojPrLadLzY8wXVNgGIbZ EHxtugJ3uBQJvhAixZ/aWoGuAXTqbi2ELGBZhMfXT2tU5Ul5WuvV4sj/R+Y2++Fd8X30 gdZh+7aTQo0QvWfkIYHanzt0ala6JvBESagBJSz5ZJhuBsdgS3kDCKsWoDFe/jkqYT+5 lx38CQ8Fkx3vlRMU3n/7D/MV1AEmtUSUkkLAwOrApXTg1HgKAuA4gMuzSi7++DFtRPiO A80g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=1GEB97nb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id yk11si11002146ejb.113.2020.08.10.08.31.23; Mon, 10 Aug 2020 08:31:46 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=1GEB97nb; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729148AbgHJPa6 (ORCPT + 99 others); Mon, 10 Aug 2020 11:30:58 -0400 Received: from mail.kernel.org ([198.145.29.99]:38102 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728622AbgHJPa5 (ORCPT ); Mon, 10 Aug 2020 11:30:57 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (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 A7B4420791; Mon, 10 Aug 2020 15:30:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1597073457; bh=unHX8a/jW92snIToUjOuWFq1WAuVmtWd2MRdQGFa8oY=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1GEB97nba/qdnhQEoPNdjOy7C8hurtAd0OxT7mPTURA6uKSvebKIPreZqYor931m8 ddWR1xeWUVwFaiqx8W8DFqniV6IRd4RcA0j/H9XWXQ6mF+LiaeOYdjDYyldcIZw9V5 eTZDlhHAHuCQION008IiXD/mMfR+sLsB6JIOxVII= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Greg Kroah-Hartman , Grzegorz Siwik , Andrew Bowers , Jeff Kirsher , Jesse Brandeburg Subject: [PATCH 4.19 45/48] i40e: Wrong truncation from u16 to u8 Date: Mon, 10 Aug 2020 17:22:07 +0200 Message-Id: <20200810151806.435542438@linuxfoundation.org> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20200810151804.199494191@linuxfoundation.org> References: <20200810151804.199494191@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: Grzegorz Siwik [ Upstream commit c004804dceee9ca384d97d9857ea2e2795c2651d ] In this patch fixed wrong truncation method from u16 to u8 during validation. It was changed by changing u8 to u32 parameter in method declaration and arguments were changed to u32. Fixes: 5c3c48ac6bf56 ("i40e: implement virtual device interface") Signed-off-by: Grzegorz Siwik Tested-by: Andrew Bowers Signed-off-by: Jeff Kirsher Signed-off-by: Jesse Brandeburg Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c +++ b/drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c @@ -196,7 +196,7 @@ static inline bool i40e_vc_isvalid_queue * * check for the valid vector id **/ -static inline bool i40e_vc_isvalid_vector_id(struct i40e_vf *vf, u8 vector_id) +static inline bool i40e_vc_isvalid_vector_id(struct i40e_vf *vf, u32 vector_id) { struct i40e_pf *pf = vf->pf;