Print this page
5255 uts shouldn't open-code ISP2

*** 30,39 **** --- 30,40 ---- * Implements all the routines necessary for setup, teardown, and * alloc/free of all Hermon resources, including those that are managed * by Hermon hardware or which live in Hermon's direct attached DDR memory. */ + #include <sys/sysmacros.h> #include <sys/types.h> #include <sys/conf.h> #include <sys/ddi.h> #include <sys/sunddi.h> #include <sys/modctl.h>
*** 2664,2674 **** * Round the configured number of QP per MCG to next larger * power-of-2 size and update. */ num_qp_per_mcg = state->hs_cfg_profile->cp_num_qp_per_mcg + 8; log2 = highbit(num_qp_per_mcg); ! if ((num_qp_per_mcg & (num_qp_per_mcg - 1)) == 0) { log2 = log2 - 1; } state->hs_cfg_profile->cp_num_qp_per_mcg = (1 << log2) - 8; /* Now make sure number of QP per MCG makes sense */ --- 2665,2675 ---- * Round the configured number of QP per MCG to next larger * power-of-2 size and update. */ num_qp_per_mcg = state->hs_cfg_profile->cp_num_qp_per_mcg + 8; log2 = highbit(num_qp_per_mcg); ! if (ISP2(num_qp_per_mcg)) { log2 = log2 - 1; } state->hs_cfg_profile->cp_num_qp_per_mcg = (1 << log2) - 8; /* Now make sure number of QP per MCG makes sense */