Changeset f14291b in mainline for uspace/srv/fs/fat/fat_ops.c


Ignore:
Timestamp:
2010-10-19T20:55:53Z (14 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
a93d79a
Parents:
1882525 (diff), a7a85d16 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/fs/fat/fat_ops.c

    r1882525 rf14291b  
    15271527void fat_sync(ipc_callid_t rid, ipc_call_t *request)
    15281528{
    1529         /* Dummy implementation */
    1530         ipc_answer_0(rid, EOK);
     1529        dev_handle_t dev_handle = (dev_handle_t) IPC_GET_ARG1(*request);
     1530        fs_index_t index = (fs_index_t) IPC_GET_ARG2(*request);
     1531       
     1532        fs_node_t *fn;
     1533        int rc = fat_node_get(&fn, dev_handle, index);
     1534        if (rc != EOK) {
     1535                ipc_answer_0(rid, rc);
     1536                return;
     1537        }
     1538        if (!fn) {
     1539                ipc_answer_0(rid, ENOENT);
     1540                return;
     1541        }
     1542       
     1543        fat_node_t *nodep = FAT_NODE(fn);
     1544       
     1545        nodep->dirty = true;
     1546        rc = fat_node_sync(nodep);
     1547       
     1548        fat_node_put(fn);
     1549        ipc_answer_0(rid, rc);
    15311550}
    15321551
Note: See TracChangeset for help on using the changeset viewer.