Date: Mon, 11 Mar 2019 21:56:35 +0000 (UTC) From: John Baldwin <jhb@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r345031 - stable/11/sys/opencrypto Message-ID: <201903112156.x2BLuZuZ049793@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: jhb Date: Mon Mar 11 21:56:35 2019 New Revision: 345031 URL: https://svnweb.freebsd.org/changeset/base/345031 Log: MFC 328057: Split crp_buf into a union. This adds explicit crp_mbuf and crp_uio pointers of the right type to replace casts of crp_buf. This does not sweep through changing existing code, but new code should use the correct fields instead of casts. Sponsored by: Chelsio Communications Modified: stable/11/sys/opencrypto/cryptodev.h Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/opencrypto/cryptodev.h ============================================================================== --- stable/11/sys/opencrypto/cryptodev.h Mon Mar 11 21:51:15 2019 (r345030) +++ stable/11/sys/opencrypto/cryptodev.h Mon Mar 11 21:56:35 2019 (r345031) @@ -421,7 +421,11 @@ struct cryptop { #define CRYPTO_F_DONE 0x0020 /* Operation completed */ #define CRYPTO_F_CBIFSYNC 0x0040 /* Do CBIMM if op is synchronous */ - caddr_t crp_buf; /* Data to be processed */ + union { + caddr_t crp_buf; /* Data to be processed */ + struct mbuf *crp_mbuf; + struct uio *crp_uio; + }; void * crp_opaque; /* Opaque pointer, passed along */ struct cryptodesc *crp_desc; /* Linked list of processing descriptors */ @@ -522,5 +526,6 @@ extern void crypto_copydata(int flags, caddr_t buf, in caddr_t out); extern int crypto_apply(int flags, caddr_t buf, int off, int len, int (*f)(void *, void *, u_int), void *arg); + #endif /* _KERNEL */ #endif /* _CRYPTO_CRYPTO_H_ */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201903112156.x2BLuZuZ049793>