hurd: Fix preprocessor indentation
This commit is contained in:
parent
9a1793289b
commit
2f8902cc7a
|
@ -62,7 +62,7 @@ extern struct mutex _hurd_dtable_lock; /* Locks those two variables. */
|
||||||
extern struct hurd_fd *_hurd_fd_get (int fd);
|
extern struct hurd_fd *_hurd_fd_get (int fd);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_FD_H_EXTERN_INLINE struct hurd_fd *
|
_HURD_FD_H_EXTERN_INLINE struct hurd_fd *
|
||||||
_hurd_fd_get (int fd)
|
_hurd_fd_get (int fd)
|
||||||
{
|
{
|
||||||
|
@ -95,7 +95,7 @@ _hurd_fd_get (int fd)
|
||||||
|
|
||||||
return descriptor;
|
return descriptor;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -281,7 +281,7 @@ extern int _hurd_select (int nfds, struct pollfd *pollfds,
|
||||||
__hurd_file_name_lookup. */
|
__hurd_file_name_lookup. */
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_FD_H_EXTERN_INLINE error_t
|
_HURD_FD_H_EXTERN_INLINE error_t
|
||||||
__hurd_at_flags (int *at_flags, int *flags)
|
__hurd_at_flags (int *at_flags, int *flags)
|
||||||
{
|
{
|
||||||
|
@ -298,7 +298,7 @@ __hurd_at_flags (int *at_flags, int *flags)
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Variant of file_name_lookup used in *at function implementations.
|
/* Variant of file_name_lookup used in *at function implementations.
|
||||||
|
|
|
@ -63,7 +63,7 @@ struct hurd_port
|
||||||
extern void _hurd_port_init (struct hurd_port *port, mach_port_t init);
|
extern void _hurd_port_init (struct hurd_port *port, mach_port_t init);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_PORT_H_EXTERN_INLINE void
|
_HURD_PORT_H_EXTERN_INLINE void
|
||||||
_hurd_port_init (struct hurd_port *port, mach_port_t init)
|
_hurd_port_init (struct hurd_port *port, mach_port_t init)
|
||||||
{
|
{
|
||||||
|
@ -71,7 +71,7 @@ _hurd_port_init (struct hurd_port *port, mach_port_t init)
|
||||||
port->users = NULL;
|
port->users = NULL;
|
||||||
port->port = init;
|
port->port = init;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -86,7 +86,7 @@ _hurd_port_locked_get (struct hurd_port *port,
|
||||||
struct hurd_userlink *link);
|
struct hurd_userlink *link);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_PORT_H_EXTERN_INLINE mach_port_t
|
_HURD_PORT_H_EXTERN_INLINE mach_port_t
|
||||||
_hurd_port_locked_get (struct hurd_port *port,
|
_hurd_port_locked_get (struct hurd_port *port,
|
||||||
struct hurd_userlink *link)
|
struct hurd_userlink *link)
|
||||||
|
@ -102,7 +102,7 @@ _hurd_port_locked_get (struct hurd_port *port,
|
||||||
__spin_unlock (&port->lock);
|
__spin_unlock (&port->lock);
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Same, but locks PORT first. */
|
/* Same, but locks PORT first. */
|
||||||
|
@ -112,7 +112,7 @@ _hurd_port_get (struct hurd_port *port,
|
||||||
struct hurd_userlink *link);
|
struct hurd_userlink *link);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_PORT_H_EXTERN_INLINE mach_port_t
|
_HURD_PORT_H_EXTERN_INLINE mach_port_t
|
||||||
_hurd_port_get (struct hurd_port *port,
|
_hurd_port_get (struct hurd_port *port,
|
||||||
struct hurd_userlink *link)
|
struct hurd_userlink *link)
|
||||||
|
@ -124,7 +124,7 @@ _hurd_port_get (struct hurd_port *port,
|
||||||
HURD_CRITICAL_END;
|
HURD_CRITICAL_END;
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -136,7 +136,7 @@ _hurd_port_free (struct hurd_port *port,
|
||||||
mach_port_t used_port);
|
mach_port_t used_port);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_PORT_H_EXTERN_INLINE void
|
_HURD_PORT_H_EXTERN_INLINE void
|
||||||
_hurd_port_free (struct hurd_port *port,
|
_hurd_port_free (struct hurd_port *port,
|
||||||
struct hurd_userlink *link,
|
struct hurd_userlink *link,
|
||||||
|
@ -156,7 +156,7 @@ _hurd_port_free (struct hurd_port *port,
|
||||||
if (dealloc)
|
if (dealloc)
|
||||||
__mach_port_deallocate (__mach_task_self (), used_port);
|
__mach_port_deallocate (__mach_task_self (), used_port);
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -166,7 +166,7 @@ _hurd_port_free (struct hurd_port *port,
|
||||||
extern void _hurd_port_locked_set (struct hurd_port *port, mach_port_t newport);
|
extern void _hurd_port_locked_set (struct hurd_port *port, mach_port_t newport);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_PORT_H_EXTERN_INLINE void
|
_HURD_PORT_H_EXTERN_INLINE void
|
||||||
_hurd_port_locked_set (struct hurd_port *port, mach_port_t newport)
|
_hurd_port_locked_set (struct hurd_port *port, mach_port_t newport)
|
||||||
{
|
{
|
||||||
|
@ -177,7 +177,7 @@ _hurd_port_locked_set (struct hurd_port *port, mach_port_t newport)
|
||||||
if (old != MACH_PORT_NULL)
|
if (old != MACH_PORT_NULL)
|
||||||
__mach_port_deallocate (__mach_task_self (), old);
|
__mach_port_deallocate (__mach_task_self (), old);
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Same, but locks PORT first. */
|
/* Same, but locks PORT first. */
|
||||||
|
@ -185,7 +185,7 @@ _hurd_port_locked_set (struct hurd_port *port, mach_port_t newport)
|
||||||
extern void _hurd_port_set (struct hurd_port *port, mach_port_t newport);
|
extern void _hurd_port_set (struct hurd_port *port, mach_port_t newport);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_PORT_H_EXTERN_INLINE void
|
_HURD_PORT_H_EXTERN_INLINE void
|
||||||
_hurd_port_set (struct hurd_port *port, mach_port_t newport)
|
_hurd_port_set (struct hurd_port *port, mach_port_t newport)
|
||||||
{
|
{
|
||||||
|
@ -194,7 +194,7 @@ _hurd_port_set (struct hurd_port *port, mach_port_t newport)
|
||||||
_hurd_port_locked_set (port, newport);
|
_hurd_port_locked_set (port, newport);
|
||||||
HURD_CRITICAL_END;
|
HURD_CRITICAL_END;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -43,9 +43,9 @@
|
||||||
#include <hurd/threadvar.h> /* We cache sigstate in a threadvar. */
|
#include <hurd/threadvar.h> /* We cache sigstate in a threadvar. */
|
||||||
struct hurd_signal_preemptor; /* <hurd/sigpreempt.h> */
|
struct hurd_signal_preemptor; /* <hurd/sigpreempt.h> */
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc) || IS_IN (libpthread)
|
# if IS_IN (libc) || IS_IN (libpthread)
|
||||||
# include <sigsetops.h>
|
# include <sigsetops.h>
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -135,7 +135,7 @@ extern struct hurd_sigstate *_hurd_self_sigstate (void)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_SIGNAL_H_EXTERN_INLINE struct hurd_sigstate *
|
_HURD_SIGNAL_H_EXTERN_INLINE struct hurd_sigstate *
|
||||||
_hurd_self_sigstate (void)
|
_hurd_self_sigstate (void)
|
||||||
{
|
{
|
||||||
|
@ -145,7 +145,7 @@ _hurd_self_sigstate (void)
|
||||||
*location = _hurd_thread_sigstate (__mach_thread_self ());
|
*location = _hurd_thread_sigstate (__mach_thread_self ());
|
||||||
return *location;
|
return *location;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Thread listening on our message port; also called the "signal thread". */
|
/* Thread listening on our message port; also called the "signal thread". */
|
||||||
|
@ -176,7 +176,7 @@ extern int _hurd_core_limit;
|
||||||
extern void *_hurd_critical_section_lock (void);
|
extern void *_hurd_critical_section_lock (void);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_SIGNAL_H_EXTERN_INLINE void *
|
_HURD_SIGNAL_H_EXTERN_INLINE void *
|
||||||
_hurd_critical_section_lock (void)
|
_hurd_critical_section_lock (void)
|
||||||
{
|
{
|
||||||
|
@ -201,13 +201,13 @@ _hurd_critical_section_lock (void)
|
||||||
_hurd_critical_section_unlock to unlock it. */
|
_hurd_critical_section_unlock to unlock it. */
|
||||||
return ss;
|
return ss;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
extern void _hurd_critical_section_unlock (void *our_lock);
|
extern void _hurd_critical_section_unlock (void *our_lock);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_SIGNAL_H_EXTERN_INLINE void
|
_HURD_SIGNAL_H_EXTERN_INLINE void
|
||||||
_hurd_critical_section_unlock (void *our_lock)
|
_hurd_critical_section_unlock (void *our_lock)
|
||||||
{
|
{
|
||||||
|
@ -230,7 +230,7 @@ _hurd_critical_section_unlock (void *our_lock)
|
||||||
__msg_sig_post (_hurd_msgport, 0, 0, __mach_task_self ());
|
__msg_sig_post (_hurd_msgport, 0, 0, __mach_task_self ());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Convenient macros for simple uses of critical sections.
|
/* Convenient macros for simple uses of critical sections.
|
||||||
|
|
|
@ -83,7 +83,7 @@ extern unsigned long int *__hurd_threadvar_location_from_sp
|
||||||
(enum __hurd_threadvar_index __index, void *__sp);
|
(enum __hurd_threadvar_index __index, void *__sp);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_THREADVAR_H_EXTERN_INLINE unsigned long int *
|
_HURD_THREADVAR_H_EXTERN_INLINE unsigned long int *
|
||||||
__hurd_threadvar_location_from_sp (enum __hurd_threadvar_index __index,
|
__hurd_threadvar_location_from_sp (enum __hurd_threadvar_index __index,
|
||||||
void *__sp)
|
void *__sp)
|
||||||
|
@ -95,7 +95,7 @@ __hurd_threadvar_location_from_sp (enum __hurd_threadvar_index __index,
|
||||||
: (unsigned long int *) ((__stack & __hurd_threadvar_stack_mask) +
|
: (unsigned long int *) ((__stack & __hurd_threadvar_stack_mask) +
|
||||||
__hurd_threadvar_stack_offset))[__index];
|
__hurd_threadvar_stack_offset))[__index];
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <machine-sp.h> /* Define __thread_stack_pointer. */
|
#include <machine-sp.h> /* Define __thread_stack_pointer. */
|
||||||
|
@ -111,14 +111,14 @@ __hurd_threadvar_location (enum __hurd_threadvar_index __index) __THROW
|
||||||
__attribute__ ((__const__));
|
__attribute__ ((__const__));
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_THREADVAR_H_EXTERN_INLINE unsigned long int *
|
_HURD_THREADVAR_H_EXTERN_INLINE unsigned long int *
|
||||||
__hurd_threadvar_location (enum __hurd_threadvar_index __index)
|
__hurd_threadvar_location (enum __hurd_threadvar_index __index)
|
||||||
{
|
{
|
||||||
return __hurd_threadvar_location_from_sp (__index,
|
return __hurd_threadvar_location_from_sp (__index,
|
||||||
__thread_stack_pointer ());
|
__thread_stack_pointer ());
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -81,7 +81,7 @@ _hurd_userlink_link (struct hurd_userlink **chainp,
|
||||||
struct hurd_userlink *link);
|
struct hurd_userlink *link);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_USERLINK_H_EXTERN_INLINE void
|
_HURD_USERLINK_H_EXTERN_INLINE void
|
||||||
_hurd_userlink_link (struct hurd_userlink **chainp,
|
_hurd_userlink_link (struct hurd_userlink **chainp,
|
||||||
struct hurd_userlink *link)
|
struct hurd_userlink *link)
|
||||||
|
@ -102,7 +102,7 @@ _hurd_userlink_link (struct hurd_userlink **chainp,
|
||||||
link->thread.prevp = thread_chainp;
|
link->thread.prevp = thread_chainp;
|
||||||
*thread_chainp = link;
|
*thread_chainp = link;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -112,7 +112,7 @@ _hurd_userlink_link (struct hurd_userlink **chainp,
|
||||||
extern int _hurd_userlink_unlink (struct hurd_userlink *link);
|
extern int _hurd_userlink_unlink (struct hurd_userlink *link);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_USERLINK_H_EXTERN_INLINE int
|
_HURD_USERLINK_H_EXTERN_INLINE int
|
||||||
_hurd_userlink_unlink (struct hurd_userlink *link)
|
_hurd_userlink_unlink (struct hurd_userlink *link)
|
||||||
{
|
{
|
||||||
|
@ -135,7 +135,7 @@ _hurd_userlink_unlink (struct hurd_userlink *link)
|
||||||
|
|
||||||
return dealloc;
|
return dealloc;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -148,7 +148,7 @@ _hurd_userlink_unlink (struct hurd_userlink *link)
|
||||||
extern int _hurd_userlink_clear (struct hurd_userlink **chainp);
|
extern int _hurd_userlink_clear (struct hurd_userlink **chainp);
|
||||||
|
|
||||||
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
#if defined __USE_EXTERN_INLINES && defined _LIBC
|
||||||
# if IS_IN (libc)
|
# if IS_IN (libc)
|
||||||
_HURD_USERLINK_H_EXTERN_INLINE int
|
_HURD_USERLINK_H_EXTERN_INLINE int
|
||||||
_hurd_userlink_clear (struct hurd_userlink **chainp)
|
_hurd_userlink_clear (struct hurd_userlink **chainp)
|
||||||
{
|
{
|
||||||
|
@ -161,7 +161,7 @@ _hurd_userlink_clear (struct hurd_userlink **chainp)
|
||||||
*chainp = NULL;
|
*chainp = NULL;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif /* hurd/userlink.h */
|
#endif /* hurd/userlink.h */
|
||||||
|
|
Loading…
Reference in New Issue