Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/external/isc/atheros_hal/ic Fix ATHHAL_DEBUG by syncing ...



details:   https://anonhg.NetBSD.org/src/rev/5ec6a7f01b29
branches:  trunk
changeset: 778732:5ec6a7f01b29
user:      nakayama <nakayama%NetBSD.org@localhost>
date:      Wed Apr 11 13:48:11 2012 +0000

description:
Fix ATHHAL_DEBUG by syncing HALDEBUG() with Atheros HAL code.

diffstat:

 sys/external/isc/atheros_hal/ic/ah_osdep.c |  23 ++++++-----------------
 1 files changed, 6 insertions(+), 17 deletions(-)

diffs (51 lines):

diff -r d7004a86de5b -r 5ec6a7f01b29 sys/external/isc/atheros_hal/ic/ah_osdep.c
--- a/sys/external/isc/atheros_hal/ic/ah_osdep.c        Wed Apr 11 10:18:25 2012 +0000
+++ b/sys/external/isc/atheros_hal/ic/ah_osdep.c        Wed Apr 11 13:48:11 2012 +0000
@@ -26,11 +26,11 @@
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
  * THE POSSIBILITY OF SUCH DAMAGES.
  *
- * $Id: ah_osdep.c,v 1.5 2011/07/17 20:54:51 joerg Exp $
+ * $Id: ah_osdep.c,v 1.6 2012/04/11 13:48:11 nakayama Exp $
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ah_osdep.c,v 1.5 2011/07/17 20:54:51 joerg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ah_osdep.c,v 1.6 2012/04/11 13:48:11 nakayama Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_athhal.h"
@@ -65,8 +65,8 @@
                int lineno, const char* msg);
 #endif
 #ifdef ATHHAL_DEBUG
-extern void HALDEBUG(struct ath_hal *ah, const char* fmt, ...);
-extern void HALDEBUGn(struct ath_hal *ah, u_int level, const char* fmt, ...);
+extern void HALDEBUG(struct ath_hal *ah, u_int mask, const char* fmt, ...)
+       __printflike(3,4);
 #endif /* ATHHAL_DEBUG */
 
 #ifdef ATHHAL_DEBUG
@@ -171,20 +171,9 @@
 
 #ifdef ATHHAL_DEBUG
 void
-HALDEBUG(struct ath_hal *ah, const char* fmt, ...)
+HALDEBUG(struct ath_hal *ah, u_int mask, const char* fmt, ...)
 {
-       if (ath_hal_debug) {
-               va_list ap;
-               va_start(ap, fmt);
-               ath_hal_vprintf(ah, fmt, ap);
-               va_end(ap);
-       }
-}
-
-void
-HALDEBUGn(struct ath_hal *ah, u_int level, const char* fmt, ...)
-{
-       if (ath_hal_debug >= level) {
+       if (ath_hal_debug & mask) {
                va_list ap;
                va_start(ap, fmt);
                ath_hal_vprintf(ah, fmt, ap);



Home | Main Index | Thread Index | Old Index