diff options
| author | Li Qiang <liqiang01@kylinos.cn> | 2026-07-17 23:39:13 +0800 |
|---|---|---|
| committer | Martin K. Petersen <martin.petersen@oracle.com> | 2026-07-26 15:51:54 -0400 |
| commit | abd26e6b53c4169122d61fdd4cabe09bdd916aac (patch) | |
| tree | af39ece9985846361de2e34904695a19176104e0 /tools/perf/scripts/python/bin/stackcollapse-record | |
| parent | 2f434f815ee2e051f9ccadfbe5db531e6fbe34ad (diff) | |
scsi: ufs: debugfs: Reserve space for a string terminator
ufs_saved_err_write() copies user input into a zero-initialized stack
buffer and passes it to kstrtoint(). A write that fills the entire buffer
overwrites its only terminator.
Reject an input whose length leaves no room for the trailing NUL.
Fixes: 7340faae9474 ("scsi: ufs: core: Add debugfs attributes for triggering the UFS EH")
Signed-off-by: Li Qiang <liqiang01@kylinos.cn>
Reviewed-by: Bart Van Assche <bvanassche@acm.org>
Reviewed-by: Peter Wang <peter.wang@mediatek.com>
Link: https://patch.msgid.link/20260717153914.26321-7-liqiang01@kylinos.cn
Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com>
Diffstat (limited to 'tools/perf/scripts/python/bin/stackcollapse-record')
0 files changed, 0 insertions, 0 deletions
