diff options
| author | 2022-04-01 07:46:35 -0400 | |
|---|---|---|
| committer | 2022-04-04 07:33:49 +0200 | |
| commit | 875e957087b5f8624a1fbfe9d9b9647ec7912bd4 (patch) | |
| tree | b18c638a692706797d55412783eaf5b614b62dbf /tools/perf/scripts/python | |
| parent | staging: vc04_services: Convert kmap() to kmap_local_page() (diff) | |
staging: rtl8723bs: simplify control flow
The function iterates an index from 0 to NUM_PMKID_CACHE and returns
the first index for which the condition is true. If no such index is
found, the function returns -1. Current code has a complex control
flow that obfuscates this simple task. Replace it with a loop.
Also, given the shortened function body, replace the long variable
name psecuritypriv with a short variable name p.
Reported by checkpatch:
WARNING: else is not generally useful after a break or return
Reviewed-by: Ira Weiny <ira.weiny@intel.com>
Signed-off-by: Sevinj Aghayeva <sevinj.aghayeva@gmail.com>
Link: https://lore.kernel.org/r/20220401114635.GA567659@euclid
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions
