From: Michal J. <mi...@ha...> - 2004-07-07 22:49:32
|
I believe that I run into another typo in bproc-4.0.0pre5. In dcache.h there is the following definition: struct qstr { unsigned int hash; const unsigned char *name; unsigned int len; }; Initializations in kernel/bpfs.c attempt to assign a pointer to a string to 'hash'. Therefore it seems to me that the following was really intended: --- bproc-4.0.0pre5/kernel/bpfs.c~ 2004-05-14 13:42:39.000000000 -0600 +++ bproc-4.0.0pre5/kernel/bpfs.c 2004-07-07 16:23:56.007513784 -0600 @@ -1315,7 +1315,7 @@ * "bproc:" much like the socketfs or pipefs. This will get * ignored for other opens in a mounted bpfs file system since * those will be mounted on top of something else. */ - sb->s_root = d_alloc(NULL, &(const struct qstr) { "bproc:", 6, 0 }); + sb->s_root = d_alloc(NULL, &(const struct qstr) { 0, "bproc:", 6}); if (!sb->s_root) { iput(root_inode); return -ENOMEM; @@ -1525,7 +1525,7 @@ struct dentry *get_dentry(struct vfsmount *mount, struct inode *inode, char *name_) { struct dentry *parent, *dentry; - struct qstr name = {name_, strlen(name_), 0}; /* screw the hash... */ + struct qstr name = {0, name_, strlen(name_)}; /* screw the hash... */ parent = mount->mnt_root; Michal |