[Home]

Summary:ASTERISK-07424: [patch] hard-safe -> hard-unsafe lock order detected
Reporter:Matthias Urlichs (smurfix)Labels:
Date Opened:2006-07-30 01:59:59Date Closed:2008-06-07 13:48:32
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Core/General
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) 20060730__bug7620.diff.txt
( 1) 20060815__bug7620.diff.txt
Description:The new kernel lock checker detected this problem (inconsistent locking).



****** ADDITIONAL INFORMATION ******

Jul 30 06:45:58 smurf kernel: ======================================================
Jul 30 06:45:58 smurf kernel: [ INFO: hard-safe -> hard-unsafe lock order detected ]
Jul 30 06:45:58 smurf kernel: ------------------------------------------------------
Jul 30 06:45:58 smurf kernel: head/9626 [HC0[0]:SC0[0]:HE0:SE1] is trying to acquire:
Jul 30 06:45:58 smurf kernel:  (zone_lock){--..}, at: [<f89f1b24>] set_tone_zone+0x44/0xa0 [zaptel]
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: and this task is already holding:
Jul 30 06:45:58 smurf kernel:  (&chan->lock){++..}, at: [<f89f6eff>] zt_specchan_open+0xef/0x4a0 [zaptel]
Jul 30 06:45:58 smurf kernel: which would create a new lock dependency:
Jul 30 06:45:58 smurf kernel:  (&chan->lock){++..} -> (zone_lock){--..}
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: but this new dependency connects a hard-irq-safe lock:
Jul 30 06:45:58 smurf kernel:  (&chan->lock){++..}
Jul 30 06:45:58 smurf kernel: ... which became hard-irq-safe at:
Jul 30 06:45:58 smurf kernel:   [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:   [<b026d3ab>] _spin_lock_irqsave+0x2c/0x3c
Jul 30 06:45:58 smurf kernel:   [<f89fa3f7>] zt_ec_chunk+0x17/0x610 [zaptel]
Jul 30 06:45:58 smurf kernel:   [<f89692c1>] wctdm_interrupt+0x221/0xc00 [wctdm]Jul 30 06:45:58 smurf kernel:   [<b01383f2>] handle_IRQ_event+0x1f/0x4c
Jul 30 06:45:58 smurf kernel:   [<b01384b3>] __do_IRQ+0x94/0xef
Jul 30 06:45:58 smurf kernel:   [<b0105021>] do_IRQ+0x71/0x84
Jul 30 06:45:58 smurf kernel:   [<b0103455>] common_interrupt+0x25/0x2c
Jul 30 06:45:58 smurf kernel:   [<b0101794>] cpu_idle+0x61/0x84
Jul 30 06:45:58 smurf kernel:   [<b010030b>] rest_init+0x37/0x39
Jul 30 06:45:58 smurf kernel:   [<b038f76f>] start_kernel+0x39c/0x3a4
Jul 30 06:45:58 smurf kernel:   [<b0100210>] 0xb0100210
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: to a hard-irq-unsafe lock:
Jul 30 06:45:58 smurf kernel:  (zone_lock){--..}
Jul 30 06:45:58 smurf kernel: ... which became hard-irq-unsafe at:
Jul 30 06:45:58 smurf kernel: ...  [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:   [<b026d5d5>] _write_lock+0x23/0x32
Jul 30 06:45:58 smurf kernel:   [<f89f75c9>] zt_ioctl+0x159/0x1310 [zaptel]
Jul 30 06:45:58 smurf kernel:   [<b0164854>] do_ioctl+0x4c/0x65
Jul 30 06:45:58 smurf kernel:   [<b0164abe>] vfs_ioctl+0x251/0x264
Jul 30 06:45:58 smurf kernel:   [<b0164b16>] sys_ioctl+0x45/0x5f
Jul 30 06:45:58 smurf kernel:   [<b01029b3>] syscall_call+0x7/0xb
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: other info that might help us debug this:
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: 1 lock held by head/9626:
Jul 30 06:45:58 smurf kernel:  #0:  (&chan->lock){++..}, at: [<f89f6eff>] zt_specchan_open+0xef/0x4a0 [zaptel]
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: the hard-irq-safe lock's dependencies:
Jul 30 06:45:58 smurf kernel: -> (&chan->lock){++..} ops: 0 {
Jul 30 06:45:58 smurf kernel:    initial-use  at:
Jul 30 06:45:58 smurf kernel:                         [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:                         [<b026d3ab>] _spin_lock_irqsave+0x2c/0x3c
Jul 30 06:45:58 smurf kernel:                         [<f89f24b1>] zt_reallocbufs+0x61/0x220 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<f89f2688>] close_channel+0x18/0x240 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<f89f2b3f>] zt_chan_reg+0x8f/0xf0 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<f89f2d61>] zt_register+0x1c1/0x310 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<f896852a>] wctdm_init_one+0x2ca/0xe40 [wctdm]
Jul 30 06:45:58 smurf kernel:                         [<b01b0134>] pci_device_probe+0x39/0x59
Jul 30 06:45:58 smurf kernel:                         [<b020118a>] driver_probe_device+0x45/0x92
Jul 30 06:45:58 smurf kernel:                         [<b02012a8>] __driver_attach+0x5e/0x89
Jul 30 06:45:58 smurf kernel:                         [<b02007db>] bus_for_each_dev+0x36/0x5b
Jul 30 06:45:58 smurf kernel:                         [<b020106c>] driver_attach+0x14/0x17
Jul 30 06:45:58 smurf kernel:                         [<b0200ab1>] bus_add_driver+0x64/0xf3
Jul 30 06:45:58 smurf kernel:                         [<b020167e>] driver_register+0x78/0x7d
Jul 30 06:45:58 smurf kernel:                         [<b01afdb9>] __pci_register_driver+0x4f/0x69
Jul 30 06:45:58 smurf kernel:                         [<f889c095>] 0xf889c095
Jul 30 06:45:58 smurf kernel:                         [<b0134a83>] sys_init_module+0x1749/0x1894
Jul 30 06:45:58 smurf kernel:                         [<b01029b3>] syscall_call+0x7/0xb
Jul 30 06:45:58 smurf kernel:    in-hardirq-W at:
Jul 30 06:45:58 smurf kernel:                         [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:                         [<b026d3ab>] _spin_lock_irqsave+0x2c/0x3c
Jul 30 06:45:58 smurf kernel:                         [<f89fa3f7>] zt_ec_chunk+0x17/0x610 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<f89692c1>] wctdm_interrupt+0x221/0xc00 [wctdm]
Jul 30 06:45:58 smurf kernel:                         [<b01383f2>] handle_IRQ_event+0x1f/0x4c
Jul 30 06:45:58 smurf kernel:                         [<b01384b3>] __do_IRQ+0x94/0xef
Jul 30 06:45:58 smurf kernel:                         [<b0105021>] do_IRQ+0x71/0x84
Jul 30 06:45:58 smurf kernel:                         [<b0103455>] common_interrupt+0x25/0x2c
Jul 30 06:45:58 smurf kernel:                         [<b0101794>] cpu_idle+0x61/0x84
Jul 30 06:45:58 smurf kernel:                         [<b010030b>] rest_init+0x37/0x39
Jul 30 06:45:58 smurf kernel:                         [<b038f76f>] start_kernel+0x39c/0x3a4
Jul 30 06:45:58 smurf kernel:                         [<b0100210>] 0xb0100210
Jul 30 06:45:58 smurf kernel:    in-softirq-W at:
Jul 30 06:45:58 smurf kernel:                         [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:                         [<b026d3ab>] _spin_lock_irqsave+0x2c/0x3c
Jul 30 06:45:58 smurf kernel:                         [<f89fa3f7>] zt_ec_chunk+0x17/0x610 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<f89692c1>] wctdm_interrupt+0x221/0xc00 [wctdm]
Jul 30 06:45:58 smurf kernel:                         [<b01383f2>] handle_IRQ_event+0x1f/0x4c
Jul 30 06:45:58 smurf kernel:                         [<b01384b3>] __do_IRQ+0x94/0xef
Jul 30 06:45:58 smurf kernel:                         [<b0105021>] do_IRQ+0x71/0x84
Jul 30 06:45:58 smurf kernel:                         [<b0103455>] common_interrupt+0x25/0x2c
Jul 30 06:45:58 smurf kernel:                         [<b011d267>] do_softirq+0x3e/0x56
Jul 30 06:45:58 smurf kernel:                         [<b011d3a7>] irq_exit+0x3f/0x4b
Jul 30 06:45:58 smurf kernel:                         [<b010cc20>] smp_apic_timer_interrupt+0x65/0x68
Jul 30 06:45:58 smurf kernel:                         [<b0103516>] apic_timer_interrupt+0x2a/0x30
Jul 30 06:45:58 smurf kernel:                         [<b011937a>] printk+0x13/0x15
Jul 30 06:45:58 smurf kernel:                         [<f8b317e2>] print_raid5_conf+0x7f/0x94 [raid456]
Jul 30 06:45:58 smurf kernel:                         [<f8b33471>] run+0x61d/0x790 [raid456]
Jul 30 06:45:58 smurf kernel:                         [<f8837634>] do_md_run+0x4b6/0x778 [md_mod]
Jul 30 06:45:58 smurf kernel:                         [<f883a054>] md_ioctl+0x11a3/0x13d5 [md_mod]
Jul 30 06:45:58 smurf kernel:                         [<b019c1bd>] blkdev_driver_ioctl+0x4b/0x5d
Jul 30 06:45:58 smurf kernel:                         [<b019c9ce>] blkdev_ioctl+0x7ae/0x7cc
Jul 30 06:45:58 smurf kernel:                         [<b015b3f6>] block_ioctl+0x16/0x1b
Jul 30 06:45:58 smurf kernel:                         [<b0164828>] do_ioctl+0x20/0x65
Jul 30 06:45:58 smurf kernel:                         [<b0164abe>] vfs_ioctl+0x251/0x264
Jul 30 06:45:58 smurf kernel:                         [<b0164b16>] sys_ioctl+0x45/0x5f
Jul 30 06:45:58 smurf kernel:                         [<b01029b3>] syscall_call+0x7/0xb
Jul 30 06:45:58 smurf kernel:  }
Jul 30 06:45:58 smurf kernel:  ... key      at: [<f8a084ac>] __key.17926+0x0/0xffff2c70 [zaptel]
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: the hard-irq-unsafe lock's dependencies:
Jul 30 06:45:58 smurf kernel: -> (zone_lock){--..} ops: 0 {
Jul 30 06:45:58 smurf kernel:    initial-use  at:
Jul 30 06:45:58 smurf kernel:                         [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:                         [<b026d5d5>] _write_lock+0x23/0x32
Jul 30 06:45:58 smurf kernel:                         [<f89f75c9>] zt_ioctl+0x159/0x1310 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<b0164854>] do_ioctl+0x4c/0x65
Jul 30 06:45:58 smurf kernel:                         [<b0164abe>] vfs_ioctl+0x251/0x264
Jul 30 06:45:58 smurf kernel:                         [<b0164b16>] sys_ioctl+0x45/0x5f
Jul 30 06:45:58 smurf kernel:                         [<b01029b3>] syscall_call+0x7/0xb
Jul 30 06:45:58 smurf kernel:    softirq-on-W at:
Jul 30 06:45:58 smurf kernel:                         [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:                         [<b026d5d5>] _write_lock+0x23/0x32
Jul 30 06:45:58 smurf kernel:                         [<f89f75c9>] zt_ioctl+0x159/0x1310 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<b0164854>] do_ioctl+0x4c/0x65
Jul 30 06:45:58 smurf kernel:                         [<b0164abe>] vfs_ioctl+0x251/0x264
Jul 30 06:45:58 smurf kernel:                         [<b0164b16>] sys_ioctl+0x45/0x5f
Jul 30 06:45:58 smurf kernel:                         [<b01029b3>] syscall_call+0x7/0xb
Jul 30 06:45:58 smurf kernel:    hardirq-on-W at:
Jul 30 06:45:58 smurf kernel:                         [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:                         [<b026d5d5>] _write_lock+0x23/0x32
Jul 30 06:45:58 smurf kernel:                         [<f89f75c9>] zt_ioctl+0x159/0x1310 [zaptel]
Jul 30 06:45:58 smurf kernel:                         [<b0164854>] do_ioctl+0x4c/0x65
Jul 30 06:45:58 smurf kernel:                         [<b0164abe>] vfs_ioctl+0x251/0x264
Jul 30 06:45:58 smurf kernel:                         [<b0164b16>] sys_ioctl+0x45/0x5f
Jul 30 06:45:58 smurf kernel:                         [<b01029b3>] syscall_call+0x7/0xb
Jul 30 06:45:58 smurf kernel:  }
Jul 30 06:45:58 smurf kernel:  ... key      at: [<f89ff134>] zone_lock+0x14/0xffffbffc [zaptel]
Jul 30 06:45:58 smurf kernel:
Jul 30 06:45:58 smurf kernel: stack backtrace:
Jul 30 06:45:58 smurf kernel:  [<b0103c40>] show_trace_log_lvl+0x54/0xfd
Jul 30 06:45:58 smurf kernel:  [<b0104d66>] show_trace+0xd/0x10
Jul 30 06:45:58 smurf kernel:  [<b0104d80>] dump_stack+0x17/0x1b
Jul 30 06:45:58 smurf kernel:  [<b012da5b>] check_usage+0x1eb/0x1f8
Jul 30 06:45:58 smurf kernel:  [<b012eb8d>] __lock_acquire+0x829/0x9ab
Jul 30 06:45:58 smurf kernel:  [<b012ef91>] lock_acquire+0x4a/0x6d
Jul 30 06:45:58 smurf kernel:  [<b026d370>] _read_lock+0x23/0x32
Jul 30 06:45:58 smurf kernel:  [<f89f1b24>] set_tone_zone+0x44/0xa0 [zaptel]
Jul 30 06:45:58 smurf kernel:  [<f89f7167>] zt_specchan_open+0x357/0x4a0 [zaptel]
Jul 30 06:45:58 smurf kernel:  [<f89f73d2>] zt_open+0x122/0x1c0 [zaptel]
Jul 30 06:45:58 smurf kernel:  [<b015c9c3>] chrdev_open+0x167/0x183
Jul 30 06:45:58 smurf kernel:  [<b0154310>] __dentry_open+0xea/0x1e9
Jul 30 06:45:58 smurf kernel:  [<b015447d>] nameidata_to_filp+0x1c/0x2e
Jul 30 06:45:58 smurf kernel:  [<b01544bd>] do_filp_open+0x2e/0x35
Jul 30 06:45:58 smurf kernel:  [<b01545ca>] do_sys_open+0x3f/0xba
Jul 30 06:45:58 smurf kernel:  [<b0154671>] sys_open+0x16/0x18
Jul 30 06:45:58 smurf kernel:  [<b01029b3>] syscall_call+0x7/0xb
Jul 30 06:45:58 smurf kernel: Registered tone zone 3 (Netherlands)
Comments:By: Tilghman Lesher (tilghman) 2006-07-30 10:31:50

This patch should address this possible deadlock condition.  Testing needed.

By: Matthias Urlichs (smurfix) 2006-07-31 09:53:53

Applied, running without problems under kernel 2.6.15(ubuntu).

I cannot extensively test 2.6.18rc3 at this time, because of file system problems (XFS), but IMHO this patch solves the problem.

By: Russell Bryant (russell) 2006-08-13 23:07:53

fixed in 1.2 and the trunk in reivisions 1304 and 1305, thanks!

By: Kevin P. Fleming (kpfleming) 2006-08-14 15:44:44

The supplied patch does not compile on 2.4.x kernels or reasonably old 2.6 kernels (like RHEL4 and CentOS 4.3). Please try to prepare a version that will support the kernel versions that Zaptel already builds on :-)

