{"id":2228787,"url":"http://patchwork.ozlabs.org/api/1.1/patches/2228787/?format=json","web_url":"http://patchwork.ozlabs.org/project/linux-mtd/patch/20260427114750.2480900-4-fuchsfl@gmail.com/","project":{"id":3,"url":"http://patchwork.ozlabs.org/api/1.1/projects/3/?format=json","name":"Linux MTD development","link_name":"linux-mtd","list_id":"linux-mtd.lists.infradead.org","list_email":"linux-mtd@lists.infradead.org","web_url":null,"scm_url":null,"webscm_url":null},"msgid":"<20260427114750.2480900-4-fuchsfl@gmail.com>","date":"2026-04-27T11:47:50","name":"[v2,3/3] mtd: maps: vmu-flash: Fix NULL pointer dereference in initialization","commit_ref":null,"pull_url":null,"state":"new","archived":false,"hash":"3f14ed73528bd8d74c98c0e8bc6413af8d0db27e","submitter":{"id":92066,"url":"http://patchwork.ozlabs.org/api/1.1/people/92066/?format=json","name":"Florian Fuchs","email":"fuchsfl@gmail.com"},"delegate":null,"mbox":"http://patchwork.ozlabs.org/project/linux-mtd/patch/20260427114750.2480900-4-fuchsfl@gmail.com/mbox/","series":[{"id":501632,"url":"http://patchwork.ozlabs.org/api/1.1/series/501632/?format=json","web_url":"http://patchwork.ozlabs.org/project/linux-mtd/list/?series=501632","date":"2026-04-27T11:47:47","name":"mtd: maps: vmu-flash: Fix build and runtime errors","version":2,"mbox":"http://patchwork.ozlabs.org/series/501632/mbox/"}],"comments":"http://patchwork.ozlabs.org/api/patches/2228787/comments/","check":"pending","checks":"http://patchwork.ozlabs.org/api/patches/2228787/checks/","tags":{},"headers":{"Return-Path":"\n <linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org>","X-Original-To":"incoming@patchwork.ozlabs.org","Delivered-To":"patchwork-incoming@legolas.ozlabs.org","Authentication-Results":["legolas.ozlabs.org;\n\tdkim=pass (2048-bit key;\n secure) header.d=lists.infradead.org header.i=@lists.infradead.org\n header.a=rsa-sha256 header.s=bombadil.20210309 header.b=C48RT0xw;\n\tdkim=fail reason=\"signature verification failed\" (2048-bit key;\n unprotected) header.d=gmail.com header.i=@gmail.com header.a=rsa-sha256\n header.s=20251104 header.b=MBz0Tv3a;\n\tdkim-atps=neutral","legolas.ozlabs.org;\n spf=none (no SPF record) smtp.mailfrom=lists.infradead.org\n (client-ip=2607:7c80:54:3::133; helo=bombadil.infradead.org;\n envelope-from=linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org;\n receiver=patchwork.ozlabs.org)"],"Received":["from bombadil.infradead.org (bombadil.infradead.org\n [IPv6:2607:7c80:54:3::133])\n\t(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)\n\t key-exchange x25519 server-signature ECDSA (secp384r1) server-digest SHA384)\n\t(No client certificate requested)\n\tby legolas.ozlabs.org (Postfix) with ESMTPS id 4g423B4f6wz1xvV\n\tfor <incoming@patchwork.ozlabs.org>; Mon, 27 Apr 2026 21:51:34 +1000 (AEST)","from localhost ([::1] helo=bombadil.infradead.org)\n\tby bombadil.infradead.org with esmtp (Exim 4.98.2 #2 (Red Hat Linux))\n\tid 1wHKUq-0000000GpSQ-29SD;\n\tMon, 27 Apr 2026 11:51:28 +0000","from mail-wr1-x435.google.com ([2a00:1450:4864:20::435])\n\tby bombadil.infradead.org with esmtps (Exim 4.98.2 #2 (Red Hat Linux))\n\tid 1wHKUi-0000000GpOi-480D\n\tfor linux-mtd@lists.infradead.org;\n\tMon, 27 Apr 2026 11:51:23 +0000","by mail-wr1-x435.google.com with SMTP id\n ffacd0b85a97d-43d74086e5bso9704929f8f.0\n        for <linux-mtd@lists.infradead.org>;\n Mon, 27 Apr 2026 04:51:20 -0700 (PDT)","from localhost ([2a02:810d:4a94:b300:3c87:b0bc:8c35:1ba0])\n        by smtp.gmail.com with UTF8SMTPSA id\n ffacd0b85a97d-43fe4e59f97sm87393680f8f.37.2026.04.27.04.51.18\n        (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128);\n        Mon, 27 Apr 2026 04:51:18 -0700 (PDT)"],"DKIM-Signature":["v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;\n\td=lists.infradead.org; s=bombadil.20210309; h=Sender:\n\tContent-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post:\n\tList-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:\n\tMessage-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description:\n\tResent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:\n\tList-Owner; bh=iKD8M25UtZlbJlPIf9IdQnmmTbwzrXn6kj9GL+EqOBI=; b=C48RT0xwWZafFc\n\tvQ9422pcBlvOiy/CzTyfwfWiFO0hJAztnF5faiPzk5tnZRrx8i9TyZBwNIbReRUZ522aQDuMRTDP4\n\tz4PyGzgzf9KAkOC5L7SQuoizd0JOY4F/ahD1HUIfUhflIYbjdc7ls8QNzOLFL585Ciohsy5T1AAvN\n\trRcXBvsmfnASpCY7+qoZpTBJKFQ7FfSDNAlmALm6q+0zjxOg1g2zfvNiVdu4b23B+kBXsZC4VwAnf\n\ttQ4g1eft5fI80oLU7VBan+29ciYtnjt+JkyzMjFL5XPi8TBbUblWWFYLXsVRC7xYzDYfX8klM2Jby\n\tm6satgKi6xd3VFilVAcw==;","v=1; a=rsa-sha256; c=relaxed/relaxed;\n        d=gmail.com; s=20251104; t=1777290679; x=1777895479;\n darn=lists.infradead.org;\n        h=content-transfer-encoding:mime-version:references:in-reply-to\n         :message-id:date:subject:cc:to:from:from:to:cc:subject:date\n         :message-id:reply-to;\n        bh=sK29FoURh791KB3pSonK6KWtGokZs28tGn9ydulth7M=;\n        b=MBz0Tv3aXQEVl+hRxYjkwt82i6QT1SUk4/bO+UUHGStt3Kx65P4ComjYKp9b64ueeL\n         wTgVIimegS4q5Z+H7SCW7Lrjp1qQDHnN+iu8w3gpR3viE8miZL9pJWYLYRW1HNmqP4oK\n         JIpiad96uI4K4K2ZAeCgK+JBSMIjHYcmQn48bI1T1JV420+ird93/fKQJjBk/sXufB4m\n         fwniZw/wE63nuhcNrhHbuLJzVZjd+zkRVi53I5zBeosks6ZQvGqhdV7TMlxbJ6pbof3s\n         smg62Gb2w0lA4FCjbcyt1Qje1pHHXH/zeNnjHTdzejo1JFw5QzjrsRptREwcJEGRFIeY\n         X0vQ=="],"X-Google-DKIM-Signature":"v=1; a=rsa-sha256; c=relaxed/relaxed;\n        d=1e100.net; s=20251104; t=1777290679; x=1777895479;\n        h=content-transfer-encoding:mime-version:references:in-reply-to\n         :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from\n         :to:cc:subject:date:message-id:reply-to;\n        bh=sK29FoURh791KB3pSonK6KWtGokZs28tGn9ydulth7M=;\n        b=OYJXhq2XSdm2ogFcrFZ2HqoTCXRhd1x+3zOLMADvI7hbdvNz5o5AC7ulik8G81JoQC\n         vAutnWH349czuSnyVR+UT1jDeWjse851JTX/xjIW0KsRStE70hw/TYBPR0Lik8q8uDQr\n         nOrJPKShg+l9LfhJqYpiMD3/OmGERJQlH9BIG2BeSwf5P0ug8b+VcvWYxJJkuvWlgPbA\n         jgGMfLKSQU9HXwIDCS1X+Nrr42sttEANBpTJGbvibiDyDLlcB+sHx8oZf+k6hbuFOnLd\n         YrZcoly0a7/ewjovvjSWz5SHTgs/vOgotnRNsg40Geujj4uxA0XCiRlb0QJhvnQCE2eG\n         2Sog==","X-Forwarded-Encrypted":"i=1;\n AFNElJ96ZXVzw8s+8Qaf/hXfZCsbyUajTLefeVT4wCBt3qW/z9gIz7rABquNiGQhpzHJzXQwXA3V8RB+/bs=@lists.infradead.org","X-Gm-Message-State":"AOJu0Yxl/Vo5OxaJr9Am0RcFGmXSzPd3HDkRByYHrRlBZy1q/IfPJqF7\n\txu7lpAx3kIQ/U97Sc6EPjyvPkFgFo7G5ZcfJ/8hgLZ5VwAQ5adUq8sQ=","X-Gm-Gg":"AeBDiet8WjmqoYsb35mqhfgNO+b9B6lyOi+vxmQoQrCuK9sfVCrdTTwU01MJpTQTcmJ\n\tC3McXWwdeY/IM33oRPbzm4T3zLdznvvOv0vSz4JiExAuRKsJcEUnzGtqUu8gmyjZKNQihyIMCP5\n\tCegAiBOeTVTACJzpe/VCme1Z1qCq4heFvEngvYqXMRKc89b7Q6lzTPW5zcCO59DEc5nzl9CDsgk\n\tFmy+doi78AQ4/MxpiffRf/lFxWu5b3bkR/ha31h8VYkntSXJJL8JsUU+HED1xKKnObCyKe5ow6u\n\tLKKCacOyu1kCP6aVRePaHFRf/u3xvY3jFOrJ7qmkYU4RNqctUgLViJ5oSWDfml7DBre8TR5LGfB\n\thZL+5gi103zcgkYbOqGbj2jwFYXp3KftHoLM5V/UpmT/TshdcXzQzpP9Y+mtNDnbgFfw16VFZMr\n\tUAvT/iCpJz7kPLK0XdvQXBGf1N6jCsRigzAEPYwxdvIDm423DI2nQgG3mZhq8TsX3sJEy/YPGYT\n\tTj9K3zi92hyg+ZbP0o=","X-Received":"by 2002:a05:6000:2303:b0:43e:b020:f8a2 with SMTP id\n ffacd0b85a97d-43fe3dd5208mr63553484f8f.19.1777290678780;\n        Mon, 27 Apr 2026 04:51:18 -0700 (PDT)","From":"Florian Fuchs <fuchsfl@gmail.com>","To":"Miquel Raynal <miquel.raynal@bootlin.com>,\n\tRichard Weinberger <richard@nod.at>,\n\tVignesh Raghavendra <vigneshr@ti.com>,\n\tlinux-mtd@lists.infradead.org","Cc":"linux-sh@vger.kernel.org,\n\tlinux-kernel@vger.kernel.org,\n\tRich Felker <dalias@libc.org>,\n\tJohn Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>,\n\tFlorian Fuchs <fuchsfl@gmail.com>,\n\tArtur Rojek <contact@artur-rojek.eu>","Subject":"[PATCH v2 3/3] mtd: maps: vmu-flash: Fix NULL pointer dereference in\n initialization","Date":"Mon, 27 Apr 2026 13:47:50 +0200","Message-ID":"<20260427114750.2480900-4-fuchsfl@gmail.com>","X-Mailer":"git-send-email 2.43.0","In-Reply-To":"<20260427114750.2480900-1-fuchsfl@gmail.com>","References":"<20260427114750.2480900-1-fuchsfl@gmail.com>","MIME-Version":"1.0","X-CRM114-Version":"20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 ","X-CRM114-CacheID":"sfid-20260427_045121_075534_664683AB ","X-CRM114-Status":"GOOD (  10.31  )","X-Spam-Score":"-2.1 (--)","X-Spam-Report":"Spam detection software,\n running on the system \"bombadil.infradead.org\",\n has NOT identified this incoming email as spam.  The original\n message has been attached to this so you can view it or label\n similar future email.  If you have any questions, see\n the administrator of that system for details.\n Content preview:  The mtd_info contains a struct device, which must be linked\n    to its parent. Without this,\n the initialization of the MTD fails with a NULL\n    pointer dereference. Signed-off-by: Florian Fuchs --- v1->v2: no\n functional\n    change\n Content analysis details:   (-2.1 points, 5.0 required)\n  pts rule name              description\n ---- ----------------------\n --------------------------------------------------\n -0.0 RCVD_IN_DNSWL_NONE     RBL: Sender listed at https://www.dnswl.org/, no\n                             trust\n                             [2a00:1450:4864:20:0:0:0:435 listed in]\n                             [list.dnswl.org]\n -0.0 SPF_PASS               SPF: sender matches SPF record\n  0.0 SPF_HELO_NONE          SPF: HELO does not publish an SPF Record\n -0.1 DKIM_VALID_EF          Message has a valid DKIM or DK signature from\n                             envelope-from domain\n -0.1 DKIM_VALID_AU          Message has a valid DKIM or DK signature from\n author's\n                             domain\n -0.1 DKIM_VALID             Message has at least one valid DKIM or DK\n signature\n  0.1 DKIM_SIGNED            Message has a DKIM or DK signature,\n not necessarily valid\n -1.9 BAYES_00               BODY: Bayes spam probability is 0 to 1%\n                             [score: 0.0000]\n  0.0 FREEMAIL_FROM          Sender email is commonly abused enduser mail\n provider\n                             [fuchsfl(at)gmail.com]","X-BeenThere":"linux-mtd@lists.infradead.org","X-Mailman-Version":"2.1.34","Precedence":"list","List-Id":"Linux MTD discussion mailing list <linux-mtd.lists.infradead.org>","List-Unsubscribe":"<http://lists.infradead.org/mailman/options/linux-mtd>,\n <mailto:linux-mtd-request@lists.infradead.org?subject=unsubscribe>","List-Archive":"<http://lists.infradead.org/pipermail/linux-mtd/>","List-Post":"<mailto:linux-mtd@lists.infradead.org>","List-Help":"<mailto:linux-mtd-request@lists.infradead.org?subject=help>","List-Subscribe":"<http://lists.infradead.org/mailman/listinfo/linux-mtd>,\n <mailto:linux-mtd-request@lists.infradead.org?subject=subscribe>","Content-Type":"text/plain; charset=\"us-ascii\"","Content-Transfer-Encoding":"7bit","Sender":"\"linux-mtd\" <linux-mtd-bounces@lists.infradead.org>","Errors-To":"linux-mtd-bounces+incoming=patchwork.ozlabs.org@lists.infradead.org"},"content":"The mtd_info contains a struct device, which must be linked to its\nparent. Without this, the initialization of the MTD fails with a NULL\npointer dereference.\n\nSigned-off-by: Florian Fuchs <fuchsfl@gmail.com>\n---\nv1->v2: no functional change\n\nv1: https://lore.kernel.org/lkml/20251117224408.498449-4-fuchsfl@gmail.com/\n\n drivers/mtd/maps/vmu-flash.c | 1 +\n 1 file changed, 1 insertion(+)","diff":"diff --git a/drivers/mtd/maps/vmu-flash.c b/drivers/mtd/maps/vmu-flash.c\nindex b76d0609d1b7..10244e6731d0 100644\n--- a/drivers/mtd/maps/vmu-flash.c\n+++ b/drivers/mtd/maps/vmu-flash.c\n@@ -547,6 +547,7 @@ static void vmu_queryblocks(struct mapleq *mq)\n \tmpart->partition = card->partition;\n \tmtd_cur->priv = mpart;\n \tmtd_cur->owner = THIS_MODULE;\n+\tmtd_cur->dev.parent = &mdev->dev;\n \n \tpcache = kzalloc_obj(struct vmu_cache);\n \tif (!pcache)\n","prefixes":["v2","3/3"]}