From a720d9e5c87511d93077f86d4fac2ed3d563bc06 Mon Sep 17 00:00:00 2001 From: russell Date: Fri, 13 Jun 2008 12:45:50 +0000 Subject: Merge changes from timing branch - Convert chan_iax2 to use the timing API - Convert usage of timing in the core to use the timing API instead of using DAHDI directly - Make a change to the timing API to add the set_rate() function - change the timing core to use a rwlock - merge a timing implementation, res_timing_dahdi Basic testing was successful using res_timing_dahdi git-svn-id: http://svn.digium.com/svn/asterisk/trunk@122523 f38db490-d61c-443f-a65b-d21fe96a405b --- main/asterisk.c | 30 +----------------------------- 1 file changed, 1 insertion(+), 29 deletions(-) (limited to 'main/asterisk.c') diff --git a/main/asterisk.c b/main/asterisk.c index 5651bbd68..0474d6375 100644 --- a/main/asterisk.c +++ b/main/asterisk.c @@ -3299,35 +3299,7 @@ int main(int argc, char *argv[]) printf("%s", term_quit()); exit(1); } -#ifdef HAVE_DAHDI - { - int fd; - int x = 160; - fd = open("/dev/dahdi/timer", O_RDWR); - if (fd >= 0) { - if (ioctl(fd, DAHDI_TIMERCONFIG, &x)) { - ast_log(LOG_ERROR, "You have DAHDI built and drivers loaded, but the DAHDI timer test failed to set DAHDI_TIMERCONFIG to %d.\n", x); - exit(1); - } - if ((x = ast_wait_for_input(fd, 300)) < 0) { - ast_log(LOG_ERROR, "You have DAHDI built and drivers loaded, but the DAHDI timer could not be polled during the DAHDI timer test.\n"); - exit(1); - } - if (!x) { - const char dahdi_timer_error[] = { - "Asterisk has detected a problem with your DAHDI configuration and will shutdown for your protection. You have options:" - "\n\t1. You only have to compile DAHDI support into Asterisk if you need it. One option is to recompile without DAHDI support." - "\n\t2. You only have to load DAHDI drivers if you want to take advantage of DAHDI services. One option is to unload DAHDI modules if you don't need them." - "\n\t3. If you need DAHDI services, you must correctly configure DAHDI." - }; - ast_log(LOG_ERROR, "%s\n", dahdi_timer_error); - usleep(100); - exit(1); - } - close(fd); - } - } -#endif + threadstorage_init(); astobj2_init(); -- cgit v1.2.3