Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2668146pxj; Mon, 31 May 2021 07:50:32 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw4Ul47/fOXS2jXxNRyqXaLWfRL6krH/i4NYd9WdFNDI3Xl2u6QSr6iUUXV+YnspaPFUvDL X-Received: by 2002:a05:6e02:1c42:: with SMTP id d2mr17458187ilg.286.1622472632067; Mon, 31 May 2021 07:50:32 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622472632; cv=none; d=google.com; s=arc-20160816; b=sFKihYr6R4oXSPzzZwcy1vr+LCbGGwAoMBXWfDco+1nXX/J1lSi4pF8uVphl7eMHmo tqtFZCzTYLAscX1vPRObUst5Vd6Gi7hZtxMccVS5VrZ9mGreyCyrwJKR5IghThoH6DeL WNqkzNcPUOJJsuMjFw49kHwgG6EWiPZlNHzNVsx4e0wXU9vNbvRuqwB1YRwgpzR4edqx Q7fU6afvZZSaVCphw40PEQrL2dyE6evXiw0ufMgKjW75unRnGVur5v+DXoxE2wdJpoGP Uq54yKelmsz9l5tAzKLYf/RouFyuxq3ktaLMbfgdQMS5ZxnE0lehm7u9HfmG1Y5e9R+F Cy/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=QY9sNtZ6tOmG4EJL8be4yn3+TDrPe/eCW+gGKdbruqo=; b=Lem17RVG8sRurrnsVGs76Xtq1nqIXh9iyIuy6a0Ydtnl1FV3hK0aS1CtPK8uvD7wW7 lh5wXmex8LqP3CF37YAdAJw52Lh7hOv/4gDsxpnN6OJEDUs7/MxBvSptewg3lZ6jT6AS EFtispULRAcxhDNtkhnfF0i3fMW7QttyAMqb5nfn5ClBwxco1ueX0BomqeVuboHKLE7i DGVeYq3Dxo+NkVs0QmIj9VcA4jxdrvN0uHy9L/IYyIoekWzHEhOKTsikgLhWiWLUoFvm N9ckK9YutkLjWzPhTCIPSwtkBArnyqd9u8K9I8zRVWvnbBd7V5/0ghc+dDxPSiuYJTVx uTlA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=Psap7DKq; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l3si16232965jad.55.2021.05.31.07.50.18; Mon, 31 May 2021 07:50:32 -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=@linuxfoundation.org header.s=korg header.b=Psap7DKq; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233325AbhEaOvS (ORCPT + 99 others); Mon, 31 May 2021 10:51:18 -0400 Received: from mail.kernel.org ([198.145.29.99]:37418 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232887AbhEaOCA (ORCPT ); Mon, 31 May 2021 10:02:00 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 9A59561942; Mon, 31 May 2021 13:37:10 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1622468230; bh=IoHREpO8T5t2jYw8sNsJ9hikV2tRTqlyPUYv5iO8hbQ=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=Psap7DKq9hVYIUbXmJg35nU3lVOvgajoprmDNxadXXbD7OLxFUH7CKpU/896I6TH9 +0qlvE6UDptSsBn4LPbp/+hnmB/8EpCH8GqG8fenmPkkrOgqZGcFct7qXicmEtwauK CZeXT09XwtVJG5a5GJqz463JIauoEGL33PaKW2Mg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kangjie Lu , "David S. Miller" , Sasha Levin Subject: [PATCH 5.10 166/252] Revert "net: liquidio: fix a NULL pointer dereference" Date: Mon, 31 May 2021 15:13:51 +0200 Message-Id: <20210531130703.647903665@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210531130657.971257589@linuxfoundation.org> References: <20210531130657.971257589@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Greg Kroah-Hartman [ Upstream commit 4fd798a5a89114c1892574c50f2aebd49bc5b4f5 ] This reverts commit fe543b2f174f34a7a751aa08b334fe6b105c4569. Because of recent interactions with developers from @umn.edu, all commits from them have been recently re-reviewed to ensure if they were correct or not. Upon review, this commit was found to be incorrect for the reasons below, so it must be reverted. It will be fixed up "correctly" in a later kernel change. While the original commit does keep the immediate "NULL dereference" from happening, it does not properly propagate the error back to the callers, AND it does not fix this same identical issue in the drivers/net/ethernet/cavium/liquidio/lio_vf_main.c for some reason. Cc: Kangjie Lu Cc: David S. Miller Link: https://lore.kernel.org/r/20210503115736.2104747-65-gregkh@linuxfoundation.org Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/net/ethernet/cavium/liquidio/lio_main.c | 5 ----- 1 file changed, 5 deletions(-) diff --git a/drivers/net/ethernet/cavium/liquidio/lio_main.c b/drivers/net/ethernet/cavium/liquidio/lio_main.c index 7d00d3a8ded4..e4c220f30040 100644 --- a/drivers/net/ethernet/cavium/liquidio/lio_main.c +++ b/drivers/net/ethernet/cavium/liquidio/lio_main.c @@ -1166,11 +1166,6 @@ static void send_rx_ctrl_cmd(struct lio *lio, int start_stop) sc = (struct octeon_soft_command *) octeon_alloc_soft_command(oct, OCTNET_CMD_SIZE, 16, 0); - if (!sc) { - netif_info(lio, rx_err, lio->netdev, - "Failed to allocate octeon_soft_command\n"); - return; - } ncmd = (union octnet_cmd *)sc->virtdptr; -- 2.30.2