CVE-2026-98722 (GCVE-0-2026-98722)
Vulnerability from cvelistv5
Published
2026-10-18 15:46
Modified
2026-10-30 12:39
Severity ?
Summary
In the Linux kernel, the following vulnerability has been resolved: mtd: block2mtd: Fix divide error when erase_size is zero The erase size is parsed from the "block2mtd" module parameter and can be set to zero. add_device() then evaluates if (size % erase_size) with a zero divisor, which triggers a divide error: divide error: 0000 [#1] PREEMPT SMP PTI RIP: 0010:add_device drivers/mtd/devices/block2mtd.c:296 [inline] RIP: 0010:block2mtd_setup2+0x592/0xda0 drivers/mtd/devices/block2mtd.c:459 Call Trace: block2mtd_setup+0x27/0xe0 drivers/mtd/devices/block2mtd.c:476 param_attr_store+0x214/0x310 kernel/params.c:589 module_attr_store+0x65/0x90 kernel/params.c:904 kernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345 ... Reject a zero erase size before performing the modulo operation so the existing "erasesize must be a divisor of device size" error path reports the invalid argument and frees the device.
Impacted products
Vendor Product Version
Linux Linux Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Version: ea6d833a3fddcd1d60414d48f34c7f4fbe88608f
Create a notification for this product.
Show details on NVD website


{
  "containers": {
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/mtd/devices/block2mtd.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "c8004de07739fa9a39e310e859384f1458d7d076",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            },
            {
              "lessThan": "7ad5287e58d7aa1a848105f119e6c5b00446882f",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            },
            {
              "lessThan": "fd73c079abc58e10183a4db4dc9dc5012db17476",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            },
            {
              "lessThan": "bff83b723e93acc788bd690dc4bc1f6f4356c35b",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            },
            {
              "lessThan": "826170a49ca1315af6b293a02200585b1e2186d9",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            },
            {
              "lessThan": "a991c28066e7ba4da7450bb04478849f7ac6a14a",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            },
            {
              "lessThan": "21d0f05989bf0d5cef57b467a7fa4feefbd7236a",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            },
            {
              "lessThan": "b5965c4221165045e19736794ca5f48ae3d67142",
              "status": "affected",
              "version": "ea6d833a3fddcd1d60414d48f34c7f4fbe88608f",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/mtd/devices/block2mtd.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "3.15"
            },
            {
              "lessThan": "3.15",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.10.*",
              "status": "unaffected",
              "version": "5.10.273",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.15.*",
              "status": "unaffected",
              "version": "5.15.224",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.1.*",
              "status": "unaffected",
              "version": "6.1.191",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.6.*",
              "status": "unaffected",
              "version": "6.6.160",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.12.*",
              "status": "unaffected",
              "version": "6.12.113",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "6.18.*",
              "status": "unaffected",
              "version": "6.18.56",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "7.2.*",
              "status": "unaffected",
              "version": "7.2.10",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "7.3",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.10.273",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.15.224",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.1.191",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.6.160",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.12.113",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "6.18.56",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "7.2.10",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "7.3",
                  "versionStartIncluding": "3.15",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nmtd: block2mtd: Fix divide error when erase_size is zero\n\nThe erase size is parsed from the \"block2mtd\" module parameter and can\nbe set to zero. add_device() then evaluates\n\n        if (size % erase_size)\n\nwith a zero divisor, which triggers a divide error:\n\ndivide error: 0000 [#1] PREEMPT SMP PTI\nRIP: 0010:add_device drivers/mtd/devices/block2mtd.c:296 [inline]\nRIP: 0010:block2mtd_setup2+0x592/0xda0 drivers/mtd/devices/block2mtd.c:459\nCall Trace:\nblock2mtd_setup+0x27/0xe0 drivers/mtd/devices/block2mtd.c:476\nparam_attr_store+0x214/0x310 kernel/params.c:589\nmodule_attr_store+0x65/0x90 kernel/params.c:904\nkernfs_fop_write_iter+0x3a4/0x540 fs/kernfs/file.c:345\n...\n\nReject a zero erase size before performing the modulo operation so the\nexisting \"erasesize must be a divisor of device size\" error path\nreports the invalid argument and frees the device."
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2026-10-30T12:39:05.611Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/c8004de07739fa9a39e310e859384f1458d7d076"
        },
        {
          "url": "https://git.kernel.org/stable/c/7ad5287e58d7aa1a848105f119e6c5b00446882f"
        },
        {
          "url": "https://git.kernel.org/stable/c/fd73c079abc58e10183a4db4dc9dc5012db17476"
        },
        {
          "url": "https://git.kernel.org/stable/c/bff83b723e93acc788bd690dc4bc1f6f4356c35b"
        },
        {
          "url": "https://git.kernel.org/stable/c/826170a49ca1315af6b293a02200585b1e2186d9"
        },
        {
          "url": "https://git.kernel.org/stable/c/a991c28066e7ba4da7450bb04478849f7ac6a14a"
        },
        {
          "url": "https://git.kernel.org/stable/c/21d0f05989bf0d5cef57b467a7fa4feefbd7236a"
        },
        {
          "url": "https://git.kernel.org/stable/c/b5965c4221165045e19736794ca5f48ae3d67142"
        }
      ],
      "title": "mtd: block2mtd: Fix divide error when erase_size is zero",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2026-98722",
    "datePublished": "2026-10-18T15:46:58.093Z",
    "dateReserved": "2026-09-25T10:25:14.366Z",
    "dateUpdated": "2026-10-30T12:39:05.611Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.2"
}


Log in or create an account to share your comment.




Tags
Taxonomy of the tags.


Loading…

Loading…

Loading…

Sightings

Author Source Type Date

Nomenclature

  • Seen: The vulnerability was mentioned, discussed, or seen somewhere by the user.
  • Confirmed: The vulnerability is confirmed from an analyst perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: This vulnerability was exploited and seen by the user reporting the sighting.
  • Patched: This vulnerability was successfully patched by the user reporting the sighting.
  • Not exploited: This vulnerability was not exploited or seen by the user reporting the sighting.
  • Not confirmed: The user expresses doubt about the veracity of the vulnerability.
  • Not patched: This vulnerability was not successfully patched by the user reporting the sighting.


Loading…

Loading…