mirror of
https://github.com/amadvance/snapraid.git
synced 2026-10-26 19:01:57 -04:00
Before spinning down flush all the disk caches
This commit is contained in:
parent
906d215bf5
commit
47c0f3b8ae
1 changed files with 5 additions and 0 deletions
|
|
@ -1548,6 +1548,11 @@ int devquery(tommy_list* high, tommy_list* low, int operation, int others)
|
|||
{
|
||||
void* (*func)(void* arg) = 0;
|
||||
|
||||
if (operation == DEVICE_DOWN) {
|
||||
/* flush all the disk caches before spinning down */
|
||||
sync();
|
||||
}
|
||||
|
||||
#if HAVE_LINUX_DEVICE
|
||||
tommy_node* i;
|
||||
struct stat st;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue