dtrace: ensure we pass a limit to dtrace_stacktrace for stackdepth
When determining the (kernel) stackdepth, we pass scratch memory to the
dtrace_stacktrace() function because we are not interested in the actual
program counter values. However, we were passing in 0 as limit rather
than the actual maximum number of PCs that could fit in the remaining
scratch memory space.
We now also add no-fault protection to dtrace_getstackdepth().
Orabug:
25559321
Signed-off-by: Kris Van Hees <kris.van.hees@oracle.com>