By: Tilghman Lesher (tilghman) 2006-08-15 21:12:07

Okay, new patch with the kernel defines.  Looks like the kernel developers massively changed how rwlock's are implemented (simpler!), so the read_trylock code won't work, even if included in the older kernels.

Testing needed.

By: Serge Vecher (serge-v) 2006-09-06 11:09:07

smurfix: any luck with testing here?

By: Tilghman Lesher (tilghman) 2006-09-16 02:49:02

Revision 1468.

By: Digium Subversion (svnbot) 2008-01-23 16:59:26.000-0600

Repository: zaptel
Revision: 3733

U   branches/1.2/zaptel-base.c
U   branches/1.4/zaptel-base.c

------------------------------------------------------------------------
r3733 | sruffell | 2008-01-23 16:59:25 -0600 (Wed, 23 Jan 2008) | 4 lines

Ensure that the zone lock is always acquired before the channel lock.  

(issue ASTERISK-7424)

------------------------------------------------------------------------

http://svn.digium.com/view/zaptel?view=rev&revision=3733

By: Digium Subversion (svnbot) 2008-06-07 11:44:18

Repository: dahdi
Revision: 1304

U   branches/1.2/zaptel.c

------------------------------------------------------------------------
r1304 | russell | 2008-06-07 11:44:18 -0500 (Sat, 07 Jun 2008) | 3 lines

