Commit ed1a1fe6 authored by Chenghao Duan's avatar Chenghao Duan Committed by Huacai Chen
Browse files

LoongArch: BPF: Rename and refactor validate_code()



1. Rename the existing validate_code() to validate_ctx()
2. Factor out the code validation handling into a new helper
   validate_code()

Then:

* validate_code() is used to check the validity of code.
* validate_ctx() is used to check both code validity and table entry
  correctness.

The new validate_code() will be used in subsequent changes.

Reviewed-by: default avatarHengqi Chen <hengqi.chen@gmail.com>
Co-developed-by: default avatarGeorge Guo <guodongtai@kylinos.cn>
Signed-off-by: default avatarGeorge Guo <guodongtai@kylinos.cn>
Signed-off-by: default avatarChenghao Duan <duanchenghao@kylinos.cn>
Signed-off-by: default avatarHuacai Chen <chenhuacai@loongson.cn>
parent 6ab55e0a
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment