[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH 3/6] libmachdev: make the two port buckets clearly distinct
From: |
Samuel Thibault |
Subject: |
Re: [PATCH 3/6] libmachdev: make the two port buckets clearly distinct |
Date: |
Mon, 14 Apr 2014 01:40:02 +0200 |
User-agent: |
Mutt/1.5.21+34 (58baf7c9f32f) (2010-12-30) |
Justus Winter, le Sun 13 Apr 2014 13:43:11 +0200, a écrit :
> libmachdev uses two port buckets previously both named port_bucket.
> Rename the one containing device_t ports to device_bucket to clearly
> distinguish them.
Ack.
> * libmachdev/ds_routines.c (port_bucket): Rename to device_bucket.
> * libmachdev/mig-decls.h: Likewise.
> ---
> libmachdev/ds_routines.c | 8 ++++----
> libmachdev/mig-decls.h | 4 ++--
> 2 files changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/libmachdev/ds_routines.c b/libmachdev/ds_routines.c
> index 2f9388a..4541d54 100644
> --- a/libmachdev/ds_routines.c
> +++ b/libmachdev/ds_routines.c
> @@ -70,7 +70,7 @@
> #include "queue.h"
> #include "mach_glue.h"
>
> -struct port_bucket *port_bucket;
> +struct port_bucket *device_bucket;
> struct port_class *dev_class;
>
> #define NUM_EMULATION num_emul
> @@ -332,7 +332,7 @@ ds_device_map (struct mach_device *device, vm_prot_t
> prot, vm_offset_t offset,
>
> int create_device_port (int size, void *result)
> {
> - return ports_create_port (dev_class, port_bucket,
> + return ports_create_port (dev_class, device_bucket,
> size, result);
> }
>
> @@ -340,7 +340,7 @@ void mach_device_init()
> {
> int i;
>
> - port_bucket = ports_create_bucket ();
> + device_bucket = ports_create_bucket ();
> dev_class = ports_create_class (0, 0);
>
> for (i = 0; i < NUM_EMULATION; i++) {
> @@ -377,7 +377,7 @@ void * ds_server(void *arg)
> /* Launch. */
> do
> {
> - ports_manage_port_operations_one_thread (port_bucket, demuxer, 0);
> + ports_manage_port_operations_one_thread (device_bucket, demuxer, 0);
> } while (1);
>
> return NULL;
> diff --git a/libmachdev/mig-decls.h b/libmachdev/mig-decls.h
> index 1d137cd..b3dc43d 100644
> --- a/libmachdev/mig-decls.h
> +++ b/libmachdev/mig-decls.h
> @@ -23,7 +23,7 @@
> #include <hurd/ports.h>
> #include "dev_hdr.h"
>
> -extern struct port_bucket *port_bucket;
> +extern struct port_bucket *device_bucket;
> extern struct port_class *dev_class;
>
> /* Called by server stub functions. */
> @@ -31,7 +31,7 @@ extern struct port_class *dev_class;
> static inline struct mach_device * __attribute__ ((unused))
> begin_using_device_port (mach_port_t port)
> {
> - return ports_lookup_port (port_bucket, port, dev_class);
> + return ports_lookup_port (device_bucket, port, dev_class);
> }
>
> static inline void __attribute__ ((unused))
> --
> 1.9.1
>
--
Samuel
<A> sauf que le firewall bloque tout sauf internet
-+- ben ouais, il bloque ipx/spx ! -+-
- more dde fixes, Justus Winter, 2014/04/13
- [PATCH 1/6] libmachdev: fix device_open, Justus Winter, 2014/04/13
- [PATCH 2/6] libmachdev: remove mach_device_deallocate, Justus Winter, 2014/04/13
- [PATCH 3/6] libmachdev: make the two port buckets clearly distinct, Justus Winter, 2014/04/13
- Re: [PATCH 3/6] libmachdev: make the two port buckets clearly distinct,
Samuel Thibault <=
- [PATCH 4/6] libmachdev: drop unused declarations, Justus Winter, 2014/04/13
- [PATCH 6/6] libmachdev: add, fix and use declaration for create_device_port, Justus Winter, 2014/04/13
- [PATCH 5/6] libmachdev: add missing includes, Justus Winter, 2014/04/13