Commit 03f0b54
riscv: module: remove relocation_head rel_entry member allocation
relocation_head's list_head member, rel_entry, doesn't need to be
allocated, its storage can just be part of the allocated relocation_head.
Remove the pointer which allows to get rid of the allocation as well as
an existing memory leak found by Kai Zhang using kmemleak.
Fixes: 8fd6c51 ("riscv: Add remaining module relocations")
Reported-by: Kai Zhang <[email protected]>
Signed-off-by: Clément Léger <[email protected]>
Reviewed-by: Andrew Jones <[email protected]>
Reviewed-by: Charlie Jenkins <[email protected]>
Tested-by: Charlie Jenkins <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Palmer Dabbelt <[email protected]>1 parent 498d5b1 commit 03f0b54
1 file changed
+4
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
26 | | - | |
| 26 | + | |
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| |||
634 | 634 | | |
635 | 635 | | |
636 | 636 | | |
637 | | - | |
| 637 | + | |
638 | 638 | | |
639 | 639 | | |
640 | 640 | | |
| |||
704 | 704 | | |
705 | 705 | | |
706 | 706 | | |
707 | | - | |
708 | | - | |
709 | | - | |
710 | | - | |
711 | | - | |
712 | | - | |
713 | | - | |
714 | | - | |
715 | | - | |
716 | | - | |
| 707 | + | |
717 | 708 | | |
718 | 709 | | |
719 | 710 | | |
| |||
722 | 713 | | |
723 | 714 | | |
724 | 715 | | |
725 | | - | |
726 | 716 | | |
727 | 717 | | |
728 | 718 | | |
| |||
735 | 725 | | |
736 | 726 | | |
737 | 727 | | |
738 | | - | |
| 728 | + | |
739 | 729 | | |
740 | 730 | | |
741 | 731 | | |
| |||
0 commit comments