From fb8de0f1e1a0e38878bacd50911133df5b0c83e9 Mon Sep 17 00:00:00 2001 From: claudio Date: Tue, 3 May 2022 09:18:11 +0000 Subject: [PATCH] Retire CRYPTO_F_MPSAFE it is no longer of any use. The crypto framework no longer uses a callback and so there is no need to define the callback as MPSAFE. OK bluhm@ --- sys/crypto/cryptodev.h | 3 +-- sys/netinet/ip_ah.c | 6 +++--- sys/netinet/ip_esp.c | 6 +++--- sys/netinet/ip_ipcomp.c | 6 +++--- 4 files changed, 10 insertions(+), 11 deletions(-) diff --git a/sys/crypto/cryptodev.h b/sys/crypto/cryptodev.h index 9f353aa86b6..c04845dadfd 100644 --- a/sys/crypto/cryptodev.h +++ b/sys/crypto/cryptodev.h @@ -1,4 +1,4 @@ -/* $OpenBSD: cryptodev.h,v 1.81 2021/10/24 14:50:42 tobhe Exp $ */ +/* $OpenBSD: cryptodev.h,v 1.82 2022/05/03 09:18:11 claudio Exp $ */ /* * The author of this code is Angelos D. Keromytis (angelos@cis.upenn.edu) @@ -158,7 +158,6 @@ struct cryptop { #define CRYPTO_F_IMBUF 0x0001 /* Input/output are mbuf chains, otherwise contig */ #define CRYPTO_F_IOV 0x0002 /* Input/output are uio */ -#define CRYPTO_F_MPSAFE 0x0004 /* Do not use kernel lock for callback */ void *crp_buf; /* Data to be processed */ diff --git a/sys/netinet/ip_ah.c b/sys/netinet/ip_ah.c index 286c6cb2f2f..a92c70e6175 100644 --- a/sys/netinet/ip_ah.c +++ b/sys/netinet/ip_ah.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_ah.c,v 1.173 2021/12/23 22:35:11 bluhm Exp $ */ +/* $OpenBSD: ip_ah.c,v 1.174 2022/05/03 09:18:11 claudio Exp $ */ /* * The authors of this code are John Ioannidis (ji@tla.org), * Angelos D. Keromytis (kermit@csd.uch.gr) and @@ -683,7 +683,7 @@ ah_input(struct mbuf **mp, struct tdb *tdb, int skip, int protoff) /* Crypto operation descriptor. */ crp->crp_ilen = m->m_pkthdr.len; /* Total input length. */ - crp->crp_flags = CRYPTO_F_IMBUF | CRYPTO_F_MPSAFE; + crp->crp_flags = CRYPTO_F_IMBUF; crp->crp_buf = (caddr_t)m; crp->crp_sid = tdb->tdb_cryptoid; @@ -1106,7 +1106,7 @@ ah_output(struct mbuf *m, struct tdb *tdb, int skip, int protoff) /* Crypto operation descriptor. */ crp->crp_ilen = m->m_pkthdr.len; /* Total input length. */ - crp->crp_flags = CRYPTO_F_IMBUF | CRYPTO_F_MPSAFE; + crp->crp_flags = CRYPTO_F_IMBUF; crp->crp_buf = (caddr_t)m; crp->crp_sid = tdb->tdb_cryptoid; diff --git a/sys/netinet/ip_esp.c b/sys/netinet/ip_esp.c index 6c8e3d7d1a3..ac4d6292bbc 100644 --- a/sys/netinet/ip_esp.c +++ b/sys/netinet/ip_esp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_esp.c,v 1.194 2022/01/20 11:06:57 bluhm Exp $ */ +/* $OpenBSD: ip_esp.c,v 1.195 2022/05/03 09:18:11 claudio Exp $ */ /* * The authors of this code are John Ioannidis (ji@tla.org), * Angelos D. Keromytis (kermit@csd.uch.gr) and @@ -483,7 +483,7 @@ esp_input(struct mbuf **mp, struct tdb *tdb, int skip, int protoff) /* Crypto operation descriptor */ crp->crp_ilen = m->m_pkthdr.len; /* Total input length */ - crp->crp_flags = CRYPTO_F_IMBUF | CRYPTO_F_MPSAFE; + crp->crp_flags = CRYPTO_F_IMBUF; crp->crp_buf = (caddr_t)m; crp->crp_sid = tdb->tdb_cryptoid; @@ -916,7 +916,7 @@ esp_output(struct mbuf *m, struct tdb *tdb, int skip, int protoff) /* Crypto operation descriptor. */ crp->crp_ilen = m->m_pkthdr.len; /* Total input length. */ - crp->crp_flags = CRYPTO_F_IMBUF | CRYPTO_F_MPSAFE; + crp->crp_flags = CRYPTO_F_IMBUF; crp->crp_buf = (caddr_t)m; crp->crp_sid = tdb->tdb_cryptoid; diff --git a/sys/netinet/ip_ipcomp.c b/sys/netinet/ip_ipcomp.c index 2221c7a44b7..4fb108299d8 100644 --- a/sys/netinet/ip_ipcomp.c +++ b/sys/netinet/ip_ipcomp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ip_ipcomp.c,v 1.91 2021/12/23 12:21:48 bluhm Exp $ */ +/* $OpenBSD: ip_ipcomp.c,v 1.92 2022/05/03 09:18:11 claudio Exp $ */ /* * Copyright (c) 2001 Jean-Jacques Bernard-Gundol (jj@wabbitt.org) @@ -167,7 +167,7 @@ ipcomp_input(struct mbuf **mp, struct tdb *tdb, int skip, int protoff) /* Crypto operation descriptor */ crp->crp_ilen = m->m_pkthdr.len - (skip + hlen); - crp->crp_flags = CRYPTO_F_IMBUF | CRYPTO_F_MPSAFE; + crp->crp_flags = CRYPTO_F_IMBUF; crp->crp_buf = (caddr_t)m; crp->crp_sid = tdb->tdb_cryptoid; @@ -453,7 +453,7 @@ ipcomp_output(struct mbuf *m, struct tdb *tdb, int skip, int protoff) /* Crypto operation descriptor */ crp->crp_ilen = m->m_pkthdr.len; /* Total input length */ - crp->crp_flags = CRYPTO_F_IMBUF | CRYPTO_F_MPSAFE; + crp->crp_flags = CRYPTO_F_IMBUF; crp->crp_buf = (caddr_t)m; crp->crp_sid = tdb->tdb_cryptoid; -- 2.20.1