svn commit: r298519 - in head/sys: compat/svr4 dev/streams modules/streams modules/svr4
Dmitry Chagin
dchagin at FreeBSD.org
Sat Apr 23 20:29:57 UTC 2016
Author: dchagin
Date: Sat Apr 23 20:29:55 2016
New Revision: 298519
URL: https://svnweb.freebsd.org/changeset/base/298519
Log:
Fix streams and svr4 module dependency. Both modules are complaining about
undefined symbol svr4_delete_socket which was moved from streams to the svr4 module
in r160558 that created a two-way dependency between them.
PR: 208464
Submitted by: Kristoffer Eriksson
Reported by: Kristoffer Eriksson
MFC after: 2 week
Modified:
head/sys/compat/svr4/svr4_socket.c
head/sys/compat/svr4/svr4_sysvec.c
head/sys/dev/streams/streams.c
head/sys/modules/streams/Makefile
head/sys/modules/svr4/Makefile
Modified: head/sys/compat/svr4/svr4_socket.c
==============================================================================
--- head/sys/compat/svr4/svr4_socket.c Sat Apr 23 18:28:59 2016 (r298518)
+++ head/sys/compat/svr4/svr4_socket.c Sat Apr 23 20:29:55 2016 (r298519)
@@ -66,6 +66,7 @@ __FBSDID("$FreeBSD$");
#include <compat/svr4/svr4_signal.h>
#include <compat/svr4/svr4_sockmod.h>
#include <compat/svr4/svr4_proto.h>
+#include <compat/svr4/svr4_stropts.h>
struct svr4_sockcache_entry {
struct proc *p; /* Process for the socket */
@@ -170,6 +171,19 @@ svr4_delete_socket(p, fp)
mtx_unlock(&svr4_sockcache_lock);
}
+struct svr4_strm *
+svr4_stream_get(fp)
+ struct file *fp;
+{
+ struct socket *so;
+
+ if (fp == NULL || fp->f_type != DTYPE_SOCKET)
+ return NULL;
+
+ so = fp->f_data;
+ return so->so_emuldata;
+}
+
void
svr4_purge_sockcache(arg, p)
void *arg;
Modified: head/sys/compat/svr4/svr4_sysvec.c
==============================================================================
--- head/sys/compat/svr4/svr4_sysvec.c Sat Apr 23 18:28:59 2016 (r298518)
+++ head/sys/compat/svr4/svr4_sysvec.c Sat Apr 23 20:29:55 2016 (r298519)
@@ -310,4 +310,4 @@ static moduledata_t svr4_elf_mod = {
0
};
DECLARE_MODULE_TIED(svr4elf, svr4_elf_mod, SI_SUB_EXEC, SI_ORDER_ANY);
-MODULE_DEPEND(svr4elf, streams, 1, 1, 1);
+MODULE_VERSION(svr4elf, 1);
Modified: head/sys/dev/streams/streams.c
==============================================================================
--- head/sys/dev/streams/streams.c Sat Apr 23 18:28:59 2016 (r298518)
+++ head/sys/dev/streams/streams.c Sat Apr 23 20:29:55 2016 (r298519)
@@ -169,6 +169,7 @@ static moduledata_t streams_mod = {
};
DECLARE_MODULE(streams, streams_mod, SI_SUB_DRIVERS, SI_ORDER_ANY);
MODULE_VERSION(streams, 1);
+MODULE_DEPEND(streams, svr4elf, 1, 1, 1);
/*
* We only need open() and close() routines. open() calls socreate()
@@ -321,19 +322,6 @@ svr4_ptm_alloc(td)
}
-struct svr4_strm *
-svr4_stream_get(fp)
- struct file *fp;
-{
- struct socket *so;
-
- if (fp == NULL || fp->f_type != DTYPE_SOCKET)
- return NULL;
-
- so = fp->f_data;
- return so->so_emuldata;
-}
-
static int
svr4_soo_close(struct file *fp, struct thread *td)
{
Modified: head/sys/modules/streams/Makefile
==============================================================================
--- head/sys/modules/streams/Makefile Sat Apr 23 18:28:59 2016 (r298518)
+++ head/sys/modules/streams/Makefile Sat Apr 23 20:29:55 2016 (r298519)
@@ -5,10 +5,6 @@
KMOD= streams
SRCS= streams.c
-EXPORT_SYMS= svr4_str_initialized \
- svr4_stream_get \
- svr4_delete_socket
-
.if defined(DEBUG)
CFLAGS+= -DDEBUG_SVR4
.endif
Modified: head/sys/modules/svr4/Makefile
==============================================================================
--- head/sys/modules/svr4/Makefile Sat Apr 23 18:28:59 2016 (r298518)
+++ head/sys/modules/svr4/Makefile Sat Apr 23 20:29:55 2016 (r298519)
@@ -8,6 +8,7 @@ SRCS= svr4_sysent.c svr4_sysvec.c opt_co
svr4_termios.c svr4_stream.c svr4_socket.c svr4_sockio.c \
svr4_machdep.c svr4_resource.c svr4_ipc.c
OBJS= svr4_locore.o
+EXPORT_SYMS= svr4_delete_socket
SRCS+= opt_ktrace.h opt_sysvipc.h
More information about the svn-src-head
mailing list