jbra...@dismail.de via Bug reports for the GNU Hurd, le sam. 12 oct. 2024 10:36:50 -0400, a ecrit: > +`struct irq`'s definition is: > + > + struct irq { > + void (*handler)(void *); > + void *context; > + int gsi; > + mach_port_t port; > + bool enabled; > + bool shutdown; > + pthread_mutex_t irqlock; > + pthread_cond_t irqcond; > + };
I don't think we want to provide the struct irq content, since it's private data. > +If you want to use pthread, then set up this function, which installs > +the handlers via pthread. `arg` is a `struct irc *`. > + > + void * irqhelp_server_loop (void *arg); You have to use this function anyway, otherwise irqhelper won't work at all. It's ready for use with pthread_create, but it could also be called explicitly in e.g. an existing thread. Samuel