Date: Thu, 05 Feb 2009 11:35:16 -0700 (MST) From: "M. Warner Losh" <imp@bsdimp.com> To: niclas.zeising@gmail.com Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r188154 - head/sys/opencrypto Message-ID: <20090205.113516.113804072.imp@bsdimp.com> In-Reply-To: <498B2829.9000608@gmail.com> References: <200902051743.n15HhCMx033130@svn.freebsd.org> <498B2829.9000608@gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
In message: <498B2829.9000608@gmail.com>
Niclas Zeising <niclas.zeising@gmail.com> writes:
: Warner Losh wrote:
: > Author: imp
: > Date: Thu Feb 5 17:43:12 2009
: > New Revision: 188154
: > URL: http://svn.freebsd.org/changeset/base/188154
: >
: > Log:
: > Fix return type for detach routine (should be int)
: > Fix first parameter for identify routine (should be driver_t *)
: >
: > Modified:
: > head/sys/opencrypto/cryptosoft.c
: >
: > Modified: head/sys/opencrypto/cryptosoft.c
: > ==============================================================================
: > --- head/sys/opencrypto/cryptosoft.c Thu Feb 5 15:09:42 2009 (r188153)
: > +++ head/sys/opencrypto/cryptosoft.c Thu Feb 5 17:43:12 2009 (r188154)
: > @@ -986,7 +986,7 @@ done:
: > }
: >
: > static void
: > -swcr_identify(device_t *dev, device_t parent)
: > +swcr_identify(driver_t *drv, device_t parent)
: ^^^
:
: Was this name change intentional?
Yes. It 'dev' is typically used for 'device_t' types. However, by
changing this to drv, it shows it isn't a device_t, and also breaks
any code that used the old variable with a compiler error.
Warner
: > {
: > /* NB: order 10 is so we get attached after h/w devices */
: > if (device_find_child(parent, "cryptosoft", -1) == NULL &&
: > @@ -1040,12 +1040,13 @@ swcr_attach(device_t dev)
: > return 0;
: > }
: >
: > -static void
: > +static int
: > swcr_detach(device_t dev)
: > {
: > crypto_unregister_all(swcr_id);
: > if (swcr_sessions != NULL)
: > free(swcr_sessions, M_CRYPTO_DATA);
: > + return 0;
: > }
: >
: > static device_method_t swcr_methods[] = {
:
: Regards!
: //Niclas
:
:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090205.113516.113804072.imp>
