/*
* 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
*/
/*
* Copyright 2008 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#include <stddef.h>
#include <sys/mdb_modapi.h>
{ NULL, 0, 0 }
};
{ NULL, 0, 0 }
};
/*
* Display a ii_fd_t
* Requires an address.
*/
/*ARGSUSED*/
static int
{
if (!(flags & DCMD_ADDRSPEC))
return (DCMD_USAGE);
return (DCMD_ERR);
}
mdb_inc_indent(4);
mdb_printf("ii_info: 0x%p ii_bmp: %d ii_shd: %d ii_ovr: %d ii_optr: "
mdb_dec_indent(4);
return (DCMD_OK);
}
/*
* displays a ii_info_dev structure.
*/
/*ARGSUSED*/
static int
{
if (!(flags & DCMD_ADDRSPEC))
return (DCMD_USAGE);
return (DCMD_ERR);
}
mdb_inc_indent(4);
mdb_printf("bi_fd: 0x%p bi_iodev: 0x%p bi_tok: 0x%p\n",
mdb_printf("bi_ref: %d bi_rsrv: %d bi_orsrv: %d\n",
/*
* use nsc_fd to dump the fd details.... if present.
*/
mdb_printf("nsc_fd structure:\n");
mdb_inc_indent(4);
mdb_dec_indent(4);
}
mdb_dec_indent(4);
return (DCMD_OK);
}
/*
* Displays an _ii_overflow structure
*/
/*ARGSUSED*/
static int
{
nextaddr = 0;
if (!(flags & DCMD_ADDRSPEC))
return (DCMD_USAGE);
!= sizeof (ii_overflow)) {
return (DCMD_ERR);
}
mdb_inc_indent(4);
mdb_printf("_ii_doverflow_t\n");
mdb_inc_indent(4);
mdb_dec_indent(4);
mdb_printf("Overflow volume:\n");
if (ii_overflow.ii_dev)
mdb_dec_indent(4);
return (DCMD_OK);
}
/*ARGSUSED*/
static int
{
nextaddr = 0;
if (!(flags & DCMD_ADDRSPEC))
return (DCMD_USAGE);
return (DCMD_ERR);
}
"bi_next: 0x%p\n"
"bi_head: 0x%p\t"
"bi_sibling: 0x%p\n"
"bi_master: 0x%p\t"
"bi_nextmst: 0x%p\n",
/*
* Print out all the fds by using ii_info_dev
*/
mdb_printf("Cache master:\n");
mdb_printf("Raw master:\n");
if (ii_info.bi_mstrdev)
mdb_printf("Cache shadow:\n");
mdb_printf("Raw shadow:\n");
mdb_printf("Bitmap:\n");
!= sizeof (string)))
string[0] = 0;
!= sizeof (string)))
string[0] = 0;
mdb_printf("bi_flags: 0x%x <%b>\n",
mdb_printf("bi_state: 0x%x <%b>\n",
mdb_printf("bi_overflow\n");
if (ii_info.bi_overflow)
mdb_printf("bi_iifd:\n");
mdb_printf("bi_linkrw:\n");
/* ii_kstat_info_t bi_kstat_io; */
return (DCMD_OK);
}
/*
* This should be a walker surely.
*/
/*ARGSUSED*/
static int
{
/*
* we use the global address.
*/
if (flags & DCMD_ADDRSPEC)
return (DCMD_USAGE);
sizeof (myaddr)) {
return (DCMD_ERR);
}
while (myaddr) {
}
return (DCMD_OK);
}
/*
* Display general ii module information.
*/
mdb_dec_indent(4); \
return (DCMD_ERR); \
} \
/* ARGSUSED */
static int
{
if (argc != 0)
return (DCMD_USAGE);
mdb_warn("unable to read 'dsw_major_rev'");
return (DCMD_ERR);
}
mdb_warn("unable to read 'dsw_minor_rev'");
return (DCMD_ERR);
}
mdb_warn("unable to read 'dsw_micro_rev'");
return (DCMD_ERR);
}
mdb_warn("unable to read 'dsw_baseline_rev'");
return (DCMD_ERR);
}
mdb_printf("Point-in-Time Copy module version: kernel %d.%d.%d.%d; "
mdb_inc_indent(4);
mdb_dec_indent(4);
return (DCMD_OK);
}
/*
* MDB module linkage information:
*/
{ NULL }
};
{ NULL }
};
};
const mdb_modinfo_t *
_mdb_init(void)
{
return (&modinfo);
}