Browse Source

[hermon] Disable debugging around mapping of firmware tables

tags/v0.9.8
Michael Brown 15 years ago
parent
commit
de50a19ae3
1 changed files with 8 additions and 0 deletions
  1. 8
    0
      src/drivers/infiniband/hermon.c

+ 8
- 0
src/drivers/infiniband/hermon.c View File

1663
 	assert ( ( pa & ( HERMON_PAGE_SIZE - 1 ) ) == 0 );
1663
 	assert ( ( pa & ( HERMON_PAGE_SIZE - 1 ) ) == 0 );
1664
 	assert ( ( len & ( HERMON_PAGE_SIZE - 1 ) ) == 0 );
1664
 	assert ( ( len & ( HERMON_PAGE_SIZE - 1 ) ) == 0 );
1665
 
1665
 
1666
+	/* These mappings tend to generate huge volumes of
1667
+	 * uninteresting debug data, which basically makes it
1668
+	 * impossible to use debugging otherwise.
1669
+	 */
1670
+	DBG_DISABLE ( DBGLVL_LOG | DBGLVL_EXTRA );
1671
+
1666
 	while ( len ) {
1672
 	while ( len ) {
1667
 		memset ( &mapping, 0, sizeof ( mapping ) );
1673
 		memset ( &mapping, 0, sizeof ( mapping ) );
1668
 		MLX_FILL_1 ( &mapping, 0, va_h, ( va >> 32 ) );
1674
 		MLX_FILL_1 ( &mapping, 0, va_h, ( va >> 32 ) );
1671
 			     log2size, 0,
1677
 			     log2size, 0,
1672
 			     pa_l, ( pa >> 12 ) );
1678
 			     pa_l, ( pa >> 12 ) );
1673
 		if ( ( rc = map ( hermon, &mapping ) ) != 0 ) {
1679
 		if ( ( rc = map ( hermon, &mapping ) ) != 0 ) {
1680
+			DBG_ENABLE ( DBGLVL_LOG | DBGLVL_EXTRA );
1674
 			DBGC ( hermon, "Hermon %p could not map %llx => %lx: "
1681
 			DBGC ( hermon, "Hermon %p could not map %llx => %lx: "
1675
 			       "%s\n", hermon, va, pa, strerror ( rc ) );
1682
 			       "%s\n", hermon, va, pa, strerror ( rc ) );
1676
 			return rc;
1683
 			return rc;
1680
 		len -= HERMON_PAGE_SIZE;
1687
 		len -= HERMON_PAGE_SIZE;
1681
 	}
1688
 	}
1682
 
1689
 
1690
+	DBG_ENABLE ( DBGLVL_LOG | DBGLVL_EXTRA );
1683
 	return 0;
1691
 	return 0;
1684
 }
1692
 }
1685
 
1693
 

Loading…
Cancel
Save