]> rtime.felk.cvut.cz Git - frescor/fwp.git/commitdiff
Little modification of my frsh
authorMartin Molnar <molnar@sum.(none)>
Tue, 8 Jul 2008 18:00:04 +0000 (20:00 +0200)
committerMartin Molnar <molnar@sum.(none)>
Tue, 8 Jul 2008 18:00:04 +0000 (20:00 +0200)
frsh/frsh_contract.h
frsh/frsh_resource.h

index 421fc7ebf55e06c7608ab28f356baed37b9b1e8d..0483dd2ae7df150e68d690ad62bd6015319ce3b9 100644 (file)
@@ -3,22 +3,25 @@
  *
  */
 
-#ifndef _FRSH_CONTRACT_H
-#define _FRSH_CONTRACT_H
+#ifndef FRSH_CONTRACT_H
+#define FRSH_CONTRACT_H
 
-typedef struct frsh_contract {
+typedef struct frsh_contract_params {
        frsh_budget_t   budget;
        frsh_period_t   period;
-}
+} frsh_contract_params_t;
 
 typedef frsh_contract_t* frsh_contract_d_t;
 
 typedef struct frsh_contract_ops {
-       frsh_contract_t* (*create)(frsh_resource_t* resource);
-       int              (*reserve)(frsh_contract_t* contract);
-       int              (*commit)(frsh_contract_t* contract);
-       /* just for compability, combination of previous */
-       int              (*negotiate)(frsh_contract_t* contract);
+       /*frsh_contract_d_t* (*create)(frsh_resource_t* resource);*/
+       int (*reserve)(frsh_contract_params_t* params, 
+                               frsh_contract_d_t* contractdp);
+       int (*commit)(frsh_contract_d_t contractd);
+       /* just for compability, combination of previous functions */
+       int (*negotiate)(frsh_contract_params_t* params, 
+                               frsh_contract_d_t* contractdp);
+       int (*create_vres)(frsh_contract_d_t contractd, frsh_vresd_t* vresdp);
 }
 
-#endif /* _FRSH_CONTRACT_H */
+#endif /* FRSH_CONTRACT_H */
index 02d2e2da603674a34d5fee913c85d9f6f368f2d8..b2ea10d10e42ae6001a81f910f646247f6a1153b 100644 (file)
@@ -17,7 +17,6 @@ typedef struct frsh_resource_id {
 typedef struct frsh_resource {
        frsh_resource_id_t      id;
        frsh_contract_ops_t     *contract_ops;
-       void                    *fna_ops;
 } frsh_resource_t;
 
 /* Resource descriptor