fix potential deadlock found by kernel's lock checker
(issue ASTERISK-7424, reported by smurfix, fixed by Corydon)

------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=1304

By: Digium Subversion (svnbot) 2008-06-07 11:44:21

Repository: dahdi
Revision: 1305

_U  trunk/
U   trunk/zaptel.c

------------------------------------------------------------------------
r1305 | russell | 2008-06-07 11:44:20 -0500 (Sat, 07 Jun 2008) | 11 lines

Merged revisions 1304 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1304 | russell | 2006-08-14 00:07:00 -0400 (Mon, 14 Aug 2006) | 3 lines

fix potential deadlock found by kernel's lock checker
(issue ASTERISK-7424, reported by smurfix, fixed by Corydon)

........

------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=1305

By: Digium Subversion (svnbot) 2008-06-07 11:44:52

Repository: dahdi
Revision: 1323

_U  team/group/vldtmf/
U   team/group/vldtmf/Makefile
U   team/group/vldtmf/acinclude.m4
U   team/group/vldtmf/configure
U   team/group/vldtmf/configure.ac
U   team/group/vldtmf/fxotune.c
U   team/group/vldtmf/wct4xxp_base.c
U   team/group/vldtmf/xpp/Makefile
U   team/group/vldtmf/xpp/card_fxo.c
U   team/group/vldtmf/xpp/card_fxs.c
U   team/group/vldtmf/xpp/utils/genzaptelconf
U   team/group/vldtmf/xpp/utils/xpp_fxloader
U   team/group/vldtmf/xpp/xbus-core.c
U   team/group/vldtmf/xpp/xpp_usb.c
U   team/group/vldtmf/xpp/xpp_zap.c
U   team/group/vldtmf/zaptel.c
U   team/group/vldtmf/zaptel.h
U   team/group/vldtmf/zaptel.init
U   team/group/vldtmf/zconfig.h

