smartmontools SVN Rev 3317
Utility to control and monitor storage systems with "S.M.A.R.T."
scsiprint.h
Go to the documentation of this file.
00001 /*
00002  * scsiprint.h
00003  *
00004  * Home page of code is: http://smartmontools.sourceforge.net
00005  *
00006  * Copyright (C) 2002-9 Bruce Allen <smartmontools-support@lists.sourceforge.net>
00007  * Copyright (C) 2000 Michael Cornwell <cornwell@acm.org>
00008  *
00009  * Additional SCSI work:
00010  * Copyright (C) 2003-13 Douglas Gilbert <dgilbert@interlog.com>
00011  *
00012  * This program is free software; you can redistribute it and/or modify
00013  * it under the terms of the GNU General Public License as published by
00014  * the Free Software Foundation; either version 2, or (at your option)
00015  * any later version.
00016  *
00017  * You should have received a copy of the GNU General Public License
00018  * (for example COPYING); if not, write to the Free Software Foundation,
00019  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
00020  *
00021  * This code was originally developed as a Senior Thesis by Michael Cornwell
00022  * at the Concurrent Systems Laboratory (now part of the Storage Systems
00023  * Research Center), Jack Baskin School of Engineering, University of
00024  * California, Santa Cruz. http://ssrc.soe.ucsc.edu/
00025  *
00026  */
00027 
00028 
00029 #ifndef SCSI_PRINT_H_
00030 #define SCSI_PRINT_H_
00031 
00032 #define SCSIPRINT_H_CVSID "$Id: scsiprint.h 3776 2013-02-17 04:25:42Z dpgilbert $\n"
00033 
00034 // Options for scsiPrintMain
00035 struct scsi_print_options
00036 {
00037   bool drive_info;
00038   bool smart_check_status;
00039   bool smart_vendor_attrib;
00040   bool smart_error_log;
00041   bool smart_selftest_log;
00042   bool smart_background_log;
00043   bool smart_ss_media_log;
00044 
00045   bool smart_disable, smart_enable;
00046   bool smart_auto_save_disable, smart_auto_save_enable;
00047 
00048   bool smart_default_selftest;
00049   bool smart_short_selftest, smart_short_cap_selftest;
00050   bool smart_extend_selftest, smart_extend_cap_selftest;
00051   bool smart_selftest_abort;
00052   bool smart_selftest_force; // Ignore already running test
00053 
00054   bool sasphy, sasphy_reset;
00055   
00056   bool get_wce, get_rcd;
00057   short int set_wce, set_rcd;  // disable(-1), enable(1) cache
00058 
00059   scsi_print_options()
00060     : drive_info(false),
00061       smart_check_status(false),
00062       smart_vendor_attrib(false),
00063       smart_error_log(false),
00064       smart_selftest_log(false),
00065       smart_background_log(false),
00066       smart_ss_media_log(false),
00067       smart_disable(false), smart_enable(false),
00068       smart_auto_save_disable(false), smart_auto_save_enable(false),
00069       smart_default_selftest(false),
00070       smart_short_selftest(false), smart_short_cap_selftest(false),
00071       smart_extend_selftest(false), smart_extend_cap_selftest(false),
00072       smart_selftest_abort(false),
00073       smart_selftest_force(false),
00074       sasphy(false), sasphy_reset(false),
00075       get_wce(false), get_rcd(false),
00076       set_wce(0), set_rcd(0)
00077     { }
00078 };
00079 
00080 int scsiPrintMain(scsi_device * device, const scsi_print_options & options);
00081 
00082 #endif