/*
* 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 2009 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
#include <strings.h>
#include <alloca.h>
#include <stdio.h>
#include <fmd_protocol.h>
#include <fmd_module.h>
#include <fmd_conf.h>
#include <fmd_subr.h>
#include <fmd_error.h>
#include <fmd_time.h>
#include <fmd.h>
/*
* Create an FMRI authority element for the environment in which this instance
* of fmd is deployed. This function is called once and the result is cached.
*/
nvlist_t *
fmd_protocol_authority(void)
{
const char *str;
int err = 0;
fmd_panic("failed to xalloc authority nvlist");
if (err != 0)
return (nvl);
}
/*
* Create an FMRI for the specified module. We use the cached authority
* nvlist saved in fmd.d_auth to fill in the authority member.
*/
nvlist_t *
{
int err = 0;
fmd_panic("failed to xalloc diag-engine fmri nvlist");
}
if (err != 0)
return (nvl);
}
nvlist_t *
{
int err = 0;
fmd_panic("failed to xalloc fault nvlist");
if (err != 0)
return (nvl);
}
nvlist_t *
{
int err = 0;
char *severity;
fmd_panic("failed to xalloc suspect list nvlist");
if (injected)
B_TRUE);
if (!domsg) {
}
if (argc != 0) {
}
/*
* Attempt to lookup the severity associated with this diagnosis from
* the portable object file using the diag code. Failure to init
* libfmd_msg or add to the nvlist will be treated as fatal. However,
* we won't treat a fmd_msg_getitem_id failure as fatal since during
* haven't yet been updated with newly added diagnoses.
*/
fmd_panic("failed to initialize libfmd_msg\n");
FMD_MSG_ITEM_SEVERITY)) != NULL) {
}
if (err != 0)
return (nvl);
}
nvlist_t *
{
int err = 0;
fmd_panic("failed to xalloc resource nvlist");
if (injected)
B_TRUE);
if (err != 0)
return (nvl);
}
nvlist_t *
{
int err = 0;
char c, *msg;
return (NULL);
if (err != 0) {
return (NULL);
}
return (nvl);
}
nvlist_t *
{
int err = 0;
fmd_panic("failed to xalloc module error nvlist");
else
if (oserr != 0) {
}
if (err != 0)
return (nvl);
}
nvlist_t *
{
int err = 0;
fmd_panic("failed to xalloc rsrc xprt nvlist");
if (err != 0)
return (nvl);
}
nvlist_t *
{
if (err != 0)
return (nvl);
}
nvlist_t *
const char *uuid)
{
if (err != 0)
return (nvl);
}
nvlist_t *
{
if (err != 0)
return (nvl);
}
nvlist_t *
{
nelem);
if (has_asrup)
if (err != 0)
return (nvl);
}