Date: Wed, 3 Jun 1998 05:20:01 -0700 (PDT) From: David Greenman <dg@root.com> To: freebsd-bugs@FreeBSD.ORG Subject: Re: kern/6837: in_setpeeraddr() and in_setsockaddr() block on memory Message-ID: <199806031220.FAA21660@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/6837; it has been noted by GNATS. From: David Greenman <dg@root.com> To: Craig Metz <cmetz@inner.net> Cc: freebsd-gnats-submit@FreeBSD.ORG, wollman@FreeBSD.ORG Subject: Re: kern/6837: in_setpeeraddr() and in_setsockaddr() block on memory Date: Wed, 03 Jun 1998 05:11:02 -0700 >In message <199806031159.EAA22091@implode.root.com>, you write: >>> The other, far easier to explain answer, is that we're putting some code in >>>there for IPv6 support that makes the malloc() happen at splnet(), and >>>tsleep()ing at such a priority is not good. >> >> That would be bad, but I don't think the solution is to make it fail on >>temporary resource shortages. I think a better solution would be to change >>the functions to take an already (m)alloced struct sockaddr_in and change >>the callers (I think there are only two) to accomodate. > > In 4.4-Lite2, they did basically just that. Why did they change? I believe this was a side effect of the elimination of using mbufs as containers for sockaddr data. I don't see a problem with changing the caller to malloc(), but perhaps Garrett might have a thought on this since he was the one to add the MALLOC there in the first place. Garrett? -DG David Greenman Co-founder/Principal Architect, The FreeBSD Project To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199806031220.FAA21660>