------------------------------------------------------------------------
r1323 | russell | 2008-06-07 11:44:43 -0500 (Sat, 07 Jun 2008) | 261 lines

Merged revisions 1277-1294,1296-1297,1299,1301-1303,1305,1307,1310,1312,1314,1316,1318-1320 via svnmerge from
https://origsvn.digium.com/svn/zaptel/trunk

................
r1277 | north | 2006-08-09 22:04:13 -0400 (Wed, 09 Aug 2006) | 4 lines

Fixed a typo.

Makes one wonder how long this has been like that..

................
r1278 | tzafrir | 2006-08-09 22:15:20 -0400 (Wed, 09 Aug 2006) | 1 line

fixed a typo: it's waitfor_xpds and not wait_for_xpds
................
r1279 | tzafrir | 2006-08-09 22:38:43 -0400 (Wed, 09 Aug 2006) | 4 lines

- In SIG_CHANGED only sig_toggles bits are interesting (was good in FXS,
 now fixed in FXO).
- Better DBG messages for SIG_CHANGED (FXS and FXO).
- Start work on new RING logic (for FXO caller id).
................
r1280 | tzafrir | 2006-08-09 22:40:45 -0400 (Wed, 09 Aug 2006) | 4 lines

Better LED handling for fxo (copied from fxs):
 - Fix both branches/RELEASE-1.1.0 and trunk/
 - Use a ledcontrol bitmask to mark led on/off
 - Actuall led commands are send only from handle_fxo_leds()
