Re: [RFC PATCH 12/15] Remove unused find_mod_etext() in store_module_symbols_v3()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2023/05/29 21:34, lijiang wrote:
> On Thu, May 11, 2023 at 12:35 PM HAGIO KAZUHITO(萩尾 一仁) <k-hagio-ab@xxxxxxx>
> wrote:
> 
>> Signed-off-by: Kazuhito Hagio <k-hagio-ab@xxxxxxx>
>> ---
>>   symbols.c | 4 +---
>>   1 file changed, 1 insertion(+), 3 deletions(-)
>>
>> diff --git a/symbols.c b/symbols.c
>> index ba9cf607f256..9714453400bf 100644
>> --- a/symbols.c
>> +++ b/symbols.c
>> @@ -2049,6 +2049,7 @@ store_module_symbols_v3(ulong total, int
>> mods_installed)
>>                  lm->mod_ext_symcnt = mcnt;
>>
>>                  lm->mod_text_start = lm->mod_base;
>> +               /* not used */
>>                  lm->mod_etext_guess = lm->mod_base +
>> lm->mem[MOD_TEXT].size;
>>
> 
> If this is not used, can we set it to an invalid value such as -1(ulong->
> 0xffffffff)? Otherwise we can still see a valid value by "help -s" command.

Agree to set an invalid value, but I would like 0.  -1 hits this:

                 fprintf(fp, "       mod_etext_guess: %lx (%lx)\n",
                         lm->mod_etext_guess,
                         lm->mod_etext_guess ?
                         lm->mod_etext_guess - lm->mod_base : 0);

Thanks,
Kazu

> 
> Thanks.
> Lianbo
> 
> 
>>                  lm->mod_init_module_ptr = lm->mem[MOD_INIT_TEXT].base;
>> @@ -2250,9 +2251,6 @@ store_module_symbols_v3(ulong total, int
>> mods_installed)
>>
>>                  lm->mod_ext_symcnt = mcnt - lm->mod_ext_symcnt;
>>
>> -               if (!lm->mod_etext_guess)
>> -                       find_mod_etext(lm);
>> -
>>                  NEXT_MODULE(mod_next, modbuf);
> 
>          }
>>
>> --
>> 2.31.1
>>
>>
--
Crash-utility mailing list
Crash-utility@xxxxxxxxxx
https://listman.redhat.com/mailman/listinfo/crash-utility
Contribution Guidelines: https://github.com/crash-utility/crash/wiki




[Index of Archives]     [Fedora Development]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [KDE Users]     [Fedora Tools]

 

Powered by Linux