Linux - KernelThis forum is for all discussion relating to the Linux kernel.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
well,the linux kernel's 0.01 version.
under the dirctory /include/linux/fs.h
well,see,there's some code about struct .
struct d_inode {
84 unsigned short i_mode;
85 unsigned short i_uid;
86 unsigned long i_size;
87 unsigned long i_time;
88 unsigned char i_gid;
89 unsigned char i_nlinks;
90 unsigned short i_zone[9];
91 };
92
93 struct m_inode {
94 unsigned short i_mode;
95 unsigned short i_uid;
96 unsigned long i_size;
97 unsigned long i_mtime;
98 unsigned char i_gid;
99 unsigned char i_nlinks;
100 unsigned short i_zone[9];
101 /* these are in memory also */
102 struct task_struct * i_wait;
103 unsigned long i_atime;
104 unsigned long i_ctime;
105 unsigned short i_dev;
106 unsigned short i_num;
107 unsigned short i_count;
108 unsigned char i_lock;
109 unsigned char i_dirt;
110 unsigned char i_pipe;
111 unsigned char i_mount;
112 unsigned char i_seek;
113 unsigned char i_update;
114 };
anyone could tell me what does the m_inode and d_inode stand for?
I mean,what they are about ? I got confused about this.
for one,I guess that the d_inode stand for the directory and the m_inode stand for the module or m_indode is something that will stored into the memory .I do not know. any one could help me ?
thank you so much......
In many cases, you will find "disk" versions of a structure and "memory" versions of the same structure. One is designed to save space (or to be backward-compatible); the other is designed to be convenient to process during the moment-to-moment operations of the system. I expect, although I am not sure, that this might be what you are dealing with here.
wha.... ,got it.
thank you .
but,I have another question,you mean save memory space here by you said "save space"?
well,I think I have another more questions now.
but,thank you .~_~!!!!
wha.... ,got it.
thank you .
but,I have another question,you mean save memory space here by you said "save space"?
well,I think I have another more questions now.
but,thank you .~_~!!!!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.