Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/opencrypto Try not to use f_data, use f_fcrypt to get a ...
details: https://anonhg.NetBSD.org/src/rev/f03181ca84fa
branches: trunk
changeset: 332054:f03181ca84fa
user: matt <matt%NetBSD.org@localhost>
date: Fri Sep 05 09:23:40 2014 +0000
description:
Try not to use f_data, use f_fcrypt to get a correctly typed pointer.
diffstat:
sys/opencrypto/cryptodev.c | 14 +++++++-------
sys/opencrypto/ocryptodev.c | 6 +++---
2 files changed, 10 insertions(+), 10 deletions(-)
diffs (90 lines):
diff -r 9b0f3b7f805d -r f03181ca84fa sys/opencrypto/cryptodev.c
--- a/sys/opencrypto/cryptodev.c Fri Sep 05 09:23:14 2014 +0000
+++ b/sys/opencrypto/cryptodev.c Fri Sep 05 09:23:40 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: cryptodev.c,v 1.80 2014/08/04 14:17:18 skrll Exp $ */
+/* $NetBSD: cryptodev.c,v 1.81 2014/09/05 09:23:40 matt Exp $ */
/* $FreeBSD: src/sys/opencrypto/cryptodev.c,v 1.4.2.4 2003/06/03 00:09:02 sam Exp $ */
/* $OpenBSD: cryptodev.c,v 1.53 2002/07/10 22:21:30 mickey Exp $ */
@@ -64,7 +64,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: cryptodev.c,v 1.80 2014/08/04 14:17:18 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: cryptodev.c,v 1.81 2014/09/05 09:23:40 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -220,7 +220,7 @@
int
cryptof_ioctl(struct file *fp, u_long cmd, void *data)
{
- struct fcrypt *fcr = fp->f_data;
+ struct fcrypt *fcr = fp->f_fcrypt;
struct csession *cse;
struct session_op *sop;
struct session_n_op *snop;
@@ -942,7 +942,7 @@
static int
cryptof_close(struct file *fp)
{
- struct fcrypt *fcr = fp->f_data;
+ struct fcrypt *fcr = fp->f_fcrypt;
struct csession *cse;
mutex_enter(&crypto_mtx);
@@ -953,7 +953,7 @@
mutex_enter(&crypto_mtx);
}
seldestroy(&fcr->sinfo);
- fp->f_data = NULL;
+ fp->f_fcrypt = NULL;
crypto_refcount--;
mutex_exit(&crypto_mtx);
@@ -2037,7 +2037,7 @@
static int
cryptof_stat(struct file *fp, struct stat *st)
{
- struct fcrypt *fcr = fp->f_data;
+ struct fcrypt *fcr = fp->f_fcrypt;
(void)memset(st, 0, sizeof(*st));
@@ -2056,7 +2056,7 @@
static int
cryptof_poll(struct file *fp, int events)
{
- struct fcrypt *fcr = (struct fcrypt *)fp->f_data;
+ struct fcrypt *fcr = fp->f_fcrypt;
int revents = 0;
if (!(events & (POLLIN | POLLRDNORM))) {
diff -r 9b0f3b7f805d -r f03181ca84fa sys/opencrypto/ocryptodev.c
--- a/sys/opencrypto/ocryptodev.c Fri Sep 05 09:23:14 2014 +0000
+++ b/sys/opencrypto/ocryptodev.c Fri Sep 05 09:23:40 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ocryptodev.c,v 1.5 2014/01/01 16:06:01 pgoyette Exp $ */
+/* $NetBSD: ocryptodev.c,v 1.6 2014/09/05 09:23:40 matt Exp $ */
/* $FreeBSD: src/sys/opencrypto/cryptodev.c,v 1.4.2.4 2003/06/03 00:09:02 sam Exp $ */
/* $OpenBSD: cryptodev.c,v 1.53 2002/07/10 22:21:30 mickey Exp $ */
@@ -69,7 +69,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ocryptodev.c,v 1.5 2014/01/01 16:06:01 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ocryptodev.c,v 1.6 2014/09/05 09:23:40 matt Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -109,7 +109,7 @@
int
ocryptof_ioctl(struct file *fp, u_long cmd, void *data)
{
- struct fcrypt *fcr = fp->f_data;
+ struct fcrypt *fcr = fp->f_fcrypt;
struct csession *cse;
struct osession_op *osop;
struct osession_n_op *osnop;
- Prev by Date:
[src/trunk]: src/sys Try not to use f_data, use f_{vnode, socket, pipe, mqueue, k...
- Next by Date:
[src/trunk]: src/sys/uvm Don't nest structure definitions.
- Previous by Thread:
[src/trunk]: src/sys Try not to use f_data, use f_{vnode, socket, pipe, mqueue, k...
- Next by Thread:
[src/trunk]: src/sys/uvm Don't nest structure definitions.
- Indexes:
Home |
Main Index |
Thread Index |
Old Index