[svn-commits] fjoe: freebsd/trunk r9175 - /freebsd/trunk/drivers/dahdi/wctc4xxp/base.c

SVN commits to the Digium repositories svn-commits at lists.digium.com
Sun Aug 22 11:34:31 CDT 2010


Author: fjoe
Date: Sun Aug 22 11:34:27 2010
New Revision: 9175

URL: http://svnview.digium.com/svn/dahdi?view=rev&rev=9175
Log:
- Fix cmd allocator
- Fix firmware loader

Modified:
    freebsd/trunk/drivers/dahdi/wctc4xxp/base.c

Modified: freebsd/trunk/drivers/dahdi/wctc4xxp/base.c
URL: http://svnview.digium.com/svn/dahdi/freebsd/trunk/drivers/dahdi/wctc4xxp/base.c?view=diff&rev=9175&r1=9174&r2=9175
==============================================================================
--- freebsd/trunk/drivers/dahdi/wctc4xxp/base.c (original)
+++ freebsd/trunk/drivers/dahdi/wctc4xxp/base.c Sun Aug 22 11:34:27 2010
@@ -411,6 +411,7 @@
 {
 	struct tcb *cmd = (struct tcb *) mem;
 
+	memset(cmd, 0, sizeof(*cmd));
 	initialize_cmd(cmd);
 	return (0);
 }
@@ -443,7 +444,7 @@
 	if (size < MIN_PACKET_LEN)
 		size = MIN_PACKET_LEN;
 #if defined(__FreeBSD__)
-	cmd = uma_zalloc(cmd_cache, M_WAITOK | M_ZERO);
+	cmd = uma_zalloc(cmd_cache, M_WAITOK);
 #else
 	cmd = kmem_cache_alloc(cmd_cache, alloc_flags);
 #endif
@@ -3198,7 +3199,7 @@
 	unsigned int last_byteloc;
 	unsigned int length;
 	struct tcb *cmd;
-	const char *firmware_data = (const char *) firmware->data;
+	const u8 *firmware_data = (const u8 *) firmware->data;
 #if defined(__FreeBSD__)
 	size_t firmware_size = firmware->datasize;
 #else
@@ -3771,7 +3772,7 @@
 	unsigned int complexfmts;
 	struct firmware embedded_firmware;
 	const struct firmware *firmware = &embedded_firmware;
-	const char *firmware_data;
+	const u8 *firmware_data;
 #if !defined(HOTPLUG_FIRMWARE)
 	extern void _binary_dahdi_fw_tc400m_bin_size;
 	extern u8 _binary_dahdi_fw_tc400m_bin_start[];




More information about the svn-commits mailing list