diff options
author | Sergey Bugaev <bugaevc@gmail.com> | 2023-05-09 00:31:23 +0300 |
---|---|---|
committer | Samuel Thibault <samuel.thibault@ens-lyon.org> | 2023-05-10 02:42:05 +0200 |
commit | ce0ae22d02f286c5a0ef61b5dd8e6ee9b56620d7 (patch) | |
tree | 916596c570226fa36b8b7ebd73edb16690f688e1 /eth-multiplexer | |
parent | 75f76d10aad328a1af5961cb365a2b4325b98d8e (diff) | |
download | hurd-ce0ae22d02f286c5a0ef61b5dd8e6ee9b56620d7.tar.gz hurd-ce0ae22d02f286c5a0ef61b5dd8e6ee9b56620d7.tar.bz2 hurd-ce0ae22d02f286c5a0ef61b5dd8e6ee9b56620d7.zip |
eth-multiplexer: Port to x86_64
Message-Id: <20230508213136.608575-29-bugaevc@gmail.com>
Diffstat (limited to 'eth-multiplexer')
-rw-r--r-- | eth-multiplexer/device_impl.c | 18 | ||||
-rw-r--r-- | eth-multiplexer/ethernet.c | 4 |
2 files changed, 12 insertions, 10 deletions
diff --git a/eth-multiplexer/device_impl.c b/eth-multiplexer/device_impl.c index 6a67fbd9..8a22793a 100644 --- a/eth-multiplexer/device_impl.c +++ b/eth-multiplexer/device_impl.c @@ -102,8 +102,8 @@ ds_device_close (struct vether_device *device) kern_return_t ds_device_write (struct vether_device *vdev, mach_port_t reply_port, mach_msg_type_name_t reply_type, dev_mode_t mode, - recnum_t recnum, io_buf_ptr_t data, size_t datalen, - int *bytes_written) + recnum_t recnum, io_buf_ptr_t data, + mach_msg_type_number_t datalen, int *bytes_written) { kern_return_t ret = 0; if (vdev == NULL) @@ -129,7 +129,7 @@ kern_return_t ds_device_write_inband (struct vether_device *vdev, mach_port_t reply_port, mach_msg_type_name_t reply_type, dev_mode_t mode, recnum_t recnum, const io_buf_ptr_inband_t data, - size_t datalen, int *bytes_written) + mach_msg_type_number_t datalen, int *bytes_written) { if (vdev == NULL) return D_NO_SUCH_DEVICE; @@ -140,7 +140,7 @@ kern_return_t ds_device_read (struct vether_device *vdev, mach_port_t reply_port, mach_msg_type_name_t reply_type, dev_mode_t mode, recnum_t recnum, int bytes_wanted, - io_buf_ptr_t *data, size_t *datalen) + io_buf_ptr_t *data, mach_msg_type_number_t *datalen) { if (vdev == NULL) return D_NO_SUCH_DEVICE; @@ -151,7 +151,8 @@ kern_return_t ds_device_read_inband (struct vether_device *vdev, mach_port_t reply_port, mach_msg_type_name_t reply_type, dev_mode_t mode, recnum_t recnum, int bytes_wanted, - io_buf_ptr_inband_t data, size_t *datalen) + io_buf_ptr_inband_t data, + mach_msg_type_number_t *datalen) { if (vdev == NULL) return D_NO_SUCH_DEVICE; @@ -169,7 +170,7 @@ ds_device_map (struct vether_device *vdev, vm_prot_t prot, vm_offset_t offset, kern_return_t ds_device_set_status (struct vether_device *vdev, dev_flavor_t flavor, - dev_status_t status, size_t statuslen) + dev_status_t status, mach_msg_type_number_t statuslen) { if (vdev == NULL) return D_NO_SUCH_DEVICE; @@ -178,7 +179,7 @@ ds_device_set_status (struct vether_device *vdev, dev_flavor_t flavor, kern_return_t ds_device_get_status (struct vether_device *vdev, dev_flavor_t flavor, - dev_status_t status, size_t *statuslen) + dev_status_t status, mach_msg_type_number_t *statuslen) { if (vdev == NULL) return D_NO_SUCH_DEVICE; @@ -188,7 +189,8 @@ ds_device_get_status (struct vether_device *vdev, dev_flavor_t flavor, kern_return_t ds_device_set_filter (struct vether_device *vdev, mach_port_t receive_port, - int priority, filter_array_t filter, size_t filterlen) + int priority, filter_array_t filter, + mach_msg_type_number_t filterlen) { kern_return_t err; diff --git a/eth-multiplexer/ethernet.c b/eth-multiplexer/ethernet.c index e45a4b94..13f0036e 100644 --- a/eth-multiplexer/ethernet.c +++ b/eth-multiplexer/ethernet.c @@ -80,7 +80,7 @@ eth_set_clear_flags (int set_flags, int clear_flags) { error_t err; int flags; - size_t count; + mach_msg_type_number_t count; count = 1; err = device_get_status (ether_port, NET_FLAGS, (dev_status_t) &flags, @@ -109,7 +109,7 @@ get_ethernet_address (mach_port_t port, char *address) { error_t err; int net_address[2]; - size_t count = 2; + mach_msg_type_number_t count = 2; assert_backtrace (count * sizeof (int) >= ETH_ALEN); err = device_get_status (port, NET_ADDRESS, net_address, &count); |