From add3d8afc7fd199c0fe6bf40a46462c2f77f9ef5 Mon Sep 17 00:00:00 2001 From: Flavio Cruz Date: Sun, 7 May 2023 13:15:02 -0400 Subject: Implement device_open_new for all the translators implementing the device interface. Message-Id: --- eth-multiplexer/Makefile | 2 +- eth-multiplexer/device_impl.c | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) (limited to 'eth-multiplexer') diff --git a/eth-multiplexer/Makefile b/eth-multiplexer/Makefile index 5f3d2739..c9dd660d 100644 --- a/eth-multiplexer/Makefile +++ b/eth-multiplexer/Makefile @@ -23,7 +23,7 @@ target = eth-multiplexer SRCS = ethernet.c vdev.c multiplexer.c dev_stat.c netfs_impl.c device_impl.c dead-name.c demuxer.c MIGSTUBS = deviceServer.o MIGSFLAGS = -imacros $(srcdir)/mig-mutate.h -device-MIGSFLAGS="-DMACH_PAYLOAD_TO_PORT=ports_payload_get_name" +device-MIGSFLAGS=-DMACH_PAYLOAD_TO_PORT=ports_payload_get_name -DDEVICE_ENABLE_DEVICE_OPEN_NEW OBJS = $(SRCS:.c=.o) $(MIGSTUBS) LCLHDRS = ethernet.h util.h vdev.h netfs_impl.h HURDLIBS = ports ihash iohelp fshelp shouldbeinlibc netfs bpf diff --git a/eth-multiplexer/device_impl.c b/eth-multiplexer/device_impl.c index 152dc7bc..6a67fbd9 100644 --- a/eth-multiplexer/device_impl.c +++ b/eth-multiplexer/device_impl.c @@ -83,6 +83,16 @@ ds_device_open (mach_port_t master_port, mach_port_t reply_port, return D_NO_SUCH_DEVICE; } +kern_return_t +ds_device_open_new (mach_port_t master_port, mach_port_t reply_port, + mach_msg_type_name_t reply_portPoly, + dev_mode_t mode, const_dev_name_t name, mach_port_t *device, + mach_msg_type_name_t *devicetype) +{ + return ds_device_open (master_port, reply_port, reply_portPoly, mode, + name, device, devicetype); +} + kern_return_t ds_device_close (struct vether_device *device) { -- cgit v1.2.3