diff options
author | Thiago Jung Bauermann <bauerman@linux.vnet.ibm.com> | 2017-06-29 23:55:36 +0200 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2017-07-02 12:40:32 +0200 |
commit | ebd4a5a3ebd9c7bef105e8581f80ae4592a21e6d (patch) | |
tree | ceedfa99f750e3a0088f788808e6e467fbad629e /arch/powerpc/perf/hv-24x7.h | |
parent | powerpc/perf/hv-24x7: Fix return value of hcalls (diff) | |
download | linux-ebd4a5a3ebd9c7bef105e8581f80ae4592a21e6d.tar.xz linux-ebd4a5a3ebd9c7bef105e8581f80ae4592a21e6d.zip |
powerpc/perf/hv-24x7: Minor improvements
There's an H24x7_DATA_BUFFER_SIZE constant, so use it in init_24x7_request.
There's also an HV_PERF_DOMAIN_MAX constant, so use it in
h_24x7_event_init. This makes the comment above the check redundant,
so remove it.
In add_event_to_24x7_request, a statement is terminated with a comma
instead of a semicolon. Fix it.
In hv-24x7.h, improve comments in struct hv_24x7_result.
Signed-off-by: Thiago Jung Bauermann <bauerman@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Diffstat (limited to 'arch/powerpc/perf/hv-24x7.h')
-rw-r--r-- | arch/powerpc/perf/hv-24x7.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/arch/powerpc/perf/hv-24x7.h b/arch/powerpc/perf/hv-24x7.h index 634ef4082cdc..b95909400b2a 100644 --- a/arch/powerpc/perf/hv-24x7.h +++ b/arch/powerpc/perf/hv-24x7.h @@ -71,6 +71,10 @@ struct hv_24x7_result_element { } __packed; struct hv_24x7_result { + /* + * The index of the 24x7 Request Structure in the 24x7 Request Buffer + * used to request this result. + */ __u8 result_ix; /* @@ -81,7 +85,12 @@ struct hv_24x7_result { __u8 results_complete; __be16 num_elements_returned; - /* This is a copy of @data_size from the corresponding hv_24x7_request */ + /* + * This is a copy of @data_size from the corresponding hv_24x7_request + * + * Warning: to obtain the size of each element in @elements you have + * to add the size of the other members of the result_element struct. + */ __be16 result_element_data_size; __u8 reserved[0x2]; |