................
r1281 | tzafrir | 2006-08-09 22:42:03 -0400 (Wed, 09 Aug 2006) | 3 lines

* xpp_fxloader: Allow loading just USB firmware with command 'usb'
* xpp_fxloader: also add 'load' as an alias of 'xppdetect'
* xpp_fxloader: and add a 'help' message.
................
r1282 | tzafrir | 2006-08-09 22:48:07 -0400 (Wed, 09 Aug 2006) | 2 lines

Bugfix: the PROC_USBXPP_SUMMARY does not own xpp->proc_xbus_dir and should
       not nullify it (partial reversal of changeset:1225)
................
r1283 | tzafrir | 2006-08-09 22:53:20 -0400 (Wed, 09 Aug 2006) | 1 line

genzaptelconf: fixed typo that prevented getting caller ID on zaptel trunks
................
r1284 | tzafrir | 2006-08-09 22:55:25 -0400 (Wed, 09 Aug 2006) | 1 line

xbus-core.c: documentation updates.
................
r1285 | tzafrir | 2006-08-09 23:12:25 -0400 (Wed, 09 Aug 2006) | 8 lines

* New SOFT_RING detection in FXO:
 - Poll register 0x05 on each DAA
 - When enough energy (value of 0x20|0x40 occurs enough times), raise
   the ringing[] flag.
 - When the value show no energy, lower the ringing[] flag.
 - When we get SIG_CHANGED of stop ringing -- stop polling.

* More debugging messages for proc files
................
r1286 | tzafrir | 2006-08-09 23:16:36 -0400 (Wed, 09 Aug 2006) | 1 line

