CVE-2021-47047 (GCVE-0-2021-47047)

Vulnerability from cvelistv5 – Published: 2024-02-28 08:13 – Updated: 2025-05-04 07:03
VLAI?
Title
spi: spi-zynqmp-gqspi: return -ENOMEM if dma_map_single fails
Summary
In the Linux kernel, the following vulnerability has been resolved: spi: spi-zynqmp-gqspi: return -ENOMEM if dma_map_single fails The spi controller supports 44-bit address space on AXI in DMA mode, so set dma_addr_t width to 44-bit to avoid using a swiotlb mapping. In addition, if dma_map_single fails, it should return immediately instead of continuing doing the DMA operation which bases on invalid address. This fixes the following crash which occurs in reading a big block from flash: [ 123.633577] zynqmp-qspi ff0f0000.spi: swiotlb buffer is full (sz: 4194304 bytes), total 32768 (slots), used 0 (slots) [ 123.644230] zynqmp-qspi ff0f0000.spi: ERR:rxdma:memory not mapped [ 123.784625] Unable to handle kernel paging request at virtual address 00000000003fffc0 [ 123.792536] Mem abort info: [ 123.795313] ESR = 0x96000145 [ 123.798351] EC = 0x25: DABT (current EL), IL = 32 bits [ 123.803655] SET = 0, FnV = 0 [ 123.806693] EA = 0, S1PTW = 0 [ 123.809818] Data abort info: [ 123.812683] ISV = 0, ISS = 0x00000145 [ 123.816503] CM = 1, WnR = 1 [ 123.819455] user pgtable: 4k pages, 48-bit VAs, pgdp=0000000805047000 [ 123.825887] [00000000003fffc0] pgd=0000000803b45003, p4d=0000000803b45003, pud=0000000000000000 [ 123.834586] Internal error: Oops: 96000145 [#1] PREEMPT SMP
Severity ?
No CVSS data available.
Assigner
Impacted products
Vendor Product Version
Linux Linux Affected: 1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e , < 5980a3b9c933408bc22b0e349b78c3ebd7cbf880 (git)
Affected: 1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e , < c26c026eb496261dbc0adbf606cc81989cd2038c (git)
Affected: 1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e , < bad5a23cf2b477fa78b85fd392736dae09a1e818 (git)
Affected: 1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e , < 126bdb606fd2802454e6048caef1be3e25dd121e (git)
Create a notification for this product.
    Linux Linux Affected: 5.10
Unaffected: 0 , < 5.10 (semver)
Unaffected: 5.10.37 , ≤ 5.10.* (semver)
Unaffected: 5.11.21 , ≤ 5.11.* (semver)
Unaffected: 5.12.4 , ≤ 5.12.* (semver)
Unaffected: 5.13 , ≤ * (original_commit_for_fix)
Create a notification for this product.
Show details on NVD website

{
  "containers": {
    "adp": [
      {
        "metrics": [
          {
            "other": {
              "content": {
                "id": "CVE-2021-47047",
                "options": [
                  {
                    "Exploitation": "none"
                  },
                  {
                    "Automatable": "no"
                  },
                  {
                    "Technical Impact": "partial"
                  }
                ],
                "role": "CISA Coordinator",
                "timestamp": "2024-02-28T19:57:19.610244Z",
                "version": "2.0.3"
              },
              "type": "ssvc"
            }
          }
        ],
        "providerMetadata": {
          "dateUpdated": "2024-06-04T17:15:11.460Z",
          "orgId": "134c704f-9b21-4f2e-91b3-4a467353bcc0",
          "shortName": "CISA-ADP"
        },
        "title": "CISA ADP Vulnrichment"
      },
      {
        "providerMetadata": {
          "dateUpdated": "2024-08-04T05:24:39.320Z",
          "orgId": "af854a3a-2127-422b-91ae-364da2661108",
          "shortName": "CVE"
        },
        "references": [
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/5980a3b9c933408bc22b0e349b78c3ebd7cbf880"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/c26c026eb496261dbc0adbf606cc81989cd2038c"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/bad5a23cf2b477fa78b85fd392736dae09a1e818"
          },
          {
            "tags": [
              "x_transferred"
            ],
            "url": "https://git.kernel.org/stable/c/126bdb606fd2802454e6048caef1be3e25dd121e"
          }
        ],
        "title": "CVE Program Container"
      }
    ],
    "cna": {
      "affected": [
        {
          "defaultStatus": "unaffected",
          "product": "Linux",
          "programFiles": [
            "drivers/spi/spi-zynqmp-gqspi.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "lessThan": "5980a3b9c933408bc22b0e349b78c3ebd7cbf880",
              "status": "affected",
              "version": "1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e",
              "versionType": "git"
            },
            {
              "lessThan": "c26c026eb496261dbc0adbf606cc81989cd2038c",
              "status": "affected",
              "version": "1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e",
              "versionType": "git"
            },
            {
              "lessThan": "bad5a23cf2b477fa78b85fd392736dae09a1e818",
              "status": "affected",
              "version": "1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e",
              "versionType": "git"
            },
            {
              "lessThan": "126bdb606fd2802454e6048caef1be3e25dd121e",
              "status": "affected",
              "version": "1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e",
              "versionType": "git"
            }
          ]
        },
        {
          "defaultStatus": "affected",
          "product": "Linux",
          "programFiles": [
            "drivers/spi/spi-zynqmp-gqspi.c"
          ],
          "repo": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git",
          "vendor": "Linux",
          "versions": [
            {
              "status": "affected",
              "version": "5.10"
            },
            {
              "lessThan": "5.10",
              "status": "unaffected",
              "version": "0",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.10.*",
              "status": "unaffected",
              "version": "5.10.37",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.11.*",
              "status": "unaffected",
              "version": "5.11.21",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "5.12.*",
              "status": "unaffected",
              "version": "5.12.4",
              "versionType": "semver"
            },
            {
              "lessThanOrEqual": "*",
              "status": "unaffected",
              "version": "5.13",
              "versionType": "original_commit_for_fix"
            }
          ]
        }
      ],
      "cpeApplicability": [
        {
          "nodes": [
            {
              "cpeMatch": [
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.10.37",
                  "versionStartIncluding": "5.10",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.11.21",
                  "versionStartIncluding": "5.10",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.12.4",
                  "versionStartIncluding": "5.10",
                  "vulnerable": true
                },
                {
                  "criteria": "cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*",
                  "versionEndExcluding": "5.13",
                  "versionStartIncluding": "5.10",
                  "vulnerable": true
                }
              ],
              "negate": false,
              "operator": "OR"
            }
          ]
        }
      ],
      "descriptions": [
        {
          "lang": "en",
          "value": "In the Linux kernel, the following vulnerability has been resolved:\n\nspi: spi-zynqmp-gqspi: return -ENOMEM if dma_map_single fails\n\nThe spi controller supports 44-bit address space on AXI in DMA mode,\nso set dma_addr_t width to 44-bit to avoid using a swiotlb mapping.\nIn addition, if dma_map_single fails, it should return immediately\ninstead of continuing doing the DMA operation which bases on invalid\naddress.\n\nThis fixes the following crash which occurs in reading a big block\nfrom flash:\n\n[  123.633577] zynqmp-qspi ff0f0000.spi: swiotlb buffer is full (sz: 4194304 bytes), total 32768 (slots), used 0 (slots)\n[  123.644230] zynqmp-qspi ff0f0000.spi: ERR:rxdma:memory not mapped\n[  123.784625] Unable to handle kernel paging request at virtual address 00000000003fffc0\n[  123.792536] Mem abort info:\n[  123.795313]   ESR = 0x96000145\n[  123.798351]   EC = 0x25: DABT (current EL), IL = 32 bits\n[  123.803655]   SET = 0, FnV = 0\n[  123.806693]   EA = 0, S1PTW = 0\n[  123.809818] Data abort info:\n[  123.812683]   ISV = 0, ISS = 0x00000145\n[  123.816503]   CM = 1, WnR = 1\n[  123.819455] user pgtable: 4k pages, 48-bit VAs, pgdp=0000000805047000\n[  123.825887] [00000000003fffc0] pgd=0000000803b45003, p4d=0000000803b45003, pud=0000000000000000\n[  123.834586] Internal error: Oops: 96000145 [#1] PREEMPT SMP"
        }
      ],
      "providerMetadata": {
        "dateUpdated": "2025-05-04T07:03:02.855Z",
        "orgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
        "shortName": "Linux"
      },
      "references": [
        {
          "url": "https://git.kernel.org/stable/c/5980a3b9c933408bc22b0e349b78c3ebd7cbf880"
        },
        {
          "url": "https://git.kernel.org/stable/c/c26c026eb496261dbc0adbf606cc81989cd2038c"
        },
        {
          "url": "https://git.kernel.org/stable/c/bad5a23cf2b477fa78b85fd392736dae09a1e818"
        },
        {
          "url": "https://git.kernel.org/stable/c/126bdb606fd2802454e6048caef1be3e25dd121e"
        }
      ],
      "title": "spi: spi-zynqmp-gqspi: return -ENOMEM if dma_map_single fails",
      "x_generator": {
        "engine": "bippy-1.2.0"
      }
    }
  },
  "cveMetadata": {
    "assignerOrgId": "416baaa9-dc9f-4396-8d5f-8c081fb06d67",
    "assignerShortName": "Linux",
    "cveId": "CVE-2021-47047",
    "datePublished": "2024-02-28T08:13:50.931Z",
    "dateReserved": "2024-02-27T18:42:55.970Z",
    "dateUpdated": "2025-05-04T07:03:02.855Z",
    "state": "PUBLISHED"
  },
  "dataType": "CVE_RECORD",
  "dataVersion": "5.1",
  "vulnerability-lookup:meta": {
    "vulnrichment": {
      "containers": "{\"adp\": [{\"title\": \"CVE Program Container\", \"references\": [{\"url\": \"https://git.kernel.org/stable/c/5980a3b9c933408bc22b0e349b78c3ebd7cbf880\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/c26c026eb496261dbc0adbf606cc81989cd2038c\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/bad5a23cf2b477fa78b85fd392736dae09a1e818\", \"tags\": [\"x_transferred\"]}, {\"url\": \"https://git.kernel.org/stable/c/126bdb606fd2802454e6048caef1be3e25dd121e\", \"tags\": [\"x_transferred\"]}], \"providerMetadata\": {\"orgId\": \"af854a3a-2127-422b-91ae-364da2661108\", \"shortName\": \"CVE\", \"dateUpdated\": \"2024-08-04T05:24:39.320Z\"}}, {\"metrics\": [{\"other\": {\"type\": \"ssvc\", \"content\": {\"id\": \"CVE-2021-47047\", \"role\": \"CISA Coordinator\", \"options\": [{\"Exploitation\": \"none\"}, {\"Automatable\": \"no\"}, {\"Technical Impact\": \"partial\"}], \"version\": \"2.0.3\", \"timestamp\": \"2024-02-28T19:57:19.610244Z\"}}}], \"providerMetadata\": {\"orgId\": \"134c704f-9b21-4f2e-91b3-4a467353bcc0\", \"shortName\": \"CISA-ADP\", \"dateUpdated\": \"2024-05-23T19:01:13.741Z\"}, \"title\": \"CISA ADP Vulnrichment\"}], \"cna\": {\"title\": \"spi: spi-zynqmp-gqspi: return -ENOMEM if dma_map_single fails\", \"affected\": [{\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e\", \"lessThan\": \"5980a3b9c933408bc22b0e349b78c3ebd7cbf880\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e\", \"lessThan\": \"c26c026eb496261dbc0adbf606cc81989cd2038c\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e\", \"lessThan\": \"bad5a23cf2b477fa78b85fd392736dae09a1e818\", \"versionType\": \"git\"}, {\"status\": \"affected\", \"version\": \"1c26372e5aa9e53391a1f8fe0dc7cd93a7e5ba9e\", \"lessThan\": \"126bdb606fd2802454e6048caef1be3e25dd121e\", \"versionType\": \"git\"}], \"programFiles\": [\"drivers/spi/spi-zynqmp-gqspi.c\"], \"defaultStatus\": \"unaffected\"}, {\"repo\": \"https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git\", \"vendor\": \"Linux\", \"product\": \"Linux\", \"versions\": [{\"status\": \"affected\", \"version\": \"5.10\"}, {\"status\": \"unaffected\", \"version\": \"0\", \"lessThan\": \"5.10\", \"versionType\": \"semver\"}, {\"status\": \"unaffected\", \"version\": \"5.10.37\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"5.10.*\"}, {\"status\": \"unaffected\", \"version\": \"5.11.21\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"5.11.*\"}, {\"status\": \"unaffected\", \"version\": \"5.12.4\", \"versionType\": \"semver\", \"lessThanOrEqual\": \"5.12.*\"}, {\"status\": \"unaffected\", \"version\": \"5.13\", \"versionType\": \"original_commit_for_fix\", \"lessThanOrEqual\": \"*\"}], \"programFiles\": [\"drivers/spi/spi-zynqmp-gqspi.c\"], \"defaultStatus\": \"affected\"}], \"references\": [{\"url\": \"https://git.kernel.org/stable/c/5980a3b9c933408bc22b0e349b78c3ebd7cbf880\"}, {\"url\": \"https://git.kernel.org/stable/c/c26c026eb496261dbc0adbf606cc81989cd2038c\"}, {\"url\": \"https://git.kernel.org/stable/c/bad5a23cf2b477fa78b85fd392736dae09a1e818\"}, {\"url\": \"https://git.kernel.org/stable/c/126bdb606fd2802454e6048caef1be3e25dd121e\"}], \"x_generator\": {\"engine\": \"bippy-1.2.0\"}, \"descriptions\": [{\"lang\": \"en\", \"value\": \"In the Linux kernel, the following vulnerability has been resolved:\\n\\nspi: spi-zynqmp-gqspi: return -ENOMEM if dma_map_single fails\\n\\nThe spi controller supports 44-bit address space on AXI in DMA mode,\\nso set dma_addr_t width to 44-bit to avoid using a swiotlb mapping.\\nIn addition, if dma_map_single fails, it should return immediately\\ninstead of continuing doing the DMA operation which bases on invalid\\naddress.\\n\\nThis fixes the following crash which occurs in reading a big block\\nfrom flash:\\n\\n[  123.633577] zynqmp-qspi ff0f0000.spi: swiotlb buffer is full (sz: 4194304 bytes), total 32768 (slots), used 0 (slots)\\n[  123.644230] zynqmp-qspi ff0f0000.spi: ERR:rxdma:memory not mapped\\n[  123.784625] Unable to handle kernel paging request at virtual address 00000000003fffc0\\n[  123.792536] Mem abort info:\\n[  123.795313]   ESR = 0x96000145\\n[  123.798351]   EC = 0x25: DABT (current EL), IL = 32 bits\\n[  123.803655]   SET = 0, FnV = 0\\n[  123.806693]   EA = 0, S1PTW = 0\\n[  123.809818] Data abort info:\\n[  123.812683]   ISV = 0, ISS = 0x00000145\\n[  123.816503]   CM = 1, WnR = 1\\n[  123.819455] user pgtable: 4k pages, 48-bit VAs, pgdp=0000000805047000\\n[  123.825887] [00000000003fffc0] pgd=0000000803b45003, p4d=0000000803b45003, pud=0000000000000000\\n[  123.834586] Internal error: Oops: 96000145 [#1] PREEMPT SMP\"}], \"cpeApplicability\": [{\"nodes\": [{\"negate\": false, \"cpeMatch\": [{\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"5.10.37\", \"versionStartIncluding\": \"5.10\"}, {\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"5.11.21\", \"versionStartIncluding\": \"5.10\"}, {\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"5.12.4\", \"versionStartIncluding\": \"5.10\"}, {\"criteria\": \"cpe:2.3:o:linux:linux_kernel:*:*:*:*:*:*:*:*\", \"vulnerable\": true, \"versionEndExcluding\": \"5.13\", \"versionStartIncluding\": \"5.10\"}], \"operator\": \"OR\"}]}], \"providerMetadata\": {\"orgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"shortName\": \"Linux\", \"dateUpdated\": \"2025-05-04T07:03:02.855Z\"}}}",
      "cveMetadata": "{\"cveId\": \"CVE-2021-47047\", \"state\": \"PUBLISHED\", \"dateUpdated\": \"2025-05-04T07:03:02.855Z\", \"dateReserved\": \"2024-02-27T18:42:55.970Z\", \"assignerOrgId\": \"416baaa9-dc9f-4396-8d5f-8c081fb06d67\", \"datePublished\": \"2024-02-28T08:13:50.931Z\", \"assignerShortName\": \"Linux\"}",
      "dataType": "CVE_RECORD",
      "dataVersion": "5.1"
    }
  }
}


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 observed by the user.
  • Confirmed: The vulnerability has been validated from an analyst's perspective.
  • Published Proof of Concept: A public proof of concept is available for this vulnerability.
  • Exploited: The vulnerability was observed as exploited by the user who reported the sighting.
  • Patched: The vulnerability was observed as successfully patched by the user who reported the sighting.
  • Not exploited: The vulnerability was not observed as exploited by the user who reported the sighting.
  • Not confirmed: The user expressed doubt about the validity of the vulnerability.
  • Not patched: The vulnerability was not observed as successfully patched by the user who reported the sighting.


Loading…

Detection rules are retrieved from Rulezet.

Loading…

Loading…