]> git.proxmox.com Git - mirror_smartmontools-debian.git/blame - ataprint.h
drop 05_wait-for-daemon-startup.diff - applied upstream
[mirror_smartmontools-debian.git] / ataprint.h
CommitLineData
832b75ed
GG
1/*
2 * ataprint.h
3 *
4 * Home page of code is: http://smartmontools.sourceforge.net
5 *
6 * Copyright (C) 2002-6 Bruce Allen <smartmontools-support@lists.sourceforge.net>
7 * Copyright (C) 1999-2000 Michael Cornwell <cornwell@acm.org>
8 *
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License as published by
11 * the Free Software Foundation; either version 2, or (at your option)
12 * any later version.
13 *
14 * You should have received a copy of the GNU General Public License
15 * (for example COPYING); if not, write to the Free
16 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
17 *
18 * This code was originally developed as a Senior Thesis by Michael Cornwell
19 * at the Concurrent Systems Laboratory (now part of the Storage Systems
20 * Research Center), Jack Baskin School of Engineering, University of
21 * California, Santa Cruz. http://ssrc.soe.ucsc.edu/
22 *
23 */
24
25#ifndef ATAPRINT_H_
26#define ATAPRINT_H_
27
a37e7145 28#define ATAPRINT_H_CVSID "$Id: ataprint.h,v 1.30 2007/04/05 18:23:29 shattered Exp $\n"
832b75ed
GG
29
30#include <stdio.h>
31#include <stdlib.h>
32
33/* Prints ATA Drive Information and S.M.A.R.T. Capability */
4d59bff9 34int ataPrintDriveInfo(struct ata_identify_device *);
832b75ed
GG
35
36void ataPrintGeneralSmartValues(struct ata_smart_values *, struct ata_identify_device *);
37
38void ataPrintSmartThresholds(struct ata_smart_thresholds_pvt *);
39
40// returns number of errors in Errorlog
41int ataPrintSmartErrorlog(struct ata_smart_errorlog *);
42
43int ataPrintLogDirectory(struct ata_smart_log_directory *);
44
45void PrintSmartAttributes(struct ata_smart_values *);
46
47void PrintSmartAttribWithThres(struct ata_smart_values *,
48 struct ata_smart_thresholds_pvt *,
49 int onlyfailed);
50
51// returns number of entries that had logged errors
52int ataPrintSmartSelfTestlog(struct ata_smart_selftestlog *, int allentries);
53
54void ataPseudoCheckSmart(struct ata_smart_values *, struct ata_smart_thresholds_pvt *);
55
56// Convenience function for formatting strings from ata_identify_device.
a37e7145 57void format_ata_string(char *out, const char *in, int n);
832b75ed
GG
58
59int ataPrintMain(int fd);
60
61#endif