[Crash-utility] Re: [PATCH v3] add "files -n" command for an inode

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

 



On 2023/11/03 18:45, Shijie Huang wrote:

>> +summary_inode_page(ulong page)
>> +{
>> +       int node;
>> +
>> +       if (!is_page_ptr(page, NULL))
>> +               error(FATAL, "Invalid inode page(0x%lx)\n", page);

I don't remember the detail of xarray, but my cacheutils extension 
module also checks this without any error, in its callback function [1]. 
So how about implementing like this?

	if (!is_page_ptr(slot, &phys))
		return FALSE;

[1] https://github.com/k-hagio/crash-cacheutils/blob/master/cacheutils.c#L98

Also, I could reproduc it and actually they can be ignored because the 
inode's nrpages equals to the number of pages in the nodes:

crash> files -n ffff9c50cbe59920
      INODE        NRPAGES
ffff9c50cbe59920       96  <<<

files: page_to_nid: invalid page: afe27
files: page_to_nid: invalid page: b35db
files: page_to_nid: invalid page: b35df
...
files: page_to_nid: invalid page: 24ced
      NODE           PAGES
       0                96  <<<

Thanks,
Kazu
--
Crash-utility mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxxxxxx
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s
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