mirror of
https://github.com/dynup/kpatch
synced 2025-02-16 17:57:02 +00:00
fix review comments
This commit is contained in:
parent
6b45c5dbd0
commit
9d016add40
@ -53,7 +53,7 @@ struct kpatch_dynrela {
|
||||
unsigned long type;
|
||||
const char *name;
|
||||
int addend;
|
||||
bool exported;
|
||||
int exported;
|
||||
struct list_head list;
|
||||
};
|
||||
|
||||
|
@ -19,9 +19,8 @@
|
||||
* Contains the structs used for the patch module special sections
|
||||
*/
|
||||
|
||||
#ifndef __KERNEL__
|
||||
#include <stdbool.h>
|
||||
#endif
|
||||
#ifndef _KPATCH_PATCH_H_
|
||||
#define _KPATCH_PATCH_H_
|
||||
|
||||
struct kpatch_patch_func {
|
||||
unsigned long new_addr;
|
||||
@ -38,6 +37,8 @@ struct kpatch_patch_dynrela {
|
||||
unsigned long type;
|
||||
char *name;
|
||||
char *objname;
|
||||
bool exported;
|
||||
int exported;
|
||||
int addend;
|
||||
};
|
||||
|
||||
#endif /* _KPATCH_PATCH_H_ */
|
||||
|
@ -1654,7 +1654,7 @@ void kpatch_create_dynamic_rela_sections(struct kpatch_elf *kelf,
|
||||
struct symbol *strsym;
|
||||
struct lookup_result result;
|
||||
struct kpatch_patch_dynrela *dynrelas;
|
||||
bool vmlinux, exported;
|
||||
int vmlinux, exported;
|
||||
|
||||
vmlinux = !strcmp(objname, "vmlinux");
|
||||
|
||||
@ -1730,7 +1730,7 @@ void kpatch_create_dynamic_rela_sections(struct kpatch_elf *kelf,
|
||||
if (rela->sym->sec)
|
||||
continue;
|
||||
|
||||
exported = false;
|
||||
exported = 0;
|
||||
|
||||
if (rela->sym->bind == STB_LOCAL) {
|
||||
/* An unchanged local symbol */
|
||||
@ -1764,7 +1764,7 @@ void kpatch_create_dynamic_rela_sections(struct kpatch_elf *kelf,
|
||||
* Not there, assume it's exported by
|
||||
* another object.
|
||||
*/
|
||||
exported = true;
|
||||
exported = 1;
|
||||
}
|
||||
log_debug("lookup for %s @ 0x%016lx len %lu\n",
|
||||
rela->sym->name, result.value, result.size);
|
||||
|
Loading…
Reference in New Issue
Block a user