{"id":"CVE-2026-139578","aliases":["CVE-2026-139578"],"related":[],"kind":"vulnerability","state":"published","title":"RDMA/ionic: Fix XArray initialization to use XArray flags","summary":"In the Linux kernel, the following vulnerability has been resolved:\n\nRDMA/ionic: Fix XArray initialization to use XArray flags\n\nxa_init_flags() takes XArray flags (XA_FLAGS_*), not gfp flags, even\nthough the parameter is typed gfp_t. Passing GFP_ATOMIC leaves both\nlock-type bits clear, so xa_lock_type() resolves to XA_LOCK_NORMAL for\nqp_tbl and cq_tbl.\n\nBoth tables are used with the IRQ-safe accessors: xa_store_irq() with\nGFP_KERNEL from process context, and xa_lock_irqsave() from the event\nqueue path. When a store needs to grow the tree, __xas_nomem() drops\nthe lock using the recorded lock type before allocating:\n\n\tif (gfpflags_allow_blocking(gfp)) {\n\t\txas_unlock_type(xas, lock_type);\n\t\txas->xa_alloc = kmem_cache_alloc_lru(...);\n\t\txas_lock_type(xas, lock_type);\n\t}\n\nWith XA_LOCK_NORMAL that is a plain spin_unlock(), so the sleeping\nGFP_KERNEL allocation runs with interrupts still disabled by\nxa_store_irq(), and lockdep annotates the lock with the wrong class.\n\nGFP_ATOMIC also happens to set __GFP_HIGH (0x20), which collides with\nXA_FLAGS_ACCOUNT (32U) and silently enables memcg accounting of the\nXArray nodes.\n\nUse XA_FLAGS_LOCK_IRQ so the lock type matches how the tables are\nactually accessed.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"In the Linux kernel, the following vulnerability has been resolved:\n\nRDMA/ionic: Fix XArray initialization to use XArray flags\n\nxa_init_flags() takes XArray flags (XA_FLAGS_*), not gfp flags, even\nthough the parameter is typed gfp_t. Passing GFP_ATOMIC leaves both\nlock-type bits clear, so xa_lock_type() resolves to XA_LOCK_NORMAL for\nqp_tbl and cq_tbl.\n\nBoth tables are used with the IRQ-safe accessors: xa_store_irq() with\nGFP_KERNEL from process context, and xa_lock_irqsave() from the event\nqueue path. When a store needs to grow the tree, __xas_nomem() drops\nthe lock using the recorded lock type before allocating:\n\n\tif (gfpflags_allow_blocking(gfp)) {\n\t\txas_unlock_type(xas, lock_type);\n\t\txas->xa_alloc = kmem_cache_alloc_lru(...);\n\t\txas_lock_type(xas, lock_type);\n\t}\n\nWith XA_LOCK_NORMAL that is a plain spin_unlock(), so the sleeping\nGFP_KERNEL allocation runs with interrupts still disabled by\nxa_store_irq(), and lockdep annotates the lock with the wrong class.\n\nGFP_ATOMIC also happens to set __GFP_HIGH (0x20), which collides with\nXA_FLAGS_ACCOUNT (32U) and silently enables memcg accounting of the\nXArray nodes.\n\nUse XA_FLAGS_LOCK_IRQ so the lock type matches how the tables are\nactually accessed.","source":"cvelist"}],"published":"2026-11-30T13:36:03.148Z","modified":"2026-11-30T14:19:39.050Z","severities":[],"cwes":[],"affected":[{"ranges":[{"type":"git","introduced":"e8521822c733c6deab0f339843cd37cd62c12795","fixed":"af56f866f152afe843239818ed127994bb564eb2","status":"affected"},{"type":"git","introduced":"e8521822c733c6deab0f339843cd37cd62c12795","fixed":"cf11ce423eb12ce5fb774101e7e49ec397ed732a","status":"affected"},{"type":"git","introduced":"e8521822c733c6deab0f339843cd37cd62c12795","fixed":"2eca9c14e66a1f71c089fe5c3afb2d339da3023a","status":"affected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"},{"ranges":[{"version":"6.18","status":"affected"},{"type":"semver","introduced":"0","fixed":"6.18","status":"unaffected"},{"type":"semver","introduced":"6.18.65","lastAffected":"6.18.*","status":"unaffected"},{"type":"semver","introduced":"7.3.6","lastAffected":"7.3.*","status":"unaffected"},{"type":"original_commit_for_fix","introduced":"7.4-rc1","lastAffected":"*","status":"unaffected"}],"vendor":"Linux","product":"Linux","repo":"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git","source":"cvelist"}],"references":[{"url":"https://git.kernel.org/stable/c/af56f866f152afe843239818ed127994bb564eb2","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/cf11ce423eb12ce5fb774101e7e49ec397ed732a","tags":[],"sources":["cvelist","nvd"]},{"url":"https://git.kernel.org/stable/c/2eca9c14e66a1f71c089fe5c3afb2d339da3023a","tags":[],"sources":["cvelist","nvd"]}],"credits":[],"assigner":"Linux","sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-139578","url":"https://www.cve.org/CVERecord?id=CVE-2026-139578","licence":"CVE Terms of Use","modified":"2026-11-30T13:36:03.148Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-139578","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-139578","licence":"Public domain","modified":"2026-11-30T14:19:39.050Z"}],"updatedAt":"2026-11-30T14:33:38.578Z","epss":{"score":0.00166,"percentile":0.061,"date":"2026-12-01T12:00:22.000Z"}}