2N/A/*
2N/A * CDDL HEADER START
2N/A *
2N/A * The contents of this file are subject to the terms of the
2N/A * Common Development and Distribution License (the "License").
2N/A * You may not use this file except in compliance with the License.
2N/A *
2N/A * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
2N/A * or http://www.opensolaris.org/os/licensing.
2N/A * See the License for the specific language governing permissions
2N/A * and limitations under the License.
2N/A *
2N/A * When distributing Covered Code, include this CDDL HEADER in each
2N/A * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
2N/A * If applicable, add the following below this CDDL HEADER, with the
2N/A * fields enclosed by brackets "[]" replaced with your own identifying
2N/A * information: Portions Copyright [yyyy] [name of copyright owner]
2N/A *
2N/A * CDDL HEADER END
2N/A */
2N/A/*
2N/A * Copyright 2008 Sun Microsystems, Inc. All rights reserved.
2N/A * Use is subject to license terms.
2N/A */
2N/A
2N/A#include <meta.h>
2N/A
2N/Aextern void mdmn_do_cmd(HANDLER_PARMS);
2N/Aextern void mdmn_do_clu(HANDLER_PARMS);
2N/Aextern void mdmn_do_req_owner(HANDLER_PARMS);
2N/Aextern void mdmn_do_susp_write(HANDLER_PARMS);
2N/Aextern void mdmn_do_state_upd_reswr(HANDLER_PARMS);
2N/Aextern void mdmn_do_allocate_hotspare(HANDLER_PARMS);
2N/Aextern void mdmn_do_poke_hotspares(HANDLER_PARMS);
2N/Aextern void mdmn_do_resync(HANDLER_PARMS);
2N/Aextern void mdmn_do_setsync(HANDLER_PARMS);
2N/Aextern void mdmn_do_choose_owner(HANDLER_PARMS);
2N/Aextern void mdmn_do_change_owner(HANDLER_PARMS);
2N/Aextern void mdmn_do_set_cap(HANDLER_PARMS);
2N/Aextern void mdmn_do_dummy(HANDLER_PARMS);
2N/Aextern void mdmn_do_mddb_parse(HANDLER_PARMS);
2N/Aextern void mdmn_do_mddb_block(HANDLER_PARMS);
2N/Aextern void mdmn_do_sm_mddb_attach(HANDLER_PARMS);
2N/Aextern void mdmn_do_sm_mddb_detach(HANDLER_PARMS);
2N/Aextern void mdmn_do_meta_db_newside(HANDLER_PARMS);
2N/Aextern void mdmn_do_meta_db_delside(HANDLER_PARMS);
2N/Aextern void mdmn_do_meta_md_addside(HANDLER_PARMS);
2N/Aextern void mdmn_do_meta_md_delside(HANDLER_PARMS);
2N/Aextern void mdmn_do_mddb_optrecerr(HANDLER_PARMS);
2N/Aextern void mdmn_do_iocset(HANDLER_PARMS);
2N/Aextern void mdmn_do_sp_setstat(HANDLER_PARMS);
2N/Aextern void mdmn_do_addkeyname(HANDLER_PARMS);
2N/Aextern void mdmn_do_delkeyname(HANDLER_PARMS);
2N/Aextern void mdmn_do_get_tstate(HANDLER_PARMS);
2N/Aextern void mdmn_do_get_mirstate(HANDLER_PARMS);
2N/Aextern void mdmn_do_addmdname(HANDLER_PARMS);
2N/Aextern void mdmn_do_mark_dirty(HANDLER_PARMS);
2N/Aextern void mdmn_do_mark_clean(HANDLER_PARMS);
2N/A
2N/Aextern int mdmn_smgen_test6(SMGEN_PARMS);
2N/Aextern int mdmn_smgen_state_upd(SMGEN_PARMS);
2N/Aextern int mdmn_smgen_mddb_attach(SMGEN_PARMS);
2N/Aextern int mdmn_smgen_mddb_detach(SMGEN_PARMS);
2N/A
2N/Amd_mn_msg_tbl_entry_t msg_table[MD_MN_NMESSAGES] = {
2N/A
2N/A/*
2N/A * In order to have fast direct access to the table, we use the message type as
2N/A * an index into it.
2N/A * Thus the order of the elements in this table MUST match the order of the
2N/A * message types specified in mdmn_commd.x!
2N/A * See the definition of md_mn_msg_t.
2N/A *
2N/A * Be careful and do not disturb the order of the messages!
2N/A */
2N/A {
2N/A /* MD_MN_MSG_NULL */
2N/A MD_MSG_CLASS0, /* message class */
2N/A NULL, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 0, 0, /* class busy retry / time delta */
2N/A 0, 0 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_TEST1 */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_dummy, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 200, 4, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_TEST2 */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_dummy, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 200, 4, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_TEST3 */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_dummy, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 200, 4, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_TEST4 */
2N/A MD_MSG_CLASS4, /* message class */
2N/A mdmn_do_dummy, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 200, 4, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_TEST5 */
2N/A MD_MSG_CLASS5, /* message class */
2N/A mdmn_do_dummy, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 4, /* timeout in seconds */
2N/A 200, 4, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_TEST6 */
2N/A MD_MSG_CLASS1, /* message class */
2N/A NULL, /* message handler */
2N/A mdmn_smgen_test6, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 200, 4, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_CMD
2N/A * Send a command string to all nodes
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_cmd, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 40, 20, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_CMD_RETRY
2N/A * Send a command string to all nodes and retry on busy
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_cmd, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 100000, 20, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_CLU_CHECK */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_clu, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 5, /* timeout in seconds */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 0, 0 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_CLU_LOCK */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_clu, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 0, 0 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_CLU_UNLOCK */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_clu, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 0, 0 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_REQUIRE_OWNER */
2N/A MD_MSG_CLASS5, /* message class */
2N/A mdmn_do_req_owner, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 12, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_CHOOSE_OWNER
2N/A * Using the current resync count for the set, choose a resync
2N/A * owner and send a CHANGE_OWNER message to request that node
2N/A * to make itself the owner
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_choose_owner, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 12, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_CHANGE_OWNER
2N/A * Request a change of ownership to the specified node
2N/A */
2N/A MD_MSG_CLASS4, /* message class */
2N/A mdmn_do_change_owner, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 12, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_SUSPEND_WRITES
2N/A * Suspend all writes to the specified mirror
2N/A */
2N/A MD_MSG_CLASS6, /* message class */
2N/A mdmn_do_susp_write, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A 200, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_STATE_UPDATE_RESWR
2N/A * Update the state of a mirror component
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_state_upd_reswr, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_STATE_UPDATE
2N/A * Suspend writes to a mirror and then update the state of a
2N/A * mirror component
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A NULL, /* message handler */
2N/A mdmn_smgen_state_upd, /* submessage generator */
2N/A 16, /* SUSPEND_WRITES + STATE_UPDATE_RESWR */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_ALLOCATE_HOTSPARE
2N/A * Allocate a hotspare for a mirror component
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_allocate_hotspare, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_RESYNC_STARTING
2N/A * Start a resync thread for the specified mirror
2N/A */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_resync, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_RESYNC_NEXT
2N/A * Send the next region to be resyned to all nodes. For ABR
2N/A * mirrors, the nodes must suspend all writes to this region until
2N/A * the next message of this type or a RESYNC_FINISH
2N/A */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_resync, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_RESYNC_FINISH
2N/A * All resyncs for a mirror are complete, terminate resync thread
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_resync, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_RESYNC_PHASE_DONE
2N/A * A resync phase, optimized, submirror or component is complete
2N/A */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_resync, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_SET_CAP
2N/A * Set the specified metadevice capability on all nodes
2N/A * This is used to propagate the ABR capability
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_set_cap, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A 100000, 10, /* class busy retry/ time delta */
2N/A 200, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /* MD_MN_MSG_VERBOSITY */
2N/A MD_MSG_CLASS0, /* special message class */
2N/A mdmn_do_dummy, /* dummy handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 0, 0, /* No retries for class busy */
2N/A 0, 0 /* No retries for comm fail */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_MDDB_PARSE
2N/A * Message cannot fail unless node failure causes node panic
2N/A */
2N/A MD_MSG_CLASS7, /* message class */
2N/A mdmn_do_mddb_parse, /* reparse mddb */
2N/A NULL, /* submessage generator */
2N/A 10, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_MDDB_BLOCK
2N/A * Message cannot fail unless node failure causes node panic
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_mddb_block, /* block/unblock reparse */
2N/A NULL, /* submessage generator */
2N/A 5, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_META_DB_ATTACH
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A NULL, /* message handler */
2N/A mdmn_smgen_mddb_attach, /* submessage generator */
2N/A 30, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_SM_MDDB_ATTACH
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_sm_mddb_attach, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 20, /* timeout in seconds */
2N/A /* creates mddbs */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_META_DB_DETACH
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A NULL, /* detach mddb */
2N/A mdmn_smgen_mddb_detach, /* submessage generator */
2N/A 10, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A {
2N/A
2N/A /*
2N/A * MD_MN_MSG_SM_MDDB_DETACH
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_sm_mddb_detach, /* detach mddb */
2N/A NULL, /* submessage generator */
2N/A 5, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_META_DB_NEWSIDE
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_meta_db_newside, /* add new mddb side info */
2N/A NULL, /* submessage generator */
2N/A 10, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_META_DB_DELSIDE
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_meta_db_delside, /* delete mddb side info */
2N/A NULL, /* submessage generator */
2N/A 10, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_META_MD_ADDSIDE
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_meta_md_addside, /* add new md side info */
2N/A NULL, /* submessage generator */
2N/A 10, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_META_MD_DELSIDE
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_meta_md_delside, /* delete md side info */
2N/A NULL, /* submessage generator */
2N/A 10, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_MDDB_OPTRECERR
2N/A * Message cannot fail unless node failure causes node panic
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_mddb_optrecerr, /* fix opt rec mddb */
2N/A NULL, /* submessage generator */
2N/A 3, /* timeout in seconds */
2N/A UINT_MAX, 2, /* class busy retry / time delta */
2N/A 10, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_ABORT
2N/A */
2N/A MD_MSG_CLASS0, /* special message class */
2N/A mdmn_do_dummy, /* dummy handler */
2N/A NULL, /* submessage generator */
2N/A 1, /* timeout in seconds */
2N/A 0, 0, /* No retries for class busy */
2N/A 0, 0 /* No retries for comm fail */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_STATE_UPDATE_RESWR2
2N/A * Update the state of a mirror component, called if during the updates
2N/A * of the watermarks for a softpartition, an IO error on a submirror
2N/A * occurs. Need to have a class different from CLASS1, otherwise we
2N/A * deadlock with the command that is currently being processed
2N/A * (metainit/metaclear/metattach/metarecover)
2N/A *
2N/A * And we may actually use a class different than CLASS1 because this
2N/A * can only happen when a metainit or similar is called, and in that
2N/A * case all potential metadb or metaset commands are blocked anyway.
2N/A * Besides the different class it does exactly what
2N/A * MD_MN_MSG_STATE_UPDATE_RESWR would do
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_state_upd_reswr, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_STATE_UPDATE2
2N/A * Like MD_MN_MSG_STATE_UPDATE only using a different class.
2N/A * See comment for MD_MN_MSG_STATE_UPDATE_RESWR2
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A NULL, /* message handler */
2N/A mdmn_smgen_state_upd, /* submessage generator */
2N/A 16, /* SUSPEND_WRITES + STATE_UPDATE_RESWR */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_ALLOCATE_HOTSPARE2
2N/A * Like MD_MN_MSG_ALLOCATE_HOTSPARE only using a different class.
2N/A * See comment for MD_MN_MSG_STATE_UPDATE_RESWR2
2N/A */
2N/A MD_MSG_CLASS3, /* message class */
2N/A mdmn_do_allocate_hotspare, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_IOCSET
2N/A * Send IOCSET ioctl to create a soft part
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_iocset, /* create softpart */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_SP_SETSTAT
2N/A * Update the status of a softpart
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_sp_setstat, /* create softpart */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_ADDKEYNAME
2N/A * Add a key to the namespace
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_addkeyname, /* add key */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_SP_DELKEYNAME
2N/A * Remove a key from the namespace
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_delkeyname, /* delete key */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_GET_TSTATE
2N/A * Get ui_tstate for a metadevice from the master. Used to get ABR
2N/A * state from the master node.
2N/A */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_get_tstate, /* get tstate */
2N/A NULL, /* submessage generator */
2N/A 5, /* times out in 5 secs */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_GET_MIRROR_STATE
2N/A * Get submirror state for specified submirror from master node.
2N/A * Used to synchronise initial resync state across a cluster.
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_get_mirstate, /* get smstate */
2N/A NULL, /* submessage generator */
2N/A 5, /* times out in 5 secs */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_SP_SETSTAT2
2N/A * Update the status of a softpart. Used for propagating an error from
2N/A * the soft-part sp_error() routine
2N/A */
2N/A MD_MSG_CLASS4, /* message class */
2N/A mdmn_do_sp_setstat, /* update softpart state */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_SETSYNC
2N/A * Start a resync thread for the specified mirror
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_setsync, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 90, /* timeout in seconds */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_POKE_HOTSPARES
2N/A * Call poke_hotspares()
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_poke_hotspares, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_ADDMDNAME
2N/A * Add metadevice name into replica
2N/A */
2N/A MD_MSG_CLASS1, /* message class */
2N/A mdmn_do_addmdname, /* add metadevice name */
2N/A NULL, /* submessage generator */
2N/A 90, /* times out in 90 secs */
2N/A 10000, 2, /* class busy retry / time delta */
2N/A 10, 1000 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_RR_DIRTY
2N/A * Mark given range of un_dirty_bm as dirty
2N/A */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_mark_dirty, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A
2N/A {
2N/A /*
2N/A * MD_MN_MSG_RR_CLEAN
2N/A * Mark given range of un_dirty_bm as clean
2N/A */
2N/A MD_MSG_CLASS2, /* message class */
2N/A mdmn_do_mark_clean, /* message handler */
2N/A NULL, /* submessage generator */
2N/A 8, /* timeout in seconds */
2N/A UINT_MAX, 10, /* class busy retry / time delta */
2N/A UINT_MAX, 100 /* comm fail retry / time delta */
2N/A },
2N/A};