diff --git a/mediachanger/castorrmc/h/rbtsubr_constants.h b/mediachanger/castorrmc/h/rbtsubr_constants.h new file mode 100644 index 0000000000000000000000000000000000000000..876b94d7f3ebca2a983a5559a44b31c1bcbf12e9 --- /dev/null +++ b/mediachanger/castorrmc/h/rbtsubr_constants.h @@ -0,0 +1,42 @@ +/****************************************************************************** + * rbtsubr_constants.h + * + * This file is part of the Castor project. + * See http://castor.web.cern.ch/castor + * + * Copyright (C) 2003 CERN + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation; either version 2 + * of the License, or (at your option) any later version. + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * + * + * + * @author Castor Dev team, castor-dev@cern.ch + *****************************************************************************/ + +#ifndef _RBTSUBR_CONSTANTS_H +#define _RBTSUBR_CONSTANTS_H 1 + + /* rbtsubr return codes */ + +#define RBT_OK 0 /* Ok or error should be ignored */ +#define RBT_NORETRY 1 /* Unrecoverable error (just log it) */ +#define RBT_SLOW_RETRY 2 /* Should release drive & retry in 600 seconds */ +#define RBT_FAST_RETRY 3 /* Should retry in 60 seconds */ +#define RBT_DMNT_FORCE 4 /* Should do first a demount force */ +#define RBT_CONF_DRV_DN 5 /* Should configure the drive down */ +#define RBT_OMSG_NORTRY 6 /* Should send a msg to operator and exit */ +#define RBT_OMSG_SLOW_R 7 /* Ops msg (nowait) + release drive + slow retry */ +#define RBT_OMSGR 8 /* Should send a msg to operator and wait */ +#define RBT_UNLD_DMNT 9 /* Should unload the tape and retry demount */ + +#endif diff --git a/mediachanger/castorrmc/rmc/rmc_smcsubr.c b/mediachanger/castorrmc/rmc/rmc_smcsubr.c index 5c952720bd6028721979f41200162188240b0008..72c3da660d765d76643a02c07c3c232db9e344bf 100644 --- a/mediachanger/castorrmc/rmc/rmc_smcsubr.c +++ b/mediachanger/castorrmc/rmc/rmc_smcsubr.c @@ -13,6 +13,7 @@ #include <sys/types.h> #include "h/Ctape.h" +#include "h/rbtsubr_constants.h" #include "h/rmc_constants.h" #include "h/rmc_send_scsi_cmd.h" #include "h/rmc_sendrep.h" diff --git a/mediachanger/castorrmc/rmc/smc.c b/mediachanger/castorrmc/rmc/smc.c index 7d5b1cf4ba9edd1671678d7688165efd102c184d..d13f8f5d2894e63d9a2d097ca0bb35c2a1c74755 100644 --- a/mediachanger/castorrmc/rmc/smc.c +++ b/mediachanger/castorrmc/rmc/smc.c @@ -10,6 +10,7 @@ #include <string.h> #include <unistd.h> #include "h/Ctape.h" +#include "h/rbtsubr_constants.h" #include "h/rmc_api.h" #include "h/serrno.h" #include "h/smc_constants.h"