Received: by 2002:a05:6a10:206:0:0:0:0 with SMTP id 6csp2667541pxj; Mon, 31 May 2021 07:49:36 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwd5uYDDirA6r/xJHHGdR2wNY20KSaw/NX7hFjgG7xfK4FxF8vJ+0KxCmOOpgNAOLHt1qgR X-Received: by 2002:a17:907:3e96:: with SMTP id hs22mr21981719ejc.313.1622472575747; Mon, 31 May 2021 07:49:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1622472575; cv=none; d=google.com; s=arc-20160816; b=DA9rMJreuOdMoKsgTI4corAO3FPk39Dzrq6054OOMpgnDNsK/mhvO6F6F26q0epxpB D3WcwVCfua6HeNIbXHt6tVFXgROEbiUZ4lWhz5yon+fwILQ9c+TF0epFgLk3QCx2+Yto WiQOiXkoSqkeOS/ZuSMKJQf7c5T+QPhh223PIQC5A3IjbQrY6T7Z8Tv/GI29oR1Aefln 5EH2H9qZt6SQtONnx+pt7oqb0h126tuju2DAigQ7qiAcDGwVQrZn7DB/z8Xqfyuko6u5 ukk8cyJEi6um6a/upC0twFWHg1zFCOF3KYcIKjLbzUKWENINz1Hopv7Tk0PdrmzNEt5o 3Ahg== 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=mx9H/GZMQ3AsqAD/4suX460eGs7FDqXglRiCXOLe8XQPiYwr/AOS7UWDVwpiGmmZuv 21u4iZfQFp6V30hL7BYfUqforzk8UKZFbsLL2qWJhJoZU9zKkuOly4s3g79/68fx/h3+ ebece8OZWY9sMXOe4xhl1rbfAeVU/LecS65dAcORtpsYMiX2PA8VpZ7N4NF8XSrEQS3/ Sz/6eDcTxiy0vus18ezgyy4NLbhkhXe5o/3PHnwMpDqpKrKcg3Uv3RBaLm3A750pW+Fn DpuxFAKJajPHnJ38W2r8yo1xn/L9oHStPzVIb980m7Z3FOXbC6xvJZ8g/vdR+JoqGz6l U6vA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=GMhrN2wt; 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 t7si12171076edd.39.2021.05.31.07.49.13; Mon, 31 May 2021 07:49:35 -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=GMhrN2wt; 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 S231231AbhEaOtz (ORCPT + 99 others); Mon, 31 May 2021 10:49:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:36982 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232791AbhEaOB3 (ORCPT ); Mon, 31 May 2021 10:01:29 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 2417E6144B; Mon, 31 May 2021 13:36:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1622468214; bh=cPwcKQnQxS1/1/Xv3aws8qFtnBrWEAHlB+cKwVlNVms=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=GMhrN2wtuaXNRL8TJiYsooS3+EZRdb7jV8SMnPoJ3pMkV1sr0llvaBvNas7FLxW6F GdYZPTQYPeehpKIyrvnksWmiLa6x+fyD0z3/9tgQgoHYc52lP8sLjqxbRxKAvQ5qfB 6WUSRJrRSUD4GBycJFDHPLwkyxBS3TAs8cMhN8mk= 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.10 152/252] Revert "isdn: mISDN: Fix potential NULL pointer dereference of kzalloc" Date: Mon, 31 May 2021 15:13:37 +0200 Message-Id: <20210531130703.173576968@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 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