summaryrefslogtreecommitdiff
path: root/drivers/dahdi/dahdi_dynamic_eth.c
AgeCommit message (Collapse)Author
2011-01-03'dahdi_copy_string()' -> 'strlcpy()'Shaun Ruffell
There is already a safe string copying function in all the kernels DAHDI currently supports. Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9585 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-01-03dahdi_dynamic: Pass the dahdi_dynamic to create/destroy functions.Shaun Ruffell
This allows the pvt member to be set under lock without holding the lock through the call to create destroy. Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9578 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-01-03dahdi_dynamic: constify the address parameter to create.Shaun Ruffell
Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9574 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-01-03dahdi_dynamic: dynamic drivers should not reference count themselves.Shaun Ruffell
Move the try_module_get/module_put calls from the various dynamic drivers into the "core" dahdi_dynamic.c file itself. This way, a reference count can always be held while calling through the function pointers. This is enabled by adding an .owner field to 'struct dahdi_dynamic_driver'. Dynamic spans are also unique in dahdi in that they require a "dahdi_cfg -s" to stop them and release the references on the modules. This is counterintuitive. This change makes sure they are reference counted just like other spans and on driver unload, if there aren't any open handles from userspace, they will take care of unwinding themselves. Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9573 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-01-03dahdi_dynamic: "dahdi_dynamic_[un]register()" -> ↵Shaun Ruffell
"dahdi_dynamic_[un]register_driver()" Clarify that we're registering / unregistering the driver. Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9572 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2011-01-03dahdi_dynamic_[loc|eth|ethmf]: Remove unused return value from transmit ↵Shaun Ruffell
callback. The return value from the transmit callback function was not used anywhere, and is now removed. Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com> git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9570 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-09-24Move test for DEFINE_SPINLOCK into include/dahdi/kernel.hShaun Ruffell
The check for DEFINE_SPINLOCK was spread throughout the source tree. If not defined we can just define it in inlucde/dahdi/kernel.h. Now include/dahdi/kernel.h is the only place that references SPIN_LOCK_UNLOCKED (which breaks lockdep checking if DEFINE_SPINLOCK is otherwise defined in the kernel). Signed-off-by: Shaun Ruffell <sruffell@digium.com> Acked-by: Kinsey Moore <kmoore@digium.com> Acked-by: Russ Meyerriecks <rmeyerriecks@digium.com> Acked-by: Tzafrir Cohen <tzafrir.cohen@xorcom.com> Review: https://reviewboard.asterisk.org/r/940/ git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@9411 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2010-02-25dahdi_dynamic: Add TDMoE Multi-Frame support.Shaun Ruffell
Add TDMoE Multi-Frame support as described in the article at the following URL: http://www.thrallingpenguin.com/articles/tdmoe-mf.htm TDMoE-MF is known to be implemented in hardware solutions from Redfone Communications. This patch additionally implements RCU within dahdi_dynamic to decrease lock contention, latency, and context switching. Because of the use of RCU locking, all prior known issues with loading and unloading of the modules are resolved, providing the spans are shutdown with "dahdi_cfg -s". It also contains an attempt, which works, at fixing a kernel change with skb_linearize(). The use of kernel version number does not work with SuSE SLES 10, as it appears they have backported the 2.6.18 change in to their 2.6.16 version. This merges in the work Jbenden did at: http://svn.digium.com/svn/dahdi/team/jbenden/tdmoe-mf@8102 (issue #13483) Patch by: JBenden Reported by: JBenden Tested by: JBenden git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@8103 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-10-28fix a large number of warnings found by sparse, the kernel code sanity ↵Kevin P. Fleming
checking tool. some of these fixes are non-optimal (casting 'unsigned long' to '__user void *'), but are unavoidable in many cases. started from tzafrir's patch, did most of the work myself. (closes issue #13763) Reported by: tzafrir Patches: sparse_fixes_1.diff uploaded by tzafrir (license 46) git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@5162 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-08-06last round of license header updates hereKevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4721 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-08-03Change all instances of printk in DAHDI to include a priorityRussell Bryant
(closes issue #11504) Reported by: tzafrir Patches: 20080717__issue11504_dahdi_printk_without_priority.diff uploaded by bbryant (license 36) git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4685 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-08-01make skb_linearize() work for kernels <= 2.6.17 tooKevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4648 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-08-01fix problem accepting non-linearized skbs from NIC driversKevin P. Fleming
(closes issue #13204) Reported by: biohumanoid Patches: ztd-eth.c.patch uploaded by biohumanoid (license 459) (modified by me to actually apply to DAHDI) git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4643 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-07-29make an initial split of dahdi/kernel.h into userspace- and ↵Kevin P. Fleming
kernelspace-specific parts git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4628 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-06-20merge modular_ec branch, which adds modular echocan support and lots of ↵Kevin P. Fleming
minor fixes and improvements... seems to work properly, except the usecount on the echocan modules never increments above zero, so they are unloadable when they should not be git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4436 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-23Update Linux Support Services copyright references to DigiumMatthew Fredrickson
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4351 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-23Remove some left over ZT referencesMatthew Fredrickson
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4341 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-22and with another fell swoop... 2.4 kernel support is gone tooKevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4327 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-22and with one fell swoop... devfs support disappearsKevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4326 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-21replace Zaptel with DAHDI, ZAPTEL with DAHDI, ZAPATA with DAHDIKevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4322 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-21replace zap_ with dahdi_, ZAP_ with DAHDI_Kevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4321 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-21replace ZT_ with DAHDI_, zt_ with dahdi_Kevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4320 a0bf4364-ded3-4de4-8d8a-66a801d63aff
2008-05-21rename modules from zt prefixes to dahdi prefixesKevin P. Fleming
git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@4319 a0bf4364-ded3-4de4-8d8a-66a801d63aff