Tor  0.4.7.0-alpha-dev
cpuworker.h
Go to the documentation of this file.
1 /* Copyright (c) 2001 Matej Pfajfar.
2  * Copyright (c) 2001-2004, Roger Dingledine.
3  * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
4  * Copyright (c) 2007-2021, The Tor Project, Inc. */
5 /* See LICENSE for licensing information */
6 
7 /**
8  * \file cpuworker.h
9  * \brief Header file for cpuworker.c.
10  **/
11 
12 #ifndef TOR_CPUWORKER_H
13 #define TOR_CPUWORKER_H
14 
15 void cpu_init(void);
16 void cpuworkers_rotate_keyinfo(void);
17 struct workqueue_entry_t;
21  enum workqueue_priority_t priority,
22  enum workqueue_reply_t (*fn)(void *, void *),
23  void (*reply_fn)(void *),
24  void *arg));
25 
26 struct create_cell_t;
28  struct create_cell_t *onionskin);
29 
30 uint64_t estimated_usec_for_onionskins(uint32_t n_requests,
31  uint16_t onionskin_type);
32 void cpuworker_log_onionskin_overhead(int severity, int onionskin_type,
33  const char *onionskin_type_name);
35 
36 #endif /* !defined(TOR_CPUWORKER_H) */
37 
void cpuworker_cancel_circ_handshake(or_circuit_t *circ)
Definition: cpuworker.c:581
void cpu_init(void)
Definition: cpuworker.c:83
int assign_onionskin_to_cpuworker(or_circuit_t *circ, struct create_cell_t *onionskin)
Definition: cpuworker.c:513
void cpuworker_log_onionskin_overhead(int severity, int onionskin_type, const char *onionskin_type_name)
Definition: cpuworker.c:292
void cpuworkers_rotate_keyinfo(void)
Definition: cpuworker.c:188
struct workqueue_entry_t * cpuworker_queue_work(enum workqueue_priority_t priority, enum workqueue_reply_t(*fn)(void *, void *), void(*reply_fn)(void *), void *arg)
Definition: cpuworker.c:496
uint64_t estimated_usec_for_onionskins(uint32_t n_requests, uint16_t onionskin_type)
Definition: cpuworker.c:244
uint8_t onionskin[CELL_PAYLOAD_SIZE - 4]
Definition: onion.h:32
Definition: workqueue.c:95
#define MOCK_DECL(rv, funcname, arglist)
Definition: testsupport.h:127
workqueue_reply_t
Definition: workqueue.h:24
workqueue_priority_t
Definition: workqueue.h:31