perf tools: Fix incorrect fd error comparison
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest1 of 2 patches 1 replyIn review
1 of 2 patches is in this archive. The cover letter announces 2.
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | perf tools: Fix incorrect fd error comparisontools/ | +1 | 1 reply |
Reviews trailers per patch
The patch has a Reviewed-by or Acked-by.
| Patch | Jiri Olsa |
|---|---|
| 1/2 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/2] perf tools: Fix incorrect fd error comparison
Quoted 10 lines · Adrian Hunter
Quoted 8 lines
Add '
data_status' to record whether a dso has data (i.e. an object file) as follows:dso->data_status meaning ---------------------------------- 0 don't know -1 no data 1 has dataplease add enum for this
Ok
Quoted 17 lines
Quoted 17 lines
Signed-off-by Adrian Hunter <[email protected]>--- tools/perf/util/dso.c | 5 ++++- tools/perf/util/dso.h | 1 + 2 files changed, 5 insertions(+), 1 deletion(-)tools/perf/util/dso.c +0
-1@@ -556,8 +556,11 @@ static ssize_t data_read_offset(struct dso *dso, u64 offset,ssize_t dso__data_read_offset (struct dso *dso,struct machine *machine,u64 offset,u8 *data,ssize_t size) { -if (dso__data_fd (dso, machine) <0 )
Quoted 8 lines
tools/perf/util/dso.c static ssize_t data_read_offset(struct dso *dso, u64 offset, · line 563
Quoted 5 lines
tools/perf/util/dso.c +4
-0+if (dso__data_fd (dso, machine) <0 ) { + dso->data.data_status =-1 ;return -1 ; + } + dso->data.data_status =1 ;we have more callers to
dso__data_fd, so I think we want to setupdso->data.data_statuswithindso__data_fd
Ok. Here are 2 patches because I noticed another thing.
Adrian Hunter (2):
perf tools: Fix incorrect fd error comparison perf tools: Record whether a dso has data
tools/perf/util/dso.c | 27 +++++++++++++++++---------- tools/perf/util/dso.h | 7 +++++++ 2 files changed, 24 insertions(+), 10 deletions(-)