svn commit: r302482 - head/sys/dev/ntb/ntb_hw
Alexander Motin
mav at FreeBSD.org
Sat Jul 9 09:34:26 UTC 2016
Author: mav
Date: Sat Jul 9 09:34:24 2016
New Revision: 302482
URL: https://svnweb.freebsd.org/changeset/base/302482
Log:
Fix NTB_SDOORBELL_LOCKUP workaround.
Since SBARxSZ register can be write-once, it can be unusable for disabling
the SBAR. For such case also set SBARxBASE to zero to not intersect with
config BAR.
Modified:
head/sys/dev/ntb/ntb_hw/ntb_hw.c
Modified: head/sys/dev/ntb/ntb_hw/ntb_hw.c
==============================================================================
--- head/sys/dev/ntb/ntb_hw/ntb_hw.c Sat Jul 9 06:52:55 2016 (r302481)
+++ head/sys/dev/ntb/ntb_hw/ntb_hw.c Sat Jul 9 09:34:24 2016 (r302482)
@@ -1673,8 +1673,12 @@ xeon_set_sbar_base_and_limit(struct ntb_
uint32_t base_reg, lmt_reg;
bar_get_xlat_params(ntb, idx, &base_reg, NULL, &lmt_reg);
- if (idx == regbar)
- bar_addr += ntb->b2b_off;
+ if (idx == regbar) {
+ if (ntb->b2b_off)
+ bar_addr += ntb->b2b_off;
+ else
+ bar_addr = 0;
+ }
/*
* Set limit registers first to avoid an errata where setting the base
More information about the svn-src-head
mailing list