diff options
author | Doug Meyer <dmeyer@gigaio.com> | 2017-10-17 13:22:53 -0700 |
---|---|---|
committer | Jon Mason <jdmason@kudzu.us> | 2018-01-28 22:17:22 -0500 |
commit | 140eb5227767c6754742020a16d2691222b9c19b (patch) | |
tree | 909750d61425a3b94b1427dcb31291fa92b67acc /drivers/ntb/test/ntb_pingpong.c | |
parent | d8a5b80568a9cb66810e75b182018e9edb68e8ff (diff) | |
download | talos-op-linux-140eb5227767c6754742020a16d2691222b9c19b.tar.gz talos-op-linux-140eb5227767c6754742020a16d2691222b9c19b.zip |
NTB: ntb_hw_switchtec: Fix peer BAR bug in switchtec_ntb_init_shared_mw
This resolves a bug which may incorrectly configure the peer host's
LUT for shared memory window access. The code was using the local
host's first BAR number, rather than the peer hosts's first BAR
number, to determine what peer NT control register to program.
The bug will cause the Switchtec NTB link to work only if both peers
have the same first NTB BAR configured. In all other configurations,
the link will not come up, failing silently.
When both hosts have the same first BAR, the configuration works only
because the first BAR numbers happent to be the same. When the hosts
do not have the same first BAR, then the LUT translation will not be
configured in the correct peer LUT and will not give the peer the
shared memory window access required for the link to operate.
Signed-off-by: Doug Meyer <dmeyer@gigaio.com>
Reviewed-by: Logan Gunthorpe <logang@deltatee.com>
Fixes: 678784a44ae8 ("NTB: switchtec_ntb: Initialize hardware for memory windows")
Signed-off-by: Jon Mason <jdmason@kudzu.us>
Diffstat (limited to 'drivers/ntb/test/ntb_pingpong.c')
0 files changed, 0 insertions, 0 deletions