Skip to content

Commit

Permalink
IB/sa: Don't need to check for default P_Key twice
Browse files Browse the repository at this point in the history
Now that ib_find_pkey() ignores the membership bit of P_Keys, there's no
need for ib_sa to look for both 0x7fff and 0xffff in a port's P_Key table.

Signed-off-by: Roland Dreier <rolandd@cisco.com>
  • Loading branch information
Roland Dreier committed Aug 3, 2007
1 parent 36026ec commit 5399891
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions drivers/infiniband/core/sa_query.c
Original file line number Diff line number Diff line change
Expand Up @@ -385,9 +385,7 @@ static void update_sm_ah(struct work_struct *work)

new_ah->pkey_index = 0;
if (ib_find_pkey(port->agent->device, port->port_num,
IB_DEFAULT_PKEY_FULL, &new_ah->pkey_index) &&
ib_find_pkey(port->agent->device, port->port_num,
IB_DEFAULT_PKEY_PARTIAL, &new_ah->pkey_index))
IB_DEFAULT_PKEY_FULL, &new_ah->pkey_index))
printk(KERN_ERR "Couldn't find index for default PKey\n");

memset(&ah_attr, 0, sizeof ah_attr);
Expand Down

0 comments on commit 5399891

Please sign in to comment.