Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stick to the SMART values mentioned in the FAQ for failure probability calculation #17

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
70 changes: 0 additions & 70 deletions cmdline/device.c
Original file line number Diff line number Diff line change
Expand Up @@ -241,70 +241,6 @@ static double SMART_188_R[SMART_MEASURES] = {
1.3731,
};

/*
* Divider for SMART attribute 193
*/
static unsigned SMART_193_STEP = 649;

/*
* Failure rate for 30 days, for a disk
* with SMART attribute 193 at a given value.
*/
static double SMART_193_R[SMART_MEASURES] = {
0.0000, 0.0016, 0.0032, 0.0036, 0.0039,
0.0042, 0.0046, 0.0049, 0.0052, 0.0054,
0.0057, 0.0060, 0.0062, 0.0065, 0.0068,
0.0071, 0.0074, 0.0077, 0.0080, 0.0083,
0.0086, 0.0091, 0.0094, 0.0098, 0.0101,
0.0104, 0.0108, 0.0111, 0.0119, 0.0122,
0.0127, 0.0130, 0.0134, 0.0137, 0.0141,
0.0144, 0.0146, 0.0152, 0.0155, 0.0159,
0.0163, 0.0165, 0.0168, 0.0172, 0.0176,
0.0179, 0.0184, 0.0188, 0.0190, 0.0194,
0.0197, 0.0201, 0.0204, 0.0207, 0.0209,
0.0213, 0.0215, 0.0219, 0.0221, 0.0225,
0.0229, 0.0234, 0.0241, 0.0246, 0.0253,
0.0263, 0.0278, 0.0286, 0.0293, 0.0298,
0.0302, 0.0306, 0.0311, 0.0315, 0.0319,
0.0322, 0.0329, 0.0334, 0.0338, 0.0343,
0.0348, 0.0352, 0.0358, 0.0362, 0.0367,
0.0371, 0.0374, 0.0378, 0.0383, 0.0388,
0.0393, 0.0397, 0.0401, 0.0404, 0.0410,
0.0416, 0.0422, 0.0428, 0.0436, 0.0443,
0.0449, 0.0454, 0.0457, 0.0462, 0.0468,
0.0473, 0.0479, 0.0483, 0.0488, 0.0491,
0.0493, 0.0497, 0.0500, 0.0504, 0.0507,
0.0510, 0.0514, 0.0519, 0.0523, 0.0528,
0.0533, 0.0538, 0.0542, 0.0547, 0.0551,
0.0556, 0.0560, 0.0565, 0.0572, 0.0577,
0.0584, 0.0590, 0.0594, 0.0599, 0.0603,
0.0607, 0.0611, 0.0616, 0.0621, 0.0626,
0.0632, 0.0639, 0.0647, 0.0655, 0.0661,
0.0669, 0.0676, 0.0683, 0.0691, 0.0699,
0.0708, 0.0713, 0.0719, 0.0724, 0.0730,
0.0736, 0.0745, 0.0751, 0.0759, 0.0769,
0.0779, 0.0787, 0.0796, 0.0804, 0.0815,
0.0825, 0.0833, 0.0840, 0.0847, 0.0854,
0.0859, 0.0865, 0.0873, 0.0881, 0.0890,
0.0900, 0.0912, 0.0919, 0.0929, 0.0942,
0.0956, 0.0965, 0.0976, 0.0986, 0.0995,
0.1006, 0.1019, 0.1031, 0.1038, 0.1045,
0.1051, 0.1058, 0.1066, 0.1072, 0.1077,
0.1084, 0.1091, 0.1099, 0.1104, 0.1111,
0.1118, 0.1127, 0.1135, 0.1142, 0.1149,
0.1157, 0.1163, 0.1168, 0.1173, 0.1179,
0.1184, 0.1189, 0.1195, 0.1203, 0.1208,
0.1213, 0.1223, 0.1231, 0.1240, 0.1246,
0.1252, 0.1260, 0.1269, 0.1276, 0.1287,
0.1303, 0.1311, 0.1319, 0.1328, 0.1335,
0.1341, 0.1348, 0.1362, 0.1373, 0.1380,
0.1387, 0.1392, 0.1398, 0.1403, 0.1408,
0.1412, 0.1418, 0.1422, 0.1428, 0.1434,
0.1439, 0.1445, 0.1451, 0.1457, 0.1464,
0.1469, 0.1475, 0.1480, 0.1486, 0.1491,
0.1498,
};

/*
* Divider for SMART attribute 197
*/
Expand Down Expand Up @@ -501,12 +437,6 @@ static double smart_afr(uint64_t* smart, const char* model)
afr = r;
}

if (smart[193] != SMART_UNASSIGNED) {
double r = smart_afr_value(SMART_193_R, SMART_193_STEP, smart[193] & mask32);
if (afr < r)
afr = r;
}

if (smart[197] != SMART_UNASSIGNED) {
double r = smart_afr_value(SMART_197_R, SMART_197_STEP, smart[197] & mask32);
if (afr < r)
Expand Down