Lines Matching refs:con

36 	let con = Connection.create xbcon None in
37 Hashtbl.add cons.anonymous (Xenbus.Xb.get_fd xbcon) con
41 let con = Connection.create xbcon (Some dom) in
42 Hashtbl.add cons.domains (Domain.get_id dom) con;
44 | Some p -> Hashtbl.add cons.ports p con;
48 Hashtbl.fold (fun _ con (ins, outs) ->
49 if (only_if con) then (
50 let fd = Connection.get_fd con in
51 (fd :: ins, if Connection.has_output con then fd :: outs else outs)
65 let del_watches_of_con con watches =
66 match List.filter (fun w -> Connection.get_con w != con) watches with
70 let del_anonymous cons con =
72 Hashtbl.remove cons.anonymous (Connection.get_fd con);
73 cons.watches <- Trie.map (del_watches_of_con con) cons.watches;
74 Connection.close con
80 let con = find_domain cons id in
82 (match Connection.get_domain con with
88 cons.watches <- Trie.map (del_watches_of_con con) cons.watches;
89 Connection.close con
104 (fun _id con acc ->
105 if Connection.has_more_work con then con :: acc else acc)
116 let add_watch cons con path token =
117 let apath, watch = Connection.add_watch con path token in
127 let del_watch cons con path token =
128 let apath, watch = Connection.del_watch con path token in
137 let del_watches cons con =
138 Connection.del_watches con;
139 cons.watches <- Trie.map (del_watches_of_con con) cons.watches
160 iter cons (fun con ->
161 List.iter (Connection.fire_single_watch (None, root)) (Connection.get_watches con specpath))
164 let con = find_domain cons domain in
165 Connection.set_target con target_domain
169 let aux con =
170 res := Connection.number_of_transactions con + !res
180 iter_anonymous cons (fun con ->
181 let con_watchs, con_ops = Connection.stats con in
185 iter_domains cons (fun con ->
186 let con_watchs, con_ops = Connection.stats con in
194 let anonymous = Hashtbl.fold (fun _ con accu -> Connection.debug con :: accu) cons.anonymous [] in
195 let domains = Hashtbl.fold (fun _ con accu -> Connection.debug con :: accu) cons.domains [] in