fkie_cve-2023-52668
Vulnerability from fkie_nvd
Published
2024-05-17 14:15
Modified
2025-09-19 14:26
Summary
In the Linux kernel, the following vulnerability has been resolved: btrfs: zoned: fix lock ordering in btrfs_zone_activate() The btrfs CI reported a lockdep warning as follows by running generic generic/129. WARNING: possible circular locking dependency detected 6.7.0-rc5+ #1 Not tainted ------------------------------------------------------ kworker/u5:5/793427 is trying to acquire lock: ffff88813256d028 (&cache->lock){+.+.}-{2:2}, at: btrfs_zone_finish_one_bg+0x5e/0x130 but task is already holding lock: ffff88810a23a318 (&fs_info->zone_active_bgs_lock){+.+.}-{2:2}, at: btrfs_zone_finish_one_bg+0x34/0x130 which lock already depends on the new lock. the existing dependency chain (in reverse order) is: -> #1 (&fs_info->zone_active_bgs_lock){+.+.}-{2:2}: ... -> #0 (&cache->lock){+.+.}-{2:2}: ... This is because we take fs_info->zone_active_bgs_lock after a block_group's lock in btrfs_zone_activate() while doing the opposite in other places. Fix the issue by expanding the fs_info->zone_active_bgs_lock's critical section and taking it before a block_group's lock.
Impacted products
Vendor Product Version
linux linux_kernel *
linux linux_kernel *
linux linux_kernel 6.8



