mirror of
https://git.proxmox.com/git/mirror_smartmontools-debian
synced 2025-08-05 10:54:13 +00:00
Merge branch 'upstream' of git.debian.org:/git/collab-maint/smartmontools into upstream
This commit is contained in:
commit
17d0b8d95e
7
AUTHORS
7
AUTHORS
@ -1,4 +1,8 @@
|
||||
<<<<<<< HEAD
|
||||
$Id: AUTHORS 4285 2016-04-10 13:17:11Z chrfranke $
|
||||
=======
|
||||
$Id: AUTHORS 4101 2015-05-30 17:52:05Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
Developers / Maintainers / Contributors:
|
||||
|
||||
@ -12,7 +16,10 @@ Yuri Dario <mc6530@mclink.it>
|
||||
Casper Dik <...>
|
||||
Christian Franke <franke@computer.org>
|
||||
Guilhem Frézou <...>
|
||||
<<<<<<< HEAD
|
||||
Thomas Gatterweh <thomas_gatterweh@hotmail.com>
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
Douglas Gilbert <dgilbert@interlog.com>
|
||||
Guido Guenther <agx@sigxcpu.org>
|
||||
Jordan Hargrave <jordan_hargrave@dell.com>
|
||||
|
@ -1,3 +1,4 @@
|
||||
<<<<<<< HEAD
|
||||
$Id: ChangeLog 4324 2016-05-31 20:45:50Z chrfranke $
|
||||
|
||||
2016-05-31 Christian Franke <franke@computer.org>
|
||||
@ -687,6 +688,9 @@ $Id: ChangeLog 4324 2016-05-31 20:45:50Z chrfranke $
|
||||
|
||||
drivedb.h:
|
||||
- USB: SimpleTech 3.0 bridge (0x4971:0x8017), reported in #554
|
||||
=======
|
||||
$Id: ChangeLog 4109 2015-06-04 16:30:15Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
2015-06-04 Christian Franke <franke@computer.org>
|
||||
|
||||
|
4
INSTALL
4
INSTALL
@ -1,7 +1,11 @@
|
||||
Smartmontools installation instructions
|
||||
=======================================
|
||||
|
||||
<<<<<<< HEAD
|
||||
$Id: INSTALL 4120 2015-08-27 16:12:21Z samm2 $
|
||||
=======
|
||||
$Id: INSTALL 4094 2015-05-27 21:41:17Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
Please also see the smartmontools home page:
|
||||
http://www.smartmontools.org/
|
||||
|
37
Makefile.am
37
Makefile.am
@ -1,6 +1,10 @@
|
||||
## Process this file with automake to produce Makefile.in
|
||||
#
|
||||
<<<<<<< HEAD
|
||||
# $Id: Makefile.am 4299 2016-04-16 19:45:57Z chrfranke $
|
||||
=======
|
||||
# $Id: Makefile.am 4102 2015-06-01 19:25:47Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
#
|
||||
|
||||
@SET_MAKE@
|
||||
@ -265,8 +269,13 @@ endif
|
||||
all-local: $(extra_MANS)
|
||||
install-man: $(extra_MANS)
|
||||
@$(NORMAL_INSTALL)
|
||||
<<<<<<< HEAD
|
||||
$(MKDIR_P) '$(DESTDIR)$(mandir)/man4'
|
||||
$(MKDIR_P) '$(DESTDIR)$(mandir)/man1m'
|
||||
=======
|
||||
$(mkinstalldirs) '$(DESTDIR)$(mandir)/man4'
|
||||
$(mkinstalldirs) '$(DESTDIR)$(mandir)/man1m'
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
for i in $(extra_MANS); do \
|
||||
if test -f $(srcdir)/$$i; then file=$(srcdir)/$$i; \
|
||||
else file=$$i; fi; \
|
||||
@ -329,7 +338,11 @@ sysconf_DATA = smartd.conf
|
||||
|
||||
# If modified smartd.conf exists install smartd.conf.sample instead
|
||||
install-sysconfDATA: $(sysconf_DATA)
|
||||
<<<<<<< HEAD
|
||||
$(MKDIR_P) '$(DESTDIR)$(sysconfdir)'
|
||||
=======
|
||||
$(mkinstalldirs) '$(DESTDIR)$(sysconfdir)'
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
@s="$(srcdir)/smartd.conf"; \
|
||||
f="$(DESTDIR)$(sysconfdir)/smartd.conf$(smartd_suffix)"; \
|
||||
if test -z "$(smartd_suffix)" && test -f "$$f"; then \
|
||||
@ -500,7 +513,11 @@ initd_DATA_install = install-initdDATA-generic
|
||||
initd_DATA_uninstall = uninstall-initdDATA-generic
|
||||
|
||||
install-initdDATA-generic: $(initd_DATA)
|
||||
<<<<<<< HEAD
|
||||
$(MKDIR_P) '$(DESTDIR)$(initddir)'
|
||||
=======
|
||||
$(mkinstalldirs) '$(DESTDIR)$(initddir)'
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
$(INSTALL_SCRIPT) '$(top_builddir)/$(initdfile)' '$(DESTDIR)$(initddir)/smartd$(smartd_suffix)'
|
||||
|
||||
uninstall-initdDATA-generic:
|
||||
@ -524,8 +541,13 @@ systemdsystemunit_DATA = smartd.service
|
||||
endif
|
||||
|
||||
smartd.service: smartd.service.in Makefile
|
||||
<<<<<<< HEAD
|
||||
@echo ' $$(SMARTD_SERVICE_FILTER) < $(srcdir)/smartd.service.in > $@'
|
||||
@{ \
|
||||
=======
|
||||
@echo ' cat $(srcdir)/smartd.service.in | $$(SMARTD_SERVICE_FILTER) > $@'
|
||||
@cat $(srcdir)/smartd.service.in | \
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
sed 's|/usr/local/sbin/smartd|$(sbindir)/smartd|' | \
|
||||
if test -n '$(systemdenvfile)'; then \
|
||||
sed 's|/usr/local/etc/sysconfig/smartmontools|$(systemdenvfile)|'; \
|
||||
@ -539,8 +561,13 @@ smartd.service: smartd.service.in Makefile
|
||||
installdirs-local:
|
||||
@for d in '$(smartdplugindir)' '$(savestatesdir)' '$(attributelogdir)'; do \
|
||||
test -n "$$d" || continue; \
|
||||
<<<<<<< HEAD
|
||||
echo " $(MKDIR_P) '$(DESTDIR)$$d'"; \
|
||||
$(MKDIR_P) "$(DESTDIR)$$d" || exit 1; \
|
||||
=======
|
||||
echo " $(mkinstalldirs) '$(DESTDIR)$$d'"; \
|
||||
$(mkinstalldirs) "$(DESTDIR)$$d" || exit 1; \
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
done
|
||||
|
||||
install-data-local: installdirs-local
|
||||
@ -548,7 +575,11 @@ install-data-local: installdirs-local
|
||||
#
|
||||
# Build man pages
|
||||
#
|
||||
<<<<<<< HEAD
|
||||
MAN_FILTER = { \
|
||||
=======
|
||||
MAN_FILTER = \
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
sed -e 's|CURRENT_SVN_VERSION|$(releaseversion)|g' \
|
||||
-e "s|CURRENT_SVN_DATE|`sed -n 's,^.*DATE[^"]*"\([^"]*\)".*$$,\1,p' svnversion.h`|g" \
|
||||
-e "s|CURRENT_SVN_REV|`sed -n 's,^.*REV[^"]*"\([^"]*\)".*$$,r\1,p' svnversion.h`|g" \
|
||||
@ -569,11 +600,14 @@ MAN_FILTER = { \
|
||||
else \
|
||||
sed '/^\.\\" %IF ENABLE_DRIVEDB/,/^\.\\" %ENDIF ENABLE_DRIVEDB/ s,^,.\\"\# ,' ; \
|
||||
fi | \
|
||||
<<<<<<< HEAD
|
||||
if test '$(with_update_smart_drivedb)' = 'yes'; then \
|
||||
cat; \
|
||||
else \
|
||||
sed '/^\.\\" %IF ENABLE_UPDATE_SMART_DRIVEDB/,/^\.\\" %ENDIF ENABLE_UPDATE_SMART_DRIVEDB/ s,^,.\\"\# ,' ; \
|
||||
fi | \
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
if test -n '$(initddir)'; then \
|
||||
sed 's|/usr/local/etc/rc\.d/init\.d/|$(initddir)/|g' ; \
|
||||
else \
|
||||
@ -599,11 +633,14 @@ MAN_FILTER = { \
|
||||
else \
|
||||
sed '/^\.\\" %IF ENABLE_CAPABILITIES/,/^\.\\" %ENDIF ENABLE_CAPABILITIES/ s,^,.\\"\# ,' ; \
|
||||
fi | \
|
||||
<<<<<<< HEAD
|
||||
if test '$(with_nvme_devicescan)' = 'yes'; then \
|
||||
cat; \
|
||||
else \
|
||||
sed '/^\.\\" %IF ENABLE_NVME_DEVICESCAN/,/^\.\\" %ENDIF ENABLE_NVME_DEVICESCAN/ s,^,.\\"\# ,' ; \
|
||||
fi | \
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
if test -n '$(os_man_filter)'; then \
|
||||
sed -e 's,OS_MAN_FILTER,$(os_man_filter),g' \
|
||||
-e '/^\.\\" %IF NOT OS .*$(os_man_filter)/,/^.\\" %ENDIF NOT OS .*$(os_man_filter)/ s,^,.\\"\# ,' \
|
||||
|
7
NEWS
7
NEWS
@ -1,10 +1,15 @@
|
||||
smartmontools NEWS
|
||||
------------------
|
||||
<<<<<<< HEAD
|
||||
$Id: NEWS 4318 2016-05-07 11:18:20Z chrfranke $
|
||||
=======
|
||||
$Id: NEWS 4109 2015-06-04 16:30:15Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
The most up-to-date version of this file is:
|
||||
http://sourceforge.net/p/smartmontools/code/HEAD/tree/trunk/smartmontools/NEWS
|
||||
|
||||
<<<<<<< HEAD
|
||||
Date 2016-05-07
|
||||
Summary: smartmontools release 6.5
|
||||
-----------------------------------------------------------
|
||||
@ -50,6 +55,8 @@ Summary: smartmontools release 6.5
|
||||
- Windows installer: Defaults to 64-bit version on 64-bit Windows.
|
||||
- Various code changes suggested by Clang Static Analyser and Cppcheck.
|
||||
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
Date 2015-06-04
|
||||
Summary: smartmontools release 6.4
|
||||
-----------------------------------------------------------
|
||||
|
4
README
4
README
@ -3,7 +3,11 @@ smartmontools - S.M.A.R.T. utility toolset for Darwin/Mac
|
||||
OSX, FreeBSD, Linux, NetBSD, OpenBSD, Solaris, and Windows.
|
||||
==========================================================
|
||||
|
||||
<<<<<<< HEAD
|
||||
$Id: README 4120 2015-08-27 16:12:21Z samm2 $
|
||||
=======
|
||||
$Id: README 4063 2015-04-19 17:34:25Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
== HOME ==
|
||||
The home for smartmontools is located at:
|
||||
|
@ -3,8 +3,13 @@
|
||||
*
|
||||
* Home page of code is: http://www.smartmontools.org
|
||||
*
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2002-11 Bruce Allen
|
||||
* Copyright (C) 2008-15 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2002-11 Bruce Allen <smartmontools-support@lists.sourceforge.net>
|
||||
* Copyright (C) 2008-15 Christian Franke <smartmontools-support@lists.sourceforge.net>
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
* Copyright (C) 1999-2000 Michael Cornwell <cornwell@acm.org>
|
||||
* Copyright (C) 2000 Andre Hedrick <andre@linux-ide.org>
|
||||
*
|
||||
@ -36,7 +41,11 @@
|
||||
#include "utility.h"
|
||||
#include "dev_ata_cmd_set.h" // for parsed_ata_device
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * atacmds_cpp_cvsid = "$Id: atacmds.cpp 4301 2016-04-16 20:48:29Z chrfranke $"
|
||||
=======
|
||||
const char * atacmds_cpp_cvsid = "$Id: atacmds.cpp 4048 2015-03-29 16:09:04Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
ATACMDS_H_CVSID;
|
||||
|
||||
// Print ATA debug messages?
|
||||
|
@ -3,8 +3,13 @@
|
||||
*
|
||||
* Home page of code is: http://www.smartmontools.org
|
||||
*
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2002-11 Bruce Allen
|
||||
* Copyright (C) 2008-15 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2002-11 Bruce Allen <smartmontools-support@lists.sourceforge.net>
|
||||
* Copyright (C) 2008-15 Christian Franke <smartmontools-support@lists.sourceforge.net>
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
* Copyright (C) 1999-2000 Michael Cornwell <cornwell@acm.org>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@ -25,7 +30,11 @@
|
||||
#ifndef ATACMDS_H_
|
||||
#define ATACMDS_H_
|
||||
|
||||
<<<<<<< HEAD
|
||||
#define ATACMDS_H_CVSID "$Id: atacmds.h 4162 2015-10-31 16:36:16Z chrfranke $"
|
||||
=======
|
||||
#define ATACMDS_H_CVSID "$Id: atacmds.h 4048 2015-03-29 16:09:04Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
#include "dev_interface.h" // ata_device
|
||||
|
||||
|
@ -18,7 +18,11 @@
|
||||
#include "config.h"
|
||||
#include "ataidentify.h"
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * ataidentify_cpp_cvsid = "$Id: ataidentify.cpp 4120 2015-08-27 16:12:21Z samm2 $"
|
||||
=======
|
||||
const char * ataidentify_cpp_cvsid = "$Id: ataidentify.cpp 4074 2015-05-01 16:03:50Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
ATAIDENTIFY_H_CVSID;
|
||||
|
||||
#include "int64.h"
|
||||
|
21
ataprint.cpp
21
ataprint.cpp
@ -4,7 +4,11 @@
|
||||
* Home page of code is: http://www.smartmontools.org
|
||||
*
|
||||
* Copyright (C) 2002-11 Bruce Allen
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2008-16 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2008-15 Christian Franke
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
* Copyright (C) 1999-2000 Michael Cornwell <cornwell@acm.org>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@ -40,7 +44,11 @@
|
||||
#include "utility.h"
|
||||
#include "knowndrives.h"
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * ataprint_cpp_cvsid = "$Id: ataprint.cpp 4256 2016-03-27 16:51:32Z chrfranke $"
|
||||
=======
|
||||
const char * ataprint_cpp_cvsid = "$Id: ataprint.cpp 4104 2015-06-03 18:50:39Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
ATAPRINT_H_CVSID;
|
||||
|
||||
|
||||
@ -697,7 +705,10 @@ static void print_drive_info(const ata_identify_device * drive,
|
||||
pout("ATA Version is: %s\n", infofound(ataver.c_str()));
|
||||
|
||||
// Print Transport specific version
|
||||
<<<<<<< HEAD
|
||||
// cppcheck-suppress variableScope
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
char buf[32] = "";
|
||||
unsigned short word222 = drive->words088_255[222-88];
|
||||
if (word222 != 0x0000 && word222 != 0xffff) switch (word222 >> 12) {
|
||||
@ -1543,6 +1554,7 @@ static void print_device_statistics_page(const unsigned char * data, int page)
|
||||
page, offset,
|
||||
abs(size),
|
||||
valstr,
|
||||
<<<<<<< HEAD
|
||||
((flags & 0x20) ? 'N' : '-'), // normalized statistics
|
||||
((flags & 0x10) ? 'D' : '-'), // supports DSN (ACS-3)
|
||||
((flags & 0x08) ? 'C' : '-'), // monitored condition met (ACS-3)
|
||||
@ -1550,6 +1562,15 @@ static void print_device_statistics_page(const unsigned char * data, int page)
|
||||
( info ? info[i].name :
|
||||
(page == 0xff) ? "Vendor Specific" // ACS-4
|
||||
: "Unknown" ));
|
||||
=======
|
||||
(flags & 0x20 ? 'N' : '-'), // normalized statistics
|
||||
(flags & 0x10 ? 'D' : '-'), // supports DSN (ACS-3)
|
||||
(flags & 0x08 ? 'C' : '-'), // monitored condition met (ACS-3)
|
||||
(flags & 0x07 ? '+' : ' '), // reserved flags
|
||||
(info ? info[i].name :
|
||||
page == 0xff ? "Vendor Specific" // ACS-4
|
||||
: "Unknown" ));
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
}
|
||||
}
|
||||
|
||||
|
39
autogen.sh
39
autogen.sh
@ -1,5 +1,9 @@
|
||||
#!/bin/sh
|
||||
<<<<<<< HEAD
|
||||
# $Id: autogen.sh 4115 2015-07-15 20:52:26Z chrfranke $
|
||||
=======
|
||||
# $Id: autogen.sh 4053 2015-04-14 20:18:50Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
#
|
||||
# Generate ./configure from configure.ac and Makefile.in from Makefile.am.
|
||||
# This also adds files like missing,depcomp,install-sh to the source
|
||||
@ -40,11 +44,33 @@ else
|
||||
fi
|
||||
fi
|
||||
|
||||
<<<<<<< HEAD
|
||||
ver=$(echo "$ver" | sed -n '1s,^.*[^.0-9]\([12]\.[0-9][-.0-9pl]*\).*$,\1,p')
|
||||
if [ -z "$ver" ]; then
|
||||
echo "$AUTOMAKE: Unable to determine automake version."
|
||||
exit 1
|
||||
fi
|
||||
=======
|
||||
test -x "$AUTOMAKE" ||
|
||||
AUTOMAKE=`typep automake-1.15` || AUTOMAKE=`typep automake-1.14` ||
|
||||
AUTOMAKE=`typep automake-1.13` || AUTOMAKE=`typep automake-1.12` ||
|
||||
AUTOMAKE=`typep automake-1.11` || AUTOMAKE=`typep automake-1.10` ||
|
||||
AUTOMAKE=`typep automake-1.9` || AUTOMAKE=`typep automake-1.8` ||
|
||||
AUTOMAKE=`typep automake-1.7` || AUTOMAKE=`typep automake17` ||
|
||||
{
|
||||
echo
|
||||
echo "You must have at least GNU Automake 1.7 (up to 1.15) installed"
|
||||
echo "in order to bootstrap smartmontools from SVN. Download the"
|
||||
echo "appropriate package for your distribution, or the source tarball"
|
||||
echo "from ftp://ftp.gnu.org/gnu/automake/ ."
|
||||
echo
|
||||
echo "Also note that support for new Automake series (anything newer"
|
||||
echo "than 1.15) is only added after extensive tests. If you live in"
|
||||
echo "the bleeding edge, you should know what you're doing, mainly how"
|
||||
echo "to test it before the developers. Be patient."
|
||||
exit 1;
|
||||
}
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
# Check aclocal
|
||||
if [ -z "$ACLOCAL" ]; then
|
||||
@ -71,7 +97,20 @@ case "$ver" in
|
||||
echo "Please report success/failure to the smartmontools-support mailing list."
|
||||
esac
|
||||
|
||||
<<<<<<< HEAD
|
||||
# required for aclocal-1.10 --install
|
||||
=======
|
||||
# Warn if Automake version is too old
|
||||
case "$ver" in
|
||||
1.[789]|1.[789].*)
|
||||
echo "WARNING:"
|
||||
echo "The use of GNU Automake version $ver is deprecated. Support for Automake"
|
||||
echo "versions 1.7 - 1.9.x will be removed in a future release of smartmontools."
|
||||
esac
|
||||
|
||||
# Install pkg-config macros
|
||||
# (Don't use 'aclocal -I m4 --install' to keep support for automake < 1.10)
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
test -d m4 || mkdir m4 || exit 1
|
||||
|
||||
set -e # stops on error status
|
||||
|
95
configure.ac
95
configure.ac
@ -1,14 +1,24 @@
|
||||
#
|
||||
<<<<<<< HEAD
|
||||
# $Id: configure.ac 4319 2016-05-07 12:14:20Z chrfranke $
|
||||
=======
|
||||
# $Id: configure.ac 4109 2015-06-04 16:30:15Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
#
|
||||
dnl Process this file with autoconf to produce a configure script.
|
||||
AC_PREREQ([2.60])
|
||||
AC_INIT(smartmontools, 6.6, smartmontools-support@lists.sourceforge.net)
|
||||
AM_INIT_AUTOMAKE([1.10 foreign])
|
||||
|
||||
<<<<<<< HEAD
|
||||
smartmontools_cvs_tag=`echo '$Id: configure.ac 4319 2016-05-07 12:14:20Z chrfranke $'`
|
||||
smartmontools_release_date=2016-05-07
|
||||
smartmontools_release_time="11:17:46 UTC"
|
||||
=======
|
||||
smartmontools_cvs_tag=`echo '$Id: configure.ac 4109 2015-06-04 16:30:15Z chrfranke $'`
|
||||
smartmontools_release_date=2015-06-04
|
||||
smartmontools_release_time="16:29:41 UTC"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
AC_DEFINE_UNQUOTED(SMARTMONTOOLS_CONFIGURE_ARGS, "$ac_configure_args", [smartmontools Configure Arguments])
|
||||
AC_DEFINE_UNQUOTED(SMARTMONTOOLS_RELEASE_DATE, "$smartmontools_release_date", [smartmontools Release Date])
|
||||
@ -232,11 +242,26 @@ case "${host}" in
|
||||
esac
|
||||
AC_SUBST(initdfile)
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
autoconf_25x=${docdir:-yes}
|
||||
AC_ARG_WITH(docdir,
|
||||
[AS_HELP_STRING([--with-docdir=DIR], [Deprecated (use --docdir=DIR instead)])],
|
||||
[docdir="$withval"],
|
||||
[ if test -z "$docdir"; then
|
||||
# autoconf 2.5x without '--docdir' support
|
||||
docdir='${datadir}/doc/${PACKAGE}'
|
||||
fi
|
||||
])
|
||||
AC_SUBST(docdir)
|
||||
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
AC_ARG_WITH(exampledir,
|
||||
[AS_HELP_STRING([--with-exampledir=DIR], [Location of example scripts [DOCDIR/examplescripts]])],
|
||||
[exampledir="$withval"], [exampledir='${docdir}/examplescripts'])
|
||||
AC_SUBST(exampledir)
|
||||
|
||||
<<<<<<< HEAD
|
||||
drivedbdir='${datadir}/${PACKAGE}'
|
||||
AC_ARG_WITH(drivedbdir,
|
||||
[AS_HELP_STRING([--with-drivedbdir@<:@=DIR|yes|no@:>@], [Location of drive database file [DATADIR/smartmontools]])],
|
||||
@ -250,6 +275,20 @@ AC_ARG_WITH(update-smart_drivedb,
|
||||
test -n "$drivedbdir" || with_update_smart_drivedb=no
|
||||
AC_SUBST(with_update_smart_drivedb)
|
||||
AM_CONDITIONAL(ENABLE_UPDATE_SMART_DRIVEDB, [test "$with_update_smart_drivedb" = "yes"])
|
||||
=======
|
||||
used_deprecated_option=no
|
||||
AC_ARG_ENABLE(drivedb,
|
||||
[AS_HELP_STRING([--disable-drivedb], [Deprecated (use --without-drivedbdir instead)])],
|
||||
[used_deprecated_option=yes], [enable_drivedb=yes])
|
||||
|
||||
drivedbdir=
|
||||
AC_ARG_WITH(drivedbdir,
|
||||
[AS_HELP_STRING([--with-drivedbdir=@<:@DIR|no@:>@], [Location of drive database file [DATADIR/smartmontools]])],
|
||||
[test "$withval" != "no" && drivedbdir="$withval"],
|
||||
[test "$enable_drivedb" != "no" && drivedbdir='${datadir}/${PACKAGE}'])
|
||||
AC_SUBST(drivedbdir)
|
||||
AM_CONDITIONAL(ENABLE_DRIVEDB, [test -n "$drivedbdir"])
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
AC_ARG_WITH(smartdscriptdir,
|
||||
[AS_HELP_STRING([--with-smartdscriptdir=DIR], [Location of smartd_warning.sh script [SYSCONFDIR]])],
|
||||
@ -263,16 +302,30 @@ AC_ARG_WITH(smartdplugindir,
|
||||
[smartdplugindir='${smartdscriptdir}/smartd_warning.d'])
|
||||
AC_SUBST(smartdplugindir)
|
||||
|
||||
<<<<<<< HEAD
|
||||
savestates=
|
||||
AC_ARG_WITH(savestates,
|
||||
[AS_HELP_STRING([--with-savestates@<:@=PREFIX|yes|no@:>@],
|
||||
[Enable default smartd state files [no] (yes=LOCALSTATEDIR/lib/smartmontools/smartd.)])],
|
||||
[case "$withval" in yes) savestates='${localstatedir}/lib/${PACKAGE}/smartd.' ;;
|
||||
no) ;; *) savestates="$withval" ;; esac])
|
||||
=======
|
||||
AC_ARG_ENABLE(savestates,
|
||||
[AS_HELP_STRING([--enable-savestates], [Deprecated (use --with-savestates@<:@=yes@:>@ instead)])],
|
||||
[used_deprecated_option=yes], [enable_savestates=no])
|
||||
|
||||
savestates='${localstatedir}/lib/${PACKAGE}/smartd.'
|
||||
AC_ARG_WITH(savestates,
|
||||
[AS_HELP_STRING([--with-savestates@<:@=PREFIX|yes|no@:>@],
|
||||
[Enable default smartd state files [no] (yes=LOCALSTATEDIR/lib/smartmontools/smartd.)])],
|
||||
[case "$withval" in yes) ;; no) savestates= ;; *) savestates="$withval" ;; esac],
|
||||
[test "$enable_savestates" != "yes" && savestates=])
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
savestatesdir="${savestates%/*}"
|
||||
AC_SUBST(savestates)
|
||||
AC_SUBST(savestatesdir)
|
||||
AM_CONDITIONAL(ENABLE_SAVESTATES, [test -n "$savestates"])
|
||||
<<<<<<< HEAD
|
||||
|
||||
attributelog=
|
||||
AC_ARG_WITH(attributelog,
|
||||
@ -280,6 +333,19 @@ AC_ARG_WITH(attributelog,
|
||||
[Enable default smartd attribute log files [no] (yes=LOCALSTATEDIR/lib/smartmontools/attrlog.)])],
|
||||
[case "$withval" in yes) attributelog='${localstatedir}/lib/${PACKAGE}/attrlog.' ;;
|
||||
no) ;; *) attributelog="$withval" ;; esac])
|
||||
=======
|
||||
|
||||
AC_ARG_ENABLE(attributelog,
|
||||
[AS_HELP_STRING([--enable-attributelog], [Deprecated (use --with-attributelog@<:@=yes@:>@ instead)])],
|
||||
[used_deprecated_option=yes], [enable_attributelog=no])
|
||||
|
||||
attributelog='${localstatedir}/lib/${PACKAGE}/attrlog.'
|
||||
AC_ARG_WITH(attributelog,
|
||||
[AS_HELP_STRING([--with-attributelog@<:@=PREFIX|yes|no@:>@],
|
||||
[Enable default smartd attribute log files [no] (yes=LOCALSTATEDIR/lib/smartmontools/attrlog.)])],
|
||||
[case "$withval" in yes) ;; no) attributelog= ;; *) attributelog="$withval" ;; esac],
|
||||
[test "$enable_attributelog" != "yes" && attributelog=])
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
attributelogdir="${attributelog%/*}"
|
||||
AC_SUBST(attributelog)
|
||||
AC_SUBST(attributelogdir)
|
||||
@ -392,6 +458,7 @@ if test "$libc_have_working_snprintf" = "yes"; then
|
||||
AC_DEFINE(HAVE_WORKING_SNPRINTF, 1, [Define to 1 if the `snprintf' function is sane.]) dnl `vim syntax
|
||||
fi
|
||||
|
||||
<<<<<<< HEAD
|
||||
os_win32_manifest=
|
||||
case "$host" in
|
||||
*-*-mingw*)
|
||||
@ -425,6 +492,13 @@ AC_ARG_ENABLE(attributelog,
|
||||
if test -n "${enable_drivedb+set}${enable_savestates+set}${enable_attributelog+set}"; then
|
||||
AC_MSG_ERROR([Options --disable-drivedb, --enable-savestates, --enable-attributelog are no longer supported.
|
||||
Use --without-drivedbdir, --with-savestates, --with-attributelog instead.])
|
||||
=======
|
||||
if test "$prefix" = "NONE"; then
|
||||
# Fix mandir default set by autoconf 2.5x
|
||||
if test "$mandir" = '${prefix}/man'; then
|
||||
AC_SUBST([mandir], ['${prefix}/share/man'])
|
||||
fi
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
fi
|
||||
|
||||
|
||||
@ -724,3 +798,24 @@ Use option '--with-solaris-sparc-ata' to enable legacy ATA support.
|
||||
Use option '--without-solaris-sparc-ata' to suppress this warning.])
|
||||
;;
|
||||
esac
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
echo "-----------------------------------------------------------------------------" >&AS_MESSAGE_FD
|
||||
|
||||
if test "$autoconf_25x" = "yes"; then
|
||||
echo "WARNING:" >&AS_MESSAGE_FD
|
||||
echo "Support for old autoconf 2.5x versions will be removed in a future" >&AS_MESSAGE_FD
|
||||
echo "release of smartmontools." >&AS_MESSAGE_FD
|
||||
elif test "${with_docdir+set}" = "set"; then
|
||||
echo "WARNING:" >&AS_MESSAGE_FD
|
||||
echo "Option --with-docdir is deprecated and will be removed in a future" >&AS_MESSAGE_FD
|
||||
echo "release of smartmontools. Use --docdir instead." >&AS_MESSAGE_FD
|
||||
fi
|
||||
|
||||
if test "$used_deprecated_option" = "yes"; then
|
||||
echo "WARNING:" >&AS_MESSAGE_FD
|
||||
echo "Options --disable-drivedb, --enable-savestates, --enable-attributelog are" >&AS_MESSAGE_FD
|
||||
echo "deprecated and will be removed in a future release of smartmontools." >&AS_MESSAGE_FD
|
||||
echo "Use --without-drivedb, --with-savestates, --with-attributelog instead." >&AS_MESSAGE_FD
|
||||
fi
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
226
drivedb.h
226
drivedb.h
@ -4,7 +4,11 @@
|
||||
* Home page of code is: http://www.smartmontools.org
|
||||
*
|
||||
* Copyright (C) 2003-11 Philip Williams, Bruce Allen
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2008-16 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2008-15 Christian Franke
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
*
|
||||
* 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
|
||||
@ -75,7 +79,11 @@
|
||||
/*
|
||||
const drive_settings builtin_knowndrives[] = {
|
||||
*/
|
||||
<<<<<<< HEAD
|
||||
{ "$Id: drivedb.h 4324 2016-05-31 20:45:50Z chrfranke $",
|
||||
=======
|
||||
{ "$Id: drivedb.h 4105 2015-06-03 19:32:30Z chrfranke $",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"-", "-",
|
||||
"This is a dummy entry to hold the SVN-Id of drivedb.h",
|
||||
""
|
||||
@ -281,12 +289,19 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "Crucial/Micron MX100/MX200/M5x0/M600 Client SSDs",
|
||||
"Crucial_CT(128|256|512)MX100SSD1|"// tested with Crucial_CT256MX100SSD1/MU01
|
||||
<<<<<<< HEAD
|
||||
"Crucial_CT(200|250|256|500|512|1000|1024)MX200SSD[1346]|" // tested with Crucial_CT500MX200SSD1/MU01,
|
||||
// Crucial_CT1024MX200SSD1/MU01, Crucial_CT250MX200SSD3/MU01, Crucial_CT250MX200SSD1/MU03
|
||||
"Crucial_CT(120|240|480|960)M500SSD[134]|" // tested with Crucial_CT960M500SSD1/MU03,
|
||||
// Crucial_CT240M500SSD4/MU05
|
||||
"Crucial_CT(128|256|512|1024)M550SSD[13]|" // tested with Crucial_CT512M550SSD3/MU01,
|
||||
// Crucial_CT1024M550SSD1/MU01
|
||||
=======
|
||||
"Crucial_CT(200|256|500|512|1000|1024)MX200SSD[1346]|" // tested with Crucial_CT500MX200SSD1/MU01,
|
||||
// Crucial_CT1024MX200SSD1/MU01
|
||||
"Crucial_CT(120|240|480|960)M500SSD1|" // tested with Crucial_CT960M500SSD1/MU03
|
||||
"Crucial_CT(128|256|512|1024)M550SSD[13]|" // tested with Crucial_CT512M550SSD3/MU01, Crucial_CT1024M550SSD1/MU01
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"Micron_M500_MTFDDA[KTV](120|240|480|960)MAV|"// tested with Micron_M500_MTFDDAK960MAV/MU05
|
||||
"(Micron_)?M510[_-]MTFDDA[KTV](128|256)MAZ|" // tested with M510-MTFDDAK256MAZ/MU01
|
||||
"(Micron_)?M550[_-]MTFDDA[KTV](064|128|256|512|1T0)MAY|" // tested with M550-MTFDDAK256MAY/MU01
|
||||
@ -400,9 +415,14 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"KINGSTON SMS200S3(30|60|120)G|" // mSATA, SF-2241, tested with SMS200S3120G/KC3ABBF0
|
||||
"KINGSTON SMS450S3(32|64|128)G|" // mSATA, SF-2281, tested with SMS450S3128G/503ABBF0
|
||||
"KINGSTON (SV300|SKC100|SE100)S3.*G|" // other SF-2281
|
||||
<<<<<<< HEAD
|
||||
"MKNSSDCR(45|60|90|120|180|240|360|480)GB(-(7|DX7?|MX|G2))?|" // Mushkin Chronos (7mm/Deluxe/MX/G2),
|
||||
// SF-2281, tested with MKNSSDCR120GB, MKNSSDCR120GB-MX/560ABBF0, MKNSSDCR480GB-DX7/603ABBF0
|
||||
"MKNSSDEC(60|120|240|480|512)GB|" // Mushkin Enhanced ECO2, tested with MKNSSDEC120GB/604ABBF0
|
||||
=======
|
||||
"MKNSSDCR(45|60|90|120|180|240|480)GB(-[DM]X)?|" // Mushkin Chronos (Deluxe/Enhanced), SF-2281,
|
||||
// tested with MKNSSDCR120GB, MKNSSDCR120GB-MX/560ABBF0
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"MKNSSDAT(30|40|60|120|180|240|480)GB(-(DX|V))?|" // Mushkin Atlas (Deluxe/Value), mSATA, SF-2281,
|
||||
// tested with MKNSSDAT120GB-V/540ABBF0
|
||||
"Mushkin MKNSSDCL(40|60|80|90|115|120|180|240|480)GB-DX2?|" // Mushkin Callisto deluxe,
|
||||
@ -580,10 +600,15 @@ const drive_settings builtin_knowndrives[] = {
|
||||
//"-v 233,raw48,Media_Wearout_Indicator"
|
||||
},
|
||||
{ "Indilinx Barefoot 3 based SSDs",
|
||||
<<<<<<< HEAD
|
||||
"OCZ-VECTOR(1[58]0)?|" // tested with OCZ-VECTOR/1.03, OCZ-VECTOR150/1.2, OCZ-VECTOR180
|
||||
"OCZ-VERTEX4[56]0A?|" // Barefoot 3 M10, tested with OCZ-VERTEX450/1.0, OCZ-VERTEX460/1.0, VERTEX460A
|
||||
"OCZ-SABER1000|"
|
||||
"OCZ-ARC100|"
|
||||
=======
|
||||
"OCZ-VECTOR(150)?|" // tested with OCZ-VECTOR/1.03, OCZ-VECTOR150/1.2
|
||||
"OCZ-VERTEX4[56]0|" // Barefoot 3 M10, tested with OCZ-VERTEX450/1.0, OCZ-VERTEX460/1.0
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"Radeon R7", // Barefoot 3 M00, tested with Radeon R7/1.00
|
||||
"", "",
|
||||
"-v 5,raw48,Runtime_Bad_Block "
|
||||
@ -613,11 +638,18 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 233,raw48,Remaining_Lifetime_Perc "
|
||||
"-v 241,raw48,Host_Writes_GiB " // M00/M10
|
||||
"-v 242,raw48,Host_Reads_GiB " // M00/M10
|
||||
<<<<<<< HEAD
|
||||
"-v 249,raw48,Total_NAND_Prog_Ct_GiB "
|
||||
"-v 251,raw48,Total_NAND_Read_Ct_GiB"
|
||||
},
|
||||
{ "OCZ Intrepid 3000 SSDs", // tested with OCZ INTREPID 3600/1.4.3.6, 3800/1.4.3.0, 3700/1.5.0.4
|
||||
"OCZ INTREPID 3[678]00",
|
||||
=======
|
||||
"-v 249,raw48,Total_NAND_Prog_Ct_GiB"
|
||||
},
|
||||
{ "OCZ Intrepid 3000 SSDs", // tested with OCZ INTREPID 3600/1.4.3.6, 3800/1.4.3.0
|
||||
"OCZ INTREPID 3[68]00",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "",
|
||||
"-v 5,raw48,Runtime_Bad_Block "
|
||||
//"-v 9,raw24(raw8),Power_On_Hours "
|
||||
@ -688,6 +720,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 236,raw48,Unstable_Power_Count "
|
||||
"-v 240,raw48,Write_Head"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "Innodisk 3ME SSDs", // tested with 2.5" SATA SSD 3ME/S140714
|
||||
"((1\\.8|2\\.5)\"? SATA SSD|SATA Slim) 3ME",
|
||||
"", "",
|
||||
@ -797,6 +830,8 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 241,raw48,Host_Writes_32MiB "
|
||||
"-v 242,raw48,Host_Reads_32MiB"
|
||||
},
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
{ "InnoDisk iCF 9000 CompactFlash Cards", // tested with InnoDisk Corp. - iCF9000 1GB/140808,
|
||||
// ..., InnoDisk Corp. - iCF9000 64GB/140808
|
||||
"InnoDisk Corp\\. - iCF9000 (1|2|4|8|16|32|64)GB",
|
||||
@ -887,9 +922,14 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 228,raw48,Workload_Minutes"
|
||||
},
|
||||
{ "Intel 311/313 Series SSDs", // tested with INTEL SSDSA2VP020G2/2CV102M5,
|
||||
<<<<<<< HEAD
|
||||
// INTEL SSDSA2VP020G3/9CV10379, INTEL SSDMAEXC024G3H/9CV10379
|
||||
"INTEL SSD(SA2VP|MAEXC)(020|024)G[23]H?",
|
||||
// SA2VP = 2.5", MAEXC = mSATA, G2 = 311, G3 = 313
|
||||
=======
|
||||
// INTEL SSDSA2VP020G3/9CV10379,
|
||||
"INTEL SSDSA2VP(020|024)G[23]", // G3 = 313 Series
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "",
|
||||
//"-v 3,raw16(avg16),Spin_Up_Time "
|
||||
//"-v 4,raw48,Start_Stop_Count "
|
||||
@ -1031,11 +1071,17 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 242,raw48,Host_Reads_32MiB "
|
||||
"-v 249,raw48,NAND_Writes_1GiB"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "Intel 53x and Pro 2500 Series SSDs", // SandForce SF-2281, tested with
|
||||
// INTEL SSDSC2BW180A4/DC12, SSDSC2BW240A4/DC12, SSDMCEAW120A4/DC33
|
||||
// INTEL SSDMCEAW240A4/DC33, SSDSC2BF480A5/TG26, SSDSC2BW240H6/RG21
|
||||
"INTEL SSD(MCEA|SC2B|SCKJ)[WF](056|080|120|180|240|360|480)(A4|A5|H6)",
|
||||
// SC2B = 2.5", MCEA = mSATA, SCKJ = M.2; A4 = 530, A5 = Pro 2500, H6 = 535
|
||||
=======
|
||||
{ "Intel 530 Series SSDs", // tested with INTEL SSDSC2BW180A4/DC12, SSDSC2BW240A4/DC12,
|
||||
// INTEL SSDMCEAW120A4/DC33, INTEL SSDMCEAW240A4/DC33
|
||||
"INTEL SSD(MCEA|SC2B)W(080|120|180|240|360|480)A4", // MCEA = mSATA
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "",
|
||||
//"-v 5,raw16(raw16),Reallocated_Sector_Ct "
|
||||
"-v 9,msec24hour32,Power_On_Hours_and_Msec "
|
||||
@ -1243,6 +1289,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"MZ7PC(512|256|128|064)HA(GH|FU|DR)-000.*|" // probably PM830, tested with SAMSUNG MZ7PC128HAFU-000L1/CXM04L1Q
|
||||
"Samsung SSD 840 (PRO )?Series|" // tested with Samsung SSD 840 PRO Series 128GB/DXM04B0Q,
|
||||
// Samsung SSD 840 Series/DXT06B0Q
|
||||
<<<<<<< HEAD
|
||||
"Samsung SSD 8[45]0 EVO (mSATA |M\\.2 )?((120|250|500|750)G|1T)B( mSATA)?|" // tested with
|
||||
// Samsung SSD 840 EVO (120|250|500|750)GB/EXT0AB0Q,
|
||||
// Samsung SSD 840 EVO (120|250)GB/EXT0BB6Q, 1TB/EXT0BB0Q, 120GB mSATA/EXT41B6Q,
|
||||
@ -1259,6 +1306,17 @@ const drive_settings builtin_knowndrives[] = {
|
||||
// SAMSUNG MZ7LM960HCHP-0E003/GXT3003Q
|
||||
"SAMSUNG MZ7KM(120|240|480|960|1T9)HA(JM|HP|GR|FD|JM)-.*|" // SM863, tested with MZ7KM480HAHP-0E005/GXM1003Q
|
||||
"SAMSUNG MZ[7N]LN(128|256|512)HC(HP|GR|JH)-.*", // PM871 Series, tested with SAMSUNG MZ7LN128HCHP
|
||||
=======
|
||||
"Samsung SSD 8[45]0 EVO ((120|250|500)G|1T)B( mSATA)?|" // tested with Samsung SSD 840 EVO (120|250|500)GB/EXT0AB0Q,
|
||||
// Samsung SSD 840 EVO (120|250)GB/EXT0BB6Q, 1TB/EXT0BB0Q, 120GB mSATA/EXT41B6Q,
|
||||
// Samsung SSD 850 EVO 250GB/EMT01B6Q
|
||||
"Samsung SSD 850 PRO ((128|256|512)G|1T)B|" // tested with Samsung SSD 850 PRO 128GB/EXM01B6Q,
|
||||
// Samsung SSD 850 PRO 1TB/EXM01B6Q
|
||||
"SAMSUNG MZ7WD((120|240)HAFV|480HAGM|960HAGP)-00003|" // SM843T Series, tested with
|
||||
// SAMSUNG MZ7WD120HAFV-00003/DXM85W3Q
|
||||
"SAMSUNG MZ7GE(240HMGR|(480|960)HMHP)-00003", // SM853T Series, tested with
|
||||
// SAMSUNG MZ7GE240HMGR-00003/EXT0303Q
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "",
|
||||
//"-v 5,raw16(raw16),Reallocated_Sector_Ct "
|
||||
//"-v 9,raw24(raw8),Power_On_Hours "
|
||||
@ -1284,6 +1342,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 235,raw48,POR_Recovery_Count " // 830/840/850 Series
|
||||
//"-v 241,raw48,Total_LBAs_Written "
|
||||
//"-v 242,raw48,Total_LBAs_Read " // PM851, SM841N
|
||||
<<<<<<< HEAD
|
||||
"-v 243,raw48,SATA_Downshift_Ct " // PM863
|
||||
"-v 244,raw48,Thermal_Throttle_St " // PM863
|
||||
"-v 245,raw48,Timed_Workld_Media_Wear " // PM863
|
||||
@ -1291,6 +1350,8 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 247,raw48,Timed_Workld_Timer " // PM863
|
||||
"-v 250,raw48,SATA_Iface_Downshift " // from the spec
|
||||
"-v 251,raw48,NAND_Writes" // PM863
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
},
|
||||
{ "Marvell based SanDisk SSDs",
|
||||
"SanDisk SD5SG2[0-9]*G1052E|" // X100 (88SS9174), tested with SanDisk SD5SG2256G1052E/10.04.01
|
||||
@ -1357,6 +1418,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-v 244,raw48,Thermal_Throttle "
|
||||
},
|
||||
{ "SiliconMotion based SSDs", // SM2246EN (Transcend TS6500)
|
||||
<<<<<<< HEAD
|
||||
"CT(120|250|500|1000)BX100SSD1|" // Crucial BX100, tested with CT250BX100SSD1/MU02,
|
||||
// CT500BX100SSD1/MU02, CT1000BX100SSD1/MU02
|
||||
"CT(240|480|960)BX200SSD1|" // Crucial BX200 Solid State Drive, tested with CT480BX200SSD1/MU02.6
|
||||
@ -1364,15 +1426,22 @@ const drive_settings builtin_knowndrives[] = {
|
||||
// tested with TS32GMSA370/20140402, TS16GMSA370/20140516, TS64GSSD370/20140516,
|
||||
// TS256GSSD370/N0815B, TS256GSSD370S/N1114H, TS512GSSD370S/N1114H, TS32GSSD420I/N1114H
|
||||
"ADATA SP550", // ADATA SP550/O0803B5a
|
||||
=======
|
||||
"TS((16|32|64|128|256|512)G|1T)(SSD|MSA)370", // Transcend SSD370 SATA/mSATA, TS6500, tested with
|
||||
// TS32GMSA370/20140402, TS16GMSA370/20140516, TS64GSSD370/20140516, TS256GSSD370/N0815B
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "",
|
||||
//"-v 1,raw48,Raw_Read_Error_Rate "
|
||||
//"-v 2,raw48,Throughput_Performance "
|
||||
//"-v 9,raw24(raw8),Power_On_Hours "
|
||||
//"-v 12,raw48,Power_Cycle_Count "
|
||||
<<<<<<< HEAD
|
||||
"-v 148,raw48,Total_SLC_Erase_Ct "
|
||||
"-v 149,raw48,Max_SLC_Erase_Ct "
|
||||
"-v 150,raw48,Min_SLC_Erase_Ct "
|
||||
"-v 151,raw48,Average_SLC_Erase_Ct "
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"-v 160,raw48,Uncorrectable_Error_Cnt "
|
||||
"-v 161,raw48,Valid_Spare_Block_Cnt "
|
||||
"-v 163,raw48,Initial_Bad_Block_Count "
|
||||
@ -1400,9 +1469,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
//"-v 232,raw48,Available_Reservd_Space "
|
||||
"-v 241,raw48,Host_Writes_32MiB "
|
||||
"-v 242,raw48,Host_Reads_32MiB "
|
||||
<<<<<<< HEAD
|
||||
"-v 245,raw48,TLC_Writes_32MiB " // FW N0815B, N1114H
|
||||
"-v 246,raw48,SLC_Writes_32MiB "
|
||||
"-v 247,raw48,Raid_Recoverty_Ct"
|
||||
=======
|
||||
"-v 245,raw48,Unkn_SiliconMotion_Attr" // FW N0815B
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
},
|
||||
{ "Smart Storage Systems Xcel-10 SSDs", // based on http://www.smartm.com/files/salesLiterature/storage/xcel10.pdf
|
||||
"SMART A25FD-(32|64|128)GI32N", // tested with SMART A25FD-128GI32N/B9F23D4K
|
||||
@ -2296,6 +2369,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "Hitachi/HGST Travelstar Z5K320", // tested with Hitachi HTS543232A7A384/ES2OA70K
|
||||
"(Hitachi|HGST) HT[ES]5432(16|25|32)A7A38[145]",
|
||||
<<<<<<< HEAD
|
||||
"", "", ""
|
||||
},
|
||||
{ "Hitachi Travelstar 5K500.B", // tested with Hitachi HTS545050B9SA00/PB4OC60X
|
||||
@ -2306,6 +2380,17 @@ const drive_settings builtin_knowndrives[] = {
|
||||
// Hitachi HTS545032A7E380/GGBOA7A0, HGST HTS545050A7E680/GR2OA230,
|
||||
// APPLE HDD HTS545050A7E362/GG2AB990
|
||||
"(Hitachi|HGST|APPLE HDD) HT[ES]5450(25|32|50)A7E(362|38[01]|680)",
|
||||
=======
|
||||
"", "", ""
|
||||
},
|
||||
{ "Hitachi Travelstar 5K500.B", // tested with Hitachi HTS545050B9SA00/PB4OC60X
|
||||
"(Hitachi )?HT[ES]5450(12|16|25|32|40|50)B9(A30[01]|SA00)",
|
||||
"", "", ""
|
||||
},
|
||||
{ "Hitachi/HGST Travelstar Z5K500", // tested with HGST HTS545050A7E380/GG2OAC90,
|
||||
// Hitachi HTS545032A7E380/GGBOA7A0, APPLE HDD HTS545050A7E362/GG2AB990
|
||||
"(Hitachi|HGST|APPLE HDD) HT[ES]5450(25|32|50)A7E3(62|8[01])",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "", ""
|
||||
},
|
||||
{ "Hitachi/HGST Travelstar 5K750", // tested with Hitachi HTS547575A9E384/JE4OA60A,
|
||||
@ -2355,9 +2440,14 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"(HITACHI )?HT[ES]7232(16|25|32)A7A36[145]",
|
||||
"", "", ""
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "Hitachi Travelstar 7K500", // tested with Hitachi HTS725050A9A360/PC4OC70D,
|
||||
// HITACHI HTS725032A9A364/PC3ZC70F
|
||||
"(Hitachi |HITACHI )?HT[ES]7250(12|16|25|32|50)A9A36[02-5]",
|
||||
=======
|
||||
{ "Hitachi Travelstar 7K500", // tested with Hitachi HTS725050A9A360/PC4OC70D
|
||||
"(Hitachi )?HT[ES]7250(12|16|25|32|50)A9A36[02-5]",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "", ""
|
||||
},
|
||||
{ "Hitachi/HGST Travelstar Z7K500", // tested with HITACHI HTS725050A7E630/GH2ZB390,
|
||||
@ -2503,6 +2593,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "HGST Ultrastar He6", // tested with HGST HUS726060ALA640/AHGNT1E2
|
||||
"HGST HUS726060ALA64[01]",
|
||||
<<<<<<< HEAD
|
||||
"", "",
|
||||
"-v 22,raw48,Helium_Level"
|
||||
},
|
||||
@ -2510,6 +2601,9 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"HGST HUH7280(60|80)AL[EN]60[014]",
|
||||
"", "",
|
||||
"-v 22,raw48,Helium_Level"
|
||||
=======
|
||||
"", "", ""
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
},
|
||||
{ "HGST MegaScale 4000", // tested with HGST HMS5C4040ALE640/MPAOA580
|
||||
"HGST HMS5C4040[AB]LE64[01]", // B = DC 4000.B
|
||||
@ -2601,6 +2695,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"TOSHIBA MQ01ABC(100|150|200)",
|
||||
"", "", ""
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "Toshiba 2.5\" HDD MQ01ABD...", // tested with TOSHIBA MQ01ABD100/AX001U,
|
||||
// TOSHIBA MQ01ABD100V/AX001Q
|
||||
"TOSHIBA MQ01ABD(025|032|050|064|075|100)V?",
|
||||
@ -2614,6 +2709,20 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"TOSHIBA MQ01UBB200",
|
||||
"", "", ""
|
||||
},
|
||||
=======
|
||||
{ "Toshiba 2.5\" HDD MQ01ABD...", // tested with TOSHIBA MQ01ABD100/AX001U
|
||||
"TOSHIBA MQ01ABD(025|032|050|064|075|100)",
|
||||
"", "", ""
|
||||
},
|
||||
{ "Toshiba 2.5\" HDD MQ01ABF...", // tested with TOSHIBA MQ01ABF050/AM001J
|
||||
"TOSHIBA MQ01ABF(050|075|100)",
|
||||
"", "", ""
|
||||
},
|
||||
{ "Toshiba 2.5\" HDD MQ01UBB... (USB 3.0)", // tested with TOSHIBA MQ01UBB200/AY000U (0x0480:0xa100)
|
||||
"TOSHIBA MQ01UBB200",
|
||||
"", "", ""
|
||||
},
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
{ "Toshiba 2.5\" HDD MQ01UBD... (USB 3.0)", // tested with TOSHIBA MQ01UBD050/AX001U (0x0480:0xa007),
|
||||
// TOSHIBA MQ01UBD100/AX001U (0x0480:0x0201, 0x0480:0xa200)
|
||||
"TOSHIBA MQ01UBD(050|075|100)",
|
||||
@ -3052,6 +3161,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
{ "Seagate Constellation.2 (SATA)", // 2.5", tested with ST91000640NS/SN02, MM1000GBKAL/HPGB
|
||||
"ST9(25061|50062|100064)[012]NS|" // *SS = SAS
|
||||
"MM1000GBKAL", // HP OEM
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
"", "", ""
|
||||
},
|
||||
{ "Seagate Enterprise Capacity 3.5 HDD", // tested with ST6000NM0024-1HT17Z/SN02
|
||||
"ST[2456]000NM0[01][248]4-.*", // *[069]4 = 4Kn
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "", ""
|
||||
},
|
||||
{ "Seagate Enterprise Capacity 3.5 HDD", // tested with ST6000NM0024-1HT17Z/SN02
|
||||
@ -3226,8 +3342,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"", "", ""
|
||||
},
|
||||
{ "Western Digital Blue", // tested with WDC WD5000AZLX-00K4KA0/80.00A80,
|
||||
<<<<<<< HEAD
|
||||
// WDC WD10EZEX-00RKKA0/80.00A80, WDC WD10EZEX-75M2NA0/01.01A01, WDC WD40EZRZ-00WN9B0/80.00A80
|
||||
"WDC WD((25|32|50)00AAKX|5000AZ(LX|RZ)|7500A(AL|ZE)X|10E(AL|ZE)X|[1-6]0EZRZ)-.*",
|
||||
=======
|
||||
// WDC WD10EZEX-00RKKA0/80.00A80, WDC WD10EZEX-75M2NA0/01.01A01
|
||||
"WDC WD((25|32|50)00AAK|5000AZL|7500AAL|10EAL|10EZE)X-.*",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "", ""
|
||||
},
|
||||
{ "Western Digital RE Serial ATA",
|
||||
@ -3370,6 +3491,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "Western Digital Red", // tested with WDC WD10EFRX-68JCSN0/01.01A01,
|
||||
// WDC WD10JFCX-68N6GN0/01.01A01, WDC WD40EFRX-68WT0N0/80.00A80,
|
||||
<<<<<<< HEAD
|
||||
// WDC WD60EFRX-68MYMN1/82.00A82, WDC WD80EFZX-68UW8N0/83.H0A83
|
||||
"WDC WD(7500BFC|10JFC|[1-6]0EFR|80EFZ)X-.*",
|
||||
"", "",
|
||||
@ -3377,6 +3499,18 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "Western Digital Red Pro", // tested with WDC WD2001FFSX-68JNUN0/81.00A81
|
||||
"WDC WD[234]001FFSX-.*",
|
||||
=======
|
||||
// WDC WD60EFRX-68MYMN1/82.00A82
|
||||
"WDC WD(7500BFC|10JFC|(10|20|30|40|50|60)EFR)X-.*",
|
||||
"", "", ""
|
||||
},
|
||||
{ "Western Digital Red Pro", // tested with WDC WD2001FFSX-68JNUN0/81.00A81
|
||||
"WDC WD[234]001FFSX-.*",
|
||||
"", "", ""
|
||||
},
|
||||
{ "Western Digital Purple", // tested with WDC WD40PURX-64GVNY0/80.00A80
|
||||
"WDC WD[123456]0PURX-.*",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", "", ""
|
||||
},
|
||||
{ "Western Digital Purple", // tested with WDC WD40PURX-64GVNY0/80.00A80
|
||||
@ -3562,8 +3696,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "USB: Toshiba Canvio; ", // 0x0210: TOSHIBA MQ03UBB300
|
||||
"0x0480:0x02(01|10)",
|
||||
=======
|
||||
{ "USB: Toshiba Canvio Basics; ", // TOSHIBA MQ01UBD100
|
||||
"0x0480:0x(0201|a200)",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"",
|
||||
"-d sat"
|
||||
@ -3586,8 +3725,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "USB: Toshiba Stor.E; ",
|
||||
"0x0480:0xa00[9ace]",
|
||||
=======
|
||||
{ "USB: Toshiba Stor.E Basics; ",
|
||||
"0x0480:0xa00[9ce]",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", // 0x0000 (0xa00e)
|
||||
"",
|
||||
"-d sat"
|
||||
@ -3598,6 +3742,15 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
{ "USB: Toshiba Canvio ALU; ", // TOSHIBA MQ01UBB200
|
||||
"0x0480:0xa100",
|
||||
"",
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
{ "USB: Toshiba Canvio Desktop; ",
|
||||
"0x0480:0xd0(00|10|11)",
|
||||
"", // 0x0316 (0xd011)
|
||||
@ -3755,7 +3908,11 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-d usbsunplus"
|
||||
},
|
||||
{ "USB: Iomega; JMicron",
|
||||
<<<<<<< HEAD
|
||||
"0x059b:0x0(47[05]|575)", // 0x0470: LPHD-UP, 0x0475: GDHDU2 (0x0100), 0x0575: LDHD-UP
|
||||
=======
|
||||
"0x059b:0x0[45]75", // 0x0475: Iomega GDHDU2 (0x0100), 0x0575: LDHD-UP
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"",
|
||||
"-d usbjmicron"
|
||||
@ -3782,6 +3939,14 @@ const drive_settings builtin_knowndrives[] = {
|
||||
{ "USB: LaCie Rugged Triple Interface; ",
|
||||
"0x059f:0x100c",
|
||||
"", // 0x0001
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
{ "USB: LaCie hard disk (Neil Poulton design);",
|
||||
"0x059f:0x1018",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
@ -3871,12 +4036,15 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "USB: ; Genesys Logic",
|
||||
"0x05e3:0x0735",
|
||||
"", // 0x1003
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
// Micron
|
||||
{ "USB: Micron USB SSD; ",
|
||||
"0x0634:0x0655",
|
||||
@ -3912,7 +4080,11 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
// SanDisk
|
||||
{ "USB: SanDisk SDCZ80 Flash Drive; Fujitsu", // ATA ID: SanDisk pSSD
|
||||
<<<<<<< HEAD
|
||||
"0x0781:0x558[08]",
|
||||
=======
|
||||
"0x0781:0x5580",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"",
|
||||
"-d sat"
|
||||
@ -4032,8 +4204,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-d sat"
|
||||
},
|
||||
{ "USB: Seagate Expansion Portable; ",
|
||||
<<<<<<< HEAD
|
||||
"0x0bc2:0x23(00|12|20|21|22)",
|
||||
"", // 12=0x0219, 22=0x0000
|
||||
=======
|
||||
"0x0bc2:0x23(00|12|20|21)",
|
||||
"", // 0x0219 (0x2312)
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
@ -4117,10 +4294,20 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "USB: Seagate Backup Plus Desktop USB 3.0; ",
|
||||
"0x0bc2:0xa(0a[14]|b31)", // 4TB, 3TB (8 LBA/1 PBA offset), 5TB
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
"",
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
{ "USB: Seagate Slim Portable Drive; ", // SRD00F1
|
||||
"0x0bc2:0xab00",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "USB: Seagate Slim Portable Drive; ", // SRD00F1
|
||||
"0x0bc2:0xab00",
|
||||
"",
|
||||
@ -4129,6 +4316,10 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "USB: Seagate Backup Plus USB 3.0; ",
|
||||
"0x0bc2:0xab2[0145]", // 0xab24: Slim (ticket #443), 0xab25: Mac
|
||||
=======
|
||||
{ "USB: Seagate Backup Plus Slim USB 3.0; ", // (ticket #443)
|
||||
"0x0bc2:0xab2[14]",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"", // 0x0100
|
||||
"",
|
||||
"-d sat"
|
||||
@ -4232,8 +4423,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-d usbcypress"
|
||||
},
|
||||
{ "USB: WD My Passport; ",
|
||||
<<<<<<< HEAD
|
||||
"0x1058:0x0(70[245a]|71a|730|74[0128a]|7a[8e]|81[06]|82[02]|83[37a])",
|
||||
"", // 822=0x1007, 837=0x1072
|
||||
=======
|
||||
"0x1058:0x0(70[245a]|730|74[0128a]|7a8|8[123]0)",
|
||||
"",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
@ -4256,6 +4452,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-d sat"
|
||||
},
|
||||
{ "USB: WD My Book; ",
|
||||
<<<<<<< HEAD
|
||||
"0x1058:0x11(0[01245]|1[0d]|30|40)",
|
||||
"", // 00/01=0x0165, 02=0x1028, 10=0x1030, 1d=0x1020, 30=0x1012, 40=0x1003
|
||||
"",
|
||||
@ -4264,6 +4461,10 @@ const drive_settings builtin_knowndrives[] = {
|
||||
{ "USB: WD Elements; ",
|
||||
"0x1058:0x25a2",
|
||||
"", // 0x1004
|
||||
=======
|
||||
"0x1058:0x11(00|01|02|04|05|10|30|40)",
|
||||
"", // 00/01=0x0165, 02=0x1028, 10=0x1030, 30=0x1012, 40=0x1003
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
@ -4276,8 +4477,13 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
// ADATA
|
||||
{ "USB: ADATA; ",
|
||||
<<<<<<< HEAD
|
||||
"0x125f:0xa(11|31|35|15)a", // 0xa11a: Classic CH11 1TB, 0xa31a: HV620 2TB (0x0100)
|
||||
"", // 0xa35a: HD650 2TB (0x6503), 0xa15a: HD710 1TB
|
||||
=======
|
||||
"0x125f:0xa(11|31|35)a", // 0xa11a: Classic CH11 1TB, 0xa31a: HV620 2TB (0x0100)
|
||||
"", // 0xa35a: HD650 2TB (0x6503)
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
@ -4343,9 +4549,15 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-d sat"
|
||||
},
|
||||
{ "USB: ; Initio",
|
||||
<<<<<<< HEAD
|
||||
"0x13fd:0x39[124]0", // 0x3910: Seagate Expansion Portable SRD00F1 (0x0100)
|
||||
"", // 0x3920: ezDISK EZ370 (0x0205)
|
||||
"", // 0x3940: MS-TECH LU-275S (0x0306)
|
||||
=======
|
||||
"0x13fd:0x39[14]0", // 0x3910: Seagate Expansion Portable SRD00F1 (0x0100)
|
||||
"", // 0x3940: MS-TECH LU-275S (0x0306)
|
||||
"",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"-d sat"
|
||||
},
|
||||
// Super Top
|
||||
@ -4364,7 +4576,11 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "USB: ; JMicron JMS539", // USB2/3->SATA (new firmware)
|
||||
"0x152d:0x0539",
|
||||
<<<<<<< HEAD
|
||||
"0x020[56]|" // 2.05, ZTC USB 3.0 enclosure (ticket #338)
|
||||
=======
|
||||
"0x020[56]|" // 2.05, ticket #338
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"0x28(03|12)", // 28.03, Mediasonic ProBox HF2-SU3S2 Rev 2 (port multiplier, ticket #504)
|
||||
"", // 28.12, Mediasonic ProBox H82-SU3S2 (port multiplier)
|
||||
"-d sat"
|
||||
@ -4375,12 +4591,15 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"",
|
||||
"-d usbjmicron,x"
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "USB: ; JMicron", // USB2/3->2xSATA
|
||||
"0x152d:0x0565",
|
||||
"", // 0x9114, Akasa DuoDock X (ticket #607)
|
||||
"",
|
||||
"-d sat"
|
||||
},
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
{ "USB: ; JMicron JMS567", // USB2/3->SATA
|
||||
"0x152d:0x0567",
|
||||
"", // 0x0114
|
||||
@ -4613,12 +4832,15 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"",
|
||||
"-d sat" // ATA output registers missing
|
||||
},
|
||||
<<<<<<< HEAD
|
||||
{ "USB: ; VIA VL711", // USB2/3->SATA
|
||||
"0x2109:0x0711",
|
||||
"", // 0x0114, Mediasonic ProBox K32-SU3 (ticket #594)
|
||||
"", // 0x0507, Intenso 2,5" Memory Case 2TB USB3
|
||||
"-d sat"
|
||||
},
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
// 0x2537 (?)
|
||||
{ "USB: ; ", // USB 3.0
|
||||
"0x2537:0x106[68]", // 0x1066: Orico 2599US3, 0x1068: Fantec ER-35U3
|
||||
@ -4654,6 +4876,7 @@ const drive_settings builtin_knowndrives[] = {
|
||||
"-d sat" // ATA output registers missing
|
||||
},
|
||||
{ "USB: Hitachi Touro Mobile; ", // 1TB
|
||||
<<<<<<< HEAD
|
||||
"0x4971:0x102[04]",
|
||||
"", // 0x0100
|
||||
"",
|
||||
@ -4661,6 +4884,9 @@ const drive_settings builtin_knowndrives[] = {
|
||||
},
|
||||
{ "USB: SimpleTech;", // USB 3.0 HDD BOX Agestar, Rock External HDD 3,5" UASP
|
||||
"0x4971:0x8017",
|
||||
=======
|
||||
"0x4971:0x1020",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
"",
|
||||
"",
|
||||
"-d sat"
|
||||
|
19
os_linux.cpp
19
os_linux.cpp
@ -5,7 +5,11 @@
|
||||
*
|
||||
* Copyright (C) 2003-11 Bruce Allen
|
||||
* Copyright (C) 2003-11 Doug Gilbert <dgilbert@interlog.com>
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2008-16 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2008-15 Christian Franke <smartmontools-support@lists.sourceforge.net>
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
*
|
||||
* Original AACRaid code:
|
||||
* Copyright (C) 2014 Raghava Aditya <raghava.aditya@pmcs.com>
|
||||
@ -102,7 +106,11 @@
|
||||
|
||||
#define ARGUSED(x) ((void)(x))
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * os_linux_cpp_cvsid = "$Id: os_linux.cpp 4295 2016-04-15 20:01:32Z chrfranke $"
|
||||
=======
|
||||
const char * os_linux_cpp_cvsid = "$Id: os_linux.cpp 4047 2015-03-22 16:16:24Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
OS_LINUX_H_CVSID;
|
||||
extern unsigned char failuretest_permissive;
|
||||
|
||||
@ -379,9 +387,15 @@ int linux_ata_device::ata_command_interface(smart_command_set command, int selec
|
||||
// copy user data into the task request structure
|
||||
memcpy(task+sizeof(ide_task_request_t), data, 512);
|
||||
|
||||
<<<<<<< HEAD
|
||||
if (ioctl(get_fd(), HDIO_DRIVE_TASKFILE, task)) {
|
||||
if (errno==EINVAL)
|
||||
pout("Kernel lacks HDIO_DRIVE_TASKFILE support; compile kernel with CONFIG_IDE_TASK_IOCTL set\n");
|
||||
=======
|
||||
if ((retval=ioctl(get_fd(), HDIO_DRIVE_TASKFILE, task))) {
|
||||
if (errno==-EINVAL)
|
||||
pout("Kernel lacks HDIO_DRIVE_TASKFILE support; compile kernel with CONFIG_IDE_TASKFILE_IO set\n");
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
return -1;
|
||||
}
|
||||
return 0;
|
||||
@ -405,8 +419,13 @@ int linux_ata_device::ata_command_interface(smart_command_set command, int selec
|
||||
buff[4]=normal_lo;
|
||||
buff[5]=normal_hi;
|
||||
|
||||
<<<<<<< HEAD
|
||||
if (ioctl(get_fd(), HDIO_DRIVE_TASK, buff)) {
|
||||
if (errno==EINVAL) {
|
||||
=======
|
||||
if ((retval=ioctl(get_fd(), HDIO_DRIVE_TASK, buff))) {
|
||||
if (errno==-EINVAL) {
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
pout("Error SMART Status command via HDIO_DRIVE_TASK failed");
|
||||
pout("Rebuild older linux 2.2 kernels with HDIO_DRIVE_TASK support added\n");
|
||||
}
|
||||
|
462
os_win32.cpp
462
os_win32.cpp
@ -3,7 +3,11 @@
|
||||
*
|
||||
* Home page of code is: http://www.smartmontools.org
|
||||
*
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2004-16 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2004-15 Christian Franke
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
*
|
||||
* Original AACRaid code:
|
||||
* Copyright (C) 2015 Nidhi Malhotra <nidhi.malhotra@pmcs.com>
|
||||
@ -112,7 +116,11 @@
|
||||
#define strnicmp strncasecmp
|
||||
#endif
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * os_win32_cpp_cvsid = "$Id: os_win32.cpp 4293 2016-04-14 19:33:05Z chrfranke $";
|
||||
=======
|
||||
const char * os_win32_cpp_cvsid = "$Id: os_win32.cpp 4098 2015-05-30 16:37:37Z chrfranke $";
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Windows I/O-controls, some declarations are missing in the include files
|
||||
@ -629,6 +637,34 @@ static int smart_ioctl(HANDLE hdevice, IDEREGS * regs, char * data, unsigned dat
|
||||
return 0;
|
||||
}
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//// PMC aacraid Support
|
||||
|
||||
class win_aacraid_device
|
||||
:public /*implements*/ scsi_device,
|
||||
public /*extends*/ win_smart_device
|
||||
{
|
||||
public:
|
||||
win_aacraid_device(smart_interface *intf, const char *dev_name,unsigned int ctrnum, unsigned int target, unsigned int lun);
|
||||
|
||||
virtual ~win_aacraid_device() throw();
|
||||
|
||||
virtual bool open();
|
||||
|
||||
virtual bool scsi_pass_through(struct scsi_cmnd_io *iop);
|
||||
|
||||
private:
|
||||
//Device Host number
|
||||
int m_ctrnum;
|
||||
|
||||
//Channel(Lun) of the device
|
||||
int m_lun;
|
||||
|
||||
//Id of the device
|
||||
int m_target;
|
||||
};
|
||||
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// IDE PASS THROUGH (2000, XP, undocumented)
|
||||
@ -799,6 +835,7 @@ static int ata_pass_through_ioctl(HANDLE hdevice, IDEREGS * regs, IDEREGS * prev
|
||||
return -1;
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
// Check and copy data
|
||||
if (datasize > 0) {
|
||||
if ( num_out != size
|
||||
@ -806,6 +843,20 @@ static int ata_pass_through_ioctl(HANDLE hdevice, IDEREGS * regs, IDEREGS * prev
|
||||
if (ata_debugmode) {
|
||||
pout(" IOCTL_ATA_PASS_THROUGH output data missing (%u)\n", (unsigned)num_out);
|
||||
print_ide_regs_io(regs, ctfregs);
|
||||
=======
|
||||
if (vi.dwMajorVersion <= 0xf && vi.dwMinorVersion <= 0xf) {
|
||||
bool ws = (vi.wProductType <= VER_NT_WORKSTATION);
|
||||
switch (vi.dwMajorVersion << 4 | vi.dwMinorVersion) {
|
||||
case 0x50: w = "2000"; break;
|
||||
case 0x51: w = "xp"; break;
|
||||
case 0x52: w = (!GetSystemMetrics(89/*SM_SERVERR2*/)
|
||||
? "2003" : "2003r2"); break;
|
||||
case 0x60: w = (ws ? "vista" : "2008" ); break;
|
||||
case 0x61: w = (ws ? "win7" : "2008r2"); break;
|
||||
case 0x62: w = (ws ? "win8" : "2012" ); break;
|
||||
case 0x63: w = (ws ? "win8.1": "2012r2"); break;
|
||||
case 0x64: w = (ws ? "win10" : "w10srv"); break;
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
}
|
||||
errno = EIO;
|
||||
return -1;
|
||||
@ -881,6 +932,7 @@ static int ata_via_scsi_miniport_smart_ioctl(HANDLE hdevice, IDEREGS * regs, cha
|
||||
ASSERT_SIZEOF(sb, sizeof(SRB_IO_CONTROL)+sizeof(SENDCMDINPARAMS)-1+512);
|
||||
memset(&sb, 0, sizeof(sb));
|
||||
|
||||
<<<<<<< HEAD
|
||||
unsigned size;
|
||||
if (datasize > 0) {
|
||||
if (datasize > (int)sizeof(sb.space)+1) {
|
||||
@ -909,6 +961,10 @@ static int ata_via_scsi_miniport_smart_ioctl(HANDLE hdevice, IDEREGS * regs, cha
|
||||
sb.srbc.Length = sizeof(SENDCMDINPARAMS)-1 + size;
|
||||
sb.params.in.irDriveRegs = *regs;
|
||||
sb.params.in.cBufferSize = size;
|
||||
=======
|
||||
// Return value for device detection functions
|
||||
enum win_dev_type { DEV_UNKNOWN = 0, DEV_ATA, DEV_SCSI, DEV_SAT, DEV_USB };
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
// Call miniport ioctl
|
||||
size += sizeof(SRB_IO_CONTROL) + sizeof(SENDCMDINPARAMS)-1;
|
||||
@ -1007,6 +1063,7 @@ static int ata_via_3ware_miniport_ioctl(HANDLE hdevice, IDEREGS * regs, char * d
|
||||
return -1;
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
// Copy data
|
||||
if (datasize > 0)
|
||||
memcpy(data, sb.buffer, datasize);
|
||||
@ -1014,12 +1071,94 @@ static int ata_via_3ware_miniport_ioctl(HANDLE hdevice, IDEREGS * regs, char * d
|
||||
if (ata_debugmode > 1) {
|
||||
pout(" ATA via IOCTL_SCSI_MINIPORT suceeded, bytes returned: %u\n", (unsigned)num_out);
|
||||
print_ide_regs_io(regs, &sb.regs);
|
||||
=======
|
||||
name = skipdev(name);
|
||||
#define ARECA_MAX_CTLR_NUM 16
|
||||
n1 = -1;
|
||||
int ctlrindex = 0;
|
||||
if (sscanf(name, "arcmsr%d%n", &ctlrindex, &n1) >= 1 && n1 == (int)strlen(name)) {
|
||||
/*
|
||||
1. scan from "\\\\.\\scsi[0]:" up to "\\\\.\\scsi[ARECA_MAX_CTLR_NUM]:" and
|
||||
2. map arcmsrX into "\\\\.\\scsiX"
|
||||
*/
|
||||
for (int idx = 0; idx < ARECA_MAX_CTLR_NUM; idx++) {
|
||||
memset(devpath, 0, sizeof(devpath));
|
||||
snprintf(devpath, sizeof(devpath), "\\\\.\\scsi%d:", idx);
|
||||
win_areca_ata_device *arcdev = new win_areca_ata_device(this, devpath, disknum, encnum);
|
||||
if(arcdev->arcmsr_probe()) {
|
||||
if(ctlrindex-- == 0) {
|
||||
return arcdev;
|
||||
}
|
||||
}
|
||||
delete arcdev;
|
||||
}
|
||||
set_err(ENOENT, "No Areca controller found");
|
||||
}
|
||||
else
|
||||
set_err(EINVAL, "Option -d areca,N/E requires device name /dev/arcmsrX");
|
||||
return 0;
|
||||
}
|
||||
|
||||
// aacraid?
|
||||
unsigned ctrnum, lun, target;
|
||||
n1 = -1;
|
||||
|
||||
if ( sscanf(type, "aacraid,%u,%u,%u%n", &ctrnum, &lun, &target, &n1) >= 3
|
||||
&& n1 == (int)strlen(type)) {
|
||||
#define aacraid_MAX_CTLR_NUM 16
|
||||
if (ctrnum >= aacraid_MAX_CTLR_NUM) {
|
||||
set_err(EINVAL, "aacraid: invalid host number %u", ctrnum);
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*
|
||||
1. scan from "\\\\.\\scsi[0]:" up to "\\\\.\\scsi[AACRAID_MAX_CTLR_NUM]:" and
|
||||
2. map ARCX into "\\\\.\\scsiX"
|
||||
*/
|
||||
memset(devpath, 0, sizeof(devpath));
|
||||
unsigned ctlrindex = 0;
|
||||
for (int portNum = 0; portNum < aacraid_MAX_CTLR_NUM; portNum++){
|
||||
char subKey[63];
|
||||
snprintf(subKey, sizeof(subKey), "HARDWARE\\DEVICEMAP\\Scsi\\Scsi Port %d", portNum);
|
||||
HKEY hScsiKey = 0;
|
||||
long regStatus = RegOpenKeyExA(HKEY_LOCAL_MACHINE, subKey, 0, KEY_READ, &hScsiKey);
|
||||
if (regStatus == ERROR_SUCCESS){
|
||||
char driverName[20];
|
||||
DWORD driverNameSize = sizeof(driverName);
|
||||
DWORD regType = 0;
|
||||
regStatus = RegQueryValueExA(hScsiKey, "Driver", NULL, ®Type, (LPBYTE) driverName, &driverNameSize);
|
||||
if (regStatus == ERROR_SUCCESS){
|
||||
if (regType == REG_SZ){
|
||||
if (stricmp(driverName, "arcsas") == 0){
|
||||
if(ctrnum == ctlrindex){
|
||||
snprintf(devpath, sizeof(devpath), "\\\\.\\Scsi%d:", portNum);
|
||||
return get_sat_device("sat,auto",
|
||||
new win_aacraid_device(this, devpath, ctrnum, target, lun));
|
||||
}
|
||||
ctlrindex++;
|
||||
}
|
||||
}
|
||||
}
|
||||
RegCloseKey(hScsiKey);
|
||||
}
|
||||
}
|
||||
|
||||
set_err(EINVAL, "aacraid: host %u not found", ctrnum);
|
||||
return 0;
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
}
|
||||
*regs = sb.regs;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
std::string win_smart_interface::get_valid_custom_dev_types_str()
|
||||
{
|
||||
return "aacraid,H,L,ID, areca,N[/E]";
|
||||
}
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@ -1061,6 +1200,7 @@ static int update_3ware_devicemap_ioctl(HANDLE hdevice)
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// IOCTL_STORAGE_QUERY_PROPERTY
|
||||
|
||||
<<<<<<< HEAD
|
||||
union STORAGE_DEVICE_DESCRIPTOR_DATA {
|
||||
STORAGE_DEVICE_DESCRIPTOR desc;
|
||||
char raw[256];
|
||||
@ -1081,6 +1221,30 @@ static int storage_query_property_ioctl(HANDLE hdevice, STORAGE_DEVICE_DESCRIPTO
|
||||
pout(" IOCTL_STORAGE_QUERY_PROPERTY failed, Error=%u\n", (unsigned)GetLastError());
|
||||
errno = ENOSYS;
|
||||
return -1;
|
||||
=======
|
||||
if (type == DEV_ATA)
|
||||
return new win_ata_device(this, name, "");
|
||||
|
||||
if (type == DEV_SCSI)
|
||||
return new win_scsi_device(this, name, "");
|
||||
|
||||
if (type == DEV_SAT)
|
||||
return get_sat_device("sat", new win_scsi_device(this, name, ""));
|
||||
|
||||
if (type == DEV_USB) {
|
||||
// Get USB bridge ID
|
||||
unsigned short vendor_id = 0, product_id = 0;
|
||||
if (!(phydrive >= 0 && get_usb_id(phydrive, vendor_id, product_id))) {
|
||||
set_err(EINVAL, "Unable to read USB device ID");
|
||||
return 0;
|
||||
}
|
||||
// Get type name for this ID
|
||||
const char * usbtype = get_usb_dev_type_by_id(vendor_id, product_id);
|
||||
if (!usbtype)
|
||||
return 0;
|
||||
// Return SAT/USB device for this type
|
||||
return get_sat_device(usbtype, new win_scsi_device(this, name, ""));
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
}
|
||||
|
||||
if (ata_debugmode > 1 || scsi_debugmode > 1) {
|
||||
@ -1121,6 +1285,7 @@ static int storage_predict_failure_ioctl(HANDLE hdevice, char * data = 0)
|
||||
return -1;
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
if (ata_debugmode > 1) {
|
||||
pout(" IOCTL_STORAGE_PREDICT_FAILURE returns:\n"
|
||||
" PredictFailure: 0x%08x\n"
|
||||
@ -1134,6 +1299,49 @@ static int storage_predict_failure_ioctl(HANDLE hdevice, char * data = 0)
|
||||
memcpy(data, pred.VendorSpecific, sizeof(pred.VendorSpecific));
|
||||
return (!pred.PredictFailure ? 0 : 1);
|
||||
}
|
||||
=======
|
||||
// Set valid types
|
||||
bool ata, scsi, sat, usb, csmi;
|
||||
if (!type) {
|
||||
ata = scsi = usb = sat = csmi = true;
|
||||
}
|
||||
else {
|
||||
ata = scsi = usb = sat = csmi = false;
|
||||
if (!strcmp(type, "ata"))
|
||||
ata = true;
|
||||
else if (!strcmp(type, "scsi"))
|
||||
scsi = true;
|
||||
else if (!strcmp(type, "sat"))
|
||||
sat = true;
|
||||
else if (!strcmp(type, "usb"))
|
||||
usb = true;
|
||||
else if (!strcmp(type, "csmi"))
|
||||
csmi = true;
|
||||
else {
|
||||
set_err(EINVAL,
|
||||
"Invalid type '%s', valid arguments are: ata[,pd], scsi[,pd], sat[,pd], usb[,pd], csmi, pd",
|
||||
type);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
char name[20];
|
||||
|
||||
if (ata || scsi || sat || usb) {
|
||||
// Scan up to 128 drives and 2 3ware controllers
|
||||
const int max_raid = 2;
|
||||
bool raid_seen[max_raid] = {false, false};
|
||||
|
||||
for (int i = 0; i < 128; i++) {
|
||||
if (pd)
|
||||
snprintf(name, sizeof(name), "/dev/pd%d", i);
|
||||
else if (i + 'a' <= 'z')
|
||||
snprintf(name, sizeof(name), "/dev/sd%c", i + 'a');
|
||||
else
|
||||
snprintf(name, sizeof(name), "/dev/sd%c%c",
|
||||
i / ('z'-'a'+1) - 1 + 'a',
|
||||
i % ('z'-'a'+1) + 'a');
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
|
||||
// Build IDENTIFY information from STORAGE_DEVICE_DESCRIPTOR
|
||||
@ -1149,11 +1357,42 @@ static int get_identify_from_device_property(HANDLE hdevice, ata_identify_device
|
||||
// others return it as ProductId only.
|
||||
char model[sizeof(id->model) + 1] = "";
|
||||
|
||||
<<<<<<< HEAD
|
||||
unsigned i = 0;
|
||||
if (data.desc.VendorIdOffset) {
|
||||
for ( ;i < sizeof(model)-1 && data.raw[data.desc.VendorIdOffset+i]; i++)
|
||||
model[i] = data.raw[data.desc.VendorIdOffset+i];
|
||||
}
|
||||
=======
|
||||
case DEV_SAT:
|
||||
// STORAGE_QUERY_PROPERTY returned VendorId "ATA "
|
||||
if (!sat)
|
||||
continue;
|
||||
devlist.push_back( get_sat_device("sat", new win_scsi_device(this, name, "")) );
|
||||
break;
|
||||
|
||||
case DEV_USB:
|
||||
// STORAGE_QUERY_PROPERTY returned USB
|
||||
if (!usb)
|
||||
continue;
|
||||
{
|
||||
// TODO: Use common function for this and autodetect_smart_device()
|
||||
// Get USB bridge ID
|
||||
unsigned short vendor_id = 0, product_id = 0;
|
||||
if (!get_usb_id(i, vendor_id, product_id))
|
||||
continue;
|
||||
// Get type name for this ID
|
||||
const char * usbtype = get_usb_dev_type_by_id(vendor_id, product_id);
|
||||
if (!usbtype)
|
||||
continue;
|
||||
// Return SAT/USB device for this type
|
||||
ata_device * dev = get_sat_device(usbtype, new win_scsi_device(this, name, ""));
|
||||
if (!dev)
|
||||
continue;
|
||||
devlist.push_back(dev);
|
||||
}
|
||||
break;
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
if (data.desc.ProductIdOffset) {
|
||||
while (i > 1 && model[i-2] == ' ') // Keep last blank from VendorId
|
||||
@ -2242,6 +2481,29 @@ bool csmi_ata_device::ata_pass_through(const ata_cmd_in & in, ata_cmd_out & out)
|
||||
// TODO: Check ptru_buf->Status.uDataBytes
|
||||
memcpy(in.buffer, pthru_buf->bDataBuffer, in.size);
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
// Return true if ATA drive behind a SAT layer
|
||||
static bool is_sat(const STORAGE_DEVICE_DESCRIPTOR_DATA * data)
|
||||
{
|
||||
if (!data->desc.VendorIdOffset)
|
||||
return false;
|
||||
if (strcmp(data->raw + data->desc.VendorIdOffset, "ATA "))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
// Return true if Intel ICHxR RAID volume
|
||||
static bool is_intel_raid_volume(const STORAGE_DEVICE_DESCRIPTOR_DATA * data)
|
||||
{
|
||||
if (!(data->desc.VendorIdOffset && data->desc.ProductIdOffset))
|
||||
return false;
|
||||
const char * vendor = data->raw + data->desc.VendorIdOffset;
|
||||
if (!(!strnicmp(vendor, "Intel", 5) && strspn(vendor+5, " ") == strlen(vendor+5)))
|
||||
return false;
|
||||
if (strnicmp(data->raw + data->desc.ProductIdOffset, "Raid ", 5))
|
||||
return false;
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
return true;
|
||||
}
|
||||
|
||||
@ -2256,11 +2518,47 @@ public:
|
||||
win_csmi_device(smart_interface * intf, const char * dev_name,
|
||||
const char * req_type);
|
||||
|
||||
<<<<<<< HEAD
|
||||
virtual ~win_csmi_device() throw();
|
||||
|
||||
virtual bool open();
|
||||
|
||||
virtual bool close();
|
||||
=======
|
||||
// Newer BusType* values are missing in older includes
|
||||
switch ((int)data.desc.BusType) {
|
||||
case BusTypeAta:
|
||||
case 0x0b: // BusTypeSata
|
||||
// Certain Intel AHCI drivers (C600+/C220+) have broken
|
||||
// IOCTL_ATA_PASS_THROUGH support and a working SAT layer
|
||||
if (is_sat(&data))
|
||||
return DEV_SAT;
|
||||
|
||||
if (ata_version_ex)
|
||||
memset(ata_version_ex, 0, sizeof(*ata_version_ex));
|
||||
return DEV_ATA;
|
||||
|
||||
case BusTypeScsi:
|
||||
case BusTypeRAID:
|
||||
if (is_sat(&data))
|
||||
return DEV_SAT;
|
||||
|
||||
// Intel ICHxR RAID volume: reports SMART_GET_VERSION but does not support SMART_*
|
||||
if (is_intel_raid_volume(&data))
|
||||
return DEV_SCSI;
|
||||
// LSI/3ware RAID volume: supports SMART_*
|
||||
if (admin && smart_get_version(hdevice, ata_version_ex) >= 0)
|
||||
return DEV_ATA;
|
||||
|
||||
return DEV_SCSI;
|
||||
|
||||
case 0x09: // BusTypeiScsi
|
||||
case 0x0a: // BusTypeSas
|
||||
if (is_sat(&data))
|
||||
return DEV_SAT;
|
||||
|
||||
return DEV_SCSI;
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
virtual bool is_open() const;
|
||||
|
||||
@ -4434,6 +4732,170 @@ bool win_smart_interface::disable_system_auto_standby(bool disable)
|
||||
return true;
|
||||
}
|
||||
|
||||
// AACRAID
|
||||
win_aacraid_device::win_aacraid_device(smart_interface * intf,
|
||||
const char *dev_name, unsigned ctrnum, unsigned target, unsigned lun)
|
||||
: smart_device(intf, dev_name, "aacraid", "aacraid"),
|
||||
m_ctrnum(ctrnum), m_lun(lun), m_target(target)
|
||||
{
|
||||
set_info().info_name = strprintf("%s [aacraid_disk_%02d_%02d_%d]", dev_name, m_ctrnum, m_lun, m_target);
|
||||
set_info().dev_type = strprintf("aacraid,%d,%d,%d", m_ctrnum, m_lun, m_target);
|
||||
}
|
||||
|
||||
win_aacraid_device::~win_aacraid_device() throw()
|
||||
{
|
||||
}
|
||||
|
||||
bool win_aacraid_device::open()
|
||||
{
|
||||
if (is_open())
|
||||
return true;
|
||||
|
||||
HANDLE hFh = CreateFile( get_dev_name(),
|
||||
GENERIC_READ|GENERIC_WRITE,
|
||||
FILE_SHARE_READ|FILE_SHARE_WRITE,
|
||||
NULL,
|
||||
OPEN_EXISTING,
|
||||
0,
|
||||
0);
|
||||
if (hFh == INVALID_HANDLE_VALUE)
|
||||
return set_err(ENODEV, "Open failed, Error=%u", (unsigned)GetLastError());
|
||||
|
||||
set_fh(hFh);
|
||||
return true;
|
||||
}
|
||||
|
||||
bool win_aacraid_device::scsi_pass_through(struct scsi_cmnd_io *iop)
|
||||
{
|
||||
int report = scsi_debugmode;
|
||||
if (report > 0)
|
||||
{
|
||||
int k, j;
|
||||
const unsigned char * ucp = iop->cmnd;
|
||||
const char * np;
|
||||
char buff[256];
|
||||
const int sz = (int)sizeof(buff);
|
||||
np = scsi_get_opcode_name(ucp[0]);
|
||||
j = snprintf(buff, sz, " [%s: ", np ? np : "<unknown opcode>");
|
||||
for (k = 0; k < (int)iop->cmnd_len; ++k)
|
||||
j += snprintf(&buff[j], (sz > j ? (sz - j) : 0), "%02x ", ucp[k]);
|
||||
if ((report > 1) &&
|
||||
(DXFER_TO_DEVICE == iop->dxfer_dir) && (iop->dxferp)) {
|
||||
int trunc = (iop->dxfer_len > 256) ? 1 : 0;
|
||||
|
||||
j += snprintf(&buff[j], (sz > j ? (sz - j) : 0), "]\n Outgoing "
|
||||
"data, len=%d%s:\n", (int)iop->dxfer_len,
|
||||
(trunc ? " [only first 256 bytes shown]" : ""));
|
||||
dStrHex((const char *)iop->dxferp,
|
||||
(trunc ? 256 : (int)iop->dxfer_len) , 1);
|
||||
}
|
||||
else
|
||||
j += snprintf(&buff[j], (sz > j ? (sz - j) : 0), "]\n");
|
||||
pout("buff %s\n",buff);
|
||||
}
|
||||
|
||||
char ioBuffer[1000];
|
||||
SRB_IO_CONTROL * pSrbIO = (SRB_IO_CONTROL *) ioBuffer;
|
||||
SCSI_REQUEST_BLOCK * pScsiIO = (SCSI_REQUEST_BLOCK *) (ioBuffer + sizeof(SRB_IO_CONTROL));
|
||||
DWORD scsiRequestBlockSize = sizeof(SCSI_REQUEST_BLOCK);
|
||||
char *pRequestSenseIO = (char *) (ioBuffer + sizeof(SRB_IO_CONTROL) + scsiRequestBlockSize);
|
||||
DWORD dataOffset = (sizeof(SRB_IO_CONTROL) + scsiRequestBlockSize + 7) & 0xfffffff8;
|
||||
char *pDataIO = (char *) (ioBuffer + dataOffset);
|
||||
memset(pScsiIO, 0, scsiRequestBlockSize);
|
||||
pScsiIO->Length = (USHORT) scsiRequestBlockSize;
|
||||
pScsiIO->Function = SRB_FUNCTION_EXECUTE_SCSI;
|
||||
pScsiIO->PathId = 0;
|
||||
pScsiIO->TargetId = m_target;
|
||||
pScsiIO->Lun = m_lun;
|
||||
pScsiIO->CdbLength = (int)iop->cmnd_len;
|
||||
switch(iop->dxfer_dir){
|
||||
case DXFER_NONE:
|
||||
pScsiIO->SrbFlags = SRB_NoDataXfer;
|
||||
break;
|
||||
case DXFER_FROM_DEVICE:
|
||||
pScsiIO->SrbFlags |= SRB_DataIn;
|
||||
break;
|
||||
case DXFER_TO_DEVICE:
|
||||
pScsiIO->SrbFlags |= SRB_DataOut;
|
||||
break;
|
||||
default:
|
||||
pout("aacraid: bad dxfer_dir\n");
|
||||
return set_err(EINVAL, "aacraid: bad dxfer_dir\n");
|
||||
}
|
||||
pScsiIO->DataTransferLength = (ULONG)iop->dxfer_len;
|
||||
pScsiIO->TimeOutValue = iop->timeout;
|
||||
UCHAR *pCdb = (UCHAR *) pScsiIO->Cdb;
|
||||
memcpy(pCdb, iop->cmnd, 16);
|
||||
if (iop->max_sense_len){
|
||||
memset(pRequestSenseIO, 0, iop->max_sense_len);
|
||||
}
|
||||
if (pScsiIO->SrbFlags & SRB_FLAGS_DATA_OUT){
|
||||
memcpy(pDataIO, iop->dxferp, iop->dxfer_len);
|
||||
}
|
||||
else if (pScsiIO->SrbFlags & SRB_FLAGS_DATA_IN){
|
||||
memset(pDataIO, 0, iop->dxfer_len);
|
||||
}
|
||||
|
||||
DWORD bytesReturned = 0;
|
||||
memset(pSrbIO, 0, sizeof(SRB_IO_CONTROL));
|
||||
pSrbIO->HeaderLength = sizeof(SRB_IO_CONTROL);
|
||||
memcpy(pSrbIO->Signature, "AACAPI", 7);
|
||||
pSrbIO->ControlCode = ARCIOCTL_SEND_RAW_SRB;
|
||||
pSrbIO->Length = (dataOffset + iop->dxfer_len - sizeof(SRB_IO_CONTROL) + 7) & 0xfffffff8;
|
||||
pSrbIO->Timeout = 3*60;
|
||||
|
||||
if (!DeviceIoControl(
|
||||
get_fh(),
|
||||
IOCTL_SCSI_MINIPORT,
|
||||
ioBuffer,
|
||||
sizeof(SRB_IO_CONTROL) + pSrbIO->Length,
|
||||
ioBuffer,
|
||||
sizeof(SRB_IO_CONTROL) + pSrbIO->Length,
|
||||
&bytesReturned,
|
||||
NULL)
|
||||
) {
|
||||
return set_err(EIO, "ARCIOCTL_SEND_RAW_SRB failed, Error=%u", (unsigned)GetLastError());
|
||||
}
|
||||
|
||||
iop->scsi_status = pScsiIO->ScsiStatus;
|
||||
if (SCSI_STATUS_CHECK_CONDITION & iop->scsi_status) {
|
||||
int slen = sizeof(pRequestSenseIO) + 8;
|
||||
if (slen > (int)sizeof(pRequestSenseIO))
|
||||
slen = sizeof(pRequestSenseIO);
|
||||
if (slen > (int)iop->max_sense_len)
|
||||
slen = (int)iop->max_sense_len;
|
||||
memcpy(iop->sensep, pRequestSenseIO, slen);
|
||||
iop->resp_sense_len = slen;
|
||||
if (report) {
|
||||
if (report > 1) {
|
||||
pout(" >>> Sense buffer, len=%d:\n", slen);
|
||||
dStrHex(iop->sensep, slen , 1);
|
||||
}
|
||||
if ((iop->sensep[0] & 0x7f) > 0x71)
|
||||
pout(" status=%x: [desc] sense_key=%x asc=%x ascq=%x\n",
|
||||
iop->scsi_status, iop->sensep[1] & 0xf,
|
||||
iop->sensep[2], iop->sensep[3]);
|
||||
else
|
||||
pout(" status=%x: sense_key=%x asc=%x ascq=%x\n",
|
||||
iop->scsi_status, iop->sensep[2] & 0xf,
|
||||
iop->sensep[12], iop->sensep[13]);
|
||||
}
|
||||
}
|
||||
else {
|
||||
iop->resp_sense_len = 0;
|
||||
}
|
||||
|
||||
if (iop->dxfer_dir == DXFER_FROM_DEVICE){
|
||||
memcpy(iop->dxferp,pDataIO, iop->dxfer_len);
|
||||
}
|
||||
if((iop->dxfer_dir == DXFER_FROM_DEVICE) && (report > 1)){
|
||||
int trunc = (iop->dxfer_len > 256) ? 1 : 0;
|
||||
pout(" Incoming data, len=%d, resid=%d%s:\n", (int)iop->dxfer_len, iop->resid,
|
||||
(trunc ? " [only first 256 bytes shown]" : ""));
|
||||
dStrHex((CHAR*)pDataIO, (trunc ? 256 : (int)(iop->dxfer_len)) , 1);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
|
@ -13,7 +13,11 @@
|
||||
; You should have received a copy of the GNU General Public License
|
||||
; (for example COPYING); If not, see <http://www.gnu.org/licenses/>.
|
||||
;
|
||||
<<<<<<< HEAD
|
||||
; $Id: installer.nsi 4174 2015-11-22 16:19:29Z chrfranke $
|
||||
=======
|
||||
; $Id: installer.nsi 4072 2015-04-28 20:35:15Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
;
|
||||
|
||||
|
||||
@ -717,6 +721,7 @@ Function AddToPath
|
||||
System::Call "advapi32::RegQueryValueEx(i $3, t'PATH', i 0, i 0, t.r1, *i ${NSIS_MAX_STRLEN} r2) i.r4"
|
||||
System::Call "advapi32::RegCloseKey(i $3)"
|
||||
|
||||
<<<<<<< HEAD
|
||||
${If} $4 = 234 ; ERROR_MORE_DATA
|
||||
DetailPrint "AddToPath: original length $2 > ${NSIS_MAX_STRLEN}"
|
||||
MessageBox MB_OK "PATH not updated, original length $2 > ${NSIS_MAX_STRLEN}" /SD IDOK
|
||||
@ -730,6 +735,18 @@ Function AddToPath
|
||||
${EndIf}
|
||||
StrCpy $1 ""
|
||||
${EndIf}
|
||||
=======
|
||||
IntCmp $4 234 0 +4 +4 ; $4 == ERROR_MORE_DATA
|
||||
DetailPrint "AddToPath: original length $2 > ${NSIS_MAX_STRLEN}"
|
||||
MessageBox MB_OK "PATH not updated, original length $2 > ${NSIS_MAX_STRLEN}"
|
||||
Goto done
|
||||
|
||||
IntCmp $4 0 +5 ; $4 != NO_ERROR
|
||||
IntCmp $4 2 +3 ; $4 != ERROR_FILE_NOT_FOUND
|
||||
DetailPrint "AddToPath: unexpected error code $4"
|
||||
Goto done
|
||||
StrCpy $1 ""
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
; Check if already in PATH
|
||||
Push "$1;"
|
||||
@ -748,11 +765,18 @@ Function AddToPath
|
||||
StrLen $3 $1
|
||||
IntOp $2 $2 + $3
|
||||
IntOp $2 $2 + 2 ; $2 = strlen(dir) + strlen(PATH) + sizeof(";")
|
||||
<<<<<<< HEAD
|
||||
${If} $2 > ${NSIS_MAX_STRLEN}
|
||||
DetailPrint "AddToPath: new length $2 > ${NSIS_MAX_STRLEN}"
|
||||
MessageBox MB_OK "PATH not updated, new length $2 > ${NSIS_MAX_STRLEN}." /SD IDOK
|
||||
Goto done
|
||||
${EndIf}
|
||||
=======
|
||||
IntCmp $2 ${NSIS_MAX_STRLEN} +4 +4 0
|
||||
DetailPrint "AddToPath: new length $2 > ${NSIS_MAX_STRLEN}"
|
||||
MessageBox MB_OK "PATH not updated, new length $2 > ${NSIS_MAX_STRLEN}."
|
||||
Goto done
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
; Append dir to PATH
|
||||
DetailPrint "Add to PATH: $0"
|
||||
|
15
scsiata.cpp
15
scsiata.cpp
@ -62,7 +62,11 @@
|
||||
#include "dev_ata_cmd_set.h" // ata_device_with_command_set
|
||||
#include "dev_tunnelled.h" // tunnelled_device<>
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * scsiata_cpp_cvsid = "$Id: scsiata.cpp 4276 2016-04-02 19:13:39Z chrfranke $";
|
||||
=======
|
||||
const char * scsiata_cpp_cvsid = "$Id: scsiata.cpp 4041 2015-03-14 00:50:20Z dpgilbert $";
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
/* This is a slightly stretched SCSI sense "descriptor" format header.
|
||||
The addition is to allow the 0x70 and 0x71 response codes. The idea
|
||||
@ -394,6 +398,7 @@ bool sat_device::ata_pass_through(const ata_cmd_in & in, ata_cmd_out & out)
|
||||
}
|
||||
scsi_do_sense_disect(&io_hdr, &sinfo);
|
||||
int status = scsiSimpleSenseFilter(&sinfo);
|
||||
<<<<<<< HEAD
|
||||
|
||||
// Workaround for bogus sense_key in sense data with SAT ATA Return Descriptor
|
||||
if ( status && ck_cond && ardp && ard_len > 13
|
||||
@ -404,6 +409,8 @@ bool sat_device::ata_pass_through(const ata_cmd_in & in, ata_cmd_out & out)
|
||||
status = 0;
|
||||
}
|
||||
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
if (0 != status) { /* other than no_sense and recovered_error */
|
||||
if (scsi_debugmode > 0) {
|
||||
pout("sat_device::ata_pass_through: scsi error: %s\n",
|
||||
@ -443,8 +450,12 @@ bool sat_device::ata_pass_through(const ata_cmd_in & in, ata_cmd_out & out)
|
||||
}
|
||||
} else if ((! sense_descriptor) &&
|
||||
(0 == ssh.asc) &&
|
||||
<<<<<<< HEAD
|
||||
(SCSI_ASCQ_ATA_PASS_THROUGH == ssh.ascq) &&
|
||||
(0 != io_hdr.sensep[4] /* Some ATA STATUS bit must be set */)) {
|
||||
=======
|
||||
(SCSI_ASCQ_ATA_PASS_THROUGH == ssh.ascq)) {
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
/* in SAT-2 and later, ATA registers may be passed back via
|
||||
* fixed format sense data [ref: sat3r07 section 12.2.2.7] */
|
||||
ata_out_regs & lo = out.out_regs;
|
||||
@ -1545,6 +1556,10 @@ ata_device * smart_interface::get_sat_device(const char * type, scsi_device * sc
|
||||
satdev = new usbprolific_device(this, scsidev, type);
|
||||
}
|
||||
|
||||
else if (!strcmp(type, "usbprolific")) {
|
||||
return new usbprolific_device(this, scsidev, type);
|
||||
}
|
||||
|
||||
else if (!strcmp(type, "usbsunplus")) {
|
||||
satdev = new usbsunplus_device(this, scsidev, type);
|
||||
}
|
||||
|
10
scsicmds.cpp
10
scsicmds.cpp
@ -5,7 +5,13 @@
|
||||
*
|
||||
* Copyright (C) 2002-8 Bruce Allen
|
||||
* Copyright (C) 1999-2000 Michael Cornwell <cornwell@acm.org>
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2003-16 Douglas Gilbert <dgilbert@interlog.com>
|
||||
=======
|
||||
*
|
||||
* Additional SCSI work:
|
||||
* Copyright (C) 2003-15 Douglas Gilbert <dgilbert@interlog.com>
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
*
|
||||
* 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
|
||||
@ -47,7 +53,11 @@
|
||||
#include "dev_interface.h"
|
||||
#include "utility.h"
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char *scsicmds_c_cvsid="$Id: scsicmds.cpp 4243 2016-03-20 18:29:36Z chrfranke $"
|
||||
=======
|
||||
const char *scsicmds_c_cvsid="$Id: scsicmds.cpp 4081 2015-05-10 16:42:50Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
SCSICMDS_H_CVSID;
|
||||
|
||||
// Print SCSI debug messages?
|
||||
|
@ -5,6 +5,11 @@
|
||||
*
|
||||
* Copyright (C) 2002-8 Bruce Allen
|
||||
* Copyright (C) 2000 Michael Cornwell <cornwell@acm.org>
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
*
|
||||
* Additional SCSI work:
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
* Copyright (C) 2003-15 Douglas Gilbert <dgilbert@interlog.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@ -30,7 +35,11 @@
|
||||
#ifndef SCSICMDS_H_
|
||||
#define SCSICMDS_H_
|
||||
|
||||
<<<<<<< HEAD
|
||||
#define SCSICMDS_H_CVSID "$Id: scsicmds.h 4152 2015-10-17 16:08:21Z chrfranke $\n"
|
||||
=======
|
||||
#define SCSICMDS_H_CVSID "$Id: scsicmds.h 4081 2015-05-10 16:42:50Z chrfranke $\n"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
|
@ -40,7 +40,11 @@
|
||||
|
||||
#define GBUF_SIZE 65535
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * scsiprint_c_cvsid = "$Id: scsiprint.cpp 4292 2016-04-12 23:06:59Z dpgilbert $"
|
||||
=======
|
||||
const char * scsiprint_c_cvsid = "$Id: scsiprint.cpp 4040 2015-03-10 22:30:44Z dpgilbert $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
SCSIPRINT_H_CVSID;
|
||||
|
||||
|
||||
|
@ -1,8 +1,14 @@
|
||||
.ig
|
||||
Copyright (C) 2002-10 Bruce Allen
|
||||
<<<<<<< HEAD
|
||||
Copyright (C) 2004-16 Christian Franke
|
||||
|
||||
$Id: smartctl.8.in 4311 2016-04-27 21:03:01Z chrfranke $
|
||||
=======
|
||||
Copyright (C) 2004-15 Christian Franke
|
||||
|
||||
$Id: smartctl.8.in 4099 2015-05-30 17:32:13Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
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
|
||||
@ -134,6 +140,7 @@ scsi controller "\\\\.\\Scsi[0\-9]:".
|
||||
|
||||
For SATA or SAS disks behind an Areca controller use
|
||||
\fB"/dev/arcmsr[0\-9]"\fP, see \'\-d areca,N[/E]\' below.
|
||||
<<<<<<< HEAD
|
||||
|
||||
[NEW EXPERIMENTAL SMARTCTL FEATURE]
|
||||
Use the forms \fB"/dev/nvme[0\-9]"\fP (broadcast namespace) or
|
||||
@ -141,6 +148,8 @@ Use the forms \fB"/dev/nvme[0\-9]"\fP (broadcast namespace) or
|
||||
second, ..., NVMe device.
|
||||
Alternatively use the forms \fB"/dev/nvmes[0\-9][n[1\-9]]"\fP for NVMe devices
|
||||
behind the logical scsi controller "\\\\.\\Scsi[0\-9]:".
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
The prefix \fB"/dev/"\fP is optional.
|
||||
.\" %ENDIF OS Windows Cygwin
|
||||
@ -995,6 +1004,7 @@ Please note that the TapeAlert log page flags are cleared for the initiator
|
||||
when the page is read.
|
||||
This means that each alert condition is reported only once by \fBsmartctl\fP
|
||||
for each initiator for each activation of the condition.
|
||||
<<<<<<< HEAD
|
||||
.\" %IF OS FreeBSD Linux Windows Cygwin
|
||||
|
||||
[NVMe] [FreeBSD, Linux, Windows and Cygwin only]
|
||||
@ -1002,6 +1012,8 @@ for each initiator for each activation of the condition.
|
||||
NVMe status is obtained by reading the "Critical Warning" byte from
|
||||
the SMART/Health Information log.
|
||||
.\" %ENDIF OS FreeBSD Linux Windows Cygwin
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
.TP
|
||||
.B \-c, \-\-capabilities
|
||||
[ATA] Prints only the generic SMART capabilities. These
|
||||
@ -2104,6 +2116,7 @@ browser.
|
||||
.SH EXAMPLES
|
||||
.nf
|
||||
.B smartctl \-a /dev/sda
|
||||
<<<<<<< HEAD
|
||||
.fi
|
||||
Print a large amount of SMART information for drive /dev/sda .
|
||||
.PP
|
||||
@ -2115,6 +2128,19 @@ Disable SMART monitoring and data log collection on drive /dev/sdd .
|
||||
.nf
|
||||
.B smartctl \-\-smart=on \-\-offlineauto=on \-\-saveauto=on /dev/sda
|
||||
.fi
|
||||
=======
|
||||
.fi
|
||||
Print a large amount of SMART information for drive /dev/sda .
|
||||
.PP
|
||||
.nf
|
||||
.B smartctl \-s off /dev/sdd
|
||||
.fi
|
||||
Disable SMART monitoring and data log collection on drive /dev/sdd .
|
||||
.PP
|
||||
.nf
|
||||
.B smartctl \-\-smart=on \-\-offlineauto=on \-\-saveauto=on /dev/sda
|
||||
.fi
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
Enable SMART on drive /dev/sda, enable automatic offline
|
||||
testing every four hours, and enable autosaving of
|
||||
SMART Attributes. This is a good start-up line for your system\'s
|
||||
@ -2358,4 +2384,8 @@ Links to these and other documents may be found on the Links page of the
|
||||
.SH PACKAGE VERSION
|
||||
CURRENT_SVN_VERSION CURRENT_SVN_DATE CURRENT_SVN_REV
|
||||
.br
|
||||
<<<<<<< HEAD
|
||||
$Id: smartctl.8.in 4311 2016-04-27 21:03:01Z chrfranke $
|
||||
=======
|
||||
$Id: smartctl.8.in 4099 2015-05-30 17:32:13Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
@ -4,7 +4,11 @@
|
||||
* Home page of code is: http://www.smartmontools.org
|
||||
*
|
||||
* Copyright (C) 2002-11 Bruce Allen
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2008-16 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2008-15 Christian Franke
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
* Copyright (C) 2000 Michael Cornwell <cornwell@acm.org>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@ -52,7 +56,11 @@
|
||||
#include "smartctl.h"
|
||||
#include "utility.h"
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * smartctl_cpp_cvsid = "$Id: smartctl.cpp 4311 2016-04-27 21:03:01Z chrfranke $"
|
||||
=======
|
||||
const char * smartctl_cpp_cvsid = "$Id: smartctl.cpp 4080 2015-05-05 20:31:22Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
CONFIG_H_CVSID SMARTCTL_H_CVSID;
|
||||
|
||||
// Globals to control printing
|
||||
|
22
smartd.8.in
22
smartd.8.in
@ -1,8 +1,14 @@
|
||||
.ig
|
||||
Copyright (C) 2002-10 Bruce Allen
|
||||
<<<<<<< HEAD
|
||||
Copyright (C) 2004-16 Christian Franke
|
||||
|
||||
$Id: smartd.8.in 4299 2016-04-16 19:45:57Z chrfranke $
|
||||
=======
|
||||
Copyright (C) 2004-15 Christian Franke
|
||||
|
||||
$Id: smartd.8.in 4102 2015-06-01 19:25:47Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
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
|
||||
@ -735,6 +741,7 @@ optional local drive database (see \'\-B\' option).
|
||||
.\" %ENDIF NOT OS Windows
|
||||
.SH AUTHORS
|
||||
\fBBruce Allen\fP (project initiator),
|
||||
<<<<<<< HEAD
|
||||
.br
|
||||
\fBChristian Franke\fP (project manager, Windows port and all sort of things),
|
||||
.br
|
||||
@ -744,6 +751,17 @@ optional local drive database (see \'\-B\' option).
|
||||
.br
|
||||
\fBGabriele Pohl\fP (wiki & development team support),
|
||||
.br
|
||||
=======
|
||||
.br
|
||||
\fBChristian Franke\fP (project manager, Windows port and all sort of things),
|
||||
.br
|
||||
\fBDouglas Gilbert\fP (SCSI subsystem),
|
||||
.br
|
||||
\fBVolker Kuhlmann\fP (moderator of support and database mailing list),
|
||||
.br
|
||||
\fBGabriele Pohl\fP (wiki & development team support),
|
||||
.br
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
\fBAlex Samorukov\fP (FreeBSD port and more, new Trac wiki).
|
||||
|
||||
Many other individuals have made contributions and corrections,
|
||||
@ -793,4 +811,8 @@ Links to these and other documents may be found on the Links page of the
|
||||
.SH PACKAGE VERSION
|
||||
CURRENT_SVN_VERSION CURRENT_SVN_DATE CURRENT_SVN_REV
|
||||
.br
|
||||
<<<<<<< HEAD
|
||||
$Id: smartd.8.in 4299 2016-04-16 19:45:57Z chrfranke $
|
||||
=======
|
||||
$Id: smartd.8.in 4102 2015-06-01 19:25:47Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
@ -2,7 +2,11 @@
|
||||
|
||||
# Home page is: http://www.smartmontools.org
|
||||
|
||||
<<<<<<< HEAD
|
||||
# $Id: smartd.conf 4120 2015-08-27 16:12:21Z samm2 $
|
||||
=======
|
||||
# $Id: smartd.conf 4047 2015-03-22 16:16:24Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
# smartd will re-read the configuration file if it receives a HUP
|
||||
# signal
|
||||
|
@ -1,8 +1,14 @@
|
||||
.ig
|
||||
Copyright (C) 2002-10 Bruce Allen
|
||||
<<<<<<< HEAD
|
||||
Copyright (C) 2004-16 Christian Franke
|
||||
|
||||
$Id: smartd.conf.5.in 4307 2016-04-24 12:37:31Z chrfranke $
|
||||
=======
|
||||
Copyright (C) 2004-15 Christian Franke
|
||||
|
||||
$Id: smartd.conf.5.in 4103 2015-06-01 19:51:18Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
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
|
||||
@ -578,7 +584,11 @@ Directive are \fIon\fP and \fIoff\fP. Also affects SCSI devices.
|
||||
[Please see the \fBsmartctl \-S\fP command-line option.]
|
||||
.TP
|
||||
.B \-H
|
||||
<<<<<<< HEAD
|
||||
[ATA] Check the health status of the disk with the SMART RETURN
|
||||
=======
|
||||
[ATA only] Check the health status of the disk with the SMART RETURN
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
STATUS command.
|
||||
If this command reports a failing health status, then disk
|
||||
failure is predicted in less than 24 hours, and a message at loglevel
|
||||
@ -1518,10 +1528,13 @@ will do the same, but restricts the scan to ATA devices only.
|
||||
will do the same, but only monitors the SMART health status of the
|
||||
devices, (rather than the default \-a, which monitors all SMART
|
||||
properties).
|
||||
<<<<<<< HEAD
|
||||
.br
|
||||
[NEW EXPERIMENTAL SMARTD FEATURE]
|
||||
Multiple \'\-d TYPE\' options may be specified with DEVICESCAN
|
||||
to combine the scan results of more than one TYPE.
|
||||
=======
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
Configuration entries for specific devices may precede the \fBDEVICESCAN\fP entry.
|
||||
For example
|
||||
@ -1613,4 +1626,8 @@ full path of this file.
|
||||
.SH PACKAGE VERSION
|
||||
CURRENT_SVN_VERSION CURRENT_SVN_DATE CURRENT_SVN_REV
|
||||
.br
|
||||
<<<<<<< HEAD
|
||||
$Id: smartd.conf.5.in 4307 2016-04-24 12:37:31Z chrfranke $
|
||||
=======
|
||||
$Id: smartd.conf.5.in 4103 2015-06-01 19:51:18Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
12
smartd.cpp
12
smartd.cpp
@ -5,6 +5,10 @@
|
||||
* Copyright (C) 2008-16 Christian Franke
|
||||
* Copyright (C) 2000 Michael Cornwell <cornwell@acm.org>
|
||||
* Copyright (C) 2008 Oliver Bock <brevilo@users.sourceforge.net>
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
* Copyright (C) 2008-15 Christian Franke <smartmontools-support@lists.sourceforge.net>
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
*
|
||||
* 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
|
||||
@ -100,7 +104,15 @@ typedef int pid_t;
|
||||
#define SIGQUIT_KEYNAME "CONTROL-\\"
|
||||
#endif // _WIN32
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * smartd_cpp_cvsid = "$Id: smartd.cpp 4308 2016-04-24 13:36:10Z chrfranke $"
|
||||
=======
|
||||
#if defined (__SVR4) && defined (__sun)
|
||||
extern "C" int getdomainname(char *, int); // no declaration in header files!
|
||||
#endif
|
||||
|
||||
const char * smartd_cpp_cvsid = "$Id: smartd.cpp 4059 2015-04-18 17:01:31Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
CONFIG_H_CVSID;
|
||||
|
||||
using namespace smartmontools;
|
||||
|
@ -1,8 +1,14 @@
|
||||
.ig
|
||||
Copyright (C) 2013 Hannes von Haugwitz <hannes@vonhaugwitz.com>
|
||||
<<<<<<< HEAD
|
||||
Copyright (C) 2014-16 Christian Franke
|
||||
|
||||
$Id: update-smart-drivedb.8.in 4223 2016-02-26 20:18:40Z chrfranke $
|
||||
=======
|
||||
Copyright (C) 2014-15 Christian Franke <smartmontools-support@lists.sourceforge.net>
|
||||
|
||||
$Id: update-smart-drivedb.8.in 4054 2015-04-15 19:04:49Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
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
|
||||
@ -163,4 +169,8 @@ Alternatively send the info to the smartmontools support mailing list:
|
||||
.SH PACKAGE VERSION
|
||||
CURRENT_SVN_VERSION CURRENT_SVN_DATE CURRENT_SVN_REV
|
||||
.br
|
||||
<<<<<<< HEAD
|
||||
$Id: update-smart-drivedb.8.in 4223 2016-02-26 20:18:40Z chrfranke $
|
||||
=======
|
||||
$Id: update-smart-drivedb.8.in 4054 2015-04-15 19:04:49Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
@ -2,7 +2,11 @@
|
||||
#
|
||||
# smartmontools drive database update script
|
||||
#
|
||||
<<<<<<< HEAD
|
||||
# Copyright (C) 2010-16 Christian Franke
|
||||
=======
|
||||
# Copyright (C) 2010-14 Christian Franke <smartmontools-support@lists.sourceforge.net>
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
#
|
||||
# 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
|
||||
@ -12,7 +16,11 @@
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# (for example COPYING); If not, see <http://www.gnu.org/licenses/>.
|
||||
#
|
||||
<<<<<<< HEAD
|
||||
# $Id: update-smart-drivedb.in 4224 2016-02-26 20:29:24Z chrfranke $
|
||||
=======
|
||||
# $Id: update-smart-drivedb.in 4019 2014-12-06 20:12:50Z chrfranke $
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
#
|
||||
|
||||
set -e
|
||||
@ -353,6 +361,7 @@ fi
|
||||
touch "$DEST.new"
|
||||
chmod 0644 "$DEST.new"
|
||||
|
||||
<<<<<<< HEAD
|
||||
if [ "$smtctl" != "-" ]; then
|
||||
# Check syntax
|
||||
rm -f "$DEST.error"
|
||||
@ -363,6 +372,14 @@ if [ "$smtctl" != "-" ]; then
|
||||
echo "$DEST.error: rejected by $smtctl, probably no longer compatible" >&2
|
||||
exit 1
|
||||
fi
|
||||
=======
|
||||
# Check syntax
|
||||
rm -f "$DEST.error"
|
||||
if "$SMARTCTL" -B "$DEST.new" -P showall >/dev/null; then :; else
|
||||
mv "$DEST.new" "$DEST.error"
|
||||
echo "$DEST.error: rejected by $SMARTCTL, probably no longer compatible" >&2
|
||||
exit 1
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
fi
|
||||
|
||||
# Keep old file if identical, ignore missing Id keyword expansion in new file
|
||||
|
63
utility.cpp
63
utility.cpp
@ -3,8 +3,13 @@
|
||||
*
|
||||
* Home page of code is: http://www.smartmontools.org
|
||||
*
|
||||
<<<<<<< HEAD
|
||||
* Copyright (C) 2002-12 Bruce Allen
|
||||
* Copyright (C) 2008-16 Christian Franke
|
||||
=======
|
||||
* Copyright (C) 2002-12 Bruce Allen <smartmontools-support@lists.sourceforge.net>
|
||||
* Copyright (C) 2008-15 Christian Franke <smartmontools-support@lists.sourceforge.net>
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
* Copyright (C) 2000 Michael Cornwell <cornwell@acm.org>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@ -52,7 +57,11 @@
|
||||
#include "atacmds.h"
|
||||
#include "dev_interface.h"
|
||||
|
||||
<<<<<<< HEAD
|
||||
const char * utility_cpp_cvsid = "$Id: utility.cpp 4309 2016-04-24 14:59:15Z chrfranke $"
|
||||
=======
|
||||
const char * utility_cpp_cvsid = "$Id: utility.cpp 4031 2015-01-01 10:47:48Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
UTILITY_H_CVSID INT64_H_CVSID;
|
||||
|
||||
const char * packet_types[] = {
|
||||
@ -90,7 +99,11 @@ std::string format_version_info(const char * prog_name, bool full /*= false*/)
|
||||
"(build date " __DATE__ ")" // checkout without expansion of Id keywords
|
||||
#endif
|
||||
" [%s] " BUILD_INFO "\n"
|
||||
<<<<<<< HEAD
|
||||
"Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org\n",
|
||||
=======
|
||||
"Copyright (C) 2002-15, Bruce Allen, Christian Franke, www.smartmontools.org\n",
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
prog_name, smi()->get_os_version_str().c_str()
|
||||
);
|
||||
if (!full)
|
||||
@ -624,6 +637,56 @@ int split_selective_arg(char *s, uint64_t *start,
|
||||
return 0;
|
||||
}
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
#ifdef OLD_INTERFACE
|
||||
|
||||
int64_t bytes = 0;
|
||||
|
||||
// Helps debugging. If the second argument is non-negative, then
|
||||
// decrement bytes by that amount. Else decrement bytes by (one plus)
|
||||
// length of null terminated string.
|
||||
void *FreeNonZero(void *address, int size, int /*line*/, const char* /*file*/){
|
||||
if (address) {
|
||||
if (size<0)
|
||||
bytes-=1+strlen((char*)address);
|
||||
else
|
||||
bytes-=size;
|
||||
free(address);
|
||||
}
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// A custom version of strdup() that keeps track of how much memory is
|
||||
// being allocated. If mustexist is set, it also throws an error if we
|
||||
// try to duplicate a NULL string.
|
||||
char *CustomStrDup(const char *ptr, int mustexist, int /*whatline*/, const char* /*file*/){
|
||||
char *tmp;
|
||||
|
||||
// report error if ptr is NULL and mustexist is set
|
||||
if (ptr==NULL){
|
||||
if (mustexist)
|
||||
throw std::runtime_error("Internal error in CustomStrDup()");
|
||||
else
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// make a copy of the string...
|
||||
tmp=strdup(ptr);
|
||||
|
||||
if (!tmp)
|
||||
throw std::bad_alloc();
|
||||
|
||||
// and track memory usage
|
||||
bytes+=1+strlen(ptr);
|
||||
|
||||
return tmp;
|
||||
}
|
||||
|
||||
#endif // OLD_INTERFACE
|
||||
|
||||
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
// Returns true if region of memory contains non-zero entries
|
||||
bool nonempty(const void * data, int size)
|
||||
{
|
||||
|
20
utility.h
20
utility.h
@ -25,7 +25,11 @@
|
||||
#ifndef UTILITY_H_
|
||||
#define UTILITY_H_
|
||||
|
||||
<<<<<<< HEAD
|
||||
#define UTILITY_H_CVSID "$Id: utility.h 4309 2016-04-24 14:59:15Z chrfranke $"
|
||||
=======
|
||||
#define UTILITY_H_CVSID "$Id: utility.h 4028 2014-12-13 14:59:48Z chrfranke $"
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
|
||||
#include <time.h>
|
||||
#include <sys/types.h> // for regex.h (according to POSIX)
|
||||
@ -99,6 +103,22 @@ int split_selective_arg(char *s, uint64_t *start, uint64_t *stop, int *mode);
|
||||
// (exit is not compatible with C++ destructors)
|
||||
#define EXIT(status) { throw (int)(status); }
|
||||
|
||||
<<<<<<< HEAD
|
||||
=======
|
||||
|
||||
#ifdef OLD_INTERFACE
|
||||
|
||||
// Utility function to free memory
|
||||
void *FreeNonZero(void* address, int size, int whatline, const char* file);
|
||||
|
||||
// A custom version of strdup() that keeps track of how much memory is
|
||||
// being allocated. If mustexist is set, it also throws an error if we
|
||||
// try to duplicate a NULL string.
|
||||
char *CustomStrDup(const char *ptr, int mustexist, int whatline, const char* file);
|
||||
|
||||
#endif // OLD_INTERFACE
|
||||
|
||||
>>>>>>> 3d8ad6fa4529eb02ae1391a1e937bf57aad3fb74
|
||||
// Compile time check of byte ordering
|
||||
// (inline const function allows compiler to remove dead code)
|
||||
inline bool isbigendian()
|
||||
|
Loading…
Reference in New Issue
Block a user