aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ntb/test/ntb_pingpong.c
diff options
context:
space:
mode:
authorDoug Meyer <dmeyer@gigaio.com>2017-10-17 13:22:53 -0700
committerJon Mason <jdmason@kudzu.us>2018-01-28 22:17:22 -0500
commit140eb5227767c6754742020a16d2691222b9c19b (patch)
tree909750d61425a3b94b1427dcb31291fa92b67acc /drivers/ntb/test/ntb_pingpong.c
parentLinux 4.15 (diff)
downloadlinux-dev-140eb5227767c6754742020a16d2691222b9c19b.tar.xz
linux-dev-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