summaryrefslogtreecommitdiff
path: root/tools/perf/scripts/python/flamegraph.py
diff options
context:
space:
mode:
authorThorsten Blum <thorsten.blum@linux.dev>2026-05-28 22:12:27 +0200
committerMadhavan Srinivasan <maddy@linux.ibm.com>2026-07-31 17:01:19 +0530
commitc7b7cea42cd4977f95ce520400c9740712b909a2 (patch)
tree1d7c90cf8076104c0345ae8820b3490136b6c712 /tools/perf/scripts/python/flamegraph.py
parent73dca15a3b813048b01e9c06c260c6508088c2ff (diff)
powerpc: rtas: use get_user to simplify manage_flash_write
Drop the local 10-byte buffer. The old code copied at most 9 bytes from the user buffer, but only the first byte was used to select the RTAS operation. Use get_user() to read the command byte instead and compare it directly with '0' and '1'. Drop the explicit user buffer check, since get_user() will fail on a NULL pointer and correctly return -EFAULT instead of -EINVAL. Remove the now-obsolete string constants as well as any strncmp() and strlen() calls. Return the original count instead of a potentially capped value, since the full user write has been consumed once the command is accepted. Use unsigned int op to better match the manage_flash() interface. Signed-off-by: Thorsten Blum <thorsten.blum@linux.dev> Signed-off-by: Madhavan Srinivasan <maddy@linux.ibm.com> Link: https://patch.msgid.link/20260528201226.1599977-3-thorsten.blum@linux.dev
Diffstat (limited to 'tools/perf/scripts/python/flamegraph.py')
0 files changed, 0 insertions, 0 deletions