btf_encoder: Move the global btf_encoder to its users, like pahole
Tools should instantiate it using btf_encoder__new(), etc, ditch the library global. Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
This commit is contained in:
parent
fa849010b4
commit
46a3e3a87a
|
@ -269,8 +269,6 @@ static int btf_encoder__encode_tag(struct btf_encoder *encoder, struct cu *cu, s
|
|||
}
|
||||
}
|
||||
|
||||
struct btf_encoder *encoder;
|
||||
|
||||
static int btf__encode_as_raw_file(struct btf *btf, const char *filename)
|
||||
{
|
||||
uint32_t raw_btf_size;
|
||||
|
|
|
@ -53,8 +53,6 @@ struct btf_encoder {
|
|||
|
||||
extern bool btf_encoder__verbose;
|
||||
|
||||
extern struct btf_encoder *encoder;
|
||||
|
||||
struct btf_encoder *btf_encoder__new(struct cu *cu, struct btf *base_btf, bool skip_encoding_vars, bool force, bool verbose);
|
||||
void btf_encoder__delete(struct btf_encoder *encoder);
|
||||
|
||||
|
|
Loading…
Reference in New Issue