Re: [Netnice-kernels] Linux NNFS API nearing completion
Status: Alpha
Brought to you by:
taost6
From: Takashi O. <ta...@cs...> - 2004-10-28 19:22:50
|
hi scott, i just simply listed what i found and did not find in the version. that might have been inappropriate, considering your previous messages... anyway. it seems like you have already fixed most of the problems. my comments follow. Scott Brumbaugh wrote: > > In summary, I added the rmdir and follow_link opperations. > > On Thu, 28 Oct 2004, Takashi Okumura wrote: > > > hi scott, > > > > - Directory: /nnfs/procs/[pid] > > This I would offer to change in the future. okay. > > - Directory: /nnfs/procs/[pid]/* > > > > this issue is not serious, but, you will add other control files, right? > > since priority of this part is low, we may skip this part, for now, also. > > > > Also, this I did not change as I _think_ all the required control files > are under Linux /proc. regarding the process-dependent directories, it is totally okay with me to leave them, as is, for now. this is because they are not required for VIF functionality, as you said. but, if time permits, we may have "cmdline" and "status", in the future, so that libnetnice may operate on such information. > > - Directory: /nnfs/procs/[pid]/*/sockets/ > > > > cann't we cd to the link? > > > > $ cd lo > > lo: Not a directory > > $ > > > > I fixed this. I have added the follow_link operation to the > per-process and per-socket vif symlinks so now you can do this: > > [root@tamarack root]# mkdir /nnfs/network/lo/vif1 > [root@tamarack root]# cd /nnfs/procs/1911/sockets/3/lo/vif1/ > [root@tamarack vif1]# ls > bandwidth drops filter port recv send type weight > [root@tamarack vif1]# pwd > /nnfs/procs/1911/sockets/3/lo/vif1 > [root@tamarack vif1]# thanks. it is interesting that output of pwd is a bit differs from FreeBSD'pwd. in this case, FreeBSD will show $ cd /nnfs/procs/1911/sockets/3/ $ ls lo eth1 $ cd lo $ pwd /nnfs/network/lo/vif1 anyway. your operation (follow_link?) also looks fine. this is okay. thanks. > > - Directory: /nnfs/network/lo > > > > i tried parameter setting under lo directory. is this expected behavior? > > i felt it is not, though i also felt it is easy to fix. > > > > $ cat type > > Non Work Conserving > > > > $ echo 1 > type; cat type > > Block > > > > I believe this happens due to how 'echo' works on Linux. This will > also happen on FreeBSD if the value 1 is passed to the os as '1\n' > Here, echo is adding a '\n' character to the string. By using 'echo > -n' the correct value is parsed: interesting. thanks for the clarification. > > - Directory: /nnfs/network/lo > > > > mkdir of VIF dir: OK > > rmdir of VIF dir: NG? > > directory not empty error. > > > > I have fixed this. I have added a stubbed out rmdir operation that > allows you to do rm -r on a created vif. However, remember that the > vif is not removed internally, the directory is just removed from the > filesystem: i understand this (we need to fix vif removal code in vif_*.c). but, i have one question. > [root@tamarack lo]# pwd > /nnfs/network/lo > [root@tamarack lo]# mkdir vif1 > [root@tamarack lo]# ls vif1/ > bandwidth drops filter port recv send type weight > [root@tamarack lo]# rmdir vif1/ > rmdir: `vif1/': Directory not empty > [root@tamarack lo]# rm -ri vif1/ > rm: descend into directory `vif1/'? y > rm: remove regular empty file `vif1//filter'? y > rm: remove regular empty file `vif1//port'? y > rm: remove regular empty file `vif1//drops'? y > rm: remove regular empty file `vif1//send'? y > rm: remove regular empty file `vif1//recv'? y > rm: remove regular empty file `vif1//weight'? y > rm: remove regular empty file `vif1//bandwidth'? y > rm: remove regular empty file `vif1//type'? y > rm: remove directory `vif1/'? y > [root@tamarack lo]# this operation suggests that we can remove the files under vif1, right? which does not make sense to me, since we cannot remove such properties from a VIF. on FreeBSD, we implemented that rmdir can simply remove the entire VIF directory. exception is that, if the VIF has a child VIF. is is hard to implement that way on linux?? > > - Kernel build > > > > can we merge CONFIG_NNFS and CONFIG_NETNICE? > > or, do you think we may leave them, for now? > > on FreeBSD, we merged the options. > > what do you recommend? > > > > This I can do in the future. okay. i understand the statement you wrote in the other message. > > - net/core/vif_subr.c > > > > we completely rewritten vif_rm(). we'll need to fix this, > > based on net/vif_suvr.c of FreeBSD5.3. > > > > This I can do in the future. that is fine. thanks!! -- taka |