/*
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
* Common Development and Distribution License (the "License").
* You may not use this file except in compliance with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* See the License for the specific language governing permissions
* and limitations under the License.
*
* When distributing Covered Code, include this CDDL HEADER in each
* file and include the License file at usr/src/OPENSOLARIS.LICENSE.
* If applicable, add the following below this CDDL HEADER, with the
* fields enclosed by brackets "[]" replaced with your own identifying
* information: Portions Copyright [yyyy] [name of copyright owner]
*
* CDDL HEADER END
*/
/*
*/
#include <kvm.h>
#include <stdio.h>
#include <stdlib.h>
#include <stdarg.h>
#include <unistd.h>
#include <limits.h>
#include <fcntl.h>
#include <strings.h>
#include <sys/sysmacros.h>
struct _kvmd {
char *kvm_debug;
int kvm_openflag;
int kvm_corefd;
int kvm_kmemfd;
int kvm_memfd;
char *kvm_core;
};
static kvm_t *
{
}
return (NULL);
}
/*ARGSUSED*/
kvm_t *
{
}
} else {
"(bad magic number %x)", corefile,
if ((DUMP_VERSION > 9) &&
/*
* The v9 dumphdr does not include a UUID,
* so need make sure it contains zero here
*/
} else {
"libkvm version (%u) != "
"corefile version (%u)",
}
}
"cannot examine with %d-bit libkvm", corefile,
/*
* We try to mmap(2) the entire corefile for performance
* (so we can use bcopy(3C) rather than pread(2)). Failing
* that, we insist on at least mmap(2)ing the dump map.
*/
}
}
(void) kvm_setproc(kd);
return (kd);
}
int
{
return (0);
}
int
{
}
static offset_t
{
long first = 0;
break;
}
else
}
} else {
while (off != 0) {
hash) {
return (0);
}
break;
}
}
}
return (off);
}
static ssize_t
{
/*
*/
if (size == 0)
return (0);
int procfd;
return (-1);
return (rval);
}
while (resid != 0) {
break;
break;
}
}
{
}
{
}
{
}
{
}
{
}
{
}
{
}
{
}
{
}
{
}
{
} else {
long pfn_index =
}
}
return (-1ULL);
}
struct proc *
{
(void) kvm_setproc(kd);
return (NULL);
}
struct proc *
{
return (NULL);
}
int
{
return (0);
}
/*ARGSUSED*/
struct user *
{
return (&p->p_user);
}