Message ID | 20230601082055.95103-3-aleksandr.mikhalitsyn@canonical.com |
---|---|
State | New |
Headers | show
Return-Path: <kernel-team-bounces@lists.ubuntu.com> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=<UNKNOWN>) Authentication-Results: legolas.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=gjpH9CmS; dkim-atps=neutral Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4QWzcX49syz20Wc for <incoming@patchwork.ozlabs.org>; Thu, 1 Jun 2023 18:21:31 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from <kernel-team-bounces@lists.ubuntu.com>) id 1q4dYW-0002ZA-26; Thu, 01 Jun 2023 08:21:12 +0000 Received: from smtp-relay-internal-1.internal ([10.131.114.114] helo=smtp-relay-internal-1.canonical.com) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from <aleksandr.mikhalitsyn@canonical.com>) id 1q4dYU-0002YP-M7 for kernel-team@lists.ubuntu.com; Thu, 01 Jun 2023 08:21:10 +0000 Received: from mail-ej1-f70.google.com (mail-ej1-f70.google.com [209.85.218.70]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-1.canonical.com (Postfix) with ESMTPS id 7D3A53F236 for <kernel-team@lists.ubuntu.com>; Thu, 1 Jun 2023 08:21:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1685607668; bh=eAYOkWU7QDNaePYzxYpsrUn7JbIZmwCBikm5oFhy7JU=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=gjpH9CmSNlNTPFwTJ5D/l64BEQQSIW97gZ6tQp8V8Q29Yq9+1rIoCh/QtMoq3hXg1 crDXipeiD6Wsj3WFutsHgzjm3IcVLR8gsnS2fXFUHjK4/tCw1shpeck0UPpx8dkI+U dowjxqlFV1cipWIJoiKTvroarqLsATUEEf1MunBL/m9LOC1iY3zizvXpDP6aTP2pfJ nw16iiYu0llWPMyHi95Ypgell1OXTUift1BkiZdax7e4mPcEyV5IEb0G0Wkv3SaSPt jTaVNW6FPH0y4UTF7G7o2Nh6Mx1fuaN+C9uLFhXajos19+QdIfOLoS+gTgRl/VJGz8 RewFz2Px9qSNw== Received: by mail-ej1-f70.google.com with SMTP id a640c23a62f3a-96fae2a13a5so36493066b.2 for <kernel-team@lists.ubuntu.com>; Thu, 01 Jun 2023 01:21:08 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685607666; x=1688199666; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=eAYOkWU7QDNaePYzxYpsrUn7JbIZmwCBikm5oFhy7JU=; b=kHlbhKSdmvPy9bLmhNXT6cuU4aamZ46fR7PYHsJ0+HjpB0/mLRw62MpqC58jkrsILB XO8G6mK1LvMoCgae6L7o3picTksS0rltyk4AEq30TgeeMqK+WCNCi+yfcfn5XFyWqj9d EYyw6+CLlpDjsQkqnCKu12Gk9qslF9mrjQEhlgo9AmOMx8+99Py10GMbeFJ9aW5Engwl sPmNAuQklBDSspQjsLOn+R9TRk9ADantzb8mRY3e1UzCaZvfmLzutUULwLm+ennpAqs9 Q8aUOolq4JK+4UQcaVB0qi4wvGrXYPoHZjT3gmSUz3y5qa7yq4Gk4Pv5u9kNTnzVrmgX 67kA== X-Gm-Message-State: AC+VfDzsQsa52GHB+B1F7RQqbhiEJno4faohVhBRlZQczboT7T1r7HJ/ lA3A1uhmLAPnOBQYpMddGDGlAdKqwM+nB+/mkJCre7UQgBMwZuKofcB4wcSAbcHfwDBUxRFcnV6 MJDMu+GAx4gMGlPy5ui3K3/HtGQ4+lrJtRtr5OmbQNiyFIDdaDA== X-Received: by 2002:a17:907:9341:b0:973:ea73:b883 with SMTP id bv1-20020a170907934100b00973ea73b883mr7025045ejc.66.1685607665836; Thu, 01 Jun 2023 01:21:05 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4Wg+xMjmLOnNCWW1HHF6dHoHzPizSLhD7cECoP7TiZnOSsuxhXRIdMvVK4mT4O5k1Hgf4xIA== X-Received: by 2002:a17:907:9341:b0:973:ea73:b883 with SMTP id bv1-20020a170907934100b00973ea73b883mr7025034ejc.66.1685607665516; Thu, 01 Jun 2023 01:21:05 -0700 (PDT) Received: from amikhalitsyn.local (dslb-002-205-068-085.002.205.pools.vodafone-ip.de. [2.205.68.85]) by smtp.gmail.com with ESMTPSA id f13-20020a170906560d00b009603d34cfecsm10154353ejq.164.2023.06.01.01.21.04 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Jun 2023 01:21:05 -0700 (PDT) From: Alexander Mikhalitsyn <aleksandr.mikhalitsyn@canonical.com> To: kernel-team@lists.ubuntu.com Subject: [PATCH v2 2/2] pktcdvd: check for NULL returna fter calling bio_split_to_limits() Date: Thu, 1 Jun 2023 10:20:55 +0200 Message-Id: <20230601082055.95103-3-aleksandr.mikhalitsyn@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230601082055.95103-1-aleksandr.mikhalitsyn@canonical.com> References: <20230601082055.95103-1-aleksandr.mikhalitsyn@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions <kernel-team.lists.ubuntu.com> List-Unsubscribe: <https://lists.ubuntu.com/mailman/options/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=unsubscribe> List-Archive: <https://lists.ubuntu.com/archives/kernel-team> List-Post: <mailto:kernel-team@lists.ubuntu.com> List-Help: <mailto:kernel-team-request@lists.ubuntu.com?subject=help> List-Subscribe: <https://lists.ubuntu.com/mailman/listinfo/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=subscribe> Cc: kamal.mostafa@canonical.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" <kernel-team-bounces@lists.ubuntu.com> |
Series |
fix bio_split_to_limits() NULL pointer dereference
|
expand
|
diff --git a/drivers/block/pktcdvd.c b/drivers/block/pktcdvd.c index 789093375344..1988bb05c0c7 100644 --- a/drivers/block/pktcdvd.c +++ b/drivers/block/pktcdvd.c @@ -2400,6 +2400,8 @@ static void pkt_submit_bio(struct bio *bio) struct bio *split; blk_queue_split(&bio); + if (!bio) + return; pkt_dbg(2, pd, "start = %6llx stop = %6llx\n", (unsigned long long)bio->bi_iter.bi_sector,