Skip to content

Commit

Permalink
NTB: remove handling of peer_sta from amd_link_is_up
Browse files Browse the repository at this point in the history
amd_link_is_up() is a callback to inquire whether
the NTB link is up or not. So it should not indulge
itself into clearing the bitmasks of peer_sta.

Signed-off-by: Arindam Nath <arindam.nath@amd.com>
Signed-off-by: Jon Mason <jdmason@kudzu.us>
  • Loading branch information
Arindam Nath authored and Jon Mason committed Mar 13, 2020
1 parent 2465b87 commit fdd8281
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions drivers/ntb/hw/amd/ntb_hw_amd.c
Original file line number Diff line number Diff line change
Expand Up @@ -253,17 +253,6 @@ static int amd_link_is_up(struct amd_ntb_dev *ndev)
return 1;
}

/* If peer_sta is reset or D0 event, the ISR has
* started a timer to check link status of hardware.
* So here just clear status bit. And if peer_sta is
* D3 or PME_TO, D0/reset event will be happened when
* system wakeup/poweron, so do nothing here.
*/
if (ndev->peer_sta & AMD_PEER_RESET_EVENT)
ndev->peer_sta &= ~AMD_PEER_RESET_EVENT;
else if (ndev->peer_sta & (AMD_PEER_D0_EVENT | AMD_LINK_DOWN_EVENT))
ndev->peer_sta = 0;

return 0;
}

Expand Down

0 comments on commit fdd8281

Please sign in to comment.