Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp3767796pxt; Tue, 10 Aug 2021 10:51:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzhafNbRQ5sS8nTcrlVT2tds/eHTEeIbcDMCJ4is/TEFaP88kPDychiYCDYQ4ul3cKDuqca X-Received: by 2002:a05:6402:328:: with SMTP id q8mr962121edw.84.1628617910945; Tue, 10 Aug 2021 10:51:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628617910; cv=none; d=google.com; s=arc-20160816; b=0n/4bkQrBk/02/zAw9vXmQ/4xKNYlB0AeHGGr8Lu6Lcok+6894FO9+r/eIhfFnY3eQ q1nL0Lk82/1rJOorQB/GZCYA7NaPLD4QzvrUFx+nveRP/uO+qmuT0p3BNLE/NjVR8IKu jDkEgO6Icqf1mQmacfMIuf+boeEAu1Te95PsXyrg4pql/P3RxjgffJL2hEzHyDAOe6A5 XQ+V+OO3JrYr3Rgs+J95y2P3NBX4Lr2edZumD9gmyMfZiMEdPc3DiK30XFNLJWw5CROx vh6Z8/LJfw0VSk7fFell3UjghVVwHk7rkEuHDlM3q7UI9APH3RJQqzLRfz3WG9AEW3Xc qnMQ== 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=uw+ffPfhvHuYrmPqP+cgafqjIk5t2XGlM34L5whrSog=; b=EkozQmcLfTkYvDS6STXehNtc9Du4aFx6tnABFvkVEU8E21KstXA2feWy7D7fo8XJaM L0Bx+mxCWAsg/AuKwN6x+0TQlrl/yFlEGH+rPPA5m8K/+ML2nR1Ag5pMFqn5UATzg5rm bPpQX7lDmT3q6H1VznvUI2Zgzk1Fzcwdtxcl8W4gMod/ATx7zlCCIskLCLXMnHiX0toM jqKUZi5ap+/ThbBFg8ID+kKgj9DcI93y9Ae72s95YahGVosrPjRrXyZQN80KQLPWR9/N xRACOliiyy/l041SJqW86PkunBzdtnw++3CJSmYI9eU1j0AbNoSkOK99x9a16ET2G8AL Vq5Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=BnWS5VH0; 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 h6si6647779edv.408.2021.08.10.10.51.26; Tue, 10 Aug 2021 10:51:50 -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=BnWS5VH0; 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 S232424AbhHJRtJ (ORCPT + 99 others); Tue, 10 Aug 2021 13:49:09 -0400 Received: from mail.kernel.org ([198.145.29.99]:40876 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236079AbhHJRqa (ORCPT ); Tue, 10 Aug 2021 13:46:30 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id DC6C161221; Tue, 10 Aug 2021 17:40:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1628617236; bh=1dfqSY3yBFiUCNg7s/r20aPg8+xO56OobT7LNFiNBKc=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=BnWS5VH0Sffz1WVg60kcfGN+vXTxB/vw4Vr6W9ki++ZpgaTIXaYD1/Jvi8ZY1xnJi UXku0onF4yfUTsBP1wghCJ/nYfOtZWfF+3TEXeazGHimdgcotqdGHzGhyRehveIvP/ KhzrJdaR3PSMFQJE7RyXUMLtQay0XLyWrzlx3W1k= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Zheyu Ma , Dominik Brodowski Subject: [PATCH 5.10 104/135] pcmcia: i82092: fix a null pointer dereference bug Date: Tue, 10 Aug 2021 19:30:38 +0200 Message-Id: <20210810172959.299535590@linuxfoundation.org> X-Mailer: git-send-email 2.32.0 In-Reply-To: <20210810172955.660225700@linuxfoundation.org> References: <20210810172955.660225700@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: Zheyu Ma commit e39cdacf2f664b09029e7c1eb354c91a20c367af upstream. During the driver loading process, the 'dev' field was not assigned, but the 'dev' field was referenced in the subsequent 'i82092aa_set_mem_map' function. Signed-off-by: Zheyu Ma CC: [linux@dominikbrodowski.net: shorten commit message, add Cc to stable] Signed-off-by: Dominik Brodowski Signed-off-by: Greg Kroah-Hartman --- drivers/pcmcia/i82092.c | 1 + 1 file changed, 1 insertion(+) --- a/drivers/pcmcia/i82092.c +++ b/drivers/pcmcia/i82092.c @@ -112,6 +112,7 @@ static int i82092aa_pci_probe(struct pci for (i = 0; i < socket_count; i++) { sockets[i].card_state = 1; /* 1 = present but empty */ sockets[i].io_base = pci_resource_start(dev, 0); + sockets[i].dev = dev; sockets[i].socket.features |= SS_CAP_PCCARD; sockets[i].socket.map_size = 0x1000; sockets[i].socket.irq_mask = 0;