Bugfix: should not call zaptel for unregistered XPD's.
................
r1287 | tzafrir | 2006-08-09 23:19:07 -0400 (Wed, 09 Aug 2006) | 1 line

Improve checking order in xpp_zap.c
................
r1288 | tzafrir | 2006-08-09 23:21:47 -0400 (Wed, 09 Aug 2006) | 1 line

card_fxo.c: Fix a potential bug: battery voltage is a 2's complement value.
................
r1289 | tzafrir | 2006-08-09 23:26:12 -0400 (Wed, 09 Aug 2006) | 6 lines

Solves spinlock-panic in CentOS 4.

zt_transmit() was called in spinlock protected context. However, it may
call back our hook setting code which tries to lock the same spinlock.

As a safeguard, the same logic was applied to zt_receive().
................
r1290 | tzafrir | 2006-08-09 23:33:57 -0400 (Wed, 09 Aug 2006) | 3 lines

* Added support for readingconfiguration from /etc/sysconfig/zaptel .
* Config file location can be overriden by environment.
* Removed an obsolete function.
................
r1291 | tzafrir | 2006-08-09 23:40:10 -0400 (Wed, 09 Aug 2006) | 3 lines

Fix ring detection logic in FXO:
Detect ring stop only when register 0x05 shows no ring voltage for
enough samples. This is done via noring_thresh[].
................
r1292 | tzafrir | 2006-08-09 23:47:30 -0400 (Wed, 09 Aug 2006) | 1 line

Show SOFT_RING compile status when xpd_fxo module is loaded.
................
r1293 | tzafrir | 2006-08-09 23:56:43 -0400 (Wed, 09 Aug 2006) | 6 lines

* A delay loop waiting for a slow udev to generate /dev/zap/ctl
* Work around stupid call to ztcfg on modprobe (as inserted by zaptel
 install script)
* -M now edits /etc/sysconfig/zaptel if it find that file and not /etc/modules
* editing of /etc/sysconfig/zaptel: remove all lines that begin with
 MODULES=, and add MODULES="list of modules" to the end.
................
r1294 | tzafrir | 2006-08-12 11:03:08 -0400 (Sat, 12 Aug 2006) | 3 lines

* Wait for /dev/zap/ctl to appear if udev takes its time creating it.
* Try looking for ztcfg in /usr/sbin as well.
* Also allow setting the location of ztcfg from environment.
................
r1296 | russell | 2006-08-13 19:19:52 -0400 (Sun, 13 Aug 2006) | 2 lines

use LDLIBS instead of LDFLAGS in various places (issue ASTERISK-7512, Mithraen)

................
r1297 | russell | 2006-08-13 19:46:10 -0400 (Sun, 13 Aug 2006) | 2 lines

use AC_MSG_* instead of echo to support ./configure --silent (issue ASTERISK-7526)

................
r1299 | russell | 2006-08-13 20:56:04 -0400 (Sun, 13 Aug 2006) | 11 lines

Merged revisions 1298 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1298 | russell | 2006-08-13 20:54:28 -0400 (Sun, 13 Aug 2006) | 3 lines

the change from $(PWD) to $(SUBDIRS) breaks the build on some systems. So, just
use them both ... (issue ASTERISK-7524)

........

................
r1301 | russell | 2006-08-13 21:45:55 -0400 (Sun, 13 Aug 2006) | 10 lines

Merged revisions 1300 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1300 | russell | 2006-08-13 21:44:59 -0400 (Sun, 13 Aug 2006) | 2 lines

add a note that ENABLE_TASKLETS is not implemented in wct4xxp (issue ASTERISK-7491)

........

................
r1302 | russell | 2006-08-13 21:55:06 -0400 (Sun, 13 Aug 2006) | 3 lines

don't try to include menuselect.makeopts or makeopts if the target is clean,
distclean, or update (fixes issue ASTERISK-7527)

................
r1303 | russell | 2006-08-13 22:48:33 -0400 (Sun, 13 Aug 2006) | 4 lines

add a SHORT_FLASH_TIME option to zconfig.h for european phones with short flash
times that sometimes get misinterpreted as a pulse digit 1
(issue ASTERISK-7174, gagravarr)

................
r1305 | russell | 2006-08-14 00:07:49 -0400 (Mon, 14 Aug 2006) | 11 lines

Merged revisions 1304 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1304 | russell | 2006-08-14 00:07:00 -0400 (Mon, 14 Aug 2006) | 3 lines

