add guts for zt

git-svn-id: http://svn.openzap.org/svn/openzap/trunk@185 a93c3328-9c30-0410-af19-c9cd2b2d52af
This commit is contained in:
Anthony Minessale
2007-05-30 01:01:32 +00:00
parent 77634068da
commit a04655dce5
10 changed files with 405 additions and 43 deletions

View File

@@ -166,7 +166,7 @@ hashtable_count(struct hashtable *h);
*/
void
hashtable_destroy(struct hashtable *h, int free_values);
hashtable_destroy(struct hashtable *h, int free_keys, int free_values);
#endif /* __HASHTABLE_CWC22_H__ */

View File

@@ -46,6 +46,7 @@ typedef int zap_socket_t;
#endif
typedef size_t zap_size_t;
typedef ssize_t zap_ssize_t;
struct zap_io_interface;
#define ZAP_COMMAND_OBJ_INT *((int *)obj)

View File

@@ -34,6 +34,8 @@
#ifndef ZAP_ZT_H
#define ZAP_ZT_H
#include "openzap.h"
#include <sys/ioctl.h>
#include <poll.h>
/* Hardware interface structures and defines */
/* Based on documentation of the structures required for the hardware interface */
@@ -69,6 +71,8 @@ struct zt_params {
int pulse_after_time;
};
typedef struct zt_params zt_params_t;
/* Used with ioctl: ZT_CONFLINK, ZT_GETCONF and ZT_SETCONF */
struct zt_confinfo {
int chan_no; /* Channel Number, 0 for current */
@@ -164,13 +168,13 @@ typedef enum {
ZT_RINGOFF = 6
} zt_hookstate_t;
typedef enum {
ZT_MAINT_NONE = 0, /* Normal Mode */
ZT_MAINT_LOCALLOOP = 1, /* Local Loopback */
ZT_MAINT_REMOTELOOP = 2, /* Remote Loopback */
ZT_MAINT_LOOPUP = 3, /* Send Loopup Code */
ZT_MAINT_LOOPDOWN = 4, /* Send Loopdown Code */
ZT_MAINT_LOOPSTOP = 5, /* Stop Sending Loop Codes */
typedef enum {
ZT_MAINT_NONE = 0, /* Normal Mode */
ZT_MAINT_LOCALLOOP = 1, /* Local Loopback */
ZT_MAINT_REMOTELOOP = 2, /* Remote Loopback */
ZT_MAINT_LOOPUP = 3, /* Send Loopup Code */
ZT_MAINT_LOOPDOWN = 4, /* Send Loopdown Code */
ZT_MAINT_LOOPSTOP = 5 /* Stop Sending Loop Codes */
} zt_maintenance_mode_t;