Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 18 May 2000 21:04:30 -0400
From:      Sergey Babkin <babkin@bellatlantic.net>
To:        Warner Losh <imp@village.org>
Cc:        Alexander Langer <alex@big.endian.de>, doc@FreeBSD.ORG, hackers@FreeBSD.ORG
Subject:   Re: request for review: bus_alloc_resource(9)
Message-ID:  <3924931E.A8471B0@bellatlantic.net>
References:  <20000518223846.A16098@cichlids.cichlids.com> <200005182332.RAA97696@harmony.village.org>

next in thread | previous in thread | raw e-mail | index | archive | help
Warner Losh wrote:
> 
> One should generally only call these functions in attach.  If you must
> call them in probe, one must release the resource before returning
> from the probe.  However, since they can affect bridge settings, it
> may be unavoidable to call them from the probe routine.

The code seems to guarantee that if the probe routine returns 0
then the attach routine will be called right away. So if the probe
routine returns 0 they don't have to be freed. Actually, the
comments seem to say explicitly that the resources should be
freed only if the probe routine returns a negative value but not 0.
Or am I missing something ?

-SB


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-doc" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3924931E.A8471B0>