summaryrefslogtreecommitdiff
path: root/usr/src/cmd/mms/mm/common/mm.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/cmd/mms/mm/common/mm.c')
-rw-r--r--usr/src/cmd/mms/mm/common/mm.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/usr/src/cmd/mms/mm/common/mm.c b/usr/src/cmd/mms/mm/common/mm.c
index 724300741d..d268c7d9e9 100644
--- a/usr/src/cmd/mms/mm/common/mm.c
+++ b/usr/src/cmd/mms/mm/common/mm.c
@@ -1741,7 +1741,7 @@ mm_remove_commands(mm_data_t *mm_data, mm_db_t *db_main, mm_wka_t *mm_wka) {
/* and reset manager states */
cur_cmd->cmd_mount_info.
cmi_reset_states = 1;
- (void) mm_rm_mount(cur_cmd);
+ (void) mm_rm_mount(cur_cmd, db_main);
cur_cmd->cmd_mount_info.
cmi_need_clear = 1;
/* Could optimize this clear */
@@ -1760,7 +1760,7 @@ mm_remove_commands(mm_data_t *mm_data, mm_db_t *db_main, mm_wka_t *mm_wka) {
mms_trace(MMS_DEVP,
"client has an outstanding "
"unmount command");
- (void) mm_rm_unmount(cur_cmd);
+ (void) mm_rm_unmount(cur_cmd, db_main);
cur_cmd->cmd_mount_info.
cmi_need_clear = 1;
cur_cmd->cmd_mount_info.
@@ -3414,6 +3414,8 @@ mm_cmd_dispatch(mm_command_t *cmd)
*
* Parameters:
* - cmd : ptr to mm_command_t
+ * - db : ptr to valid db connection, mm_db_t
+ *
*
* Do additional steps to clean up when the command
* being removed is an unmount command
@@ -3427,8 +3429,7 @@ mm_cmd_dispatch(mm_command_t *cmd)
*
*/
int
-mm_rm_unmount(mm_command_t *cmd) {
- mm_db_t *db = &cmd->cmd_mm_data->mm_db_main;
+mm_rm_unmount(mm_command_t *cmd, mm_db_t *db) {
PGresult *drive_results;
mm_command_t *cur_cmd;
@@ -3496,6 +3497,7 @@ mm_rm_unmount(mm_command_t *cmd) {
*
* Parameters:
* - cmd : ptr to mm_command_t
+ * - db : ptr to valid db connection, mm_db_t
*
* Do additional steps to clean up when the command
* being removed is a mount command
@@ -3509,13 +3511,12 @@ mm_rm_unmount(mm_command_t *cmd) {
*
*/
int
-mm_rm_mount(mm_command_t *cmd)
+mm_rm_mount(mm_command_t *cmd, mm_db_t *db)
{
/* This function is called when a client has disconnected */
/* with an outstanding mount command */
/* need to deallocate the resources and reset device manager states */
- mm_db_t *db = &cmd->cmd_mm_data->mm_db_main;
PGresult *drive_results;
if (cmd->cmd_root == NULL) {