fix potential deadlock found by kernel's lock checker
(issue ASTERISK-7424, reported by smurfix, fixed by Corydon)

........

................
r1307 | kpfleming | 2006-08-14 16:42:35 -0400 (Mon, 14 Aug 2006) | 10 lines

Merged revisions 1306 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1306 | kpfleming | 2006-08-14 15:40:55 -0500 (Mon, 14 Aug 2006) | 2 lines

revert this change until a version that compiles on 2.4 kernels and older 2.6 kernels is made available and tested

........

................
r1310 | mattf | 2006-08-15 14:42:22 -0400 (Tue, 15 Aug 2006) | 2 lines

Add support for looping back a single channel

................
r1312 | russell | 2006-08-15 17:34:16 -0400 (Tue, 15 Aug 2006) | 11 lines

Merged revisions 1311 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1311 | russell | 2006-08-15 17:30:49 -0400 (Tue, 15 Aug 2006) | 3 lines

fix passing a 'w' to wait when using pulse dialing
(issue ASTERISK-7539, hanabana)

........

................
r1314 | russell | 2006-08-15 17:44:46 -0400 (Tue, 15 Aug 2006) | 12 lines

Merged revisions 1313 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1313 | russell | 2006-08-15 17:43:26 -0400 (Tue, 15 Aug 2006) | 4 lines

fix erroneous check to see if PWD was set before setting it in the Zaptel
Makefile.  It should always be set.  If not, it breaks the build when using
recursive calls to make. (issue ASTERISK-7534, tzafrir)

........

................
r1316 | russell | 2006-08-15 18:14:21 -0400 (Tue, 15 Aug 2006) | 12 lines

Merged revisions 1315 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1315 | russell | 2006-08-15 18:06:13 -0400 (Tue, 15 Aug 2006) | 4 lines

Ensure that fopen() is only called once for the debug output file to prevent
excessive file descriptor leakage when this function is called many times in
a loop.  (issue ZAP-106)

........

................
r1318 | tilghman | 2006-08-15 21:40:16 -0400 (Tue, 15 Aug 2006) | 10 lines

Merged revisions 1317 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1317 | tilghman | 2006-08-15 20:36:34 -0500 (Tue, 15 Aug 2006) | 2 lines

Bug 7624 - Debian lacks /var/lock/subsys

........

................
r1319 | kpfleming | 2006-08-16 16:01:27 -0400 (Wed, 16 Aug 2006) | 2 lines

clean up libtonezone-related rules

................
r1320 | kpfleming | 2006-08-16 17:09:21 -0400 (Wed, 16 Aug 2006) | 2 lines

run ranlib on static library

................

------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=1323

By: Digium Subversion (svnbot) 2008-06-07 11:49:48

Repository: dahdi
Revision: 1371

_U  be/B.1-2/
U   be/B.1-2/Makefile
D   be/B.1-2/OCT6114-128D.ima
D   be/B.1-2/fw2h.c
U   be/B.1-2/fxotune.c
D   be/B.1-2/include/
D   be/B.1-2/octapi_bt0_private.h
D   be/B.1-2/octapi_llman_private.h
D   be/B.1-2/octvpm.h
D   be/B.1-2/vpm450m.c
D   be/B.1-2/vpm450m.h
A   be/B.1-2/wct4xxp/
D   be/B.1-2/wct4xxp/Kbuild
A   be/B.1-2/wct4xxp/Kbuild
D   be/B.1-2/wct4xxp/Makefile
A   be/B.1-2/wct4xxp/Makefile
D   be/B.1-2/wct4xxp/OCT6114-128D.ima
A   be/B.1-2/wct4xxp/OCT6114-128D.ima
D   be/B.1-2/wct4xxp/base.c
A   be/B.1-2/wct4xxp/base.c
D   be/B.1-2/wct4xxp/fw2h.c
A   be/B.1-2/wct4xxp/fw2h.c
D   be/B.1-2/wct4xxp/vpm450m.c
A   be/B.1-2/wct4xxp/vpm450m.c
D   be/B.1-2/wct4xxp/vpm450m.h
A   be/B.1-2/wct4xxp/vpm450m.h
D   be/B.1-2/wct4xxp/wct4xxp-diag.c
A   be/B.1-2/wct4xxp/wct4xxp-diag.c
D   be/B.1-2/wct4xxp/wct4xxp.h
A   be/B.1-2/wct4xxp/wct4xxp.h
D   be/B.1-2/wct4xxp-diag.c
D   be/B.1-2/wct4xxp.h
D   be/B.1-2/wct4xxp_base.c
U   be/B.1-2/wcte11xp.c
U   be/B.1-2/zaptel.c
U   be/B.1-2/zaptel.init

