In the Linux kernel, the following vulnerability has been resolved:
scsi: core: ufs: Fix a hang in the error handler
ufshcderrhandlingprepare() calls ufshcdrpmgetsync(). The latter function can only succeed if UFSHCDEHINPROGRESS is not set because resuming involves submitting a SCSI command and ufshcdqueuecommand() returns SCSIMLQUEUEHOSTBUSY if UFSHCDEHINPROGRESS is set. Fix this hang by setting UFSHCDEHINPROGRESS after ufshcdrpmgetsync() has been called instead of before.
Backtrace: _switchto+0x174/0x338 _schedule+0x600/0x9e4 schedule+0x7c/0xe8 scheduletimeout+0xa4/0x1c8 ioscheduletimeout+0x48/0x70 waitforcommonio+0xa8/0x160 //waiting on STARTSTOP waitforcompletioniotimeout+0x10/0x20 blkexecuterq+0xe4/0x1e4 scsiexecutecmd+0x108/0x244 ufshcdsetdevpwrmode+0xe8/0x250 _ufshcdwlresume+0x94/0x354 ufshcdwlruntimeresume+0x3c/0x174 scsiruntimeresume+0x64/0xa4 rpmresume+0x15c/0xa1c _pmruntimeresume+0x4c/0x90 // Runtime resume ongoing ufshcderrhandler+0x1a0/0xd08 processonework+0x174/0x808 workerthread+0x15c/0x490 kthread+0xf4/0x1ec retfrom_fork+0x10/0x20
[ bvanassche: rewrote patch description ]
[ { "signature_type": "Line", "id": "CVE-2025-38119-0631c7bd", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@f592eb12b43f21dbc972cbe583a12d256901e569", "signature_version": "v1", "target": { "file": "drivers/scsi/ufs/ufshcd.c" }, "digest": { "threshold": 0.9, "line_hashes": [ "106334272365448490368008359750677519193", "304240450173938674821020829504319128843", "64244254981855284017121413945996700657", "157243681237966311134121705863701035962", "279580714869526679417750942394418009441", "245992674551933402540718725482120182912" ] }, "deprecated": false }, { "signature_type": "Line", "id": "CVE-2025-38119-0d952bee", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@21f071261f946c5ca1adf378f818082a112b34d2", "signature_version": "v1", "target": { "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "threshold": 0.9, "line_hashes": [ "106334272365448490368008359750677519193", "304240450173938674821020829504319128843", "64244254981855284017121413945996700657", "100987051319098034055335865629556037094", "67482151124172217202469629234972110024", "102272226863145201354553219713234786885" ] }, "deprecated": false }, { "signature_type": "Line", "id": "CVE-2025-38119-337c408d", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3464a707d137efc8aea1d4ae234d26a28d82b78c", "signature_version": "v1", "target": { "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "threshold": 0.9, "line_hashes": [ "106334272365448490368008359750677519193", "304240450173938674821020829504319128843", "64244254981855284017121413945996700657", "100987051319098034055335865629556037094", "67482151124172217202469629234972110024", "102272226863145201354553219713234786885" ] }, "deprecated": false }, { "signature_type": "Line", "id": "CVE-2025-38119-4c47ae97", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@ded80255c59a57cd3270d98461f6508730f9767c", "signature_version": "v1", "target": { "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "threshold": 0.9, "line_hashes": [ "106334272365448490368008359750677519193", "304240450173938674821020829504319128843", "64244254981855284017121413945996700657", "157243681237966311134121705863701035962", "279580714869526679417750942394418009441", "90433016639241996794234101594510592513" ] }, "deprecated": false }, { "signature_type": "Function", "id": "CVE-2025-38119-6775ac4a", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@ded80255c59a57cd3270d98461f6508730f9767c", "signature_version": "v1", "target": { "function": "ufshcd_err_handler", "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "function_hash": "36516350442114105143477204499492290363", "length": 4774.0 }, "deprecated": false }, { "signature_type": "Line", "id": "CVE-2025-38119-6be8fb7c", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8a3514d348de87a9d5e2ac00fbac4faae0b97996", "signature_version": "v1", "target": { "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "threshold": 0.9, "line_hashes": [ "106334272365448490368008359750677519193", "304240450173938674821020829504319128843", "64244254981855284017121413945996700657", "100987051319098034055335865629556037094", "67482151124172217202469629234972110024", "102272226863145201354553219713234786885" ] }, "deprecated": false }, { "signature_type": "Function", "id": "CVE-2025-38119-a06bc59e", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@3464a707d137efc8aea1d4ae234d26a28d82b78c", "signature_version": "v1", "target": { "function": "ufshcd_err_handler", "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "function_hash": "327452825824659109496192083743575573819", "length": 4192.0 }, "deprecated": false }, { "signature_type": "Function", "id": "CVE-2025-38119-b8afa472", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@21f071261f946c5ca1adf378f818082a112b34d2", "signature_version": "v1", "target": { "function": "ufshcd_err_handler", "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "function_hash": "327452825824659109496192083743575573819", "length": 4192.0 }, "deprecated": false }, { "signature_type": "Function", "id": "CVE-2025-38119-bd4e5f37", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@f592eb12b43f21dbc972cbe583a12d256901e569", "signature_version": "v1", "target": { "function": "ufshcd_err_handler", "file": "drivers/scsi/ufs/ufshcd.c" }, "digest": { "function_hash": "160967193301207389018168925620144599715", "length": 3893.0 }, "deprecated": false }, { "signature_type": "Function", "id": "CVE-2025-38119-d4e88655", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@bb37f795d01961286b8f768a6d7152f32b589067", "signature_version": "v1", "target": { "function": "ufshcd_err_handler", "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "function_hash": "327452825824659109496192083743575573819", "length": 4192.0 }, "deprecated": false }, { "signature_type": "Function", "id": "CVE-2025-38119-dc4939f8", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@8a3514d348de87a9d5e2ac00fbac4faae0b97996", "signature_version": "v1", "target": { "function": "ufshcd_err_handler", "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "function_hash": "241996485810926128067210008461174243377", "length": 4196.0 }, "deprecated": false }, { "signature_type": "Line", "id": "CVE-2025-38119-fe664ff8", "source": "https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git@bb37f795d01961286b8f768a6d7152f32b589067", "signature_version": "v1", "target": { "file": "drivers/ufs/core/ufshcd.c" }, "digest": { "threshold": 0.9, "line_hashes": [ "106334272365448490368008359750677519193", "304240450173938674821020829504319128843", "64244254981855284017121413945996700657", "100987051319098034055335865629556037094", "67482151124172217202469629234972110024", "102272226863145201354553219713234786885" ] }, "deprecated": false } ]