@cryptotaxi247 / netdata-1 / commits / c92057221

diskstats use a sector size of 512 bytes only; fixes #3481

Costa Tsaousis (ktsaou) committed Feb 27, 2018 at 21:03 UTC c9205722134672a691f1703ce43ff3471a041ff5
1 file changed +4
src/proc_diskstats.c
+4
@@ -263,6 +263,9 @@ static struct disk *get_disk(unsigned long major, unsigned long minor, char *dis
263 // ------------------------------------------------------------------------
264 // find the disk sector size
265
266 + /*
267 + * sector size is always 512 bytes inside the kernel #3481
268 + *
269 {
270 char tf[FILENAME_MAX + 1], *t;
271 strncpyz(tf, d->device, FILENAME_MAX);
@@ -294,6 +297,7 @@ static struct disk *get_disk(unsigned long major, unsigned long minor, char *dis
297 }
298 else error("Cannot read sector size for device %s from %s. Assuming 512.", d->device, buffer);
299 }
300 + */
301
302 return d;
303 }