------------------------------------------------------------------------
r1371 | jlyons | 2008-06-07 11:49:40 -0500 (Sat, 07 Jun 2008) | 87 lines

Merged revisions 1262,1298,1300,1304,1306,1311,1313,1315,1317,1326-1327,1359,1362-1363,1368 via svnmerge from
https://origsvn.digium.com/svn/zaptel/branches/1.2

........
r1262 | kpfleming | 2006-08-08 17:22:24 -0500 (Tue, 08 Aug 2006) | 2 lines

update Octasic API headers (but not code yet) to PR43, and use version with GPL licenses instead of proprietary licenses

........
r1298 | russell | 2006-08-13 19:54:28 -0500 (Sun, 13 Aug 2006) | 3 lines

the change from $(PWD) to $(SUBDIRS) breaks the build on some systems. So, just
use them both ... (issue ASTERISK-7524)

........
r1300 | russell | 2006-08-13 20:44:59 -0500 (Sun, 13 Aug 2006) | 2 lines

add a note that ENABLE_TASKLETS is not implemented in wct4xxp (issue ASTERISK-7491)

........
r1304 | russell | 2006-08-13 23:07:00 -0500 (Sun, 13 Aug 2006) | 3 lines

fix potential deadlock found by kernel's lock checker
(issue ASTERISK-7424, reported by smurfix, fixed by Corydon)

........
r1306 | kpfleming | 2006-08-14 15:40:55 -0500 (Mon, 14 Aug 2006) | 2 lines

revert this change until a version that compiles on 2.4 kernels and older 2.6 kernels is made available and tested

........
r1311 | russell | 2006-08-15 16:30:49 -0500 (Tue, 15 Aug 2006) | 3 lines

fix passing a 'w' to wait when using pulse dialing
(issue ASTERISK-7539, hanabana)

........
r1313 | russell | 2006-08-15 16:43:26 -0500 (Tue, 15 Aug 2006) | 4 lines

fix erroneous check to see if PWD was set before setting it in the Zaptel
Makefile.  It should always be set.  If not, it breaks the build when using
recursive calls to make. (issue ASTERISK-7534, tzafrir)

........
r1315 | russell | 2006-08-15 17:06:13 -0500 (Tue, 15 Aug 2006) | 4 lines

Ensure that fopen() is only called once for the debug output file to prevent
excessive file descriptor leakage when this function is called many times in
a loop.  (issue ZAP-106)

........
r1317 | tilghman | 2006-08-15 20:36:34 -0500 (Tue, 15 Aug 2006) | 2 lines

Bug 7624 - Debian lacks /var/lock/subsys

........
r1326 | mattf | 2006-08-18 15:20:08 -0500 (Fri, 18 Aug 2006) | 2 lines

Add b410p support into 1.2 Makefile.

........
r1327 | kpfleming | 2006-08-18 21:27:49 -0500 (Fri, 18 Aug 2006) | 2 lines

don't report the VPM servicing more spans than the card actually has

........
r1359 | kpfleming | 2006-08-26 21:02:42 -0500 (Sat, 26 Aug 2006) | 2 lines

merge in new, cleaner Octasic API integration

........
r1362 | kpfleming | 2006-08-26 21:20:56 -0500 (Sat, 26 Aug 2006) | 2 lines

it would probably help if we actually linked the Octasic API objects into the wct4xxp module :-)

........
r1363 | kpfleming | 2006-08-26 21:27:23 -0500 (Sat, 26 Aug 2006) | 2 lines

ok... finally, this actually does build correctly for 2.4 kernels

........
r1368 | file | 2006-08-27 17:58:06 -0500 (Sun, 27 Aug 2006) | 2 lines

Copy the firmware from the new location

........

------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=1371

By: Digium Subversion (svnbot) 2008-06-07 13:48:32

Repository: dahdi
Revision: 3733

U   branches/1.2/zaptel-base.c
U   branches/1.4/zaptel-base.c

------------------------------------------------------------------------
r3733 | sruffell | 2008-06-07 13:48:31 -0500 (Sat, 07 Jun 2008) | 4 lines

Ensure that the zone lock is always acquired before the channel lock.  

(issue ASTERISK-7424)

------------------------------------------------------------------------

http://svn.digium.com/view/dahdi?view=rev&revision=3733