An idea of remove MUTEX_WAKE_ALL
Hi hackers, I have an idea about remove the kernel option MUTEX_WAKE_ALL. When we unlock the mutex(in _mtx_unlock_sleep),we can directly give the lock to the first thread waiting on the turnstile.And a thread gets the mutex after he returned from turnstile_wait so he can simply jump out the _obtain_lock loop in _mtx_lock_sleep. This makes a mutex always be owned by a thread when there are threads waiting on the turnstile,so priority inheritance can work now. This idea need only a few changes in kern/kern_mutex.c .But when NO_ADAPTIVE_MUTEXS not set,it makes threads that spinning on other CPU to get the mutex have to spin for a long time,and this makes the short term mutex more expensive(maybe should use spin mutex instead). What do think about the idea? Thanks. -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. -Bertrand Russell ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Deadlock FreeBSD 6 / 7
> > It's more likely to be a general instability from broken hardware. > > > > Use prime95 (ports/math/mprime) to test your processor and thermal > > stability (36 hours or so), and memtest86 (seperately). > > I guess I should have mentioned that other systems work fine and run > stable (and memtest returns no errors) > (Linux was up several days compiling stuff like OO etc) Still, we have seen that several times before, machine stable in Linux, not in FreeBSD and vice versa. Using prime95/mprime ist the best way to ensure this. Run it for 36 hours in the torture test mode. Martin -- %%% Martin Cracauerhttp://www.cons.org/cracauer/ FreeBSD - where you want to go, today. http://www.freebsd.org/ ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Problem about libnet on FreeBSD 6.0
> [EMAIL PROTECTED] wrote: > > > > Did you read my post? > > > Or are you not on the list? I sent my response directly to the list, > > > not including you specifically. > [...] > > I am on the list,and I don't receive your post. > > I think you can send post specifically to me and cc > > to the list :-). > > Thanks. > > In the future, please respond to personal mails personally. Neither my > direct e-mail address nor this mail were intended for public viewing. > > The post to which i was referring is: > http://lists.freebsd.org/pipermail/freebsd-hackers/2005-December/014986.html The problem is that libnet defines ether_addr without regard for the fact that it's defined in our system headers. This is a bug in libnet, not FreeBSD. In particular, libnet/libnet-headers.h has this code, which is very Linux-centric and works around the duplicate definition problem on Linux, but doesn't help anyone on other platforms. 391 #if (!__GLIBC__) 392 struct ether_addr 393 { 394 u_char ether_addr_octet[6]; 395 }; 396 #endif The problem has been properly fixed in the current development version of libnet (net/libnet-devel), by renaming the ether_addr structure to libnet_ether_addr. The net/libnet port should be marked BROKEN because of this issue (I've opened a PR) and folks should use libnet-devel instead, until the net/libnet port is updated to a newer version. The net/libnet maintainer has been notified of this problem. Regards, -- Matt Emmerton ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Problem about libnet on FreeBSD 6.0
[EMAIL PROTECTED] wrote: > > Did you read my post? > > Or are you not on the list? I sent my response directly to the list, > > not including you specifically. [...] > I am on the list,and I don't receive your post. > I think you can send post specifically to me and cc > to the list :-). > Thanks. In the future, please respond to personal mails personally. Neither my direct e-mail address nor this mail were intended for public viewing. The post to which i was referring is: http://lists.freebsd.org/pipermail/freebsd-hackers/2005-December/014986.html ari ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Problem about libnet on FreeBSD 6.0
On 1/1/06, ari edelkind <[EMAIL PROTECTED]> wrote: > > Did you read my post? > Or are you not on the list? I sent my response directly to the list, > not including you specifically. > > ari > > [EMAIL PROTECTED] wrote: > > [...] > > In my opinion,struct ether_addr is defined both in > > and libnet-headers.h,and we need > > include these two header files at the same time. > > > > And here is my include lines > [...] > I am on the list,and I don't receive your post. I think you can send post specifically to me and cc to the list :-). Thanks. -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. -Bertrand Russell ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Deadlock FreeBSD 6 / 7
Martin Cracauer wrote: Armin Pirkovitsch wrote on Sat, Dec 31, 2005 at 06:34:44PM +0100: Hi! I have some troubles with my notebook and any version of FreeBSD (starting with 6 since my sata controller wasn't supported earlier). It looks like as it would end up in a deadlock which means i have no access to the debugger nor to any other kind of tracing methods. Even with KTR, WITTNESS and DIAGNOSTIC enabled in the kerenl I get no message what went wrong or what might have caused the trouble. These fullstops always turn up when i compile and install programs (or sometimes during the installation of FreeBSD itself) Hardware: Intel Pentium-M 760 (Centrino, 2GHz) VIA VT 6421 SATA Controller 80GB Samsung SATA HD I guess one of those parts creates the trouble, but I have no idea how to trace it... Is there a way to run the whole thing in some kind of debugger? Or is there a diffrent way to locate the problem? It's more likely to be a general instability from broken hardware. Use prime95 (ports/math/mprime) to test your processor and thermal stability (36 hours or so), and memtest86 (seperately). I guess I should have mentioned that other systems work fine and run stable (and memtest returns no errors) (Linux was up several days compiling stuff like OO etc) -- Armin Pirkovitsch [EMAIL PROTECTED] ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Happy new year! (empty body)
I told you it's an empty body, but this is probably why you opened it. Happy new year FreeBSD hackers, and thank you all for your work and efforts. Yours Sincerely, -- Alin-Adrian Anton GPG keyID 0x183087BA (B129 E8F4 7B34 15A9 0785 2F7C 5823 ABA0 1830 87BA) gpg --keyserver pgp.mit.edu --recv-keys 0x183087BA "It is dangerous to be right when the government is wrong." - Voltaire ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Deadlock FreeBSD 6 / 7
Armin Pirkovitsch wrote on Sat, Dec 31, 2005 at 06:34:44PM +0100: > Hi! > > I have some troubles with my notebook and any version of FreeBSD > (starting with 6 since my sata controller wasn't supported earlier). > It looks like as it would end up in a deadlock which means i have no > access to the debugger nor to any other kind of tracing methods. > Even with KTR, WITTNESS and DIAGNOSTIC enabled in the kerenl I get no > message what went wrong or what might have caused the trouble. > These fullstops always turn up when i compile and install programs (or > sometimes during the installation of FreeBSD itself) > Hardware: > Intel Pentium-M 760 (Centrino, 2GHz) > VIA VT 6421 SATA Controller > 80GB Samsung SATA HD > > I guess one of those parts creates the trouble, but I have no idea how > to trace it... > Is there a way to run the whole thing in some kind of debugger? > Or is there a diffrent way to locate the problem? It's more likely to be a general instability from broken hardware. Use prime95 (ports/math/mprime) to test your processor and thermal stability (36 hours or so), and memtest86 (seperately). Martin -- %%% Martin Cracauerhttp://www.cons.org/cracauer/ FreeBSD - where you want to go, today. http://www.freebsd.org/ ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Deadlock FreeBSD 6 / 7
Hi! I have some troubles with my notebook and any version of FreeBSD (starting with 6 since my sata controller wasn't supported earlier). It looks like as it would end up in a deadlock which means i have no access to the debugger nor to any other kind of tracing methods. Even with KTR, WITTNESS and DIAGNOSTIC enabled in the kerenl I get no message what went wrong or what might have caused the trouble. These fullstops always turn up when i compile and install programs (or sometimes during the installation of FreeBSD itself) Hardware: Intel Pentium-M 760 (Centrino, 2GHz) VIA VT 6421 SATA Controller 80GB Samsung SATA HD I guess one of those parts creates the trouble, but I have no idea how to trace it... Is there a way to run the whole thing in some kind of debugger? Or is there a diffrent way to locate the problem? Thank's in advance and a Happy New Year, -- Armin Pirkovitsch [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: Problem about libnet on FreeBSD 6.0
On 12/31/05, Gilbert Fernandes <[EMAIL PROTECTED]> wrote: > > > - Message from [EMAIL PROTECTED] - > > Date: Sat, 31 Dec 2005 20:55:38 +0800 > > From: prime <[EMAIL PROTECTED] > > > Reply-To: prime <[EMAIL PROTECTED]> > > Subject: Re: Problem about libnet on FreeBSD 6.0 > > To: Gilbert Fernandes < [EMAIL PROTECTED]> > > > > On 12/31/05, Gilbert Fernandes <[EMAIL PROTECTED]> wrote: > > > > > > > I find that I can't include when I programming > > > > with libnet,because $(CC) complains that "struct ether_addr > > redefined". > > > > But I need some definitions in ,struct ether_header > > etc. > > > > Currently,I just copy the definitions I need from > > ,but > > > > it seems very ugly.Any one has some good ideas? > > > > > > Could you show us the include line you use ? > > > > > > #include "blabla" and > > > #include > > > > > > will produce very different results as you know :) > > > > > > You do use #include ? > > > > > > -- > > > unzip ; strip ; touch ; grep ; finger ; mount ; fsck ; more ; yes ; > > > fsck ; umount ; sleep > > > > > Here is my include lines, > > #include .. > > #include > > #include > > #include > > ... > > and this is the error, > > $(CC) said "/usr/local/include/./libnet/libnet-headers.h:393: error: > > redefinition of `struct ether_addr'" > > > > > > Thanks. > > -- > > Three passions, simple but overwhelmingly strong, have governed my life: > > > the longing for love, the search for knowledge, and unbearable pity for > > the suffering of mankind. > > -Bertrand Russell > > > > > > - End message from [EMAIL PROTECTED] - > > Redefinition means that you have two declarations of the same > function. > > One of the files you are including IS already including net/ethernet > probably. > > Can you check ? :) > > -- > unzip ; strip ; touch ; grep ; finger ; mount ; fsck ; more ; yes ; > fsck ; umount ; sleep > I can't agree more.Header files usually use "#ifndef XXX_H #define XXX_H . #endif" to avoid being included more than once. is not different. it use "#ifndef _NET_ETHERNET_H_ #define _NET_ETHERNET_H_ .. #endif" to avoid more than once include. In my opinion,struct ether_addr is defined both in and libnet-headers.h,and we need include these two header files at the same time. And here is my include lines #include #include #include #include #include #include #include #include #include #include #include #include #include #include -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. -Bertrand Russell ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: My wish list for 6.1
Robert Watson wrote on Sat, Dec 31, 2005 at 07:12:23AM +: > > On Fri, 16 Dec 2005, Avleen Vig wrote: > > > On Fri, Dec 16, 2005 at 10:40:22AM -0500, Martin Cracauer wrote: > >>> 2. SMP kernels for install. Right now we only install a UP kernel, for > >>> performance reasons. We should be able to package both a UP and SMP > >>> kernel into the release bits, and have sysinstall install both. It > >>> should also select the correct one for the target system and make that > >>> the default on boot. > >> > >> If people are concerned about performance, I benchmarked a 6-beta kernel > >> SMP versus UP on a socket 939 Opteron. > > > > If those results are accurate, there's no real reason not to just use an > > SMP > > kernel on default install? > > This is an old thread that I'm just catching up on, but I figured I'd chime > in > anyway: you have to be really careful benchmarking across CPU types and > configurations, as the performance characteristics of important insturctions > differ a lot across hardware variations. For example, the performance of > atomic operations, used to synchronize between CPUs, varies significantly by > CP, bus configuration, etc. On modern opteron hardware, the performance of > inter-CPU synchronization instructions is blindingly fast. On modern Xeon P4 > hardware, it is incredibly slow. Well, my runs included P4s and P4-based Xeons, and hyperthreading, too. The core of the problem here is that while my parallel benchmarks are partly system-call exercising, I use apache over localhost and zero-spaced files to get the disk and network out of the equitation. I think I have a solid framework in place to run parallel benchmarks and see the tradeoffs involved, but I need to fill it with activity that exercises what we want to see. Still, I bet that my measurements are good enough to label the SMP kernel "defaultable" for FreeBSD installations, from a performance standpoint. After all, I *do* test parallel activity, CPU-intensive and systemcall-intensive and various mixes thereof. Remember that those people who do a lot of parallel activity and hence would suffer from the additional locks in the SMP kernel are very likely to have a SMP system, dual-cores or at least hyperthreading in first place. On the other hand, people who use very low-end hardware to do demanding tasks are very likely to build their own kernel anyway. > Software optimized for the Opteron will > often perform much slower on Xeon P4 hardware as a result. P3 hardware tends > to behave a lot more like Opteron in terms of speed of insturctions relating > to disabling interrupts, where on P4 Xeon they are proprtionally much slower. > The critical section optimizations made by John Baldwin, and the movement to > critical sections in UMA and kernel malloc that I made, made a big > performance > difference on Xeon P4 hardware, but relatively little difference on > Opteron. One thing I noticed is that anything P4-based is very sensitive to spinlocks being placed on the same cache line as the data it protects. Putting a lock into a struct without cache-line crossing padding means doom for the P4-based/netburst CPUs (I'm sure it's not a good thing for Opterons either but they don't seem to mind that much). Martin -- %%% Martin Cracauerhttp://www.cons.org/cracauer/ FreeBSD - where you want to go, today. http://www.freebsd.org/ ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Problem about libnet on FreeBSD 6.0
> - Message from [EMAIL PROTECTED] - > Date: Sat, 31 Dec 2005 20:55:38 +0800 > From: prime <[EMAIL PROTECTED]> > Reply-To: prime <[EMAIL PROTECTED]> > Subject: Re: Problem about libnet on FreeBSD 6.0 > To: Gilbert Fernandes <[EMAIL PROTECTED]> > > On 12/31/05, Gilbert Fernandes <[EMAIL PROTECTED]> wrote: > > > > > I find that I can't include when I programming > > > with libnet,because $(CC) complains that "struct ether_addr > redefined". > > > But I need some definitions in ,struct ether_header > etc. > > > Currently,I just copy the definitions I need from > ,but > > > it seems very ugly.Any one has some good ideas? > > > > Could you show us the include line you use ? > > > > #include "blabla" and > > #include > > > > will produce very different results as you know :) > > > > You do use #include ? > > > > -- > > unzip ; strip ; touch ; grep ; finger ; mount ; fsck ; more ; yes ; > > fsck ; umount ; sleep > > > Here is my include lines, > #include .. > #include > #include > #include > ... > and this is the error, > $(CC) said "/usr/local/include/./libnet/libnet-headers.h:393: error: > redefinition of `struct ether_addr'" > > > Thanks. > -- > Three passions, simple but overwhelmingly strong, have governed my life: > the longing for love, the search for knowledge, and unbearable pity for > the suffering of mankind. > -Bertrand Russell > > > - End message from [EMAIL PROTECTED] - Redefinition means that you have two declarations of the same function. One of the files you are including IS already including net/ethernet probably. Can you check ? :) -- unzip ; strip ; touch ; grep ; finger ; mount ; fsck ; more ; yes ; fsck ; umount ; sleep ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Problem about libnet on FreeBSD 6.0
[EMAIL PROTECTED] wrote: > On 12/31/05, Gilbert Fernandes <[EMAIL PROTECTED]> wrote: > > > > > I find that I can't include when I programming > > > with libnet,because $(CC) complains that "struct ether_addr redefined". > > > But I need some definitions in ,struct ether_header etc. > > > Currently,I just copy the definitions I need from ,but > > > it seems very ugly.Any one has some good ideas? > > > Here is my include lines, > #include .. > #include > #include > #include > ... > and this is the error, > $(CC) said "/usr/local/include/./libnet/libnet-headers.h:393: error: > redefinition of `struct ether_addr'" > Assuming that either the practical contents of 'struct ether_addr' are the same for both definitions or that it doesn't matter for any inline functions you may be using within the header file (chances are, this assumption is valid): #include #include #define ether_addr ether_addr_BROKEN_LIBNET # include #undef ether_addr ari ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"
Re: Preserve date when cp over smbfs
On Fri, Dec 30, 2005 at 05:48:56PM -0800, Doug Barton wrote: > Gilbert Cao wrote: > > Hi, the list. > > > > I have recently notice a problem when I copy a file to a SMB mount > > directory : > > Thanks for the good detective work. Can you send-pr this so that it does not > get lost? Yep, it is done : http://www.freebsd.org/cgi/query-pr.cgi?pr=91134 Hope this helps. > > Doug > -- (hika) Gilbert Cao http://www.miaouirc.com - MiaouIRC Project 2002-2003 http://www.bsdmon.com - The BSD DMON Power to serve IRC : #miaule at IRCNET Network pgpGsiuzyhul0.pgp Description: PGP signature
Re: Problem about libnet on FreeBSD 6.0
On 12/31/05, Gilbert Fernandes <[EMAIL PROTECTED]> wrote: > > > I find that I can't include when I programming > > with libnet,because $(CC) complains that "struct ether_addr redefined". > > But I need some definitions in ,struct ether_header etc. > > Currently,I just copy the definitions I need from ,but > > it seems very ugly.Any one has some good ideas? > > Could you show us the include line you use ? > > #include "blabla" and > #include > > will produce very different results as you know :) > > You do use #include ? > > -- > unzip ; strip ; touch ; grep ; finger ; mount ; fsck ; more ; yes ; > fsck ; umount ; sleep > Here is my include lines, #include .. #include #include #include ... and this is the error, $(CC) said "/usr/local/include/./libnet/libnet-headers.h:393: error: redefinition of `struct ether_addr'" Thanks. -- Three passions, simple but overwhelmingly strong, have governed my life: the longing for love, the search for knowledge, and unbearable pity for the suffering of mankind. -Bertrand Russell ___ freebsd-hackers@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-hackers To unsubscribe, send any mail to "[EMAIL PROTECTED]"