Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2741922pxj; Mon, 31 May 2021 09:35:05 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyW+8OCjRIPuS+avOH2OPAQF5fgD9QvvtS8JwJpwmTDE+lKyqgJKvdMYXCMIbiDXnAFTRb6 X-Received: by 2002:a5e:a704:: with SMTP id b4mr18120832iod.35.1622478905219; Mon, 31 May 2021 09:35:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622478905; cv=none; d=google.com; s=arc-20160816; b=wXISavk3M9zV+dcrcdNtMgGM/AHCbuM/RT/amMlW62r9d4s3qtTHa4LNCgD36PgIH2 wJxmzIf2dREyNv5n5A5XjbJQ+NKVzHQfphUr2Fje9Vv9q/+BJYfYRsd02WUZodxuLhTi ZsZQjkTY6bwidpBXq8u5LbhWEx7md0sAsHySHz0PPndsrU6aYa2YfgRiuhR1UylfMWWb +bL29UsQkuLwc+YUohvSfb487K41JPHQxVXRx5JvQ3+ilyX9KH7GoE4F8ON4oJwsovO9 pGM3YSpYB//G1uw8hATa8Fx2TVP/XPHdlGw9WaWRS6wgsTXLabqrerVqrMHg1agle7kQ Vozg== 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=mgTF6suaIzTvhbhpDAXzxYS09yBSt6JDyiTwVEUhtE0=; b=VKeIZCbSUz7cd6iEdtoSN/bFw7orbcrDXitG3dMeTO2thEQiTqsCSwm+NR0KXDpCOA yW0Yg+Bbv3oZFXspA0rFQHrT8y7xP9kF+qj0smkFCJRFhRrfYAE/TNn4ztqlxtF6rLRn BNP6u5Vs/DPq2iQ5ZADX+KybAJu6Pny6cWfi3Ml/QXgp9XEb4fjhINFLjf6AsIDsrEyD iC1NIJq6gDn6LHCPXFUFu6gpfQLETqzYV/4YFNz6TUy4xDnezMppifQvrIig5gXPO3J+ QMGeejWUEyrRGcFLy1HMDxt7fdzCs5I4xZFGYllwavPDBTQZyDoR6upEAw6CkxWdZW0V WM6Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=1C5lbNSR; 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 r17si12803338ilq.4.2021.05.31.09.34.52; Mon, 31 May 2021 09:35:05 -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=1C5lbNSR; 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 S233996AbhEaQeV (ORCPT + 99 others); Mon, 31 May 2021 12:34:21 -0400 Received: from mail.kernel.org ([198.145.29.99]:39884 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S233891AbhEaOrn (ORCPT ); Mon, 31 May 2021 10:47:43 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 4BD5360FF0; Mon, 31 May 2021 13:56:34 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1622469394; bh=cPwcKQnQxS1/1/Xv3aws8qFtnBrWEAHlB+cKwVlNVms=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=1C5lbNSRFBBEnoEGEGddmk5qWW7jixhjmtQhWFUYkrTlmIBSkw/tcrZRW7pGNv0sd LPeMCTEQvWpvpeeyPBtOLpPy8YgXO+XO23R5lAOwJ8/KTH7eLpQ3TCHu5iOn3fbAgj HfqAgWEB7fab/3ztcT7yOZP6zO60/LqsqZW7LdPo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Aditya Pakki , "David S. Miller" , Sasha Levin Subject: [PATCH 5.12 182/296] Revert "isdn: mISDN: Fix potential NULL pointer dereference of kzalloc" Date: Mon, 31 May 2021 15:13:57 +0200 Message-Id: <20210531130709.983479633@linuxfoundation.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20210531130703.762129381@linuxfoundation.org> References: <20210531130703.762129381@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 36a2c87f7ed9e305d05b9a5c044cc6c494771504 ] This reverts commit 38d22659803a033b1b66cd2624c33570c0dde77d. 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 it looks like the original change is correct, it is not, as none of the setup actually happens, and the error value is not propagated upwards. Cc: Aditya Pakki Cc: David S. Miller Link: https://lore.kernel.org/r/20210503115736.2104747-47-gregkh@linuxfoundation.org Signed-off-by: Greg Kroah-Hartman Signed-off-by: Sasha Levin --- drivers/isdn/hardware/mISDN/hfcsusb.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/drivers/isdn/hardware/mISDN/hfcsusb.c b/drivers/isdn/hardware/mISDN/hfcsusb.c index 70061991915a..4bb470d3963d 100644 --- a/drivers/isdn/hardware/mISDN/hfcsusb.c +++ b/drivers/isdn/hardware/mISDN/hfcsusb.c @@ -249,9 +249,6 @@ hfcsusb_ph_info(struct hfcsusb *hw) int i; phi = kzalloc(struct_size(phi, bch, dch->dev.nrbchan), GFP_ATOMIC); - if (!phi) - return; - phi->dch.ch.protocol = hw->protocol; phi->dch.ch.Flags = dch->Flags; phi->dch.state = dch->state; -- 2.30.2