From bdrewery at FreeBSD.org Sat Feb 1 14:40:40 2014
From: bdrewery at FreeBSD.org (Bryan Drewery)
Date: Sat, 01 Feb 2014 08:40:33 -0600
Subject: [patch] TLS Server Name Indication (SNI) support for fetch(1)
In-Reply-To: <52BECBE8.8080906@gibfest.dk>
References: <20130608205653.GA8765@ogoshi.int.nbs-system.com>
<52BECBE8.8080906@gibfest.dk>
Message-ID: <52ED0761.5000301@FreeBSD.org>
On 12/28/2013 7:02 AM, Thomas Steen Rasmussen wrote:
> On 08-06-2013 22:56, Sofian Brabez wrote:
>> Hi,
>>
>> fetch(1) currently does not support TLS extension Server Name
>> Indication (RFC
>> 6066) [1] when dealing with SSL. Nowadays lot of clients and servers
>> implement
>> this extension.
> Hello!
>
> fetch(1) is still missing SNI support as of r259440 - any chance of
> seeing this patch committed ?
> As ipv4 depletion gets worse we will see SSL websites using SNI more and
> more. This is overdue.
>
> Thanks, and may you all have a wonderful new year!
>
> /Thomas Steen Rasmussen
This was added in head r258347 Nov 19 2013:
http://svnweb.freebsd.org/changeset/base/258347
It made it to stable/10 before 10.0 and into stable/9.
It works if you install ca_root_nss cert.pem:
> # pkg install ca_root_nss
> ...
> # ln -s /usr/local/share/certs/ca-root-nss.crt /etc/ssl/cert.pem
> ...
> # fetch -v -o - https://sni.velox.ch|head -n 15
> looking up sni.velox.ch
> connecting to sni.velox.ch:443
> SSL options: 81004bff
> Peer verification enabled
> Using CA cert file: /etc/ssl/cert.pem
> Verify hostname
> SSL connection established using ECDHE-RSA-AES256-GCM-SHA384
> Certificate subject: /C=CH/ST=Zuerich/L=Zuerich/O=Kaspar Brand/CN=*.sni.velox.ch
> Certificate issuer: /C=BM/O=QuoVadis Limited/OU=www.quovadisglobal.com/CN=QuoVadis Global SSL ICA
> requesting https://sni.velox.ch/
> -
>
>
> 5063 BTLS SNI Test Site: *.sni.velox.ch
>
> 945 kBps
> 00m00sTLS SNI Test Site: *.sni.velox.ch
>
>
> Great! Your client [fetch libfetch/2.0]
> sent the following TLS server name indication extension
> (RFC 6066)
> in its ClientHello (negotiated protocol: TLSv1.2, cipher suite: ECDHE-RSA-AES256-GCM-SHA384):
> sni.velox.ch
> In your request, this header was included:
> Host: sni.velox.ch
I'm not sure what the plan is for a base CA file, but adding ca_root_nss
does allow it to work.
--
Regards,
Bryan Drewery
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 553 bytes
Desc: OpenPGP digital signature
URL:
From yuri at rawbw.com Sat Feb 1 22:55:36 2014
From: yuri at rawbw.com (Yuri)
Date: Sat, 01 Feb 2014 14:55:35 -0800
Subject: r_debug in ld-elf.so.1 should be a public symbol to allow for an
alternative run-time loader
Message-ID: <52ED7B67.2090801@rawbw.com>
I think it would be reasonable if r_debug and related symbols in the
ld-elf.so.1 run-time loader would be made public.
Currently, only r_debug_symbol is public out of all debugger-related
symbols in ld-elf.so. This is done so that debuggers can add a
breakpoint on it to get notified of changes in the set of loaded shared
libraries. This is sufficient when ld-elf.so is the only one who loads
objects.
Now imagine the situation when an application wants to load its own ELF
objects in its own way, still having the benefit of using the debug
info. Such application would need to have access to the list of objects
maintained by ld-elf.so. r_debug variable contains this list.
Such application would necessarily be system specific, and would have to
have the knowledge of some inner workings of ld-elf.so. But, in my
opinion, this is a legitimate use and should be allowed. Therefore I am
suggesting this patch. Except r_debug, it adds related lock object and
functions to the list of publics, because they are needed to avoid race
conditions.
This is, of course, not a mainstream way to do things, but nevertheless
it should be allowed.
This is also a minor patch, and it can't possibly hurt anything else.
--begin patch--
--- libexec/rtld-elf/Symbol.map (revision 260894)
+++ libexec/rtld-elf/Symbol.map (working copy)
@@ -15,6 +15,11 @@
dlinfo;
dl_iterate_phdr;
r_debug_state;
+ r_debug;
+ rtld_bind_lock;
+ rlock_acquire;
+ wlock_acquire;
+ lock_release;
__tls_get_addr;
};
--end patch--
Yuri
From rmirzazadeh at gmail.com Sun Feb 2 10:07:59 2014
From: rmirzazadeh at gmail.com (Reza Mirzazadeh)
Date: Sun, 2 Feb 2014 13:37:37 +0330
Subject: remove shutdown messages in console
Message-ID:
hi . how can i remove shutdown messages in console ? or even print my
arbitrary messages in console ?
*** FINAL System shutdown message from root at geekiam ***
System going down IMMEDIATELY
some messages like these ! i don't want it print theses messages
--
From jhellenthal at dataix.net Sun Feb 2 11:02:20 2014
From: jhellenthal at dataix.net (Jason Hellenthal)
Date: Sun, 2 Feb 2014 06:02:14 -0500
Subject: remove shutdown messages in console
In-Reply-To:
References:
Message-ID: <2D6DF212-BF65-4784-B466-8F595DF2059B@dataix.net>
Either configure syslogd correctly or use sysctl consmute
--
Jason Hellenthal
Voice: 95.30.17.6/616
JJH48-ARIN
> On Feb 2, 2014, at 5:07, Reza Mirzazadeh wrote:
>
> hi . how can i remove shutdown messages in console ? or even print my
> arbitrary messages in console ?
>
>
> *** FINAL System shutdown message from root at geekiam ***
> System going down IMMEDIATELY
>
> some messages like these ! i don't want it print theses messages
> --
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 6118 bytes
Desc: not available
URL:
From killing at multiplay.co.uk Mon Feb 3 09:12:18 2014
From: killing at multiplay.co.uk (Steven Hartland)
Date: Mon, 3 Feb 2014 09:12:10 -0000
Subject: iconv support in 10.x compatibility with closed source apps?
Message-ID: <00018D706D2B4278A74A58BE482BF968@multiplay.co.uk>
Since 10.x includes iconv in base the converts/libiconv port
refuses to build with the error:
===> libiconv-1.14_1 converters/libiconv should not be used
with iconv from base. Please fix the port which tries to use it.
Now thats all well and good if this was port but its not its
a piece of close source software which is linked to libiconv.so.3
So without the option of recompiling the application with base
iconv what's the correct fix?
Regards
Steve
================================================
This e.mail is private and confidential between Multiplay (UK) Ltd. and the person or entity to whom it is addressed. In the event of misdirection, the recipient is prohibited from using, copying, printing or otherwise disseminating it or any information contained in it.
In the event of misdirection, illegible or incomplete transmission please telephone +44 845 868 1337
or return the E.mail to postmaster at multiplay.co.uk.
From tijl at FreeBSD.org Mon Feb 3 10:29:23 2014
From: tijl at FreeBSD.org (Tijl Coosemans)
Date: Mon, 3 Feb 2014 11:29:13 +0100
Subject: iconv support in 10.x compatibility with closed source apps?
In-Reply-To: <00018D706D2B4278A74A58BE482BF968@multiplay.co.uk>
References: <00018D706D2B4278A74A58BE482BF968@multiplay.co.uk>
Message-ID: <20140203112913.47bfc11b@kalimero.tijl.coosemans.org>
On Mon, 3 Feb 2014 09:12:10 -0000 Steven Hartland wrote:
> Since 10.x includes iconv in base the converts/libiconv port
> refuses to build with the error:
>
> ===> libiconv-1.14_1 converters/libiconv should not be used
> with iconv from base. Please fix the port which tries to use it.
>
> Now thats all well and good if this was port but its not its
> a piece of close source software which is linked to libiconv.so.3
>
> So without the option of recompiling the application with base
> iconv what's the correct fix?
Update your ports tree and install converters/libiconv. The ban has
been lifted.
From rysto32 at gmail.com Mon Feb 3 16:41:14 2014
From: rysto32 at gmail.com (Ryan Stone)
Date: Mon, 3 Feb 2014 11:41:13 -0500
Subject: Races in ichsmb(9) when accessed from a multithreaded process
Message-ID:
ichsmb.c has the following rather worrisome comment:
* This driver assumes that the generic SMBus code will ensure that
* at most one process at a time calls into the SMBus methods below.
However, when I look at the code is sys/dev/smbus, I see nothing that
actually guarantees this if two threads in the same process call
ioctls on the same file descriptor. It does call smbus_request_bus,
but mostly that just calls down into the smbus implementation (in this
case ichsmb) with SMBUS_CALLBACK. ichsmb always just acks the
request, so no actual locking ends up occurring.
Is it intended that smb(9) clients be required to do their own
locking? It seems to me that that is way more fragile than it needs
to be.
From w-info2 at xs4all.nl Mon Feb 3 19:42:03 2014
From: w-info2 at xs4all.nl (Photo stuff)
Date: Mon, 03 Feb 2014 20:33:11 +0100
Subject: The sonewconn listen queue overflow issue
Message-ID: <52EFEEF7.5010704@xs4all.nl>
L.S.
I came across a lot of messages in the log since, I think, about 9.1,
that sometimes fill it up so much that all else is made invisible, of
the type:
sonewconn: pcb 0xyyyyyyyyyyyyyyyy: Listen queue overflow: 8 already in
queue awaiting acceptance
I searched a bit on the web and came across recommendations to try
netstat -nAa to find out which program this came from.
Well, running netstat -nAa |grep pcb 0xyyyyyyyyyyyyyyyy in a loop didn't
work, it didn't give any output even though the messages kept coming in
the log during that time.
I forgot about it then recently searched a bit more, and I found this page:
http://lawrencechen.net/2014/sonewconn-pcb-0xfffffe006acd9310-listen-queue
So a listen queue overflow of 8 is caused by a listen value of 5 (QLEN >
3 * (QLIM / 2))
Doing:
netstat -LaAn | grep '/5 '
resulted in
ffffzzzzzzzzzzzz tcp4 0/0/5 127.0.0.1:8000
The ffffzzz value was not the value in the message log,
but the connection means in my case it had to be the junkbuster proxy
(which I still use, still works well :) ), as I didn't run anything else
locally.
So I looked into junkbuster's cource and in bind.c I changed 2 instances of:
while (listen(fd, 5) == -1) {
to
while (listen(fd, 10) == -1) { /* 10 instead of 5, this fixes dmesg
spamming of the type 'sonewconn: pcb 0xyyyyyyyyyyyyyyyy: Listen queue
overflow: 8 already in queue awaiting acceptance'? */
This improved the situation, but still gave the issue of the log filling
up too much. So then I changed it to 20, which gave me silence :)
Checking the latest log I couldn't find anything in the last 10 days.
So for people who have this issue I recommend calculating which value
the listen-value that the overflow-value corresponds to, then checking
as above and then it should be possible to find the daemon causing the
issue. And modify that program...
But while this removes the errors, what do these messages really
signify? I mean which didn't this happen before in earlier versions of
FreeBSD?
Some people have recommended just to stop using certain programs but
that doesn't seem a solution. listen(2) doesn't give a real clue. It
mentions changes to the queue in 4.5, so very long ago. Haven't read
commit logs to see if there are hints there :)
Btw., at the moment (running 10.0 RC2) my message log now gets filled up
with something else :)
hwpstate0: set freq failed, err 6
This happened long ago already in 9.1 with my AMD3500+ and still now on
my AMD FX6100...
Regards,
Wouter
From ian at FreeBSD.org Mon Feb 3 20:28:47 2014
From: ian at FreeBSD.org (Ian Lepore)
Date: Mon, 03 Feb 2014 13:28:43 -0700
Subject: Races in ichsmb(9) when accessed from a multithreaded process
In-Reply-To:
References:
Message-ID: <1391459323.13026.100.camel@revolution.hippie.lan>
On Mon, 2014-02-03 at 11:41 -0500, Ryan Stone wrote:
> ichsmb.c has the following rather worrisome comment:
>
> * This driver assumes that the generic SMBus code will ensure that
> * at most one process at a time calls into the SMBus methods below.
>
> However, when I look at the code is sys/dev/smbus, I see nothing that
> actually guarantees this if two threads in the same process call
> ioctls on the same file descriptor. It does call smbus_request_bus,
> but mostly that just calls down into the smbus implementation (in this
> case ichsmb) with SMBUS_CALLBACK. ichsmb always just acks the
> request, so no actual locking ends up occurring.
>
> Is it intended that smb(9) clients be required to do their own
> locking? It seems to me that that is way more fragile than it needs
> to be.
It looks to me like most of the SMBUS_CALLBACK implementations are
stubbed out, and thus are wrong. The notable exceptions are
iicbus/iicsmb.c which relies on the underlying iic driver to get it
right (and I know at least some of them do), and bktr/bktr_i2c.c which
has what looks like good exclusive-bus-grant logic (modulo the use of
Giant for locking).
-- Ian
From torek at elf.torek.net Mon Feb 3 21:20:51 2014
From: torek at elf.torek.net (Chris Torek)
Date: Mon, 3 Feb 2014 14:01:00 -0700 (MST)
Subject: Races in ichsmb(9) when accessed from a multithreaded process
In-Reply-To:
Message-ID: <201402032101.s13L10rm092760@elf.torek.net>
Yes, we found that the code does not properly allow either
multiple threads *or* multiple processes to work. The top level
driver makes it a single-open device (which has the obvious
drawback that only one process can open() the device). But even
then, multiple threads within a process, or forking, or using
PF_LOCAL sockets to hand over the file descriptor, result in
races.
We have a hack that makes it work for our case but the SMB
framework needs an overhaul.
Chris
From julian at freebsd.org Tue Feb 4 03:27:08 2014
From: julian at freebsd.org (Julian Elischer)
Date: Tue, 04 Feb 2014 11:26:52 +0800
Subject: remove shutdown messages in console
In-Reply-To:
References:
Message-ID: <52F05DFC.7070007@freebsd.org>
On 2/2/14, 6:07 PM, Reza Mirzazadeh wrote:
> hi . how can i remove shutdown messages in console ? or even print my
> arbitrary messages in console ?
>
>
> *** FINAL System shutdown message from root at geekiam ***
> System going down IMMEDIATELY
>
> some messages like these ! i don't want it print theses messages
> --
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
>
we implimented the consmute sysctl option to "mute" an otherwise
configured console for exactly this purpose.
(and boot messages).
From feld at FreeBSD.org Tue Feb 4 18:30:51 2014
From: feld at FreeBSD.org (Mark Felder)
Date: Tue, 04 Feb 2014 12:30:49 -0600
Subject: opteron a1100 arm
In-Reply-To:
References:
Message-ID: <1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
On Fri, Jan 31, 2014, at 12:13, Wojciech Puchar wrote:
> AMD just presented it's ARM based CPU and motherboard. is support in
> FreeBSD planned and what is it's status?
>
Is it even available to purchase?
From riggs at freebsd.org Tue Feb 4 21:00:49 2014
From: riggs at freebsd.org (Thomas Zander)
Date: Tue, 4 Feb 2014 22:00:47 +0100
Subject: opteron a1100 arm
In-Reply-To: <1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
Message-ID:
On 4 Feb 2014 19:31, "Mark Felder" wrote:
>
> On Fri, Jan 31, 2014, at 12:13, Wojciech Puchar wrote:
> > AMD just presented it's ARM based CPU and motherboard. is support in
> > FreeBSD planned and what is it's status?
> >
>
> Is it even available to purchase?
No but it may well be an early reminder of the upcoming generation of
powerful ARM servers that we don't want to leave unsupported.
Riggs
From jim at netgate.com Tue Feb 4 21:21:06 2014
From: jim at netgate.com (Jim Thompson)
Date: Tue, 4 Feb 2014 15:21:03 -0600
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
Message-ID: <493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
On Feb 4, 2014, at 3:00 PM, Thomas Zander wrote:
> On 4 Feb 2014 19:31, "Mark Felder" wrote:
>>
>> On Fri, Jan 31, 2014, at 12:13, Wojciech Puchar wrote:
>>> AMD just presented it's ARM based CPU and motherboard. is support in
>>> FreeBSD planned and what is it's status?
>>>
>>
>> Is it even available to purchase?
>
> No but it may well be an early reminder of the upcoming generation of
> powerful ARM servers that we don't want to leave unsupported.
?may well be? isn?t that attractive when the 8-core, 64-bit Intel C2000 parts are here, now, at a lower TDP
(20W, .vs 25W for the a1100. 22nm rocks).
When Intel moves the C2K series to 14nm later this year, the power savings will close the door.
The opteron a1100 samples in March, I wouldn?t expect boards before Summer.
Jim
From jim at netgate.com Tue Feb 4 21:42:29 2014
From: jim at netgate.com (Jim Thompson)
Date: Tue, 4 Feb 2014 15:42:19 -0600
Subject: opteron a1100 arm
In-Reply-To: <60555.1391549390@critter.freebsd.dk>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
Message-ID: <23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
On Feb 4, 2014, at 3:29 PM, Poul-Henning Kamp wrote:
> In message <493DEB39-C4B4-409E-B8B2-B1B11E013754 at netgate.com>, Jim Thompson wri
> tes:
>
>>> No but it may well be an early reminder of the upcoming generation of
>>> powerful ARM servers that we don't want to leave unsupported.
>>
>> isn't that attractive when the 8-core, 64-bit Intel C20
>> 00 parts are here, now, at a lower TDP
>> (20W, .vs 25W for the a1100. 22nm rocks).
>
> I very much welcome a competing 64bit CPU into the marketplace and
> will buy one myself, as soon as I can, for no other reason than to
> help break the X86 monopoly on server architecture.
>
> Monopolies are never a good thing.
True, but I didn?t say that the chip wasn?t interesting. What I said is that it?s not that attractive (to the real market for these: micro servers).
The dual 10Gig Ethernet and 8 SATA 3.0 ports are interesting. You won?t get that with a C2K system at 25W TDP, (4 x GigE that can run at 2.5Gbps per port, and 2 SATA 3.0 ports currently) but Intel owns IP for both, so if that becomes a differentiator for design wins, I?d expect a future variant to cover.
But by all means, port FreeBSD to it. Perhaps it can be the long-desired ?reference platform? to bring ARM into a ?Tier 1? architecture status.
Jim
From phk at phk.freebsd.dk Tue Feb 4 21:36:59 2014
From: phk at phk.freebsd.dk (Poul-Henning Kamp)
Date: Tue, 04 Feb 2014 21:29:50 +0000
Subject: opteron a1100 arm
In-Reply-To: <493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
Message-ID: <60555.1391549390@critter.freebsd.dk>
In message <493DEB39-C4B4-409E-B8B2-B1B11E013754 at netgate.com>, Jim Thompson wri
tes:
>> No but it may well be an early reminder of the upcoming generation of
>> powerful ARM servers that we don't want to leave unsupported.
>
>isn't that attractive when the 8-core, 64-bit Intel C20
>00 parts are here, now, at a lower TDP
>(20W, .vs 25W for the a1100. 22nm rocks).
I very much welcome a competing 64bit CPU into the marketplace and
will buy one myself, as soon as I can, for no other reason than to
help break the X86 monopoly on server architecture.
Monopolies are never a good thing.
... Not even if they're FOSS software: LLVM did wonders for the
GCC projects drive and attitude.
--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
From ian at FreeBSD.org Tue Feb 4 22:10:00 2014
From: ian at FreeBSD.org (Ian Lepore)
Date: Tue, 04 Feb 2014 15:09:55 -0700
Subject: opteron a1100 arm
In-Reply-To: <23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID: <1391551795.1196.11.camel@revolution.hippie.lan>
On Tue, 2014-02-04 at 15:42 -0600, Jim Thompson wrote:
> On Feb 4, 2014, at 3:29 PM, Poul-Henning Kamp wrote:
>
> > In message <493DEB39-C4B4-409E-B8B2-B1B11E013754 at netgate.com>, Jim Thompson wri
> > tes:
> >
> >>> No but it may well be an early reminder of the upcoming generation of
> >>> powerful ARM servers that we don't want to leave unsupported.
> >>
> >> isn't that attractive when the 8-core, 64-bit Intel C20
> >> 00 parts are here, now, at a lower TDP
> >> (20W, .vs 25W for the a1100. 22nm rocks).
> >
> > I very much welcome a competing 64bit CPU into the marketplace and
> > will buy one myself, as soon as I can, for no other reason than to
> > help break the X86 monopoly on server architecture.
> >
> > Monopolies are never a good thing.
>
> True, but I didn?t say that the chip wasn?t interesting. What I said is that it?s not that attractive (to the real market for these: micro servers).
>
> The dual 10Gig Ethernet and 8 SATA 3.0 ports are interesting. You won?t get that with a C2K system at 25W TDP, (4 x GigE that can run at 2.5Gbps per port, and 2 SATA 3.0 ports currently) but Intel owns IP for both, so if that becomes a differentiator for design wins, I?d expect a future variant to cover.
>
> But by all means, port FreeBSD to it. Perhaps it can be the long-desired ?reference platform? to bring ARM into a ?Tier 1? architecture status.
>
> Jim
We have no shortage of ARM platforms. IMO the thing that prevents ARM
from becoming tier 1 is manpower.
-- Ian
From lev at FreeBSD.org Tue Feb 4 22:12:08 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Wed, 5 Feb 2014 02:12:01 +0400
Subject: opteron a1100 arm
In-Reply-To: <23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID: <28896996.20140205021201@serebryakov.spb.ru>
Hello, Jim.
You wrote 5 ??????? 2014 ?., 1:42:19:
JT> But by all means, port FreeBSD to it. Perhaps it can be the
JT> long-desired ?reference platform? to bring ARM into a ?Tier 1? architecture status.
It is ARMv8A, which is differs from ARMv5/6/7 as i385 from amd64. So, we
should talks about TWO architectures here, as we talk about i386 and amd64.
--
// Black Lion AKA Lev Serebryakov
From lev at FreeBSD.org Tue Feb 4 22:15:42 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Wed, 5 Feb 2014 02:15:36 +0400
Subject: opteron a1100 arm
In-Reply-To: <28896996.20140205021201@serebryakov.spb.ru>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
<28896996.20140205021201@serebryakov.spb.ru>
Message-ID: <1801933421.20140205021536@serebryakov.spb.ru>
Hello, Lev.
You wrote 5 ??????? 2014 ?., 2:12:01:
JT>> But by all means, port FreeBSD to it. Perhaps it can be the
JT>> long-desired ?reference platform? to bring ARM into a ?Tier 1? architecture status.
LS> It is ARMv8A, which is differs from ARMv5/6/7 as i385 from amd64. So, we
LS> should talks about TWO architectures here, as we talk about i386 and amd64.
I'm not even sure, that we have compiler for ARMv8, as we have very old
gcc, and is LLVM AArch64 backend production-ready?
--
// Black Lion AKA Lev Serebryakov
From phk at phk.freebsd.dk Tue Feb 4 21:48:21 2014
From: phk at phk.freebsd.dk (Poul-Henning Kamp)
Date: Tue, 04 Feb 2014 21:48:20 +0000
Subject: opteron a1100 arm
In-Reply-To: <23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID: <60681.1391550500@critter.freebsd.dk>
In message <23B18B88-D888-46B3-99F6-905F86E20FAF at netgate.com>, Jim Thompson wri
tes:
>The dual 10Gig Ethernet and 8 SATA 3.0 ports are interesting. You
>won't get that with a C2K system at 25W TDP [...]
Couple that with some decent SSD disks and you have a system that
should be able to pump out close to 400k HTTP requests a second
running Varnish...
--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
From feld at FreeBSD.org Tue Feb 4 22:31:28 2014
From: feld at FreeBSD.org (Mark Felder)
Date: Tue, 04 Feb 2014 16:31:27 -0600
Subject: opteron a1100 arm
In-Reply-To: <60681.1391550500@critter.freebsd.dk>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
<60681.1391550500@critter.freebsd.dk>
Message-ID: <1391553087.27234.79361889.59679194@webmail.messagingengine.com>
On Tue, Feb 4, 2014, at 15:48, Poul-Henning Kamp wrote:
> In message <23B18B88-D888-46B3-99F6-905F86E20FAF at netgate.com>, Jim
> Thompson wri
> tes:
>
> >The dual 10Gig Ethernet and 8 SATA 3.0 ports are interesting. You
> >won't get that with a C2K system at 25W TDP [...]
>
> Couple that with some decent SSD disks and you have a system that
> should be able to pump out close to 400k HTTP requests a second
> running Varnish...
>
Wow that would be amazing
From bapt at FreeBSD.org Tue Feb 4 22:35:34 2014
From: bapt at FreeBSD.org (Baptiste Daroussin)
Date: Tue, 4 Feb 2014 23:35:28 +0100
Subject: opteron a1100 arm
In-Reply-To: <493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
Message-ID: <20140204223528.GF23872@ithaqua.etoilebsd.net>
On Tue, Feb 04, 2014 at 03:21:03PM -0600, Jim Thompson wrote:
>
> On Feb 4, 2014, at 3:00 PM, Thomas Zander wrote:
>
> > On 4 Feb 2014 19:31, "Mark Felder" wrote:
> >>
> >> On Fri, Jan 31, 2014, at 12:13, Wojciech Puchar wrote:
> >>> AMD just presented it's ARM based CPU and motherboard. is support in
> >>> FreeBSD planned and what is it's status?
> >>>
> >>
> >> Is it even available to purchase?
> >
> > No but it may well be an early reminder of the upcoming generation of
> > powerful ARM servers that we don't want to leave unsupported.
>
> ?may well be? isn?t that attractive when the 8-core, 64-bit Intel C2000 parts are here, now, at a lower TDP
> (20W, .vs 25W for the a1100. 22nm rocks).
>
> When Intel moves the C2K series to 14nm later this year, the power savings will close the door.
>
> The opteron a1100 samples in March, I wouldn?t expect boards before Summer.
>
> Jim
>
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
A board like this will allow portmgr to provide official and regular package
built for arm! so yes for sure we do need to support that!
regards,
Bapt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL:
From cbergstrom at pathscale.com Tue Feb 4 22:40:54 2014
From: cbergstrom at pathscale.com (=?UTF-8?B?IkMuIEJlcmdzdHLDtm0i?=)
Date: Wed, 05 Feb 2014 05:37:24 +0700
Subject: opteron a1100 arm
In-Reply-To: <20140204223528.GF23872@ithaqua.etoilebsd.net>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
Message-ID: <52F16BA4.4060202@pathscale.com>
On 02/ 5/14 05:35 AM, Baptiste Daroussin wrote:
> On Tue, Feb 04, 2014 at 03:21:03PM -0600, Jim Thompson wrote:
>> On Feb 4, 2014, at 3:00 PM, Thomas Zander wrote:
>>
>>> On 4 Feb 2014 19:31, "Mark Felder" wrote:
>>>> On Fri, Jan 31, 2014, at 12:13, Wojciech Puchar wrote:
>>>>> AMD just presented it's ARM based CPU and motherboard. is support in
>>>>> FreeBSD planned and what is it's status?
>>>>>
>>>> Is it even available to purchase?
>>> No but it may well be an early reminder of the upcoming generation of
>>> powerful ARM servers that we don't want to leave unsupported.
>> ?may well be? isn?t that attractive when the 8-core, 64-bit Intel C2000 parts are here, now, at a lower TDP
>> (20W, .vs 25W for the a1100. 22nm rocks).
>>
>> When Intel moves the C2K series to 14nm later this year, the power savings will close the door.
>>
>> The opteron a1100 samples in March, I wouldn?t expect boards before Summer.
I don't track the Atom family and not sure if C2000 is the new
out-of-order version, but until that is available - this is no
comparison by a long shot.
Also 5w on the cpu package could easily be made up for in a superior
motherboard and chassis design. Think about how much power interconnects
takes, PCIe and everything else..
From phk at freebsd.org Tue Feb 4 22:49:28 2014
From: phk at freebsd.org (Poul-Henning Kamp)
Date: Tue, 04 Feb 2014 22:49:24 +0000
Subject: opteron a1100 arm
In-Reply-To: <52F16BA4.4060202@pathscale.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com>
Message-ID: <60985.1391554164@critter.freebsd.dk>
In message <52F16BA4.4060202 at pathscale.com>, =?UTF-8?B?IkMuIEJlcmdzdHLDtm0i?= w
rites:
> Think about how much power interconnects takes, PCIe and everything else..
Not to mention the raw savings of avoiding all the crap that has
been nailed inexpertly onto the X86 platform over the years...
Did you notice that "X86 arduino" Intel just launched ?
Does anybody but me cringe at the thought of an Arduino with UEFI, ACPI,
microcode updates and SMM ticking away in the background to make sure
it doesn't run too hot ?
If ARM and AMD are smart, an ARM64 machine will have the OS loaded
and handed over to in a matter of seconds rather than minutes, and
that alone would make a lot of people love them.
--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
From jim at netgate.com Tue Feb 4 23:31:22 2014
From: jim at netgate.com (Jim Thompson)
Date: Tue, 4 Feb 2014 17:31:12 -0600
Subject: opteron a1100 arm
In-Reply-To: <1391553087.27234.79361889.59679194@webmail.messagingengine.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
<60681.1391550500@critter.freebsd.dk>
<1391553087.27234.79361889.59679194@webmail.messagingengine.com>
Message-ID: <7DAAAE33-2502-410D-A840-5EFB6EB8EE0B@netgate.com>
On Feb 4, 2014, at 4:31 PM, Mark Felder wrote:
>
>
> On Tue, Feb 4, 2014, at 15:48, Poul-Henning Kamp wrote:
>> In message <23B18B88-D888-46B3-99F6-905F86E20FAF at netgate.com>, Jim
>> Thompson wri
>> tes:
>>
>>> The dual 10Gig Ethernet and 8 SATA 3.0 ports are interesting. You
>>> won't get that with a C2K system at 25W TDP [...]
>>
>> Couple that with some decent SSD disks and you have a system that
>> should be able to pump out close to 400k HTTP requests a second
>> running Varnish...
>>
>
> Wow that would be amazing
and then there?s Sandstorm
http://conferences.sigcomm.org/hotnets/2013/papers/hotnets-final43.pdf
From nwhitehorn at freebsd.org Tue Feb 4 23:37:43 2014
From: nwhitehorn at freebsd.org (Nathan Whitehorn)
Date: Tue, 04 Feb 2014 17:37:42 -0600
Subject: opteron a1100 arm
In-Reply-To: <60985.1391554164@critter.freebsd.dk>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com> <60985.1391554164@critter.freebsd.dk>
Message-ID: <52F179C6.2050400@freebsd.org>
On 02/04/14 16:49, Poul-Henning Kamp wrote:
> In message <52F16BA4.4060202 at pathscale.com>, =?UTF-8?B?IkMuIEJlcmdzdHLDtm0i?= w
> rites:
>
>> Think about how much power interconnects takes, PCIe and everything else..
> Not to mention the raw savings of avoiding all the crap that has
> been nailed inexpertly onto the X86 platform over the years...
>
> Did you notice that "X86 arduino" Intel just launched ?
>
> Does anybody but me cringe at the thought of an Arduino with UEFI, ACPI,
> microcode updates and SMM ticking away in the background to make sure
> it doesn't run too hot ?
>
This AMD platform has UEFI and ACPI, so that's at least 2 out of 4...
-Nathan
From jim at netgate.com Wed Feb 5 00:23:17 2014
From: jim at netgate.com (Jim Thompson)
Date: Tue, 4 Feb 2014 18:23:08 -0600
Subject: opteron a1100 arm
In-Reply-To: <52F16BA4.4060202@pathscale.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com>
Message-ID: <8537A333-176E-4DF4-A712-2ADFE1B75338@netgate.com>
On Feb 4, 2014, at 4:37 PM, C. Bergstr?m wrote:
> I don't track the Atom family and not sure if C2000 is the new out-of-order version, but until that is available - this is no comparison by a long shot.
Yes, the C2000 SoCs and Bay Trail are Silvermont architecture. Silvermont has OOE and a better branch predictor than did Bonnell or Saltwell.
At 22nm, Intel had enough die area to just add in more cores rather than rely on ?hyper threading" for better threaded performance so Hyper Threading isn?t part of this SoC. The ISA
is roughly Westmere (think 2010 Core architecture). AES-NI, SSE4.1/4.2 and extended page tables (so: bhyve) are all ?in there?.
> Also 5w on the cpu package could easily be made up for in a superior motherboard and chassis design. Think about how much power interconnects takes, PCIe and everything else..
That?s why the infrastructure guys ( ? Dell, HP, NEC, Ericsson, Quanta, Supermicro, etc) are building micro server systems with 450 ?nodes? per rack.
From jim at netgate.com Wed Feb 5 00:35:25 2014
From: jim at netgate.com (Jim Thompson)
Date: Tue, 4 Feb 2014 18:35:15 -0600
Subject: opteron a1100 arm
In-Reply-To: <52F179C6.2050400@freebsd.org>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com> <60985.1391554164@critter.freebsd.dk>
<52F179C6.2050400@freebsd.org>
Message-ID:
On Feb 4, 2014, at 5:37 PM, Nathan Whitehorn wrote:
> On 02/04/14 16:49, Poul-Henning Kamp wrote:
>> In message <52F16BA4.4060202 at pathscale.com>, =?UTF-8?B?IkMuIEJlcmdzdHLDtm0i?= w
>> rites:
>>
>>> Think about how much power interconnects takes, PCIe and everything else..
>> Not to mention the raw savings of avoiding all the crap that has
>> been nailed inexpertly onto the X86 platform over the years...
>>
>> Did you notice that "X86 arduino" Intel just launched ?
>>
>> Does anybody but me cringe at the thought of an Arduino with UEFI, ACPI,
>> microcode updates and SMM ticking away in the background to make sure
>> it doesn't run too hot ?
>>
>
> This AMD platform has UEFI and ACPI, so that's at least 2 out of 4...
> -Nathan
The ?X86 arduino? (?Gallileo?) has a Quark 1100 SoC running at 400MHz. It implements a 32-bit Pentium instruction set and has a TDP of 1.9W - 2.2W.
I don?t think it?s going to ?run too hot?, and yes it runs SMM, UEFI and ACPI-compatible sleep states.
From adrian at freebsd.org Wed Feb 5 02:09:47 2014
From: adrian at freebsd.org (Adrian Chadd)
Date: Tue, 4 Feb 2014 18:09:46 -0800
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com>
<60985.1391554164@critter.freebsd.dk>
<52F179C6.2050400@freebsd.org>
Message-ID:
On 4 February 2014 16:35, Jim Thompson wrote:
>
> On Feb 4, 2014, at 5:37 PM, Nathan Whitehorn wrote:
>
>> On 02/04/14 16:49, Poul-Henning Kamp wrote:
>>> In message <52F16BA4.4060202 at pathscale.com>, =?UTF-8?B?IkMuIEJlcmdzdHLDtm0i?= w
>>> rites:
>>>
>>>> Think about how much power interconnects takes, PCIe and everything else..
>>> Not to mention the raw savings of avoiding all the crap that has
>>> been nailed inexpertly onto the X86 platform over the years...
>>>
>>> Did you notice that "X86 arduino" Intel just launched ?
>>>
>>> Does anybody but me cringe at the thought of an Arduino with UEFI, ACPI,
>>> microcode updates and SMM ticking away in the background to make sure
>>> it doesn't run too hot ?
>>>
>>
>> This AMD platform has UEFI and ACPI, so that's at least 2 out of 4...
>> -Nathan
>
> The "X86 arduino" ("Gallileo") has a Quark 1100 SoC running at 400MHz. It implements a 32-bit Pentium instruction set and has a TDP of 1.9W - 2.2W.
>
> I don't think it's going to "run too hot", and yes it runs SMM, UEFI and ACPI-compatible sleep states.
We'd still have to port to that platform.
I'd give it go if someone would ship me one. :)
-a
From adrian at freebsd.org Wed Feb 5 02:37:56 2014
From: adrian at freebsd.org (Adrian Chadd)
Date: Tue, 4 Feb 2014 18:37:54 -0800
Subject: opteron a1100 arm
In-Reply-To: <52F19E8F.1030101@pathscale.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com>
<60985.1391554164@critter.freebsd.dk>
<52F179C6.2050400@freebsd.org>
<52F19E8F.1030101@pathscale.com>
Message-ID:
The first project is "make 32 bit uefi booting work."
That's kind of a requirement.
-a
From adrian at freebsd.org Wed Feb 5 02:13:23 2014
From: adrian at freebsd.org (Adrian Chadd)
Date: Tue, 4 Feb 2014 18:13:21 -0800
Subject: opteron a1100 arm
In-Reply-To: <60985.1391554164@critter.freebsd.dk>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com>
<60985.1391554164@critter.freebsd.dk>
Message-ID:
On 4 February 2014 14:49, Poul-Henning Kamp wrote:
> In message <52F16BA4.4060202 at pathscale.com>, =?UTF-8?B?IkMuIEJlcmdzdHLDtm0i?= w
> rites:
>
>> Think about how much power interconnects takes, PCIe and everything else..
>
> Not to mention the raw savings of avoiding all the crap that has
> been nailed inexpertly onto the X86 platform over the years...
>
> Did you notice that "X86 arduino" Intel just launched ?
>
> Does anybody but me cringe at the thought of an Arduino with UEFI, ACPI,
> microcode updates and SMM ticking away in the background to make sure
> it doesn't run too hot ?
>
> If ARM and AMD are smart, an ARM64 machine will have the OS loaded
> and handed over to in a matter of seconds rather than minutes, and
> that alone would make a lot of people love them.
My experience with ARM and power management is that as the chips get
more recent, the voodoo hiding behind black boxes increases.
Qualcomm wouldn't even contemplate open sourcing the power management stuff.
I have more faith that the intel stuff will at least be sanely usable
by us OS hackers over what the multiplude of ARM vendors have given
us. It looks like a mess and I've only vaguely peripherally looked at
it.
-a
From cbergstrom at pathscale.com Wed Feb 5 02:18:12 2014
From: cbergstrom at pathscale.com (=?ISO-8859-1?Q?=22C=2E_Bergstr=F6m=22?=)
Date: Wed, 05 Feb 2014 09:14:39 +0700
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com> <60985.1391554164@critter.freebsd.dk>
<52F179C6.2050400@freebsd.org>
Message-ID: <52F19E8F.1030101@pathscale.com>
On 02/ 5/14 09:09 AM, Adrian Chadd wrote:
> On 4 February 2014 16:35, Jim Thompson wrote:
>> On Feb 4, 2014, at 5:37 PM, Nathan Whitehorn wrote:
>>
>>> On 02/04/14 16:49, Poul-Henning Kamp wrote:
>>>> In message <52F16BA4.4060202 at pathscale.com>, =?UTF-8?B?IkMuIEJlcmdzdHLDtm0i?= w
>>>> rites:
>>>>
>>>>> Think about how much power interconnects takes, PCIe and everything else..
>>>> Not to mention the raw savings of avoiding all the crap that has
>>>> been nailed inexpertly onto the X86 platform over the years...
>>>>
>>>> Did you notice that "X86 arduino" Intel just launched ?
>>>>
>>>> Does anybody but me cringe at the thought of an Arduino with UEFI, ACPI,
>>>> microcode updates and SMM ticking away in the background to make sure
>>>> it doesn't run too hot ?
>>>>
>>> This AMD platform has UEFI and ACPI, so that's at least 2 out of 4...
>>> -Nathan
>> The "X86 arduino" ("Gallileo") has a Quark 1100 SoC running at 400MHz. It implements a 32-bit Pentium instruction set and has a TDP of 1.9W - 2.2W.
>>
>> I don't think it's going to "run too hot", and yes it runs SMM, UEFI and ACPI-compatible sleep states.
> We'd still have to port to that platform.
>
> I'd give it go if someone would ship me one. :)
If a few of these could be procured - I wonder if this is a good GSOC
topic? Anyone know any students who might be interested?
From superbisquit at gmail.com Wed Feb 5 05:35:42 2014
From: superbisquit at gmail.com (Joe Nosay)
Date: Wed, 5 Feb 2014 00:35:40 -0500
Subject: WebRTC
Message-ID:
Is it stupid for me to try to port WebRTC plus dependencies to FreeBSD?
I am not good at programming; but, I try to find and/or ask for solutions
so that a program can work in/on FreeBSD.
What I am aware of is that even if it is a good idea, unless it has been
presented by someone more well known or higher up in the food chain, it
will be ignored. I could say," Hey, know what? If we start on such-and-such
right now, then FreeBSD will be at the same level as X and Y in this."
However, I know that such words are useless from someone on the bottom.
As I states, my knowledge is limited; yet, a starting effort has been done
for webrtc. I can't do much more. Why? Because I am homeless and sick,
that's why.
Adrian Chadd asked on Google+ about FreeBSD having webrtc; and, I decided
to try to start it. I'm stuck at the beginning step of porting a
dependency. I re-edited the file paths in
/usr/local/include/unicode/$ITEM.c_OR_h .
I decided to present this idea to the list even after being taunted.
There is no reason to worry about who says what.
From lev at FreeBSD.org Wed Feb 5 09:54:05 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Wed, 5 Feb 2014 13:53:52 +0400
Subject: opteron a1100 arm
In-Reply-To: <20140204223528.GF23872@ithaqua.etoilebsd.net>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
Message-ID: <18209443.20140205135352@serebryakov.spb.ru>
Hello, Baptiste.
You wrote 5 ??????? 2014 ?., 2:35:28:
BD> A board like this will allow portmgr to provide official and regular package
BD> built for arm! so yes for sure we do need to support that!
Again: it is ARMv8. So, board like this will allow portmgr to provide official and regular package
built for arm in same sense, that amd64-based board will help to build
packages for i386 :)
--
// Black Lion AKA Lev Serebryakov
From bapt at FreeBSD.org Wed Feb 5 10:05:00 2014
From: bapt at FreeBSD.org (Baptiste Daroussin)
Date: Wed, 5 Feb 2014 11:04:54 +0100
Subject: opteron a1100 arm
In-Reply-To: <18209443.20140205135352@serebryakov.spb.ru>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<18209443.20140205135352@serebryakov.spb.ru>
Message-ID: <20140205100453.GH23872@ithaqua.etoilebsd.net>
On Wed, Feb 05, 2014 at 01:53:52PM +0400, Lev Serebryakov wrote:
> Hello, Baptiste.
> You wrote 5 ??????? 2014 ?., 2:35:28:
>
> BD> A board like this will allow portmgr to provide official and regular package
> BD> built for arm! so yes for sure we do need to support that!
> Again: it is ARMv8. So, board like this will allow portmgr to provide official and regular package
> built for arm in same sense, that amd64-based board will help to build
> packages for i386 :)
>
Yes and we do build i386 packages on and amd64 box :)
regards,
Bapt
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL:
From phk at phk.freebsd.dk Wed Feb 5 08:01:12 2014
From: phk at phk.freebsd.dk (Poul-Henning Kamp)
Date: Wed, 05 Feb 2014 08:01:02 +0000
Subject: opteron a1100 arm
In-Reply-To: <52F179C6.2050400@freebsd.org>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com> <60985.1391554164@critter.freebsd.dk>
<52F179C6.2050400@freebsd.org>
Message-ID: <62389.1391587262@critter.freebsd.dk>
In message <52F179C6.2050400 at freebsd.org>, Nathan Whitehorn writes:
>This AMD platform has UEFI and ACPI, so that's at least 2 out of 4...
Ahh crap!
--
Poul-Henning Kamp | UNIX since Zilog Zeus 3.20
phk at FreeBSD.ORG | TCP/IP since RFC 956
FreeBSD committer | BSD since 4.3-tahoe
Never attribute to malice what can adequately be explained by incompetence.
From kevin.bowling at kev009.com Wed Feb 5 08:05:16 2014
From: kevin.bowling at kev009.com (Kevin Bowling)
Date: Wed, 05 Feb 2014 00:55:22 -0700
Subject: opteron a1100 arm
In-Reply-To: <23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID:
On 2/4/2014 2:42 PM, Jim Thompson wrote:
>
> On Feb 4, 2014, at 3:29 PM, Poul-Henning Kamp wrote:
>
>> In message <493DEB39-C4B4-409E-B8B2-B1B11E013754 at netgate.com>, Jim Thompson wri
>> tes:
>>
>>>> No but it may well be an early reminder of the upcoming generation of
>>>> powerful ARM servers that we don't want to leave unsupported.
>>>
>>> isn't that attractive when the 8-core, 64-bit Intel C20
>>> 00 parts are here, now, at a lower TDP
>>> (20W, .vs 25W for the a1100. 22nm rocks).
>>
>> I very much welcome a competing 64bit CPU into the marketplace and
>> will buy one myself, as soon as I can, for no other reason than to
>> help break the X86 monopoly on server architecture.
>>
>> Monopolies are never a good thing.
>
> True, but I didn?t say that the chip wasn?t interesting. What I said is that it?s not that attractive (to the real market for these: micro servers).
>
> The dual 10Gig Ethernet and 8 SATA 3.0 ports are interesting. You won?t get that with a C2K system at 25W TDP, (4 x GigE that can run at 2.5Gbps per port, and 2 SATA 3.0 ports currently) but Intel owns IP for both, so if that becomes a differentiator for design wins, I?d expect a future variant to cover.
>
> But by all means, port FreeBSD to it. Perhaps it can be the long-desired ?reference platform? to bring ARM into a ?Tier 1? architecture status.
>
> Jim
Where A1100 wins hands down is memory capacity, and possibly even memory
bandwidth (DDR4 mentioned in the PR..).
Intel's server Atom chips and even the extremely powerful Xeon E3 are
quite limited by 32GB RAM (and it's also somewhat expensive vs RDIMMs).
This just doesn't cut it for a ton of workloads either family of Intel
CPU is otherwise well suited for.
The A1100 is going to force Intel to fix that nonsense quickly or see a
rapid exodus on the low end.
From jim at netgate.com Wed Feb 5 13:45:00 2014
From: jim at netgate.com (Jim Thompson)
Date: Wed, 5 Feb 2014 07:44:55 -0600
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID:
> On Feb 5, 2014, at 1:55, Kevin Bowling wrote:
>
[...]
> Where A1100 wins hands down is memory capacity, and possibly even memory bandwidth (DDR4 mentioned in the PR..).
>
> Intel's server Atom chips and even the extremely powerful Xeon E3 are quite limited by 32GB RAM (and it's also somewhat expensive vs RDIMMs).
I'm not sure what your point is.
The C2750, C2550, C2558 & C2758 will all address 64 GB of DDR3 RAM.
You'll have to use Registered DIMMs and likely drop back to DDR3 to get to 128GB on the A1100.
So I see parity in terms of addressable RAM.
From george+freebsd at m5p.com Wed Feb 5 14:09:38 2014
From: george+freebsd at m5p.com (George Mitchell)
Date: Wed, 05 Feb 2014 09:09:31 -0500
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID: <52F2461B.1070405@m5p.com>
On 02/05/14 08:44, Jim Thompson wrote:
>
>
>> On Feb 5, 2014, at 1:55, Kevin Bowling wrote:
>>
> [...]
>
>> Where A1100 wins hands down is memory capacity, and possibly even memory bandwidth (DDR4 mentioned in the PR..).
>>
>> Intel's server Atom chips and even the extremely powerful Xeon E3 are quite limited by 32GB RAM (and it's also somewhat expensive vs RDIMMs).
>
> I'm not sure what your point is.
>
> The C2750, C2550, C2558 & C2758 will all address 64 GB of DDR3 RAM.
>
> You'll have to use Registered DIMMs and likely drop back to DDR3 to get to 128GB on the A1100.
>
> So I see parity in terms of addressable RAM.
>
> [...]
This discussion is very entertaining. But let's not lose sight of the
main point: ARM processors are not going away. It is to FreeBSD's
detriment if we don't have Tier 1 support for a processor that, by some
guesses, already comprises the majority of new installations by count.
-- George
From Kamil.Choudhury at anserinae.net Wed Feb 5 14:34:55 2014
From: Kamil.Choudhury at anserinae.net (Kamil Choudhury)
Date: Wed, 5 Feb 2014 14:34:50 +0000
Subject: opteron a1100 arm
In-Reply-To: <52F2461B.1070405@m5p.com>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
, <52F2461B.1070405@m5p.com>
Message-ID:
George wrote:
> This discussion is very entertaining. But let's not lose sight of the
> main point: ARM processors are not going away. It is to FreeBSD's
> detriment if we don't have Tier 1 support for a processor that, by some
> guesses, already comprises the majority of new installations by count.
Moving on to specifics, what concrete steps would be necessary to actually
get FreeBSD support for this architecture?
_______________________________________________
freebsd-hackers at freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
From george+freebsd at m5p.com Wed Feb 5 15:02:55 2014
From: george+freebsd at m5p.com (George Mitchell)
Date: Wed, 05 Feb 2014 10:02:48 -0500
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
,
<52F2461B.1070405@m5p.com>
Message-ID: <52F25298.9000307@m5p.com>
On 02/05/14 09:34, Kamil Choudhury wrote:
>
> George wrote:
>> This discussion is very entertaining. But let's not lose sight of the
>> main point: ARM processors are not going away. It is to FreeBSD's
>> detriment if we don't have Tier 1 support for a processor that, by some
>> guesses, already comprises the majority of new installations by count.
>
> Moving on to specifics, what concrete steps would be necessary to actually
> get FreeBSD support for this architecture? [...]
https://wiki.freebsd.org/ARMTier1 -- George
From lidl at pix.net Wed Feb 5 17:23:17 2014
From: lidl at pix.net (Kurt Lidl)
Date: Wed, 05 Feb 2014 12:23:14 -0500
Subject: opteron a1100 arm
In-Reply-To: <62389.1391587262@critter.freebsd.dk>
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<20140204223528.GF23872@ithaqua.etoilebsd.net>
<52F16BA4.4060202@pathscale.com> <60985.1391554164@critter.freebsd.dk>
<52F179C6.2050400@freebsd.org> <62389.1391587262@critter.freebsd.dk>
Message-ID: <52F27382.1030505@pix.net>
On 2/5/14 3:01 AM, Poul-Henning Kamp wrote:
> In message <52F179C6.2050400 at freebsd.org>, Nathan Whitehorn writes:
>
>> This AMD platform has UEFI and ACPI, so that's at least 2 out of 4...
>
> Ahh crap!
>
It's actually more than that. The AMD64 platform has been called out
for a much greater deal of standardization than the multitude of
different options in the various existing ARM SoC boards.
The phrase you want to search for is:
ARM Server Base System Architecture
Of course, the reference doc:
http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.den0029/index.html
Is only available to registered ARM customers.
But, my understanding is that UEFI is the only boot option,
ACPI is the power management system, the USB2 controllers must
support EHCI 1.1, the USB3 controllers must support XHCI 1.0
and all SATA controllers must support AHCI 1.3.
They're attempting to drive the platform to a more standardized
set of components and boot methods (and hypervisor support) so
that if your software works on vendor A's SBSA board, it should
also work on vendor B's SBSA board.
-Kurt
From kevin.bowling at kev009.com Wed Feb 5 18:11:51 2014
From: kevin.bowling at kev009.com (Kevin Bowling)
Date: Wed, 05 Feb 2014 11:11:30 -0700
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID:
On 2/5/2014 6:44 AM, Jim Thompson wrote:
>
>
>> On Feb 5, 2014, at 1:55, Kevin Bowling wrote:
>>
> [...]
>
>> Where A1100 wins hands down is memory capacity, and possibly even memory bandwidth (DDR4 mentioned in the PR..).
>>
>> Intel's server Atom chips and even the extremely powerful Xeon E3 are quite limited by 32GB RAM (and it's also somewhat expensive vs RDIMMs).
>
> I'm not sure what your point is.
Simply that this is a better chip than Intel's current low end offerings
because all relevant bandwidths are much higher (RAM, I/O, net) and
these matter more to many DC workloads.
> The C2750, C2550, C2558 & C2758 will all address 64 GB of DDR3 RAM.
>
> You'll have to use Registered DIMMs and likely drop back to DDR3 to get to 128GB on the A1100.
>
> So I see parity in terms of addressable RAM.
That's half, and a big deal if you want to run multiple VMs or a large
ARC or many large JVM heaps or any number of other things. You're
trying to claim the chip is already matched by the current Atom, where
it is clearly not, so I'll fire it back at you - I'm not sure what your
point is.
I'm happy to see the announcement and am looking forward to running
FreeBSD on the platform with others.
From dieterbsd at gmail.com Wed Feb 5 18:41:26 2014
From: dieterbsd at gmail.com (Dieter BSD)
Date: Wed, 5 Feb 2014 10:41:24 -0800
Subject: opteron a1100 arm
Message-ID:
Jim writes:
> So I see parity in terms of addressable RAM.
Parity is better than nothing (which seems to be what most machines
provide these days :-( ), but ECC is much better. :-)
Speaking of new machines and ECC, anyone heard any news about
an ETA for Berlin? (and mainboards for it that support ECC?)
(google finds nothing)
From adrian at freebsd.org Wed Feb 5 19:35:41 2014
From: adrian at freebsd.org (Adrian Chadd)
Date: Wed, 5 Feb 2014 11:35:39 -0800
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
Message-ID:
On 5 February 2014 10:11, Kevin Bowling wrote:
> On 2/5/2014 6:44 AM, Jim Thompson wrote:
>>
>>
>>
>>> On Feb 5, 2014, at 1:55, Kevin Bowling wrote:
>>>
>> [...]
>>
>>> Where A1100 wins hands down is memory capacity, and possibly even memory
>>> bandwidth (DDR4 mentioned in the PR..).
>>>
>>> Intel's server Atom chips and even the extremely powerful Xeon E3 are
>>> quite limited by 32GB RAM (and it's also somewhat expensive vs RDIMMs).
>>
>>
>> I'm not sure what your point is.
>
>
> Simply that this is a better chip than Intel's current low end offerings
> because all relevant bandwidths are much higher (RAM, I/O, net) and these
> matter more to many DC workloads.
>
>
>> The C2750, C2550, C2558 & C2758 will all address 64 GB of DDR3 RAM.
>>
>> You'll have to use Registered DIMMs and likely drop back to DDR3 to get to
>> 128GB on the A1100.
>>
>> So I see parity in terms of addressable RAM.
>
>
> That's half, and a big deal if you want to run multiple VMs or a large ARC
> or many large JVM heaps or any number of other things. You're trying to
> claim the chip is already matched by the current Atom, where it is clearly
> not, so I'll fire it back at you - I'm not sure what your point is.
>
> I'm happy to see the announcement and am looking forward to running FreeBSD
> on the platform with others.
But that's not enough - some one / some company has to step up and do
a port, then run with it long enough in -HEAD to make it stable for
general use.
Almost all of the ARM stuff in FreeBSD doesn't fall under this
category. It's getting better, but in a lot of instances the ports are
done for very specific chipsets and/or use cases and that doesn't
stress the rest of the system out enough.
The MIPS port went through this too, FWIW - it initially was stable if
you never bothered doing much in userland, but userland suffered from
a lot of random hilarity. so if you were a router that occasionally
ran ntpd, it was great. If you were an AP that kept going into hostapd
to do things, it would get upset. "make all install clean" in a port
directory wasn't great. It was only through repeated head-slamming
from Warner, Juli and others that this stuff got ironed out enough.
So, I'm all for the platform - who's going to port it? Step up please
and be cheered. :-P
-a
From imp at bsdimp.com Thu Feb 6 20:57:06 2014
From: imp at bsdimp.com (Warner Losh)
Date: Thu, 6 Feb 2014 13:56:54 -0700
Subject: opteron a1100 arm
In-Reply-To:
References:
<1391538649.19169.79261269.3C5F49D1@webmail.messagingengine.com>
<493DEB39-C4B4-409E-B8B2-B1B11E013754@netgate.com>
<60555.1391549390@critter.freebsd.dk>
<23B18B88-D888-46B3-99F6-905F86E20FAF@netgate.com>
,
<52F2461B.1070405@m5p.com>
Message-ID:
On Feb 5, 2014, at 7:34 AM, Kamil Choudhury wrote:
>
> George wrote:
>> This discussion is very entertaining. But let's not lose sight of the
>> main point: ARM processors are not going away. It is to FreeBSD's
>> detriment if we don't have Tier 1 support for a processor that, by some
>> guesses, already comprises the majority of new installations by count.
>
> Moving on to specifics, what concrete steps would be necessary to actually
> get FreeBSD support for this architecture?
You'll need a new pmap for arm, and a bunch of other things. Plus you'll need to get ACPI working on arm64, and you may also need FDT + ACPI coexistence depending on your development route. Plus you'll need arm64 (aarch64) support in llvm and/or some external toolchain (which would mean you'd need to beef up the external toolchain support for freebsd's build). And then you'll need new drivers. And people to test it and hammer it and fix the stability issues that pop up. And that's not even considering the issues with pkg support etc.
It is a heavy lift to get all the way there, although a 'hack' port that gets to single user with a ram-disk or nfs root and a serial port working wouldn't be too hard.
So it's like Ian said: we need bodies working on this... So far, I'm only aware of one part timer.
Warner
From imp at bsdimp.com Thu Feb 6 21:00:54 2014
From: imp at bsdimp.com (Warner Losh)
Date: Thu, 6 Feb 2014 14:00:51 -0700
Subject: remove shutdown messages in console
In-Reply-To: <52F05DFC.7070007@freebsd.org>
References:
<52F05DFC.7070007@freebsd.org>
Message-ID: <1D565840-1ADA-4567-85B0-FB4AE771B823@bsdimp.com>
On Feb 3, 2014, at 8:26 PM, Julian Elischer wrote:
> On 2/2/14, 6:07 PM, Reza Mirzazadeh wrote:
>> hi . how can i remove shutdown messages in console ? or even print my
>> arbitrary messages in console ?
>>
>>
>> *** FINAL System shutdown message from root at geekiam ***
>> System going down IMMEDIATELY
>>
>> some messages like these ! i don't want it print theses messages
>> --
>> _______________________________________________
>> freebsd-hackers at freebsd.org mailing list
>> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
>> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
>>
> we implimented the consmute sysctl option to "mute" an otherwise configured console for exactly this purpose.
> (and boot messages).
Except these are different beast. They aren't kernel messages, but generated by userland...
to get rid of these, hack /etc/syslog.conf to get rid of the *.emerg * line.
Or hack shutdown to stop sending them....
Or use 'halt' and 'reboot' only
Warner
From lev at FreeBSD.org Fri Feb 7 13:50:07 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Fri, 7 Feb 2014 17:49:57 +0400
Subject: Why clang bundled with 10-RELEASE doesn't define
__has_feature(cxx_nullptr)?
Message-ID: <717736061.20140207174957@serebryakov.spb.ru>
Hello, freebsd-stable.
Why __has_feature(cxx_nulptr) doesn't work on system compiler? nullptr
itself works!
Here is sample program:
============================= test.cxx
#include
#ifndef __has_feature
#warning "Doesn't support for __has_feature at all"
#define __has_feature(x) 0
#endif
#if __has_feature(cxx_nullptr)
#warning "Has nullptr"
#else
#warning "Doesn't have nullptr"
#endif
int main(int argn, char *argv[]) {
void *v = nullptr;
return 0;
}
======================================
> c++ --version
FreeBSD clang version 3.3 (tags/RELEASE_33/final 183502) 20130610
Target: x86_64-unknown-freebsd10.0
Thread model: posix
> c++ test.cxx
test.cxx:11:2: warning: "Doesn't have nullptr" [-W#warnings]
#warning "Doesn't have nullptr"
^
1 warning generated.
>
--
// Black Lion AKA Lev Serebryakov
From dim at FreeBSD.org Fri Feb 7 15:47:51 2014
From: dim at FreeBSD.org (Dimitry Andric)
Date: Fri, 7 Feb 2014 16:47:31 +0100
Subject: Why clang bundled with 10-RELEASE doesn't define
__has_feature(cxx_nullptr)?
In-Reply-To: <717736061.20140207174957@serebryakov.spb.ru>
References: <717736061.20140207174957@serebryakov.spb.ru>
Message-ID: <4D300C6C-4684-4C42-B059-4CC40258358F@FreeBSD.org>
On 07 Feb 2014, at 14:49, Lev Serebryakov wrote:
> Hello, freebsd-stable.
>
> Why __has_feature(cxx_nulptr) doesn't work on system compiler? nullptr
> itself works!
...
>> c++ test.cxx
> test.cxx:11:2: warning: "Doesn't have nullptr" [-W#warnings]
> #warning "Doesn't have nullptr"
Hi Lev,
You need to specify at least -std=c++0x for nullptr to be 'officially' available.
-Dimitry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 203 bytes
Desc: Message signed with OpenPGP using GPGMail
URL:
From lev at FreeBSD.org Fri Feb 7 16:34:26 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Fri, 7 Feb 2014 20:34:17 +0400
Subject: Is it possible to get make variable without recursive expansion?
Message-ID: <12310461351.20140207203417@serebryakov.spb.ru>
Hello, Freebsd-hackers.
Suppose, I have in my Makefile such construction:
A=xxx
B=yyy
ANB=${A} and ${B}
Is it possible to get value of ANB without recursive expansion, i.e. string
"${A} and ${B} and" in this case? I know, that all expansions are done at
last moment (If I don't use ":=" operator), but is it possible to block
second- and more-level expansion?
I need to output "ANB=${ANB}" construction to external file without further
expansion...
--
// Black Lion AKA Lev Serebryakov
From bright at mu.org Fri Feb 7 18:25:27 2014
From: bright at mu.org (Alfred Perlstein)
Date: Fri, 07 Feb 2014 10:25:30 -0800
Subject: Is it possible to get make variable without recursive expansion?
In-Reply-To: <12310461351.20140207203417@serebryakov.spb.ru>
References: <12310461351.20140207203417@serebryakov.spb.ru>
Message-ID: <52F5251A.8020401@mu.org>
On 2/7/14 8:34 AM, Lev Serebryakov wrote:
> Hello, Freebsd-hackers.
>
>
> Suppose, I have in my Makefile such construction:
>
> A=xxx
> B=yyy
> ANB=${A} and ${B}
>
> Is it possible to get value of ANB without recursive expansion, i.e. string
> "${A} and ${B} and" in this case? I know, that all expansions are done at
> last moment (If I don't use ":=" operator), but is it possible to block
> second- and more-level expansion?
>
> I need to output "ANB=${ANB}" construction to external file without further
> expansion...
>
a:
echo "AMB=\$${AMB}"
?
--
Alfred Perlstein
From lev at FreeBSD.org Fri Feb 7 18:52:14 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Fri, 7 Feb 2014 22:52:05 +0400
Subject: Is it possible to get make variable without recursive expansion?
In-Reply-To: <52F5251A.8020401@mu.org>
References: <12310461351.20140207203417@serebryakov.spb.ru>
<52F5251A.8020401@mu.org>
Message-ID: <201495029.20140207225205@serebryakov.spb.ru>
Hello, Alfred.
You wrote 7 ??????? 2014 ?., 22:25:30:
AP> On 2/7/14 8:34 AM, Lev Serebryakov wrote:
>> Hello, Freebsd-hackers.
>>
>>
>> Suppose, I have in my Makefile such construction:
>>
>> A=xxx
>> B=yyy
>> ANB=${A} and ${B}
>>
>> Is it possible to get value of ANB without recursive expansion, i.e. string
>> "${A} and ${B} and" in this case? I know, that all expansions are done at
>> last moment (If I don't use ":=" operator), but is it possible to block
>> second- and more-level expansion?
>>
>> I need to output "ANB=${ANB}" construction to external file without further
>> expansion...
>>
AP> a:
AP> echo "AMB=\$${AMB}"
It will echo "AMB=${AMB}" as-is, as far as I understand, it is simple. And I need to get
"ANB=${A} and ${B}" output.
--
// Black Lion AKA Lev Serebryakov
From bright at mu.org Fri Feb 7 19:07:47 2014
From: bright at mu.org (Alfred Perlstein)
Date: Fri, 07 Feb 2014 11:07:50 -0800
Subject: Is it possible to get make variable without recursive expansion?
In-Reply-To: <201495029.20140207225205@serebryakov.spb.ru>
References: <12310461351.20140207203417@serebryakov.spb.ru>
<52F5251A.8020401@mu.org> <201495029.20140207225205@serebryakov.spb.ru>
Message-ID: <52F52F06.8080605@mu.org>
On 2/7/14 10:52 AM, Lev Serebryakov wrote:
> Hello, Alfred.
> You wrote 7 ??????? 2014 ?., 22:25:30:
>
> AP> On 2/7/14 8:34 AM, Lev Serebryakov wrote:
>>> Hello, Freebsd-hackers.
>>>
>>>
>>> Suppose, I have in my Makefile such construction:
>>>
>>> A=xxx
>>> B=yyy
>>> ANB=${A} and ${B}
>>>
>>> Is it possible to get value of ANB without recursive expansion, i.e. string
>>> "${A} and ${B} and" in this case? I know, that all expansions are done at
>>> last moment (If I don't use ":=" operator), but is it possible to block
>>> second- and more-level expansion?
>>>
>>> I need to output "ANB=${ANB}" construction to external file without further
>>> expansion...
>>>
> AP> a:
> AP> echo "AMB=\$${AMB}"
> It will echo "AMB=${AMB}" as-is, as far as I understand, it is simple. And I need to get
> "ANB=${A} and ${B}" output.
>
>
>
I do not think it's possible. You're basically asking "is there a way
to ask Make for the text on the lhs of the variable assignment WITHOUT
expansion?
Your only option would be to "cheat" and not use the expanded form I think:
A=aaa
B=bbb
AMB=\$${A} and \$${B}
a:
echo "AMB=${AMB}"
Results in:
.(19:07:30)(alfred at freefall.freebsd.org)
~ % make
echo "AMB=\${A} and \${B}"
AMB=${A} and ${B}
.(19:07:30)(alfred at freefall.freebsd.org)
~ %
There is no way to query make(1) (that I can see) for the exact value at
the time of assignment and before expansion.
--
Alfred Perlstein
From lev at FreeBSD.org Fri Feb 7 19:38:53 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Fri, 7 Feb 2014 23:38:44 +0400
Subject: Is it possible to get make variable without recursive expansion?
In-Reply-To: <52F52F06.8080605@mu.org>
References: <12310461351.20140207203417@serebryakov.spb.ru>
<52F5251A.8020401@mu.org> <201495029.20140207225205@serebryakov.spb.ru>
<52F52F06.8080605@mu.org>
Message-ID: <933525355.20140207233844@serebryakov.spb.ru>
Hello, Alfred.
You wrote 7 ??????? 2014 ?., 23:07:50:
AP> Your only option would be to "cheat" and not use the expanded form I think:
AP> A=aaa
AP> B=bbb
AP> AMB=\$${A} and \$${B}
AP> a:
AP> echo "AMB=${AMB}"
AP> Results in:
AP> .(19:07:30)(alfred at freefall.freebsd.org)
AP> ~ % make
AP> echo "AMB=\${A} and \${B}"
AP> AMB=${A} and ${B}
AP> .(19:07:30)(alfred at freefall.freebsd.org)
AP> ~ %
AP> There is no way to query make(1) (that I can see) for the exact value at
AP> the time of assignment and before expansion.
It is pity, because I need to make it with MAKE_ENV & CONFIGURE_MAKE
variables in out port system :(
--
// Black Lion AKA Lev Serebryakov
From hrs at FreeBSD.org Fri Feb 7 19:46:56 2014
From: hrs at FreeBSD.org (Hiroki Sato)
Date: Sat, 08 Feb 2014 04:45:59 +0900 (JST)
Subject: Is it possible to get make variable without recursive expansion?
In-Reply-To: <12310461351.20140207203417@serebryakov.spb.ru>
References: <12310461351.20140207203417@serebryakov.spb.ru>
Message-ID: <20140208.044559.1454108709341728013.hrs@allbsd.org>
Lev Serebryakov wrote
in <12310461351.20140207203417 at serebryakov.spb.ru>:
le> Hello, Freebsd-hackers.
le>
le>
le> Suppose, I have in my Makefile such construction:
le>
le> A=xxx
le> B=yyy
le> ANB=${A} and ${B}
le>
le> Is it possible to get value of ANB without recursive expansion, i.e. string
le> "${A} and ${B} and" in this case? I know, that all expansions are done at
le> last moment (If I don't use ":=" operator), but is it possible to block
le> second- and more-level expansion?
le>
le> I need to output "ANB=${ANB}" construction to external file without further
le> expansion...
This may be what you want but works only with bmake:
----Makefile----
A=xxx
B=yyy
ANB=${A} and ${B}
all:
@echo ANB=$$(make -VANB)
@echo ANB=$$(make .MAKE.EXPAND_VARIABLES=0 -VANB)
----Makefile----
-- Hiroki
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 181 bytes
Desc: not available
URL:
From dieterbsd at gmail.com Fri Feb 7 20:19:26 2014
From: dieterbsd at gmail.com (Dieter BSD)
Date: Fri, 7 Feb 2014 12:19:23 -0800
Subject: opteron a1100 arm
Message-ID:
STefan writes,
"parity" == "Gleichstand" ...
Ya, ya, Ich verstehen. The parity-verses-ECC stuff was an (apparently failed)
attempt at humor, hence the ":-)".
Mark asks,
> Is it even available to purchase?
"AMD this quarter will ship the software development kits (CPUs, mainboards,
etc.) to select software developers."
"AMD Opteron A1100 "Seattle" system-on-chips will be commercially available
in the second half of 2014."
"The extremely popular GNU C compiler and the critical GNU C Library have
already been ported to the 64-bit ARM architecture."
The kit of course comes with penguinix.
The bad news is that it has only 8 PCIe lanes. Are expansion cards
considered uncool these days, or what? How are you supposed to add all
the essential stuff they leave off the mainboard?
http://www.xbitlabs.com/news/cpu/display/20140131110927_AMD_to_Ship_ARM_Based_Opteron_PCs_to_Software_Makers_This_Quarter.html
(I'm still seeking info on Berlin. Hopefully the boards will have more
than 1 or 2 expansion slots.)
From bright at mu.org Fri Feb 7 20:44:41 2014
From: bright at mu.org (Alfred Perlstein)
Date: Fri, 07 Feb 2014 12:44:37 -0800
Subject: Is it possible to get make variable without recursive expansion?
In-Reply-To: <933525355.20140207233844@serebryakov.spb.ru>
References: <12310461351.20140207203417@serebryakov.spb.ru>
<52F5251A.8020401@mu.org> <201495029.20140207225205@serebryakov.spb.ru>
<52F52F06.8080605@mu.org> <933525355.20140207233844@serebryakov.spb.ru>
Message-ID: <52F545B5.7040407@mu.org>
On 2/7/14, 11:38 AM, Lev Serebryakov wrote:
> Hello, Alfred.
> You wrote 7 ??????? 2014 ?., 23:07:50:
>
> AP> Your only option would be to "cheat" and not use the expanded form I think:
>
> AP> A=aaa
> AP> B=bbb
> AP> AMB=\$${A} and \$${B}
>
> AP> a:
> AP> echo "AMB=${AMB}"
>
> AP> Results in:
> AP> .(19:07:30)(alfred at freefall.freebsd.org)
> AP> ~ % make
> AP> echo "AMB=\${A} and \${B}"
> AP> AMB=${A} and ${B}
> AP> .(19:07:30)(alfred at freefall.freebsd.org)
> AP> ~ %
>
> AP> There is no way to query make(1) (that I can see) for the exact value at
> AP> the time of assignment and before expansion.
> It is pity, because I need to make it with MAKE_ENV & CONFIGURE_MAKE
> variables in out port system :(
>
>
>
~ % make -f Makefile -XV AMB
?
From lev at FreeBSD.org Fri Feb 7 21:12:33 2014
From: lev at FreeBSD.org (Lev Serebryakov)
Date: Sat, 8 Feb 2014 01:12:25 +0400
Subject: Is it possible to get make variable without recursive expansion?
In-Reply-To: <52F545B5.7040407@mu.org>
References: <12310461351.20140207203417@serebryakov.spb.ru>
<52F5251A.8020401@mu.org> <201495029.20140207225205@serebryakov.spb.ru>
<52F52F06.8080605@mu.org> <933525355.20140207233844@serebryakov.spb.ru>
<52F545B5.7040407@mu.org>
Message-ID: <173605890.20140208011225@serebryakov.spb.ru>
Hello, Alfred.
You wrote 8 ??????? 2014 ?., 0:44:37:
AP> ~ % make -f Makefile -XV AMB
Yoohoo! It works!
--
// Black Lion AKA Lev Serebryakov
From cary at sdf.org Sat Feb 8 01:21:49 2014
From: cary at sdf.org (Cary)
Date: Fri, 07 Feb 2014 17:21:39 -0800
Subject: remove shutdown messages in console
In-Reply-To: <1D565840-1ADA-4567-85B0-FB4AE771B823@bsdimp.com>
References:
<52F05DFC.7070007@freebsd.org>
<1D565840-1ADA-4567-85B0-FB4AE771B823@bsdimp.com>
Message-ID: <52F586A3.6080404@sdf.org>
Warner Losh wrote:
>
> On Feb 3, 2014, at 8:26 PM, Julian Elischer wrote:
>
>> On 2/2/14, 6:07 PM, Reza Mirzazadeh wrote:
>>> hi . how can i remove shutdown messages in console ? or even print my
>>> arbitrary messages in console ?
>>>
>>>
>>> *** FINAL System shutdown message from root at geekiam ***
>>> System going down IMMEDIATELY
>>>
>>> some messages like these ! i don't want it print theses messages
>>> --
>>> _______________________________________________
>>> freebsd-hackers at freebsd.org mailing list
>>> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
>>> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
>>>
>> we implimented the consmute sysctl option to "mute" an otherwise configured console for exactly this purpose.
>> (and boot messages).
>
> Except these are different beast. They aren't kernel messages, but generated by userland...
>
> to get rid of these, hack /etc/syslog.conf to get rid of the *.emerg * line.
> Or hack shutdown to stop sending them....
> Or use 'halt' and 'reboot' only
>
> Warner
>
>
>
It was easy to substitute an arbitrary message.
I used the following command:
# sed 's/System going down IMMEDIATELY/Farewell, Doctor F, until our paths meet yet
once more/' /usr/src/sbin/shutdown/shutdown.c >new.shutdown.c
then ran "clang -o shutdown new.shutdown.c" . If the file "shutdown" were copied to
/sbin would that work as expected?
Cary
--
cary at sdf.org
SDF Public Access UNIX System - http://sdf.org
------------------------------
From rmacklem at uoguelph.ca Mon Feb 10 06:01:11 2014
From: rmacklem at uoguelph.ca (Rick Macklem)
Date: Mon, 10 Feb 2014 01:01:10 -0500 (EST)
Subject: threads getting stuck in vmem_bt_alloc() at "btalloc"?
Message-ID: <1714012824.3160193.1392012070166.JavaMail.root@uoguelph.ca>
Hi,
I've been doing some testing using pagesize clusters (4K) for NFS
instead of mclbytes (2K) on a single core i386.
Sometimes I get threads stuck sleeping on "btalloc", which seems
to happen in vmem_bt_alloc().
The comment in vmem_bt_alloc() basically says:
out of address space or lost a fill race
Since this is persistent, I suspect it is the first case?
So, does anyone know what is going on here or what I should look
at to try and resolve this?
Btw, when I am testing, I don't see the pagesize cluster allocation
exceed 400, so it doesn't seem to be a leak or excessive allocation.
Thanks in advance for any help, rick
ps: Garrett, I cc'd you in part because I remember you mentioning
something about mclbyte clusters being pre-allocated vs ??
Maybe, you could explain what you were talking about, since
I didn't follow it the last time.
From wojtek at wojtek.tensor.gdynia.pl Mon Feb 10 10:52:26 2014
From: wojtek at wojtek.tensor.gdynia.pl (Wojciech Puchar)
Date: Mon, 10 Feb 2014 11:42:36 +0100 (CET)
Subject: opteron a1100 arm
In-Reply-To:
References:
Message-ID:
>
> The bad news is that it has only 8 PCIe lanes. Are expansion cards
> considered uncool these days, or what? How are you supposed to add all
> the essential stuff they leave off the mainboard?
anyway - it already have 10Gb/s ethernet, USB and 8 SATA ports. no need
for high speed I/O expansions.
and 8 single lane PCIe ports seems enough for me.
From egoitz at ramattack.net Tue Feb 11 18:13:10 2014
From: egoitz at ramattack.net (Egoitz Aurrekoetxea)
Date: Tue, 11 Feb 2014 19:05:26 +0100
Subject: mbuf_tag memory freeing issues with LRO enabled on the XENHVM driver
Message-ID: <1AECA876-08BC-48F8-B356-42CE35100805@ramattack.net>
Good afternoon,
It seems the LRO code inside the FreeBSD's kernel is causing the first mbuf chain?s anymbuf->m_hdr->mh_flags due to some failure not to contain the M_PKTHDR flag.
Have you ever seen this bad behavior with any of these drivers having LRO enabled :
cxgb
cxgbe
e1000
ixgbe
ixgbe
mxge
oce
qlxgb
qlxge
virtio
vxge
The no presence of this flag, seems to be causing the kernel not to be able to enter :
static void
mb_dtor_pack(void *mem, int size, void *arg)
{
struct mbuf *m;
m = (struct mbuf *)mem;
if ((m->m_flags & M_PKTHDR) != 0)
m_tag_delete_chain(m, NULL); <============ to this function.
causing the wired memory to increase a lot due mbuf_tags usage memory to be pretty high.
I have noticed about this issue using the XENHVM network driver (xn), but taking a look at some other drivers using the same code as this one? have found the commented before ones?.
Has anyone too suffered the issue?.
Best regards,
From wojtek at wojtek.tensor.gdynia.pl Tue Feb 11 18:36:23 2014
From: wojtek at wojtek.tensor.gdynia.pl (Wojciech Puchar)
Date: Tue, 11 Feb 2014 19:36:04 +0100 (CET)
Subject: FreeBSD UDF support
Message-ID:
what is the status?
i see mount_udf and UDF filesystem in kernel options. man mount_udf
doesn't state it's read only - so i assume RW support is there.
but no newfs_udf
tried to compile udfclient from ports - doesn't compile, both clang and
gcc
FreeBSD 10 about month old from cvs.
any ideas?
From jhb at freebsd.org Tue Feb 11 19:49:42 2014
From: jhb at freebsd.org (John Baldwin)
Date: Tue, 11 Feb 2014 13:19:14 -0500
Subject: Atom Board ACPI API MOPNV10J failing since 9.1
In-Reply-To: <52DED060.4070800@yahoo.com>
References: <52CF850A.9060906@erdgeist.org>
<201401211215.22021.jhb@freebsd.org> <52DED060.4070800@yahoo.com>
Message-ID: <201402111319.14546.jhb@freebsd.org>
On Tuesday, January 21, 2014 2:54:08 pm David Shane Holden wrote:
> On 01/21/14 12:15, John Baldwin wrote:
> >
> > Hmm, I think I see the issue, and I might have a fix for it in the
> > works already. The problem is that we haven't reserved pcib1's
> > windows when agp probes, so agp0 steals a resource that is already
> > in use. The change I have that might fix this isn't trivial though,
> > so I don't have a patch I can just give you to test right now. :(
> > Also, this isn't a BIOS issue per se.
> >
>
> I came to the same conclusion a few days ago when I started digging into
> it more. The agp driver requests some memory and the resource manager
> gives it a chunk which should be reserved for the bridge. I couldn't
> find an elegant solution; the best I could come up with was to add the
> bridge devices first in pci_add_children() to ensure they got attached
> before anything else. Which worked, but seems like a hack. Feel free
> to ping me if you have something that needs testing.
The patch I have in mind is a more general version of this that would
have the same effect.
I haven't tested it in quite a while, but if you are brave you can test it.
http://people.freebsd.org/~jhb/patches/multipass.patch
--
John Baldwin
From jhb at freebsd.org Tue Feb 11 19:49:48 2014
From: jhb at freebsd.org (John Baldwin)
Date: Tue, 11 Feb 2014 13:30:54 -0500
Subject: The sonewconn listen queue overflow issue
In-Reply-To: <52EFEEF7.5010704@xs4all.nl>
References: <52EFEEF7.5010704@xs4all.nl>
Message-ID: <201402111330.54758.jhb@freebsd.org>
On Monday, February 03, 2014 2:33:11 pm Photo stuff wrote:
> L.S.
>
> I came across a lot of messages in the log since, I think, about 9.1,
> that sometimes fill it up so much that all else is made invisible, of
> the type:
>
> sonewconn: pcb 0xyyyyyyyyyyyyyyyy: Listen queue overflow: 8 already in
> queue awaiting acceptance
>
> I searched a bit on the web and came across recommendations to try
> netstat -nAa to find out which program this came from.
>
> Well, running netstat -nAa |grep pcb 0xyyyyyyyyyyyyyyyy in a loop didn't
> work, it didn't give any output even though the messages kept coming in
> the log during that time.
>
> I forgot about it then recently searched a bit more, and I found this page:
>
> http://lawrencechen.net/2014/sonewconn-pcb-0xfffffe006acd9310-listen-queue
>
> So a listen queue overflow of 8 is caused by a listen value of 5 (QLEN >
> 3 * (QLIM / 2))
>
> Doing:
> netstat -LaAn | grep '/5 '
>
> resulted in
> ffffzzzzzzzzzzzz tcp4 0/0/5 127.0.0.1:8000
>
> The ffffzzz value was not the value in the message log,
> but the connection means in my case it had to be the junkbuster proxy
> (which I still use, still works well :) ), as I didn't run anything else
> locally.
>
> So I looked into junkbuster's cource and in bind.c I changed 2 instances of:
>
> while (listen(fd, 5) == -1) {
>
> to
>
> while (listen(fd, 10) == -1) { /* 10 instead of 5, this fixes dmesg
> spamming of the type 'sonewconn: pcb 0xyyyyyyyyyyyyyyyy: Listen queue
> overflow: 8 already in queue awaiting acceptance'? */
>
> This improved the situation, but still gave the issue of the log filling
> up too much. So then I changed it to 20, which gave me silence :)
>
> Checking the latest log I couldn't find anything in the last 10 days.
>
> So for people who have this issue I recommend calculating which value
> the listen-value that the overflow-value corresponds to, then checking
> as above and then it should be possible to find the daemon causing the
> issue. And modify that program...
>
> But while this removes the errors, what do these messages really
> signify? I mean which didn't this happen before in earlier versions of
> FreeBSD?
Maybe earlier versions just dropped the connections without logging a message?
The message means that connections are arriving faster than the userland
program can accept them. There is a stat for that in 'netstat -s -p tcp' and
you can see if it was increasing on older versions of FreeBSD (if you still
have a machine with that around) to make sure the only change is the
additional log message.
> Btw., at the moment (running 10.0 RC2) my message log now gets filled up
> with something else :)
>
> hwpstate0: set freq failed, err 6
>
> This happened long ago already in 9.1 with my AMD3500+ and still now on
> my AMD FX6100...
I am not familiar with how hwpstate works, sorry.
--
John Baldwin
From jhb at freebsd.org Tue Feb 11 19:49:51 2014
From: jhb at freebsd.org (John Baldwin)
Date: Tue, 11 Feb 2014 13:38:41 -0500
Subject: FreeBSD UDF support
In-Reply-To:
References:
Message-ID: <201402111338.41451.jhb@freebsd.org>
On Tuesday, February 11, 2014 1:36:04 pm Wojciech Puchar wrote:
> what is the status?
>
> i see mount_udf and UDF filesystem in kernel options. man mount_udf
> doesn't state it's read only - so i assume RW support is there.
No, it is read-only.
--
John Baldwin
From jhb at freebsd.org Tue Feb 11 19:49:44 2014
From: jhb at freebsd.org (John Baldwin)
Date: Tue, 11 Feb 2014 13:21:02 -0500
Subject: core dump vs kern.ipc.shm_use_phys
In-Reply-To: <52DFAC31.6030905@FreeBSD.org>
References: <52DFAC31.6030905@FreeBSD.org>
Message-ID: <201402111321.02294.jhb@freebsd.org>
On Wednesday, January 22, 2014 6:32:01 am Andriy Gapon wrote:
>
> I seems that if kern.ipc.shm_use_phys is enabled then shared memory regions are
> not included into a coredump. Seems that each_writable_segment() in
> sys/kern/imgact_elf.c skips OBJT_PHYS objects.
Hmm, that may be a feature. I often map large shared memory segments with
MAP_NOCORE on purpose. Is it to tell if a given OBJT_PHYS object is a SYSV
SHM object? (I assume it isn't.)
--
John Baldwin
From jhb at freebsd.org Tue Feb 11 19:49:47 2014
From: jhb at freebsd.org (John Baldwin)
Date: Tue, 11 Feb 2014 13:25:24 -0500
Subject: ULE locking mechanism
In-Reply-To:
References:
Message-ID: <201402111325.24523.jhb@freebsd.org>
On Tuesday, January 28, 2014 8:07:08 am Jens Krieg wrote:
> Hello,
>
> we are currently working on project for our university. Our goal is to
implement a simple round robin scheduler for FreeBSD 9.2 on a single core
machine.
> So far we removed most of the functionality of the ULE scheduler except the
functions that are called from outside. The system successfully boots to user
land with our RR scheduler managing thread in a list based run queue. Further,
it is possible to interact with the system using the shell.
>
> The next step is to replace the locking mechanism of the ULE scheduler.
Therefore, we replaced the scheduling dependent thread_lock/thread_unlock
functions by simply disabling/enabling the interrupts. With this modification
the kernel works fine until we hit the user land then the system crashes.
> The error occurs in the init user process (init_main.c:start_init:685). We
found out that the page fault is triggered while executing the subyte function
for the first time. See the error description below (unfortunately not shown
in backtrace).
> We compared the ULE scheduler with our RR implementation and it appears,
that the parameters passed to subyte as well as the register values are
identical. We assume, that whatever caused the error is related to the thread
locking replacement.
>
> Every time the kernel want to modify thread data the corresponding thread is
locked to prevent any interference by other threads. Since we are using a
single core machine why isn?t it sufficient to simply disable interrupt while
modifying thread data. Could you provide us with detailed information about
the locking mechanism in FreeBSD and also answer the following questions,
please.
>
> What is the purpose of thread_lock/thread_unlock besides protecting thread
data?
> How does the TDQ LOCK works and how is it related to a thread LOCK?
> - all thread LOCKs of the thread located in the run queue pointing to the
TDQ LOCK, and
> - the TDQ LOCK points to the currently running thread
> - on context switching the current thread passes the TDQ LOCK to the new
chosen thread
> - Could you explain the idea behind that locking concept, please?
> Any suggestions we shall care about in our own lock implementation?
thread_lock is quite intertwined with other locks. E.g. when a thread is
blocked on a turnstile, thread_lock() for that thread locks the 'ts_lock'
spin mutex for that turnstile. If you want to replace thread lock, you need
to change all the locks that td_lock can be to use your new primitive. You'd
probably have an easier time just changing how mtx_lock_spin() works. (In
fact, if you just disable 'options SMP', the stock kernel turns
mtx_lock_spin() into a function that just disables interrupts.)
For your core dump, the first step would be to use gdb to map that address to
a file line. For example, you can just do 'l *fork_exit+0x9d', or you can do
'l *' where you use the value from the trap message.
Looking at that can probably tell you why you panic'd.
--
John Baldwin
From rhurlin at gwdg.de Tue Feb 11 21:23:15 2014
From: rhurlin at gwdg.de (Rainer Hurling)
Date: Tue, 11 Feb 2014 22:23:11 +0100
Subject: FreeBSD UDF support
In-Reply-To:
References:
Message-ID: <52FA94BF.80304@gwdg.de>
Am 11.02.2014 19:36, schrieb Wojciech Puchar:
> what is the status?
>
> i see mount_udf and UDF filesystem in kernel options. man mount_udf
> doesn't state it's read only - so i assume RW support is there.
>
> but no newfs_udf
>
> tried to compile udfclient from ports - doesn't compile, both clang and gcc
>
> FreeBSD 10 about month old from cvs.
>
> any ideas?
Not a direct answer on your question with base mount_udf.
Do you know https://github.com/williamdevries/UDF/ from William DeVries?
His project comes from NetBSD and modernises the UDF standard towards
2.5x. With this driver, you would be able to read modern not encrypted
Blu-rays and DVDs. The driver works in principle, some minor issues have
to be solved.
Unfortunately there is only very little interest to integrate this
driver into base.
Regards,
Rainer
From dpejesh at yahoo.com Tue Feb 11 22:12:25 2014
From: dpejesh at yahoo.com (David Shane Holden)
Date: Tue, 11 Feb 2014 17:12:11 -0500
Subject: Atom Board ACPI API MOPNV10J failing since 9.1
In-Reply-To: <201402111319.14546.jhb@freebsd.org>
References: <52CF850A.9060906@erdgeist.org>
<201401211215.22021.jhb@freebsd.org> <52DED060.4070800@yahoo.com>
<201402111319.14546.jhb@freebsd.org>
Message-ID:
On 02/11/14 13:19, John Baldwin wrote:
>
> The patch I have in mind is a more general version of this that
> would have the same effect.
>
> I haven't tested it in quite a while, but if you are brave you can
> test it.
>
> http://people.freebsd.org/~jhb/patches/multipass.patch
>
When I tested your pci_bus_rman3.patch the other day I ran it on this
Atom board. To my surprise the problem seemed to have been fixed
somewhere along the line. I'm not sure if it was your patch, r261243,
some other commit, or me just not having it configured properly to
trigger the problem again. I'll try to spend some time tonight on it.
From adrian at freebsd.org Tue Feb 11 23:35:16 2014
From: adrian at freebsd.org (Adrian Chadd)
Date: Tue, 11 Feb 2014 15:35:15 -0800
Subject: mbuf_tag memory freeing issues with LRO enabled on the XENHVM
driver
In-Reply-To: <1AECA876-08BC-48F8-B356-42CE35100805@ramattack.net>
References: <1AECA876-08BC-48F8-B356-42CE35100805@ramattack.net>
Message-ID:
+net
.. any ideas?
-a
On 11 February 2014 10:05, Egoitz Aurrekoetxea wrote:
> Good afternoon,
>
> It seems the LRO code inside the FreeBSD's kernel is causing the first mbuf chain's anymbuf->m_hdr->mh_flags due to some failure not to contain the M_PKTHDR flag.
> Have you ever seen this bad behavior with any of these drivers having LRO enabled :
>
> cxgb
> cxgbe
> e1000
> ixgbe
> ixgbe
> mxge
> oce
> qlxgb
> qlxge
> virtio
> vxge
>
> The no presence of this flag, seems to be causing the kernel not to be able to enter :
>
> static void
> mb_dtor_pack(void *mem, int size, void *arg)
> {
> struct mbuf *m;
>
> m = (struct mbuf *)mem;
> if ((m->m_flags & M_PKTHDR) != 0)
> m_tag_delete_chain(m, NULL); <============ to this function.
>
> causing the wired memory to increase a lot due mbuf_tags usage memory to be pretty high.
>
> I have noticed about this issue using the XENHVM network driver (xn), but taking a look at some other drivers using the same code as this one... have found the commented before ones....
>
> Has anyone too suffered the issue?.
>
> Best regards,
>
>
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
From Suresh.Gumpula at netapp.com Wed Feb 12 02:02:08 2014
From: Suresh.Gumpula at netapp.com (Gumpula, Suresh)
Date: Wed, 12 Feb 2014 02:02:01 +0000
Subject: malloc(9) and its alignment
Message-ID:
Hi,
It appears the malloc(9) returns 8 byte aligned ( UMA_ALIGN_PTR) pointers, but in bus_dmamem_alloc we might end up checking for greater alignment
if we take malloc(9) path instead contig_malloc.
Can someone please confirm if malloc(9) returns different alignment pointers ?
bus_dmamem_alloc(bus_dma_tag_t dmat, void** vaddr, int flags,
bus_dmamap_t *mapp)
{
/*
* XXX:
* (dmat->alignment < dmat->maxsize) is just a quick hack; the exact
* alignment guarantees of malloc need to be nailed down, and the
* code below should be rewritten to take that into account.
*
* In the meantime, we'll warn the user if malloc gets it wrong.
*/
if ((dmat->maxsize <= PAGE_SIZE) &&
(dmat->alignment < dmat->maxsize) &&
dmat->lowaddr >= ptoa((vm_paddr_t)Maxmem)) {
*vaddr = malloc(dmat->maxsize, M_DEVBUF, mflags);
} else {
*vaddr = contigmalloc(dmat->maxsize, M_DEVBUF, mflags,
0ul, dmat->lowaddr, dmat->alignment? dmat->alignment : 1ul,
dmat->boundary);
}
if (vtophys(*vaddr) & (dmat->alignment - 1)) {
NETAPP_MUTED_PRINTF("bus_dmamem_alloc failed to align memory properly.\n");
Regards,
Suresh
From jhellenthal at dataix.net Wed Feb 12 05:09:35 2014
From: jhellenthal at dataix.net (Jason Hellenthal)
Date: Wed, 12 Feb 2014 00:09:34 -0500
Subject: Thoughts on Multi-Symlink Concept
Message-ID:
Hi All,
Now I already know the thoughts on symlink hell within filesystems all to
well considering most Linux flavoring's. But I am curious as to what all
your opinions would be to add symlink support to multiple target files much
like what you could do with cat(1) or portalfs to include a bunch of files
in one instance but similar to the following examples in place of such.
Instead of: cat /path/to/files*
ln -sm /path/to/files* ./my_concat_list
cat ./my_concat_list
Or
ln -sm /path/to/file1 /path/to/file2 ./my_concat_filters
pfctl -v -f ./my_concat_filters
Personally while I know it's a hack, but I feel it would bring some glue to
programs and other such situations that do not have file include support
and add support per-say way to create a repeatable playlist to shorten user
operations at any given time.
Obviously this isn't anywhere else implemented and would need to be a BSD
extension of ln(1) but I find that it could be a beneficial feature for
those that could use it to its full potential.
I've thought about the same instance also being done with hardlinks but I
keep coming across the idea that there are too many race conditions that
would be found with that.
Anyway . . . opinions, thoughts, ideas, criticism . . . welcome.
Thanks for your time.
From george+freebsd at m5p.com Wed Feb 12 11:08:34 2014
From: george+freebsd at m5p.com (George Mitchell)
Date: Wed, 12 Feb 2014 06:08:26 -0500
Subject: Thoughts on Multi-Symlink Concept
In-Reply-To:
References:
Message-ID: <52FB562A.20509@m5p.com>
On 02/12/14 00:09, Jason Hellenthal wrote:
> Hi All,
>
> Now I already know the thoughts on symlink hell within filesystems all to
> well considering most Linux flavoring's. But I am curious as to what all
> your opinions would be to add symlink support to multiple target files much
> like what you could do with cat(1) or portalfs to include a bunch of files
> in one instance but similar to the following examples in place of such.
>
> Instead of: cat /path/to/files*
> ln -sm /path/to/files* ./my_concat_list
> cat ./my_concat_list
>
> Or
>
> ln -sm /path/to/file1 /path/to/file2 ./my_concat_filters
> pfctl -v -f ./my_concat_filters
>
> Personally while I know it's a hack, but I feel it would bring some glue to
> programs and other such situations that do not have file include support
> and add support per-say way to create a repeatable playlist to shorten user
> operations at any given time.
>
> Obviously this isn't anywhere else implemented and would need to be a BSD
> extension of ln(1) but I find that it could be a beneficial feature for
> those that could use it to its full potential.
>
> I've thought about the same instance also being done with hardlinks but I
> keep coming across the idea that there are too many race conditions that
> would be found with that.
>
> Anyway . . . opinions, thoughts, ideas, criticism . . . welcome.
>
>
> Thanks for your time. [...]
My gut feeling is that it pushes functionality that belongs in userland
down into the kernel, plus probably introducing new security loopholes.
-- George
From ian at FreeBSD.org Wed Feb 12 14:19:54 2014
From: ian at FreeBSD.org (Ian Lepore)
Date: Wed, 12 Feb 2014 07:19:48 -0700
Subject: malloc(9) and its alignment
In-Reply-To:
References:
Message-ID: <1392214788.1145.52.camel@revolution.hippie.lan>
On Wed, 2014-02-12 at 02:02 +0000, Gumpula, Suresh wrote:
> Hi,
> It appears the malloc(9) returns 8 byte aligned ( UMA_ALIGN_PTR) pointers, but in bus_dmamem_alloc we might end up checking for greater alignment
> if we take malloc(9) path instead contig_malloc.
> Can someone please confirm if malloc(9) returns different alignment pointers ?
>
> bus_dmamem_alloc(bus_dma_tag_t dmat, void** vaddr, int flags,
> bus_dmamap_t *mapp)
> {
> /*
> * XXX:
> * (dmat->alignment < dmat->maxsize) is just a quick hack; the exact
> * alignment guarantees of malloc need to be nailed down, and the
> * code below should be rewritten to take that into account.
> *
> * In the meantime, we'll warn the user if malloc gets it wrong.
> */
> if ((dmat->maxsize <= PAGE_SIZE) &&
> (dmat->alignment < dmat->maxsize) &&
> dmat->lowaddr >= ptoa((vm_paddr_t)Maxmem)) {
> *vaddr = malloc(dmat->maxsize, M_DEVBUF, mflags);
> } else {
>
> *vaddr = contigmalloc(dmat->maxsize, M_DEVBUF, mflags,
> 0ul, dmat->lowaddr, dmat->alignment? dmat->alignment : 1ul,
> dmat->boundary);
> }
> if (vtophys(*vaddr) & (dmat->alignment - 1)) {
> NETAPP_MUTED_PRINTF("bus_dmamem_alloc failed to align memory properly.\n");
>
> Regards,
> Suresh
In my experience, the effective malloc(9) alignment ends up being the
same as MINALLOCSIZE, which is UMA_SMALLEST_UNIT, which is 16 bytes on a
system with 4K pages. At $work we overrode MINALLOCSIZE to 32 to work
around cache line alignment problems in busdma for ARM systems a few
years ago.
There is a newer set of busdma allocator routines available in
kern/subr_busdma_bufalloc.c which are designed to give a platform more
control over alignment of busdma buffers smaller than a page. An
example of using them can be found in arm/busdma_machdep[-v6].c. As far
as I know, they're only being used on ARM platforms right now.
-- Ian
From Suresh.Gumpula at netapp.com Wed Feb 12 19:40:18 2014
From: Suresh.Gumpula at netapp.com (Gumpula, Suresh)
Date: Wed, 12 Feb 2014 19:40:15 +0000
Subject: malloc(9) and its alignment
In-Reply-To: <1392214788.1145.52.camel@revolution.hippie.lan>
References:
<1392214788.1145.52.camel@revolution.hippie.lan>
Message-ID:
Thanks Ian for the reply. I will look at the ARM code, but I was thinking why malloc(9) does not return bucket size aligned pointers.
Regards,
Suresh
-----Original Message-----
From: Ian Lepore [mailto:ian at FreeBSD.org]
Sent: Wednesday, February 12, 2014 9:20 AM
To: Gumpula, Suresh
Cc: freebsd-hackers at freebsd.org
Subject: Re: malloc(9) and its alignment
On Wed, 2014-02-12 at 02:02 +0000, Gumpula, Suresh wrote:
> Hi,
> It appears the malloc(9) returns 8 byte aligned ( UMA_ALIGN_PTR)
> pointers, but in bus_dmamem_alloc we might end up checking for greater alignment if we take malloc(9) path instead contig_malloc.
> Can someone please confirm if malloc(9) returns different alignment pointers ?
>
> bus_dmamem_alloc(bus_dma_tag_t dmat, void** vaddr, int flags,
> bus_dmamap_t *mapp)
> {
> /*
> * XXX:
> * (dmat->alignment < dmat->maxsize) is just a quick hack; the exact
> * alignment guarantees of malloc need to be nailed down, and the
> * code below should be rewritten to take that into account.
> *
> * In the meantime, we'll warn the user if malloc gets it wrong.
> */
> if ((dmat->maxsize <= PAGE_SIZE) &&
> (dmat->alignment < dmat->maxsize) &&
> dmat->lowaddr >= ptoa((vm_paddr_t)Maxmem)) {
> *vaddr = malloc(dmat->maxsize, M_DEVBUF, mflags);
> } else {
>
> *vaddr = contigmalloc(dmat->maxsize, M_DEVBUF, mflags,
> 0ul, dmat->lowaddr, dmat->alignment? dmat->alignment : 1ul,
> dmat->boundary);
> }
> if (vtophys(*vaddr) & (dmat->alignment - 1)) {
> NETAPP_MUTED_PRINTF("bus_dmamem_alloc failed to align
> memory properly.\n");
>
> Regards,
> Suresh
In my experience, the effective malloc(9) alignment ends up being the same as MINALLOCSIZE, which is UMA_SMALLEST_UNIT, which is 16 bytes on a system with 4K pages. At $work we overrode MINALLOCSIZE to 32 to work around cache line alignment problems in busdma for ARM systems a few years ago.
There is a newer set of busdma allocator routines available in kern/subr_busdma_bufalloc.c which are designed to give a platform more control over alignment of busdma buffers smaller than a page. An example of using them can be found in arm/busdma_machdep[-v6].c. As far as I know, they're only being used on ARM platforms right now.
-- Ian
From wkoszek at freebsd.org Wed Feb 12 21:52:15 2014
From: wkoszek at freebsd.org (Wojciech A. Koszek)
Date: Wed, 12 Feb 2014 21:51:23 +0000
Subject: FreeBSD GSOC 2014: call for ideas!
Message-ID: <20140212215123.GB31185@FreeBSD.org>
(cross-posted message; keep discussion on hackers@ only)
Hello,
We want to participate in GSOC 2014. We need more ideas for students, who
can be new to FreeBSD and Open Source.
Submit your ideas here:
http://tinyurl.com/FreeBSD-GSOC2014
If you make them attractive and clearly explained, there should be a bigger
chance of getting them picked by somebody.
All submitted ideas upon review will be put here:
https://wiki.freebsd.org/SummerOfCode2014
If you have a Wiki access, please just copy the skeleton from the top of
this page and use it for your task.
Thanks,
--
Wojciech A. Koszek
wkoszek at FreeBSD.org
http://www.koszek.com/
From jmg at funkthat.com Wed Feb 12 22:07:13 2014
From: jmg at funkthat.com (John-Mark Gurney)
Date: Wed, 12 Feb 2014 14:07:05 -0800
Subject: malloc(9) and its alignment
In-Reply-To:
References:
<1392214788.1145.52.camel@revolution.hippie.lan>
Message-ID: <20140212220705.GV34851@funkthat.com>
Gumpula, Suresh wrote this message on Wed, Feb 12, 2014 at 19:40 +0000:
> Thanks Ian for the reply. I will look at the ARM code, but I was thinking why malloc(9) does not return bucket size aligned pointers.
Always returning bucket sizes aligned pointers may not be ideal for a
cache.. say you have a buffer of 512 bytes, where often only the first
128 bytes are used (but all 512 bytes may be)... If you always align at
512, some cache lines will be more heavily used than others, reducing
the effective size of the cache...
This is only one reason not aligning to size may be better...
--
John-Mark Gurney Voice: +1 415 225 5579
"All that I will do, has been done, All that I have, has not."
From rpokala at panasas.com Thu Feb 13 01:53:52 2014
From: rpokala at panasas.com (Pokala, Ravi)
Date: Thu, 13 Feb 2014 01:51:48 +0000
Subject: AF-4Kn and DEV_BSIZE
Message-ID:
Hi hackers,
At Panasas, we're working on supporting AF-4Kn drives (and also optimizing
for AF-512e drives while we're at it) in our legacy codebase, which is
based on:
7.2-RELEASE
- a bunch of drivers we don't need
- a bunch of utilities we don't use
+ a bunch of bug fixes merged from 7-STABLE
+ a bunch of drivers back-ported from {8,9,10}-STABLE
+ a bunch of internal changes
Since 7-STABLE doesn't support AF-4Kn, I'm looking at 10-STABLE for
inspiration.
We're only interested in SATA, so this basically breaks down into:
ata(4) / ad(4) [1]
GEOM [2]
General kernel stuff
I have a pretty good handle on the drivers and GEOM, but I'd like to
discuss the "General kernel stuff" bucket. Of particular concern is
DEV_BSIZE - and it's relatives: DEV_BSHIFT, btodb() and dbtob() - which
are used pretty much everywhere. A bunch of that is in places that don't
come anywhere near the drives, so I'm not worried about them. But when I
see those macros used in places that *do* come near the drives, I get
nervous. For example:
sys/kern/vfs_aio.c
sys/kern/vfs_bio.c
sys/kern/kern_physio.c
sys/vm/swap_pager.c
sys/vm/vnode_pager.c
Swapping, paging, and block IO all come near the drives.
On the one hand, the fact that we're doing things in terms of 512-byte
blocks all those places suggests that lots of stuff has to change to work
with 4KB drive blocks. On the other hand, when I compare the use of those
macros in our code base against what's in 10-STABLE, they are
substantively the same; since 10-STABLE supports AF-4Kn, that implies it's
okay to use those macros those ways. But I'm fuzzy on *how*, if we're
passing around 512-byte buffers, everything still works okay with AF-4Kn
drives.
Can someone shed some light?
Thanks,
Ravi
[1] The elephant in the room was the move from the old ATA driver to
ATACAM. Fortunately, the code in sys/cam/ata/ata_da.c::adaregister() that
maps from the logical and physical sector sizes detected from the drive,
to the more abstract 'struct disk' used by GEOM, is pretty easy to
understand and shoehorn into the 7-ish drivers. Once that's done and the
disk softc is carrying around the logical sector size, then a bunch of
places get changed to use that value instead of DEV_BSIZE. There are a few
other nits, but that's the bulk of the changes needed for ata(4) / ad(4).
[2] geom_disk.c::g_disk_create() copies 'struct disk's 'd_sectorsize' and
'd_stripesize' into the provider's 'sectorsize' and 'stripesize'. The rest
of the GEOM stack uses those correctly, so there aren't any real changes
required in GEOM. Hurray!
--rp
From jordan.hubbard at gmail.com Thu Feb 13 05:08:34 2014
From: jordan.hubbard at gmail.com (Jordan Hubbard)
Date: Wed, 12 Feb 2014 21:08:30 -0800
Subject: Thoughts on Multi-Symlink Concept
In-Reply-To:
References:
Message-ID:
On Feb 11, 2014, at 9:09 PM, Jason Hellenthal wrote:
> Instead of: cat /path/to/files*
> ln -sm /path/to/files* ./my_concat_list
> cat ./my_concat_list
>
> Or
>
> ln -sm /path/to/file1 /path/to/file2 ./my_concat_filters
> pfctl -v -f ./my_concat_filters
Globbing is done in user land (by the shell) - you wouldn?t want to push that down into the kernel, which is either what you?d have to do or you?d need a user land daemon which did round-trips with the kernel to do the translation, which would also need to make sure to get all of the process permission stuff right since the user id / gid / $CWD would all potentially affect the expansion of the ?symlink?.
There are other problems. Since ?my_concat_list? now expands to multiple files, you have to pre-expand its contents before actually execing cat(1), and since filenames can have spaces and other magic characters (to the shell) in them, you would need to be able to deal with escaping all of that. Just like? the shell does!
Even worse still, you?d be essentially creating a new file type with very non-file like semantics. Even variant symlinks (/bin -> /${ARCH}/bin), which can expand differently depending on the user context, have clearly understandable semantics - you know that the symlink is going to expand to exactly one file no matter what ARCH is set to. How, conversely, would you expect ?cat < my_concat_filters? or ?dd if=my_concat_filters of=?? to work? You?ve essentially created a construct that can cause truly weird behaviors unless you use it in exactly one way and one way only (as a file argument list), the user having to explicitly know the difference when they consume the symlink. That creates a whole raft of layering violations, and is very ?not Unix?, to be honest.
If you want to get creative along these lines without breaking Unix, I think creating some new type of artificial directory that doesn?t actually physically contain files but can flexibly reference a collection of files based on some sort of query - that might be interesting.
- Jordan
From jordan.hubbard at gmail.com Thu Feb 13 05:17:23 2014
From: jordan.hubbard at gmail.com (Jordan Hubbard)
Date: Wed, 12 Feb 2014 21:17:19 -0800
Subject: Thoughts on Multi-Symlink Concept
In-Reply-To:
References:
Message-ID:
On Feb 12, 2014, at 9:08 PM, Jordan Hubbard wrote:
> Globbing is done in user land (by the shell) - you wouldn?t want to push that down into the kernel, which is either what you?d have to do or you?d need a user land daemon which did round-trips with the kernel to do the translation, which would also need to make sure to get all of the process permission stuff right since the user id / gid / $CWD would all potentially affect the expansion of the ?symlink?.
Actually, just to correct myself, there is a third way, which is that you could make the shell also do the expansion of the symlink (or interpose it into libc), but now you?d just be stacking one weird hack on top of another weird hack. It?s still not a good idea for all the reasons I mentioned, at least not as a ?symlink?. Maybe some new type of shell builtin, though I?m not sure how/where you?d use it.
- Jordan
From bakul at bitblocks.com Thu Feb 13 06:41:12 2014
From: bakul at bitblocks.com (Bakul Shah)
Date: Wed, 12 Feb 2014 22:35:01 -0800
Subject: Thoughts on Multi-Symlink Concept
In-Reply-To:
References:
Message-ID:
On Feb 12, 2014, at 9:08 PM, Jordan Hubbard wrote:
>
> On Feb 11, 2014, at 9:09 PM, Jason Hellenthal wrote:
>
>> Instead of: cat /path/to/files*
>> ln -sm /path/to/files* ./my_concat_list
>> cat ./my_concat_list
>>
>> Or
>>
>> ln -sm /path/to/file1 /path/to/file2 ./my_concat_filters
>> pfctl -v -f ./my_concat_filters
>
> Globbing is done in user land (by the shell) - you wouldn?t want to push that down into the kernel, which is either what you?d have to do or you?d need a user land daemon which did round-trips with the kernel to do the translation, which would also need to make sure to get all of the process permission stuff right since the user id / gid / $CWD would all potentially affect the expansion of the ?symlink?.
>
> There are other problems. Since ?my_concat_list? now expands to multiple files, you have to pre-expand its contents before actually execing cat(1), and since filenames can have spaces and other magic characters (to the shell) in them, you would need to be able to deal with escaping all of that. Just like? the shell does!
>
> Even worse still, you?d be essentially creating a new file type with very non-file like semantics. Even variant symlinks (/bin -> /${ARCH}/bin), which can expand differently depending on the user context, have clearly understandable semantics - you know that the symlink is going to expand to exactly one file no matter what ARCH is set to. How, conversely, would you expect ?cat < my_concat_filters? or ?dd if=my_concat_filters of=?? to work? You?ve essentially created a construct that can cause truly weird behaviors unless you use it in exactly one way and one way only (as a file argument list), the user having to explicitly know the difference when they consume the symlink. That creates a whole raft of layering violations, and is very ?not Unix?, to be honest.
May be a similar idea can be used to implement file striping & mirroring on top of existing filesystems -- modern distributed FS seem to reinvent a lot stuff. Instead one can just build a simple thin layer and use local and remote simple filesystems to create a distributed FS. I wouldn't use symlinks but indicate additional semantics via some metadata.
> If you want to get creative along these lines without breaking Unix, I think creating some new type of artificial directory that doesn?t actually physically contain files but can flexibly reference a collection of files based on some sort of query - that might be interesting.
Lot of such variations are possible using fusefs
From wojtek at wojtek.tensor.gdynia.pl Thu Feb 13 09:15:04 2014
From: wojtek at wojtek.tensor.gdynia.pl (Wojciech Puchar)
Date: Thu, 13 Feb 2014 10:14:45 +0100 (CET)
Subject: FreeBSD UDF support
In-Reply-To: <52FA94BF.80304@gwdg.de>
References:
<52FA94BF.80304@gwdg.de>
Message-ID:
> His project comes from NetBSD and modernises the UDF standard towards
> 2.5x. With this driver, you would be able to read modern not encrypted
> Blu-rays and DVDs. The driver works in principle, some minor issues have
> to be solved.
>
> Unfortunately there is only very little interest to integrate this
> driver into base.
>
i need RW support so it is not much use for me.
From brueffer at FreeBSD.org Thu Feb 13 09:20:40 2014
From: brueffer at FreeBSD.org (Christian Brueffer)
Date: Thu, 13 Feb 2014 10:20:33 +0100
Subject: FreeBSD UDF support
In-Reply-To:
References:
<52FA94BF.80304@gwdg.de>
Message-ID: <52FC8E61.5050200@FreeBSD.org>
On 2/13/14 10:14 AM, Wojciech Puchar wrote:
>> His project comes from NetBSD and modernises the UDF standard towards
>> 2.5x. With this driver, you would be able to read modern not encrypted
>> Blu-rays and DVDs. The driver works in principle, some minor issues have
>> to be solved.
>>
>> Unfortunately there is only very little interest to integrate this
>> driver into base.
>>
> i need RW support so it is not much use for me.
NetBSD has newfs_udf(8), but it doesn't look like anyone has ported it
to FreeBSD yet,
Chris
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 1036 bytes
Desc: OpenPGP digital signature
URL:
From vpenkoff at gmail.com Thu Feb 13 09:05:32 2014
From: vpenkoff at gmail.com (Viktor Penkoff)
Date: Thu, 13 Feb 2014 11:05:31 +0200
Subject: Receiving jumbo frames
Message-ID:
Hi, folks! I'm writing an extension functionality to not-yet published
network driver.
I'm receiving the typical ethernet frames without problems. Considering the
datasheet of the device,
I'm capable of receiving jumbo frames. When I try to do that, e.g. to send
jumbo frame of 8000 bytes, I'm receiving only a limited count of them -
105, then the kernel crashes with the following message:
"panic: vm_fault: fault on nofault entry, addr: cfcec000".
I have inspected a kernel dump with kgdb and the problem occurs at the
function bus_dmamap_sync.
The line that the panic happens is in a standard invoking receive
interrupt function. Packet data is stored in memory buffers, with any
single packet spanning multiple buffers if necessary. The buffers are
allocated by the CPU and are managed through chained descriptor lists.
When I'm sending jumbo packets, e.g. 8008 bytes in size each, due to live
debugging with jtag and kgdb, I've got the following information for the
mbuf:
% ping -I eth0 -c 1 -s 8000 -M dont A.B.C.D -v -p ff
{m_hdr = {mh_next = 0x0, mh_nextpkt = 0x0, mh_data = 0xc3d41800 "",
mh_len = 2048, mh_flags = 3, mh_type = 1, pad = "\000"}, M_dat = {
MH = {MH_pkthdr = {rcvif = 0x0, header = 0x0, len = 2048, flowid = 0,
csum_flags = 0, csum_data = 0, tso_segsz = 0, PH_vt = {
vt_vtag = 0, vt_nrecs = 0}, tags = {slh_first = 0x0},
dsa_tag = {0, 0}}, MH_dat = {MH_ext = {ext_buf = 0xc3d41800 "",
ext_free = 0, ext_arg1 = 0x0, ext_arg2 = 0x0, ext_size = 2048,
ref_cnt = 0xc3d3f244, ext_type = 6},
In this case, the given mbuf must occupy ~4 descriptors, IMO. Following the
next pointer in the descriptor list shows that the CPU has
an ownership. Nevertheless, ?he byte count of the received frame shows that
8056 bytes are received.
More interesting is the fact that an echo reply is given back. But after a
constant count of received packets, the kernel hangs.
Some background information:
To enable the jumbo frame, one must set the appropriate register.
At the software level, a ring buffer with the descriptors is implemented.
The device, under which the driver runs, is arm-based.
The freebsd version is 8.0. The device uses SerialDMA queues for
transmitting and receiving.
To receive packets, the CPU must perform the following:
1. Prepare a linked list of descriptors
2. Configure a given queue with the address of the first descriptor in
the list,
3. enable SerialDMA;
With the transmission - I don't have any problems. The logic is the same as
by the reception of packets - ring buffer with descriptors.
Any ideas what can cause this type of crashes?
From ian at FreeBSD.org Thu Feb 13 14:50:25 2014
From: ian at FreeBSD.org (Ian Lepore)
Date: Thu, 13 Feb 2014 07:50:12 -0700
Subject: Receiving jumbo frames
In-Reply-To:
References:
Message-ID: <1392303012.1145.81.camel@revolution.hippie.lan>
On Thu, 2014-02-13 at 11:05 +0200, Viktor Penkoff wrote:
> Hi, folks! I'm writing an extension functionality to not-yet published
> network driver.
> I'm receiving the typical ethernet frames without problems. Considering the
> datasheet of the device,
> I'm capable of receiving jumbo frames. When I try to do that, e.g. to send
> jumbo frame of 8000 bytes, I'm receiving only a limited count of them -
> 105, then the kernel crashes with the following message:
> "panic: vm_fault: fault on nofault entry, addr: cfcec000".
> I have inspected a kernel dump with kgdb and the problem occurs at the
> function bus_dmamap_sync.
>
> The line that the panic happens is in a standard invoking receive
> interrupt function. Packet data is stored in memory buffers, with any
> single packet spanning multiple buffers if necessary. The buffers are
> allocated by the CPU and are managed through chained descriptor lists.
> When I'm sending jumbo packets, e.g. 8008 bytes in size each, due to live
> debugging with jtag and kgdb, I've got the following information for the
> mbuf:
>
> % ping -I eth0 -c 1 -s 8000 -M dont A.B.C.D -v -p ff
>
> {m_hdr = {mh_next = 0x0, mh_nextpkt = 0x0, mh_data = 0xc3d41800 "",
> mh_len = 2048, mh_flags = 3, mh_type = 1, pad = "\000"}, M_dat = {
> MH = {MH_pkthdr = {rcvif = 0x0, header = 0x0, len = 2048, flowid = 0,
> csum_flags = 0, csum_data = 0, tso_segsz = 0, PH_vt = {
> vt_vtag = 0, vt_nrecs = 0}, tags = {slh_first = 0x0},
> dsa_tag = {0, 0}}, MH_dat = {MH_ext = {ext_buf = 0xc3d41800 "",
> ext_free = 0, ext_arg1 = 0x0, ext_arg2 = 0x0, ext_size = 2048,
> ref_cnt = 0xc3d3f244, ext_type = 6},
>
> In this case, the given mbuf must occupy ~4 descriptors, IMO. Following the
> next pointer in the descriptor list shows that the CPU has
> an ownership. Nevertheless, ?he byte count of the received frame shows that
> 8056 bytes are received.
>
> More interesting is the fact that an echo reply is given back. But after a
> constant count of received packets, the kernel hangs.
>
> Some background information:
> To enable the jumbo frame, one must set the appropriate register.
> At the software level, a ring buffer with the descriptors is implemented.
> The device, under which the driver runs, is arm-based.
> The freebsd version is 8.0. The device uses SerialDMA queues for
> transmitting and receiving.
> To receive packets, the CPU must perform the following:
> 1. Prepare a linked list of descriptors
> 2. Configure a given queue with the address of the first descriptor in
> the list,
> 3. enable SerialDMA;
>
> With the transmission - I don't have any problems. The logic is the same as
> by the reception of packets - ring buffer with descriptors.
>
> Any ideas what can cause this type of crashes?
You mention FreeBSD 8.0, that's pretty old. There have been many fixes
to the arm busdma code since then. We still use 8.2 at work, and while
we know there are problems with the busdma code that have been fixed in
later revisions, they aren't affecting us so we leave well enough alone.
We don't use jumbo frames though.
At the very least you should apply the changeset r236086 to your code,
although it's not all that likely to fix your problem because the mbufs
you're working with should be aligned on 2k boundaries and never require
a partial cacheline flush.
Are you allocating the buffers with bus_dmamem_alloc() then attaching
them to mbuf chains as external buffers? Or are you using one of the
mbuf allocation routines? When interfacing with the busdma code, are
you using bus_dmamap_load_mbuf()?
Posting the full backtrace from the panic might help. More information
about the arm chip/system you're using might be helpful too. (I've
added the freebsd-arm mailing list to the CC, this is pretty likely to
be an arm-specific problem rather than a general freebsd thing.)
-- Ian
From wblock at wonkity.com Thu Feb 13 15:30:35 2014
From: wblock at wonkity.com (Warren Block)
Date: Thu, 13 Feb 2014 08:30:33 -0700 (MST)
Subject: FreeBSD UDF support
In-Reply-To: <52FC8E61.5050200@FreeBSD.org>
References:
<52FA94BF.80304@gwdg.de>
<52FC8E61.5050200@FreeBSD.org>
Message-ID:
On Thu, 13 Feb 2014, Christian Brueffer wrote:
> On 2/13/14 10:14 AM, Wojciech Puchar wrote:
>>> His project comes from NetBSD and modernises the UDF standard towards
>>> 2.5x. With this driver, you would be able to read modern not encrypted
>>> Blu-rays and DVDs. The driver works in principle, some minor issues have
>>> to be solved.
>>>
>>> Unfortunately there is only very little interest to integrate this
>>> driver into base.
>>>
>> i need RW support so it is not much use for me.
>
> NetBSD has newfs_udf(8), but it doesn't look like anyone has ported it
> to FreeBSD yet,
GSOC candidates have been requested. That might be perfect.
From vijju.singh at gmail.com Thu Feb 13 20:51:51 2014
From: vijju.singh at gmail.com (Vijay Singh)
Date: Thu, 13 Feb 2014 12:51:50 -0800
Subject: Debugging rw lock
Message-ID:
I am running into an issue where an rw lock is read locked and never
unlocked, and causes a system to livelock. I was wondering if its possible
to figure out which thread owns the read lock?
It's the tcp pcbinfo lock.
(kgdb-amd64-7.4-08) show_rwlock rw
name : tcp
class: rw
flags: {SLEEP, INITED, WITNESS, RECURSE, UPGRADABLE}
state: RLOCK: 1 locks
waiters: writers
Any help is appreciated.
-vijay
From bright at mu.org Thu Feb 13 20:53:35 2014
From: bright at mu.org (Alfred Perlstein)
Date: Thu, 13 Feb 2014 12:53:45 -0800
Subject: Debugging rw lock
In-Reply-To:
References:
Message-ID: <52FD30D9.6050604@mu.org>
Keep a stack of rwlocks owned in the struct thread.
-Alfred
On 2/13/14, 12:51 PM, Vijay Singh wrote:
> I am running into an issue where an rw lock is read locked and never
> unlocked, and causes a system to livelock. I was wondering if its possible
> to figure out which thread owns the read lock?
>
> It's the tcp pcbinfo lock.
>
> (kgdb-amd64-7.4-08) show_rwlock rw
> name : tcp
> class: rw
> flags: {SLEEP, INITED, WITNESS, RECURSE, UPGRADABLE}
> state: RLOCK: 1 locks
> waiters: writers
>
> Any help is appreciated.
>
> -vijay
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
>
From vijju.singh at gmail.com Thu Feb 13 20:59:11 2014
From: vijju.singh at gmail.com (Vijay Singh)
Date: Thu, 13 Feb 2014 12:59:10 -0800
Subject: Debugging rw lock
In-Reply-To: <52FD30D9.6050604@mu.org>
References:
<52FD30D9.6050604@mu.org>
Message-ID:
You're talking about instrumenting the code, right? But which thread? I was
thinking of augmenting the rw lock to record the readers, but wanted to
check if something is possible without instrumentation.
On Thu, Feb 13, 2014 at 12:53 PM, Alfred Perlstein wrote:
> Keep a stack of rwlocks owned in the struct thread.
>
> -Alfred
>
> On 2/13/14, 12:51 PM, Vijay Singh wrote:
>
>> I am running into an issue where an rw lock is read locked and never
>> unlocked, and causes a system to livelock. I was wondering if its possible
>> to figure out which thread owns the read lock?
>>
>> It's the tcp pcbinfo lock.
>>
>> (kgdb-amd64-7.4-08) show_rwlock rw
>> name : tcp
>> class: rw
>> flags: {SLEEP, INITED, WITNESS, RECURSE, UPGRADABLE}
>> state: RLOCK: 1 locks
>> waiters: writers
>>
>> Any help is appreciated.
>>
>> -vijay
>> _______________________________________________
>> freebsd-hackers at freebsd.org mailing list
>> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
>> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org
>> "
>>
>>
>
From bright at mu.org Thu Feb 13 21:02:42 2014
From: bright at mu.org (Alfred Perlstein)
Date: Thu, 13 Feb 2014 13:02:55 -0800
Subject: Debugging rw lock
In-Reply-To:
References:
<52FD30D9.6050604@mu.org>
Message-ID: <52FD32FF.70106@mu.org>
On 2/13/14, 12:59 PM, Vijay Singh wrote:
> You're talking about instrumenting the code, right? But which thread? I was
> thinking of augmenting the rw lock to record the readers, but wanted to
> check if something is possible without instrumentation.
If rw locks are implemented using low level atomics then you're going to
make the very slow and have a LOT of work to do as opposed to just using
a thread specific storage to implement it. You're better off just
making use of the fact that only "curthread" can access the per-thread
stack and just use that. Or at least that's how it works in my brain.
-Alfred
>
>
> On Thu, Feb 13, 2014 at 12:53 PM, Alfred Perlstein wrote:
>
>> Keep a stack of rwlocks owned in the struct thread.
>>
>> -Alfred
>>
>> On 2/13/14, 12:51 PM, Vijay Singh wrote:
>>
>>> I am running into an issue where an rw lock is read locked and never
>>> unlocked, and causes a system to livelock. I was wondering if its possible
>>> to figure out which thread owns the read lock?
>>>
>>> It's the tcp pcbinfo lock.
>>>
>>> (kgdb-amd64-7.4-08) show_rwlock rw
>>> name : tcp
>>> class: rw
>>> flags: {SLEEP, INITED, WITNESS, RECURSE, UPGRADABLE}
>>> state: RLOCK: 1 locks
>>> waiters: writers
>>>
>>> Any help is appreciated.
>>>
>>> -vijay
>>> _______________________________________________
>>> freebsd-hackers at freebsd.org mailing list
>>> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
>>> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org
>>> "
>>>
>>>
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
>
From ian at FreeBSD.org Thu Feb 13 21:06:33 2014
From: ian at FreeBSD.org (Ian Lepore)
Date: Thu, 13 Feb 2014 14:06:27 -0700
Subject: Debugging rw lock
In-Reply-To:
References:
<52FD30D9.6050604@mu.org>
Message-ID: <1392325587.1145.96.camel@revolution.hippie.lan>
Does option DEADLKRES not work with rwlocks? (I've never used it, just
seen it in the NOTES).
-- Ian
On Thu, 2014-02-13 at 12:59 -0800, Vijay Singh wrote:
> You're talking about instrumenting the code, right? But which thread? I was
> thinking of augmenting the rw lock to record the readers, but wanted to
> check if something is possible without instrumentation.
>
>
> On Thu, Feb 13, 2014 at 12:53 PM, Alfred Perlstein wrote:
>
> > Keep a stack of rwlocks owned in the struct thread.
> >
> > -Alfred
> >
> > On 2/13/14, 12:51 PM, Vijay Singh wrote:
> >
> >> I am running into an issue where an rw lock is read locked and never
> >> unlocked, and causes a system to livelock. I was wondering if its possible
> >> to figure out which thread owns the read lock?
> >>
> >> It's the tcp pcbinfo lock.
> >>
> >> (kgdb-amd64-7.4-08) show_rwlock rw
> >> name : tcp
> >> class: rw
> >> flags: {SLEEP, INITED, WITNESS, RECURSE, UPGRADABLE}
> >> state: RLOCK: 1 locks
> >> waiters: writers
> >>
> >> Any help is appreciated.
> >>
> >> -vijay
> >> _______________________________________________
> >> freebsd-hackers at freebsd.org mailing list
> >> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> >> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org
> >> "
> >>
> >>
> >
> _______________________________________________
> freebsd-hackers at freebsd.org mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
> To unsubscribe, send any mail to "freebsd-hackers-unsubscribe at freebsd.org"
From rysto32 at gmail.com Thu Feb 13 22:03:07 2014
From: rysto32 at gmail.com (Ryan Stone)
Date: Thu, 13 Feb 2014 17:03:06 -0500
Subject: Debugging rw lock
In-Reply-To: <1392325587.1145.96.camel@revolution.hippie.lan>
References:
<52FD30D9.6050604@mu.org>
<1392325587.1145.96.camel@revolution.hippie.lan>
Message-ID:
On Thu, Feb 13, 2014 at 4:06 PM, Ian Lepore wrote:
> Does option DEADLKRES not work with rwlocks? (I've never used it, just
> seen it in the NOTES).
>
> -- Ian
DEADLKRES will panic the system after a thread has been blocked for a
timeout period (I think that it's something ridiculous like 30
minutes). However it's of no use when trying to debugging a leaked
read lock, because the thread that lost the lock will have left behind
no clues as to it's identity.
If you have some kind of reproduction scenario, the quickest hack that
might get you an answer would be to change INP_INFO_RLOCK to actually
take a wlock instead.
Rather than instrumenting the code, you could use the dtrace lockstat
provider to log every lock/unlock and post-process the output to find
the culprit. Make sure that you have r258541 if you want to use
lockstat.
http://svnweb.freebsd.org/changeset/base/258541
From adrian at freebsd.org Thu Feb 13 23:57:34 2014
From: adrian at freebsd.org (Adrian Chadd)
Date: Thu, 13 Feb 2014 15:57:33 -0800
Subject: can the scheduler decide to schedule an interrupted but runnable
thread on another CPU core? What are the implications for code?
Message-ID:
Hi,
Whilst digging into collisions in the flowtable code I discovered that
a bunch of them are due to some of the flowtable_lookup() code running
on a different CPU - the contention on the l2/l3 lookup lock(s) was
enough to block things so they'd get an obvious chance to be migrated.
So this led me to wonder whether in a fully preemptive kernel, a
running kernel thread would stay on the current CPU until it hit a
very specific subset of things (exited to userland, hit a lock, etc.)
Apparently (according to kan and rwatson) this is how we define fully
preemptive - it's not just interruptable at almost any point, but the
running task may be interrupted and rescheduled on a different CPU
outside of specific critical sections.
This means that for the flowtable case, the current setup (without
atomics to maintain the lists) can only work if all threads doing work
with the flowtable structures (ie, lookup, insert, purge) have to be
CPU pinned. Otherwise we may have the situation where:
sequentually:
* lookup occurs on CPU A;
* lookup succeeds on CPU A for some almost-expired entry;
* preemption occurs, and it gets scheduled to CPU B;
then simultaneously:
* CPU A's flowtable purge code runs, and decides to purge entries
including the current one;
* the code now running on CPU B has an item from the CPU A flowtable,
and dereferences it as it's being freed, leading to potential badness.
Now, it's a ridiculously small window of opportunity, but I'd rather
the code be written to be correct and mostly-fast versus very fast and
potentially exploding. I'm sure those in operations would agree. :-)
So, my questions:
* is this actually how fully pre-emptive kernels _may_ behave?
* I believe there's a difference between what 4BSD and ULE will do
here - is this the case? What are the scheduler behaviours?
* are there any other areas in the kernel that rely on pcpu uma zones
/ curcpu indexes for things outside of sched_pin() ?
Thanks,
-a
From Suresh.Gumpula at netapp.com Fri Feb 14 02:07:55 2014
From: Suresh.Gumpula at netapp.com (Gumpula, Suresh)
Date: Fri, 14 Feb 2014 02:07:51 +0000
Subject: malloc(9) and its alignment
In-Reply-To: <20140212220705.GV34851@funkthat.com>
References:
<1392214788.1145.52.camel@revolution.hippie.lan>
<20140212220705.GV34851@funkthat.com>
Message-ID:
Thanks for the explanation John. How about porting ARM way of handling required alignment with creation of separate zones
And allocating with uma_zalloc(zone) for AMD64 too for bus_dmamem_alloc?
Thanks
Suresh
-----Original Message-----
From: John-Mark Gurney [mailto:jmg at funkthat.com]
Sent: Wednesday, February 12, 2014 5:07 PM
To: Gumpula, Suresh
Cc: Ian Lepore; freebsd-hackers at freebsd.org
Subject: Re: malloc(9) and its alignment
Gumpula, Suresh wrote this message on Wed, Feb 12, 2014 at 19:40 +0000:
> Thanks Ian for the reply. I will look at the ARM code, but I was thinking why malloc(9) does not return bucket size aligned pointers.
Always returning bucket sizes aligned pointers may not be ideal for a cache.. say you have a buffer of 512 bytes, where often only the first
128 bytes are used (but all 512 bytes may be)... If you always align at 512, some cache lines will be more heavily used than others, reducing the effective size of the cache...
This is only one reason not aligning to size may be better...
--
John-Mark Gurney Voice: +1 415 225 5579
"All that I will do, has been done, All that I have, has not."
From matthias.andree at gmx.de Fri Feb 14 02:14:14 2014
From: matthias.andree at gmx.de (Matthias Andree)
Date: Fri, 14 Feb 2014 03:14:04 +0100
Subject: can the scheduler decide to schedule an interrupted but runnable
thread on another CPU core? What are the implications for code?
In-Reply-To:
References:
Message-ID: <52FD7BEC.9050807@gmx.de>
Am 14.02.2014 00:57, schrieb Adrian Chadd:
> Hi,
>
> Whilst digging into collisions in the flowtable code I discovered that
> a bunch of them are due to some of the flowtable_lookup() code running
> on a different CPU - the contention on the l2/l3 lookup lock(s) was
> enough to block things so they'd get an obvious chance to be migrated.
>
> So this led me to wonder whether in a fully preemptive kernel, a
> running kernel thread would stay on the current CPU until it hit a
> very specific subset of things (exited to userland, hit a lock, etc.)
>
> Apparently (according to kan and rwatson) this is how we define fully
> preemptive - it's not just interruptable at almost any point, but the
> running task may be interrupted and rescheduled on a different CPU
> outside of specific critical sections.
There's one more question to ask, and that is if you have a thread that
warmed up its caches and you migrate it to a different core - what
happens with the execution time? It might become longer because you
don't usually share or migrate the L1/L2 cache contents, so I'd naively
expect lower cache hit ratios. Certainly there is not a simple answer
to that, but should someone start thinking about scheduler
implementations, the "setup overhead" for the switch to a different core
might be relevant. (Whether it's really more than the extra effort a
scheduler would require to spend to make a better decision is then yet
one more question.)
From rysto32 at gmail.com Fri Feb 14 02:37:05 2014
From: rysto32 at gmail.com (Ryan Stone)
Date: Thu, 13 Feb 2014 21:37:04 -0500
Subject: can the scheduler decide to schedule an interrupted but runnable
thread on another CPU core? What are the implications for code?
In-Reply-To:
References:
Message-ID:
On Thu, Feb 13, 2014 at 6:57 PM, Adrian Chadd wrote:
> sequentually:
>
> * lookup occurs on CPU A;
> * lookup succeeds on CPU A for some almost-expired entry;
> * preemption occurs, and it gets scheduled to CPU B;
>
> then simultaneously:
>
> * CPU A's flowtable purge code runs, and decides to purge entries
> including the current one;
> * the code now running on CPU B has an item from the CPU A flowtable,
> and dereferences it as it's being freed, leading to potential badness.
This kind of scenario is definitely possible. All of the FreeBSD
kernel code that deals with lockless per-cpu data structures that I
have seen (e.g. uma) has used critical_enter()/critical_exit() to
prevent preemption, and have been careful to invalidate their
references to the per-cpu data if they have to drop the critical
section.
I don't believe that sched_pin() is good enough because I don't
believe that it handles the scenario when thread A gets a reference
and then is preempted, thread B frees the entry, and then A is
scheduled and uses the now-freed entry. However I'm really not
familiar at all with flowtable so maybe there's something preventing
that.
From adrian at freebsd.org Fri Feb 14 03:06:09 2014
From: adrian at freebsd.org (Adrian Chadd)
Date: Thu, 13 Feb 2014 19:06:07 -0800
Subject: can the scheduler decide to schedule an interrupted but runnable
thread on another CPU core? What are the implications for code?
In-Reply-To:
References:
Message-ID:
On 13 February 2014 18:37, Ryan Stone wrote:
> On Thu, Feb 13, 2014 at 6:57 PM, Adrian Chadd wrote:
>> sequentually:
>>
>> * lookup occurs on CPU A;
>> * lookup succeeds on CPU A for some almost-expired entry;
>> * preemption occurs, and it gets scheduled to CPU B;
>>
>> then simultaneously:
>>
>> * CPU A's flowtable purge code runs, and decides to purge entries
>> including the current one;
>> * the code now running on CPU B has an item from the CPU A flowtable,
>> and dereferences it as it's being freed, leading to potential badness.
>
> This kind of scenario is definitely possible. All of the FreeBSD
> kernel code that deals with lockless per-cpu data structures that I
> have seen (e.g. uma) has used critical_enter()/critical_exit() to
> prevent preemption, and have been careful to invalidate their
> references to the per-cpu data if they have to drop the critical
> section.
>
> I don't believe that sched_pin() is good enough because I don't
> believe that it handles the scenario when thread A gets a reference
> and then is preempted, thread B frees the entry, and then A is
> scheduled and uses the now-freed entry. However I'm really not
> familiar at all with flowtable so maybe there's something preventing
> that.
Oh man, I hate you for bringing that up.
So, both flowtable_lookup_common() and flowtable_insert() does do a
critical_enter() / critical_exit() during the list operations, so
that's ok. It won't be pre-empted.
If I wrap flowtable_lookup() with sched_pin() so it covers both the
lookup path and the insert path, then it won't get scheduled on
another CPU. Then the critical sections around the list operations
guarantee it won't end up with a freed entry. The fl entry uptime is
updated in the critical section so it shouldn't end up overlapping
with the flow purger in a way that has it removed.
So, I think that's okay. I think once i add sched_pin() in the right
spots, this crap won't use a stale entry. Well, as long as the entry
get used before the flow cleaner picks it up.
Phew!
-adrian
From Mark.Martinec+freebsd at ijs.si Fri Feb 14 01:40:14 2014
From: Mark.Martinec+freebsd at ijs.si (Mark Martinec)
Date: Fri, 14 Feb 2014 02:40:07 +0100
Subject: Merge ping+ping6 and traceroue+traceroute6 to single
=?UTF-8?Q?utilities=3F?=
In-Reply-To:
References: <1063008459.20140111160525@serebryakov.spb.ru>
<52D14140.3090003@gibfest.dk> <20140111.143644.41639035.sthaug@nethelp.no>
<52D15185.50802@gibfest.dk>
<0c45208d87526a80f559ac09e28163c2.authenticated@ultimatedns.net>