From: Martin Molnar Date: Tue, 8 Jul 2008 18:00:04 +0000 (+0200) Subject: Little modification of my frsh X-Git-Url: http://rtime.felk.cvut.cz/gitweb/frescor/fwp.git/commitdiff_plain/4f0d61cb40fde6f975af705cb2ce6dd815f88c55 Little modification of my frsh --- diff --git a/frsh/frsh_contract.h b/frsh/frsh_contract.h index 421fc7e..0483dd2 100644 --- a/frsh/frsh_contract.h +++ b/frsh/frsh_contract.h @@ -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 */ diff --git a/frsh/frsh_resource.h b/frsh/frsh_resource.h index 02d2e2d..b2ea10d 100644 --- a/frsh/frsh_resource.h +++ b/frsh/frsh_resource.h @@ -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