Changeset cf7b3e0 in mainline for contrib/arch/uspace/srv/vfs/vfs.bp


Ignore:
Timestamp:
2009-09-16T22:46:58Z (15 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
51d4040
Parents:
57688fe2
Message:

various fixes and cleanup

File:
1 edited

Legend:

Unmodified
Added
Removed
  • contrib/arch/uspace/srv/vfs/vfs.bp

    r57688fe2 rcf7b3e0  
    2121                                                (
    2222                                                        /* root fs */
    23                                                         !fs.mounted ;
    24                                                         !fs.ipc_m_data_write /* mount options */
     23                                                        alternative fs tmpfs fat devfs {
     24                                                                !fs.mounted ;
     25                                                                !fs.ipc_m_data_write /* mount options */
     26                                                        }
    2527                                                ) +
    2628                                                (
    2729                                                        /* non-root fs */
    2830                                                        tentative {
    29                                                                 [fnc.vfs_lookup_internal] ;
    30                                                                 tentative {
    31                                                                         [fnc.vfs_grab_phone] ;
    32                                                                         [fnc.vfs_grab_phone] ;
    33                                                                         !fs.mount ;
    34                                                                         !fs.ipc_m_connection_clone ;
    35                                                                         [fnc.vfs_release_phone] ;
     31                                                                alternative fs tmpfs fat devfs {
     32                                                                        [fnc.vfs_lookup_internal] ;
    3633                                                                        tentative {
    37                                                                                 !fs.vfs_m_data_write /* mount options */
    38                                                                         } ;
    39                                                                         [fnc.vfs_release_phone]
     34                                                                                [fnc.vfs_grab_phone] ;
     35                                                                                [fnc.vfs_grab_phone] ;
     36                                                                                !fs.mount ;
     37                                                                                !fs.ipc_m_connection_clone ;
     38                                                                                [fnc.vfs_release_phone] ;
     39                                                                                tentative {
     40                                                                                        !fs.vfs_m_data_write /* mount options */
     41                                                                                } ;
     42                                                                                [fnc.vfs_release_phone]
     43                                                                        }
    4044                                                                }
    4145                                                        }
     
    5155                        ?ipc_m_data_write /* path */ ;
    5256                        tentative {
    53                                 [fnc.vfs_lookup_internal] ;
    54                                 tentative {
     57                                alternative fs tmpfs fat devfs {
     58                                        [fnc.vfs_lookup_internal] ;
     59                                        tentative {
     60                                                [fnc.vfs_grab_phone] ;
     61                                                !fs.truncate ;
     62                                                [fnc.vfs_release_phone]
     63                                        }
     64                                }
     65                        }
     66                }
     67        } +
     68       
     69        ?open_node {
     70                alternative fs tmpfs fat devfs {
     71                        [fnc.vfs_open_node_internal] ;
     72                        tentative {
     73                                [fnc.vfs_grab_phone] ;
     74                                !fs.truncate ;
     75                                [fnc.vfs_release_phone]
     76                        }
     77                }
     78        } +
     79       
     80        ?close {
     81                tentative {
     82                        alternative fs tmpfs fat devfs {
     83                                [fnc.vfs_grab_phone] ;
     84                                !fs.close ;
     85                                [fnc.vfs_release_phone]
     86                        }
     87                }
     88        } +
     89       
     90        ?read {
     91                tentative {
     92                        ?ipc_m_data_read {
     93                                alternative fs tmpfs fat devfs {
    5594                                        [fnc.vfs_grab_phone] ;
    56                                         !fs.truncate ;
     95                                        !fs.read ;
     96                                        !fs.ipc_m_data_read /* forward payload */ ;
    5797                                        [fnc.vfs_release_phone]
    5898                                }
     
    61101        } +
    62102       
    63         ?open_node {
    64                 [fnc.vfs_open_node_internal] ;
    65                 tentative {
    66                         [fnc.vfs_grab_phone] ;
    67                         !fs.truncate ;
    68                         [fnc.vfs_release_phone]
    69                 }
    70         } +
    71        
    72         ?close {
    73                 tentative {
    74                         [fnc.vfs_grab_phone] ;
    75                         !fs.close ;
    76                         [fnc.vfs_release_phone]
    77                 }
    78         } +
    79        
    80         ?read {
    81                 tentative {
    82                         ?ipc_m_data_read {
     103        ?write {
     104                tentative {
     105                        ?ipc_m_data_write {
     106                                alternative fs tmpfs fat devfs {
     107                                        [fnc.vfs_grab_phone] ;
     108                                        !fs.write ;
     109                                        !fs.ipc_m_data_write /* forward payload */ ;
     110                                        [fnc.vfs_release_phone]
     111                                }
     112                        }
     113                }
     114        } +
     115       
     116        ?truncate {
     117                tentative {
     118                        alternative fs tmpfs fat devfs {
    83119                                [fnc.vfs_grab_phone] ;
    84                                 !fs.read ;
    85                                 !fs.ipc_m_data_read /* forward payload */ ;
     120                                !fs.truncate ;
    86121                                [fnc.vfs_release_phone]
    87122                        }
     
    89124        } +
    90125       
    91         ?write {
    92                 tentative {
    93                         ?ipc_m_data_write {
    94                                 [fnc.vfs_grab_phone] ;
    95                                 !fs.write ;
    96                                 !fs.ipc_m_data_write /* forward payload */ ;
    97                                 [fnc.vfs_release_phone]
    98                         }
    99                 }
    100         } +
    101        
    102         ?truncate {
    103                 tentative {
    104                         [fnc.vfs_grab_phone] ;
    105                         !fs.truncate ;
    106                         [fnc.vfs_release_phone]
    107                 }
    108         } +
    109        
    110126        ?fstat {
    111127                tentative {
    112128                        ?ipc_m_data_read /* struct stat */ {
    113                                 [fnc.vfs_grab_phone] ;
    114                                 !fs.stat ;
    115                                 !fs.ipc_m_data_read /* forward struct stat */ ;
    116                                 [fnc.vfs_release_phone]
     129                                alternative fs tmpfs fat devfs {
     130                                        [fnc.vfs_grab_phone] ;
     131                                        !fs.stat ;
     132                                        !fs.ipc_m_data_read /* forward struct stat */ ;
     133                                        [fnc.vfs_release_phone]
     134                                }
    117135                        }
    118136                }
     
    123141                tentative {
    124142                        ?ipc_m_data_read /* struct stat */ {
    125                                 [fnc.vfs_lookup_internal] ;
    126                                 tentative {
    127                                         !fs.stat ;
    128                                         !fs.ipc_m_data_read /* forward struct stat */
     143                                alternative fs tmpfs fat devfs {
     144                                        [fnc.vfs_lookup_internal] ;
     145                                        tentative {
     146                                                !fs.stat ;
     147                                                !fs.ipc_m_data_read /* forward struct stat */
     148                                        }
    129149                                }
    130150                        }
     
    135155                ?ipc_m_data_write /* path */ ;
    136156                tentative {
    137                         [fnc.vfs_lookup_internal]
     157                        alternative fs tmpfs fat devfs {
     158                                [fnc.vfs_lookup_internal]
     159                        }
    138160                }
    139161        } +
     
    142164                ?ipc_m_data_write /* path */ ;
    143165                tentative {
    144                         [fnc.vfs_lookup_internal]
     166                        alternative fs tmpfs fat devfs {
     167                                [fnc.vfs_lookup_internal]
     168                        }
    145169                }
    146170        } +
     
    151175                        ?ipc_m_data_write /* new path */ ;
    152176                        tentative {
    153                                 [fnc.vfs_lookup_internal] /* lookup old path */ ;
    154                                 tentative {
    155                                         [fnc.vfs_lookup_internal] /* lookup parent of new path */ ;
    156                                         tentative {
    157                                                 [fnc.vfs_lookup_internal] /* destroy old link for the new path */ ;
     177                                alternative fs tmpfs fat devfs {
     178                                        [fnc.vfs_lookup_internal] /* lookup old path */ ;
     179                                        tentative {
     180                                                [fnc.vfs_lookup_internal] /* lookup parent of new path */ ;
    158181                                                tentative {
    159                                                         [fnc.vfs_lookup_internal] /* create new link for the new path */ ;
     182                                                        [fnc.vfs_lookup_internal] /* destroy old link for the new path */ ;
    160183                                                        tentative {
    161                                                                 [fnc.vfs_lookup_internal] /* destroy link for the old path */
     184                                                                [fnc.vfs_lookup_internal] /* create new link for the new path */ ;
     185                                                                tentative {
     186                                                                        [fnc.vfs_lookup_internal] /* destroy link for the old path */
     187                                                                }
    162188                                                        }
    163189                                                }
     
    170196        ?sync {
    171197                tentative {
    172                         !fs.sync
     198                        alternative fs tmpfs fat devfs {
     199                                !fs.sync
     200                        }
    173201                }
    174202        } +
Note: See TracChangeset for help on using the changeset viewer.