"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "drivers/net/ethernet/emulex/benet/be_cmds.c" between
linux-5.3-rc3.tar.gz and linux-5.3-rc4.tar.gz

About: The full source of the development Linux kernel 5.3 (release candidate).

be_cmds.c  (linux-5.3-rc3):be_cmds.c  (linux-5.3-rc4)
skipping to change at line 553 skipping to change at line 553
spin_unlock_bh(&adapter->mcc_cq_lock); spin_unlock_bh(&adapter->mcc_cq_lock);
} }
int be_process_mcc(struct be_adapter *adapter) int be_process_mcc(struct be_adapter *adapter)
{ {
struct be_mcc_compl *compl; struct be_mcc_compl *compl;
int num = 0, status = 0; int num = 0, status = 0;
struct be_mcc_obj *mcc_obj = &adapter->mcc_obj; struct be_mcc_obj *mcc_obj = &adapter->mcc_obj;
spin_lock(&adapter->mcc_cq_lock); spin_lock_bh(&adapter->mcc_cq_lock);
while ((compl = be_mcc_compl_get(adapter))) { while ((compl = be_mcc_compl_get(adapter))) {
if (compl->flags & CQE_FLAGS_ASYNC_MASK) { if (compl->flags & CQE_FLAGS_ASYNC_MASK) {
be_mcc_event_process(adapter, compl); be_mcc_event_process(adapter, compl);
} else if (compl->flags & CQE_FLAGS_COMPLETED_MASK) { } else if (compl->flags & CQE_FLAGS_COMPLETED_MASK) {
status = be_mcc_compl_process(adapter, compl); status = be_mcc_compl_process(adapter, compl);
atomic_dec(&mcc_obj->q.used); atomic_dec(&mcc_obj->q.used);
} }
be_mcc_compl_use(compl); be_mcc_compl_use(compl);
num++; num++;
} }
if (num) if (num)
be_cq_notify(adapter, mcc_obj->cq.id, mcc_obj->rearm_cq, num); be_cq_notify(adapter, mcc_obj->cq.id, mcc_obj->rearm_cq, num);
spin_unlock(&adapter->mcc_cq_lock); spin_unlock_bh(&adapter->mcc_cq_lock);
return status; return status;
} }
/* Wait till no more pending mcc requests are present */ /* Wait till no more pending mcc requests are present */
static int be_mcc_wait_compl(struct be_adapter *adapter) static int be_mcc_wait_compl(struct be_adapter *adapter)
{ {
#define mcc_timeout 12000 /* 12s timeout */ #define mcc_timeout 12000 /* 12s timeout */
int i, status = 0; int i, status = 0;
struct be_mcc_obj *mcc_obj = &adapter->mcc_obj; struct be_mcc_obj *mcc_obj = &adapter->mcc_obj;
for (i = 0; i < mcc_timeout; i++) { for (i = 0; i < mcc_timeout; i++) {
if (be_check_error(adapter, BE_ERROR_ANY)) if (be_check_error(adapter, BE_ERROR_ANY))
return -EIO; return -EIO;
local_bh_disable();
status = be_process_mcc(adapter); status = be_process_mcc(adapter);
local_bh_enable();
if (atomic_read(&mcc_obj->q.used) == 0) if (atomic_read(&mcc_obj->q.used) == 0)
break; break;
usleep_range(500, 1000); usleep_range(500, 1000);
} }
if (i == mcc_timeout) { if (i == mcc_timeout) {
dev_err(&adapter->pdev->dev, "FW not responding\n"); dev_err(&adapter->pdev->dev, "FW not responding\n");
be_set_error(adapter, BE_ERROR_FW); be_set_error(adapter, BE_ERROR_FW);
return -EIO; return -EIO;
} }
 End of changes. 4 change blocks. 
4 lines changed or deleted 2 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)