{
  "configurations": [
    {
      "nodes": [
        {
          "cpeMatch": [
            {
              "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
              "matchCriteriaId": "EB070897-9C4B-4820-AE94-31318C9F5D76",
              "versionEndExcluding": "6.6.15",
              "versionStartIncluding": "6.6",
              "vulnerable": true
            },
            {
              "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
              "matchCriteriaId": "58FD5308-148A-40D3-B36A-0CA6B434A8BF",
              "versionEndExcluding": "6.7.3",
              "versionStartIncluding": "6.7",
              "vulnerable": true
            },
            {
              "criteria": "cpe:2.3:o:linux:linux_kernel:6.8:rc1:*:*:*:*:*:*",
              "matchCriteriaId": "B9F4EA73-0894-400F-A490-3A397AB7A517",
              "vulnerable": true
            }
          ],
          "negate": false,
          "operator": "OR"
        }
      ]
    }
  ],
  "cveTags": [],
  "descriptions": [
    {
      "lang": "en",
      "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nbtrfs: zoned: fix lock ordering in btrfs_zone_activate()\n\nThe btrfs CI reported a lockdep warning as follows by running generic\ngeneric/129.\n\n   WARNING: possible circular locking dependency detected\n   6.7.0-rc5+ #1 Not tainted\n   ------------------------------------------------------\n   kworker/u5:5/793427 is trying to acquire lock:\n   ffff88813256d028 (\u0026cache-\u003elock){+.+.}-{2:2}, at: btrfs_zone_finish_one_bg+0x5e/0x130\n   but task is already holding lock:\n   ffff88810a23a318 (\u0026fs_info-\u003ezone_active_bgs_lock){+.+.}-{2:2}, at: btrfs_zone_finish_one_bg+0x34/0x130\n   which lock already depends on the new lock.\n\n   the existing dependency chain (in reverse order) is:\n   -\u003e #1 (\u0026fs_info-\u003ezone_active_bgs_lock){+.+.}-{2:2}:\n   ...\n   -\u003e #0 (\u0026cache-\u003elock){+.+.}-{2:2}:\n   ...\n\nThis is because we take fs_info-\u003ezone_active_bgs_lock after a block_group\u0027s\nlock in btrfs_zone_activate() while doing the opposite in other places.\n\nFix the issue by expanding the fs_info-\u003ezone_active_bgs_lock\u0027s critical\nsection and taking it before a block_group\u0027s lock."
    },
    {
      "lang": "es",
      "value": "En el kernel de Linux, se resolvi\u00f3 la siguiente vulnerabilidad: btrfs:zoned: corrige el orden de bloqueo en btrfs_zone_activate() El CI de btrfs inform\u00f3 una advertencia de bloqueo de la siguiente manera al ejecutar generic generic/129. ADVERTENCIA: se detect\u00f3 posible dependencia de bloqueo circular 6.7.0-rc5+ #1 No contaminado ---------------------------------- -------------------- kworker/u5:5/793427 est\u00e1 intentando adquirir el bloqueo: ffff88813256d028 (\u0026amp;cache-\u0026gt;lock){+.+.}-{2: 2}, en: btrfs_zone_finish_one_bg+0x5e/0x130 pero la tarea ya mantiene el bloqueo: ffff88810a23a318 (\u0026amp;fs_info-\u0026gt;zone_active_bgs_lock){+.+.}-{2:2}, en: btrfs_zone_finish_one_bg+0x34/0x130 cuyo bloqueo ya depende del cerradura nueva. la cadena de dependencia existente (en orden inverso) es: -\u0026gt; #1 (\u0026amp;fs_info-\u0026gt;zone_active_bgs_lock){+.+.}-{2:2}: ... -\u0026gt; #0 (\u0026amp;cache-\u0026gt;lock){+. +.}-{2:2}: ... Esto se debe a que tomamos fs_info-\u0026gt;zone_active_bgs_lock despu\u00e9s del bloqueo de un block_group en btrfs_zone_activate() mientras hacemos lo contrario en otros lugares. Solucione el problema expandiendo la secci\u00f3n cr\u00edtica de fs_info-\u0026gt;zone_active_bgs_lock y llev\u00e1ndola antes del bloqueo de block_group."
    }
  ],
  "id": "CVE-2023-52668",
  "lastModified": "2025-09-19T14:26:06.557",
  "metrics": {
    "cvssMetricV31": [
      {
        "cvssData": {
          "attackComplexity": "LOW",
          "attackVector": "LOCAL",
          "availabilityImpact": "HIGH",
          "baseScore": 5.5,
          "baseSeverity": "MEDIUM",
          "confidentialityImpact": "NONE",
          "integrityImpact": "NONE",
          "privilegesRequired": "LOW",
          "scope": "UNCHANGED",
          "userInteraction": "NONE",
          "vectorString": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H",
          "version": "3.1"
        },
        "exploitabilityScore": 1.8,
        "impactScore": 3.6,
        "source": "nvd@nist.gov",
        "type": "Primary"
      }
    ]
  },
  "published": "2024-05-17T14:15:09.640",
  "references": [
    {
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
      "tags": [
        "Patch"
      ],
      "url": "https://git.kernel.org/stable/c/1908e9d01e5395adff68d9d308a0fb15337e6272"
    },
    {
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
      "tags": [
        "Patch"
      ],
      "url": "https://git.kernel.org/stable/c/6f74989f5909cdec9b1274641f0fa306b15bb476"
    },
    {
      "source": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
      "tags": [
        "Patch"
      ],
      "url": "https://git.kernel.org/stable/c/b18f3b60b35a8c01c9a2a0f0d6424c6d73971dc3"
    },
    {
      "source": "af854a3a-2127-422b-91ae-364da2661108",
      "tags": [
        "Patch"
      ],
      "url": "https://git.kernel.org/stable/c/1908e9d01e5395adff68d9d308a0fb15337e6272"
    },
    {
      "source": "af854a3a-2127-422b-91ae-364da2661108",
      "tags": [
        "Patch"
      ],
      "url": "https://git.kernel.org/stable/c/6f74989f5909cdec9b1274641f0fa306b15bb476"
    },
    {
      "source": "af854a3a-2127-422b-91ae-364da2661108",
      "tags": [
        "Patch"
      ],
      "url": "https://git.kernel.org/stable/c/b18f3b60b35a8c01c9a2a0f0d6424c6d73971dc3"
    }
  ],
  "sourceIdentifier": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
  "vulnStatus": "Analyzed",
  "weaknesses": [
    {
      "description": [
        {
          "lang": "en",
          "value": "CWE-667"
        }
      ],
      "source": "nvd@nist.gov",
      "type": "Primary"
    }
  ]
}


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.
  • 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…