- XBT_DEBUG("storage_share_resources");
- unsigned int i, j;
- Storage *storage;
- void *_write_action;
- StorageAction *write_action;
-
- double min_completion = shareResourcesMaxMin(getRunningActionSet(),
- maxminSystem_, lmm_solve);
-
- double rate;
- // Foreach disk
- xbt_dynar_foreach(p_storageList,i,storage)
- {
- rate = 0;
- // Foreach write action on disk
- xbt_dynar_foreach(storage->p_writeActions, j, _write_action)
- {
- write_action = static_cast<StorageAction*>(_write_action);
+ double min_completion = StorageModel::nextOccuringEventFull(now);
+
+ for(auto storage: p_storageList) {
+ double rate = 0;
+ // Foreach write action on that disk
+ for (auto write_action: storage->writeActions_) {