inconsistency in using vn_fullpath1()
hi I noticed that kern___getcwd() calls vn_fullpath1() with Giant held like this: mtx_lock(&Giant); FILEDESC_LOCK(fdp); error = vn_fullpath1(td, fdp->fd_cdir, fdp->fd_rdir, tmpbuf, &bp, buflen); FILEDESC_UNLOCK(fdp); mtx_unlock(&Giant); on the other hand vn_fullpath() calls it without Giant held like this: FILEDESC_LOCK(fdp); error = vn_fullpath1(td, vn, fdp->fd_rdir, buf, retbuf, MAXPATHLEN); FILEDESC_UNLOCK(fdp); I dont see much difference in the callings so I wonder if holding Giant is necessary when calling vn_fullpath1(). Because we either - do one unecessary locking operation or unsufficiently lock it. thnx for explaining to me and possibly fixing it. roman ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Are there any known issues for installing FreeBSD on Vmware onwindows XP ?
Hi Greg, I am facing with some issues in getting FreeBSD installed on my machine. I am using Vmware workstation version 5. I am using an evaluation version of it. I downloaded the FreeBSD Release 6.2 from freebsd.org. I downloaded all the 3 ISO images. cd1 , cd2 and docs . I did not write these images on the CD but i mounted them directly on the CD drive of Vmware. I had selected OS Type as Other/FreeBSD at the time of installation. My basic installation got over properly and smoothly without any pains. But, i faced an error when i selected some packages for installation and kde from the packages list. It said 'Could not load package libiconv-1.9.2_2 and gettext... etc'. What could be the issue here? Also what mode should i select when installing the network adapter. Which one should i select. lance/Slip/ppp ? I am using DSL cable internet modem internet connection and the modem is connected to my computer using an ethernet. Further, after installation how should i ensure that all the required kernel sources are installed? Is there any way by which i can install a specific package from from CD and let the OS determine and install all the dependencies automatically? Is there any command for this like we have apt-get in debian? Thanks, Ajay. On 3/2/07, Greg Larkin <[EMAIL PROTECTED]> wrote: > > Hey all, > > Are there any known issues for installing FreeBSD on Vmware > on windows XP ? > I have never tried installiing FreeBSD earlier and i just saw > a mail in this > mailing list regarding some problems while installing on > vmware. Could not > make out much. Can someone just elaborate on the issues faced while > installing on Vmware. > > Regards, > ajay. Hi Ajay, I wrote in to the list a little while back about VMware installation problems that I had with FreeBSD 6.2, but the issue was completely related to the CPU architecture (Via C3 Nehemiah) that I was using. VMware doesn't officially support that processor, even though it's supposed to be Intel compatible. Another list member sent me a kernel patch that fixed the problem (thanks ghozzy). I also have a WinXP box with a Celeron processor in it and VMware Server installed, and FreeBSD 4.x and 6.x both install and run with no problems at all. If you have any specific questions, let me know and I'll try to answer them. I'm going to be learning a lot more about VMware Server and FreeBSD in the coming months, as I'm working on redeploying my company's service using those tools as the foundation. I hope to share that knowledge with the list as I proceed. I also found this thread (http://lists.freebsd.org/pipermail/freebsd-questions/2006-October/132 716.html) with some information in it about issues to be aware of while running FreeBSD as a guest OS under VMware. Follow the thread a little way, and you'll see an example kernel config file, too. Best of luck, Greg Larkin ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: inconsistency in using vn_fullpath1()
On Sun, 4 Mar 2007, Divacky Roman wrote: I noticed that kern___getcwd() calls vn_fullpath1() with Giant held like this: mtx_lock(&Giant); FILEDESC_LOCK(fdp); error = vn_fullpath1(td, fdp->fd_cdir, fdp->fd_rdir, tmpbuf, &bp, buflen); FILEDESC_UNLOCK(fdp); mtx_unlock(&Giant); on the other hand vn_fullpath() calls it without Giant held like this: FILEDESC_LOCK(fdp); error = vn_fullpath1(td, vn, fdp->fd_rdir, buf, retbuf, MAXPATHLEN); FILEDESC_UNLOCK(fdp); I dont see much difference in the callings so I wonder if holding Giant is necessary when calling vn_fullpath1(). Because we either - do one unecessary locking operation or unsufficiently lock it. thnx for explaining to me and possibly fixing it. I suspect that the Giant acquisition there is a conservative acquisition based on VFS not having been MPSAFE, and can be removed. Robert N M Watson Computer Laboratory University of Cambridge ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Are there any known issues for installing FreeBSD on Vmware onwindows XP ?
Further, after installation how should i ensure that all the required kernel sources are installed? You want the sources to the complete system, not just the "kernel", and you would want to keep these upto-date too. See: http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/synching.html and, http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/cvsup.html Is there any way by which i can install a specific package from from CD and let the OS determine and install all the dependencies automatically? Is there any command for this like we have apt-get in debian? 'pkg_add' should be installing dependencies automatically. -- FreeBSD Volunteer, http://people.freebsd.org/~jkoshy ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
investigation of Giant usage in kernel
hi I looked at where Giant is held in the kernel and I found these interesting things: 1) in fs/fifofs/fifo_vnops.c we lock Giant when calling sorecieve()/sosend() this is a bandaid for fixing a race that doesnt have to exist anymore. ie. it needs some testing and can be remvoed 2) in geom/geom_dev.c we lock Giant for: 2a) calling make_dev() which seems unecessary because make_dev protects itself with devmtx 2b) setting a flag in cdev which I think is unecessary as well 3) in kern/kern_descrip.c we lock Giant for the whole life of flock() I dont see a need for this protection becuase 3a) access to fp is protected with FILE_LOCK()ing 3b) otherwise it operates on local variables 3c) it also calls VOP_* functions but those dont require Giant, right? 4) in kern/kern_lockf.c we lock Giant for the whole life of lf_advlock() I dont think this is necessary because 4a) it operates on local variables 4b) it calls various lf_*lock() functions which seems to either protect themselves or not needed protection at all 5) in kern/kern_time.c we lock Giant to protect 5a) tc_setclock() call - I dont know if this is necessary or not 5b) lease_updatetime call which is a function pointer that seems to be only assigned at one place (line 119 in kern_time.c) to a NOP function. can this be removed? 6) in vm/device_pager.c we lock Giant to (also) protect cdevsw->d_mmap but the device mmap is either MPSAFE or assigned to giant_mmap (a wrapper that locks GIant and calls the original d_mmap) so this seems unecessary. These are just my impressions on the code and I'd like to hear some comments if its correct and if its I'd like to see some fixes. thnx roman ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Are there any known issues for installing FreeBSD on Vmware onwindows XP ?
ajay gopalakrishnan skrev: Hi Greg, I am facing with some issues in getting FreeBSD installed on my machine. I am using Vmware workstation version 5. I am using an evaluation version of it. I downloaded the FreeBSD Release 6.2 from freebsd.org. I downloaded all the 3 ISO images. cd1 , cd2 and docs . I did not write these images on the CD but i mounted them directly on the CD drive of Vmware. I had selected OS Type as Other/FreeBSD at the time of installation. My basic installation got over properly and smoothly without any pains. But, i faced an error when i selected some packages for installation and kde from the packages list. It said 'Could not load package libiconv-1.9.2_2 and gettext... etc'. What could be the issue here? Also what mode should i select when installing the network adapter. Which one should i select. lance/Slip/ppp ? I am using DSL cable internet modem internet connection and the modem is connected to my computer using an ethernet. I set the nics to bridge when I ran this way. Further, after installation how should i ensure that all the required kernel sources are installed? This is only necessary if you want to build a kernel of your own. If you are satisfied with the kernel shipped with the cds (called GENERIC) there is no need. The handbook at www.freebsd.org is a very good starting point and answers many questions. Is there any way by which i can install a specific package from from CD and let the OS determine and install all the dependencies automatically? Is there any command for this like we have apt-get in debian? Yes, this is done automagically when you either add the binary package or when you do make install clean in the source code for it. Again, the handbook answers all this. Thanks, Ajay. On 3/2/07, Greg Larkin <[EMAIL PROTECTED]> wrote: > > Hey all, > > Are there any known issues for installing FreeBSD on Vmware > on windows XP ? > I have never tried installiing FreeBSD earlier and i just saw > a mail in this > mailing list regarding some problems while installing on > vmware. Could not > make out much. Can someone just elaborate on the issues faced while > installing on Vmware. > > Regards, > ajay. Hi Ajay, I wrote in to the list a little while back about VMware installation problems that I had with FreeBSD 6.2, but the issue was completely related to the CPU architecture (Via C3 Nehemiah) that I was using. VMware doesn't officially support that processor, even though it's supposed to be Intel compatible. Another list member sent me a kernel patch that fixed the problem (thanks ghozzy). I also have a WinXP box with a Celeron processor in it and VMware Server installed, and FreeBSD 4.x and 6.x both install and run with no problems at all. If you have any specific questions, let me know and I'll try to answer them. I'm going to be learning a lot more about VMware Server and FreeBSD in the coming months, as I'm working on redeploying my company's service using those tools as the foundation. I hope to share that knowledge with the list as I proceed. I also found this thread (http://lists.freebsd.org/pipermail/freebsd-questions/2006-October/132 716.html) with some information in it about issues to be aware of while running FreeBSD as a guest OS under VMware. Follow the thread a little way, and you'll see an example kernel config file, too. Best of luck, Greg Larkin ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]" ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: investigation of Giant usage in kernel
Hello, I took a grep on the kernel source and took a look to Giant usage as well. I too have a question about locking in uipc_domain.c: The file has a mutex, dom_mtx, which protects the 'domain list lock', which could be declared static by the way. The strange thing is that it isn't used to lock the domain list lock in any way. It is only used to lock the domain_init_status variable. Wouldn't it be better to rename it to something better? The pf_proto_register() routine locks and unlocks Giant. It looks like s/Giant/dom_mtx/ would be enough to remove the usage of Giant from uipc_domain.c. Yours, -- Ed Schouten <[EMAIL PROTECTED]> WWW: http://g-rave.nl/ pgpLjozkLVRJf.pgp Description: PGP signature
Keyboard not working except "Enter" Key and getting monochrome color with Vmware on HP Pavillio dv6000 series notebook
Hi, I'm trying to install FreeBSD on Vmware on windows XP Media Center Edition on my notebook HP Pavillion dv6000 series. The installation is proper. Everything gets installed perfectly. KDE starts also but the resolution is not OK. I'm not getting a colored output for KDE. everything is black and white. Keyboard does not work except the "Enter" Key. Mouse Works properly. I have a NVidia GForce Go 7400 Graphics card with 256MB memory. My settings on Windows XP currently are 1280x800 and color quality is highest 32bit and refresh rate is 60Hz. I had ran xorgconfig and xorgcfg. But, here i am not able to find any keyboard looks like the layout of my notebook keyboard layout. The closest match would be the Winbook and the IBM Thinkpad series. I had selected the color to highest possible value 24bit (16 million colors). I dont know the HSync and VSync values of my notebook since the manual of the notebook doesnt have these values. I had performed the same installation procedures on my desktop machine which is a DELL Optiplex. It is working perfectly there. So i think that my xorgconfig is wrong. Thanks in advance, Ajay. On 3/4/07, Roger Olofsson <[EMAIL PROTECTED]> wrote: ajay gopalakrishnan skrev: > Hi Greg, > > I am facing with some issues in getting FreeBSD installed on my machine. > I am using Vmware workstation version 5. I am using an evaluation > version of > it. > I downloaded the FreeBSD Release 6.2 from freebsd.org. > I downloaded all the 3 ISO images. cd1 , cd2 and docs . > I did not write these images on the CD but i mounted them directly on > the CD > drive of Vmware. > > I had selected OS Type as Other/FreeBSD at the time of installation. > My basic installation got over properly and smoothly without any pains. > But, i faced an error when i selected some packages for installation and > kde > from the packages list. It said 'Could not load package libiconv-1.9.2_2 > and > gettext... etc'. What could be the issue here? > > Also what mode should i select when installing the network adapter. Which > one should i select. lance/Slip/ppp ? I am using DSL cable internet modem > internet connection and the modem is connected to my computer using an > ethernet. > I set the nics to bridge when I ran this way. > Further, after installation how should i ensure that all the required > kernel > sources are installed? > This is only necessary if you want to build a kernel of your own. If you are satisfied with the kernel shipped with the cds (called GENERIC) there is no need. The handbook at www.freebsd.org is a very good starting point and answers many questions. > Is there any way by which i can install a specific package from from CD and > let the OS determine and install all the dependencies automatically? Is > there any command for this like we have apt-get in debian? > Yes, this is done automagically when you either add the binary package or when you do make install clean in the source code for it. Again, the handbook answers all this. > Thanks, > Ajay. > > On 3/2/07, Greg Larkin <[EMAIL PROTECTED]> wrote: >> >> > >> > Hey all, >> > >> > Are there any known issues for installing FreeBSD on Vmware >> > on windows XP ? >> > I have never tried installiing FreeBSD earlier and i just saw >> > a mail in this >> > mailing list regarding some problems while installing on >> > vmware. Could not >> > make out much. Can someone just elaborate on the issues faced while >> > installing on Vmware. >> > >> > Regards, >> > ajay. >> >> Hi Ajay, >> >> I wrote in to the list a little while back about VMware installation >> problems that I had with FreeBSD 6.2, but the issue was completely >> related to the CPU architecture (Via C3 Nehemiah) that I was using. >> VMware doesn't officially support that processor, even though it's >> supposed to be Intel compatible. Another list member sent me a kernel >> patch that fixed the problem (thanks ghozzy). >> >> I also have a WinXP box with a Celeron processor in it and VMware >> Server installed, and FreeBSD 4.x and 6.x both install and run with no >> problems at all. >> >> If you have any specific questions, let me know and I'll try to answer >> them. I'm going to be learning a lot more about VMware Server and >> FreeBSD in the coming months, as I'm working on redeploying my >> company's service using those tools as the foundation. I hope to >> share that knowledge with the list as I proceed. >> >> I also found this thread >> (http://lists.freebsd.org/pipermail/freebsd-questions/2006-October/132 >> 716.html) with some information in it about issues to be aware of >> while running FreeBSD as a guest OS under VMware. Follow the thread a >> little way, and you'll see an example kernel config file, too. >> >> Best of luck, >> Greg Larkin >> >> >> >> > ___ > freebsd-hackers@freebsd.org mailing list > http://lists.freebsd.org/mailman/listinfo/freebsd-hackers > To unsubscribe, send any mail to " [EMAIL PROTECTED]" > > _