Add GET_STACK_USAGE() for arm64.
Its absence meant that GEOM direct dispatch was disabled (the service routines check the current thread's stack usage to determine whether to hand off the request to a dedicated thread), and this change is sufficient to enable direct dispatch by default. Reviewed by: allanjude MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D15527
This commit is contained in:
parent
64223daed4
commit
6514b4f061
@ -54,4 +54,18 @@ struct syscall_args {
|
||||
int narg;
|
||||
};
|
||||
|
||||
#ifdef _KERNEL
|
||||
|
||||
#include <machine/pcb.h>
|
||||
|
||||
#define GET_STACK_USAGE(total, used) do { \
|
||||
struct thread *td = curthread; \
|
||||
(total) = td->td_kstack_pages * PAGE_SIZE - sizeof(struct pcb); \
|
||||
(used) = (char *)td->td_kstack + \
|
||||
td->td_kstack_pages * PAGE_SIZE - \
|
||||
(char *)&td; \
|
||||
} while (0)
|
||||
|
||||
#endif
|
||||
|
||||
#endif /* !_MACHINE_PROC_H_ */
|
||||
|
Loading…
Reference in New Issue
Block a user