Commit b5c2161c authored by Adrian Hunter's avatar Adrian Hunter Committed by Arnaldo Carvalho de Melo

perf dso: Export data_file_size() method there are no symbols

Will be used outside dso.c in a followup patch, so rename it and make it
non-static.
Signed-off-by: default avatarAdrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@redhat.com>
Link: http://lkml.kernel.org/r/20181127084634.12469-1-adrian.hunter@intel.com
[ split from a larger patch ]
Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
parent ca46afdb
......@@ -894,7 +894,7 @@ static ssize_t cached_read(struct dso *dso, struct machine *machine,
return r;
}
static int data_file_size(struct dso *dso, struct machine *machine)
int dso__data_file_size(struct dso *dso, struct machine *machine)
{
int ret = 0;
struct stat st;
......@@ -943,7 +943,7 @@ static int data_file_size(struct dso *dso, struct machine *machine)
*/
off_t dso__data_size(struct dso *dso, struct machine *machine)
{
if (data_file_size(dso, machine))
if (dso__data_file_size(dso, machine))
return -1;
/* For now just estimate dso data size is close to file size */
......@@ -953,7 +953,7 @@ off_t dso__data_size(struct dso *dso, struct machine *machine)
static ssize_t data_read_offset(struct dso *dso, struct machine *machine,
u64 offset, u8 *data, ssize_t size)
{
if (data_file_size(dso, machine))
if (dso__data_file_size(dso, machine))
return -1;
/* Check the offset sanity. */
......
......@@ -322,6 +322,7 @@ int dso__data_get_fd(struct dso *dso, struct machine *machine);
void dso__data_put_fd(struct dso *dso);
void dso__data_close(struct dso *dso);
int dso__data_file_size(struct dso *dso, struct machine *machine);
off_t dso__data_size(struct dso *dso, struct machine *machine);
ssize_t dso__data_read_offset(struct dso *dso, struct machine *machine,
u64 offset, u8 *data, ssize_t size);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment