← Back to CVE Explorer

CVE-2026-98198

Full vulnerability record from the local CVENow database.

Description

In the Linux kernel, the following vulnerability has been resolved: hwmon: (pwm-fan) Stop RPM timer before freeing tach data sample_timer() rearms the RPM timer and accesses the devm-managed ctx->tachs and ctx->pulses_per_revolution arrays. The cleanup action which stops the timer is registered before those arrays are allocated. Since devres releases entries in reverse order, driver detach can free the arrays before pwm_fan_cleanup() shuts down the timer. A timer expiry in that window accesses the freed tach data. With a KASAN kernel, a test-only kprobe delayed entry to pwm_fan_cleanup() while normal sysfs unbind ran. Each of three runs reported three four-byte reads and two four-byte writes in sample_timer() after its backing devm allocations had been freed. The helper did not invoke the timer callback, cleanup actions or free functions. With the fix, three matching unbind runs completed without KASAN, BUG, WARNING, Oops or panic. Instrumentation confirmed that timer retirement completed before the first timer backing allocation was released. Split timer retirement from the power cleanup and register its devres action after the timer backing data and IRQ actions are installed. This preserves the early power rollback action while ensuring the timer is retired before its backing data is released. Use timer_shutdown_sync() because the callback can rearm itself.

Severity
Not scored
CVSS score
Not available
Vulnerability status
Received
Source identifier
416baaa9-dc9f-4396-8d5f-8c081fb06d67
Published
2026-10-06 09:18:05.440000
Last modified
2026-10-30 13:21:12.060000
View original CVE JSON
{
  "id": "CVE-2026-98198",
  "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
  "published": "2026-10-06T09:18:05.440",
  "lastModified": "2026-10-30T13:21:12.060",
  "vulnStatus": "Received",
  "cveTags": [],
  "descriptions": [
    {
      "lang": "en",
      "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nhwmon: (pwm-fan) Stop RPM timer before freeing tach data\n\nsample_timer() rearms the RPM timer and accesses the devm-managed\nctx->tachs and ctx->pulses_per_revolution arrays. The cleanup action\nwhich stops the timer is registered before those arrays are allocated.\n\nSince devres releases entries in reverse order, driver detach can free\nthe arrays before pwm_fan_cleanup() shuts down the timer. A timer expiry\nin that window accesses the freed tach data.\n\nWith a KASAN kernel, a test-only kprobe delayed entry to\npwm_fan_cleanup() while normal sysfs unbind ran. Each of three runs\nreported three four-byte reads and two four-byte writes in sample_timer()\nafter its backing devm allocations had been freed. The helper did not\ninvoke the timer callback, cleanup actions or free functions.\n\nWith the fix, three matching unbind runs completed without KASAN, BUG,\nWARNING, Oops or panic. Instrumentation confirmed that timer retirement\ncompleted before the first timer backing allocation was released.\n\nSplit timer retirement from the power cleanup and register its devres\naction after the timer backing data and IRQ actions are installed. This\npreserves the early power rollback action while ensuring the timer is\nretired before its backing data is released. Use timer_shutdown_sync()\nbecause the callback can rearm itself."
    }
  ],
  "affected": [
    {
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
      "affectedData": [
        {
          "vendor": "Linux",
          "product": "Linux",
          "defaultStatus": "unaffected",
          "programFiles": [
            "drivers/hwmon/pwm-fan.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "versions": [
            {
              "version": "01695410d4529e38fea6159fa9f1260c598290b0",
              "lessThan": "6f890d1fe8325ac8330473428b9a9d6526de1b32",
              "versionType": "git",
              "status": "affected"
            },
            {
              "version": "01695410d4529e38fea6159fa9f1260c598290b0",
              "lessThan": "7743183d8b0f6ba88738805c824a255baae674b9",
              "versionType": "git",
              "status": "affected"
            },
            {
              "version": "01695410d4529e38fea6159fa9f1260c598290b0",
              "lessThan": "d073d306e587c1f35aaf9c07c42e54a3d5895d8f",
              "versionType": "git",
              "status": "affected"
            },
            {
              "version": "01695410d4529e38fea6159fa9f1260c598290b0",
              "lessThan": "1e824fdb14a187ce56697e803b02b1e86243a755",
              "versionType": "git",
              "status": "affected"
            },
            {
              "version": "01695410d4529e38fea6159fa9f1260c598290b0",
              "lessThan": "a5ce3fe5335a24d0220958c6866830a6d5fa1cc0",
              "versionType": "git",
              "status": "affected"
            },
            {
              "version": "01695410d4529e38fea6159fa9f1260c598290b0",
              "lessThan": "b48339b0a577783e4590a69e4cd2f2760ce33154",
              "versionType": "git",
              "status": "affected"
            },
            {
              "version": "01695410d4529e38fea6159fa9f1260c598290b0",
              "lessThan": "26d5ff79768548efb1e604bb6e8697c101e06269",
              "versionType": "git",
              "status": "affected"
            }
          ]
        },
        {
          "vendor": "Linux",
          "product": "Linux",
          "defaultStatus": "affected",
          "programFiles": [
            "drivers/hwmon/pwm-fan.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "versions": [
            {
              "version": "5.12",
              "status": "affected"
            },
            {
              "version": "0",
              "lessThan": "5.12",
              "versionType": "semver",
              "status": "unaffected"
            },
            {
              "version": "5.15.224",
              "lessThanOrEqual": "5.15.*",
              "versionType": "semver",
              "status": "unaffected"
            },
            {
              "version": "6.1.191",
              "lessThanOrEqual": "6.1.*",
              "versionType": "semver",
              "status": "unaffected"
            },
            {
              "version": "6.6.160",
              "lessThanOrEqual": "6.6.*",
              "versionType": "semver",
              "status": "unaffected"
            },
            {
              "version": "6.12.112",
              "lessThanOrEqual": "6.12.*",
              "versionType": "semver",
              "status": "unaffected"
            },
            {
              "version": "6.18.54",
              "lessThanOrEqual": "6.18.*",
              "versionType": "semver",
              "status": "unaffected"
            },
            {
              "version": "7.2.8",
              "lessThanOrEqual": "7.2.*",
              "versionType": "semver",
              "status": "unaffected"
            },
            {
              "version": "7.3",
              "lessThanOrEqual": "*",
              "versionType": "original_commit_for_fix",
              "status": "unaffected"
            }
          ]
        }
      ]
    }
  ],
  "metrics": {},
  "references": [
    {
      "url": "https://git.kernel.org/stable/c/1e824fdb14a187ce56697e803b02b1e86243a755",
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
    },
    {
      "url": "https://git.kernel.org/stable/c/26d5ff79768548efb1e604bb6e8697c101e06269",
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
    },
    {
      "url": "https://git.kernel.org/stable/c/6f890d1fe8325ac8330473428b9a9d6526de1b32",
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
    },
    {
      "url": "https://git.kernel.org/stable/c/7743183d8b0f6ba88738805c824a255baae674b9",
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
    },
    {
      "url": "https://git.kernel.org/stable/c/a5ce3fe5335a24d0220958c6866830a6d5fa1cc0",
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
    },
    {
      "url": "https://git.kernel.org/stable/c/b48339b0a577783e4590a69e4cd2f2760ce33154",
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
    },
    {
      "url": "https://git.kernel.org/stable/c/d073d306e587c1f35aaf9c07c42e54a3d5895d8f",
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67"
    }
  ]
}