]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - share/man/man4/ntb_hw_intel.4
Merge llvm-project 12.0.0 release
[FreeBSD/FreeBSD.git] / share / man / man4 / ntb_hw_intel.4
1 .\"
2 .\" Copyright (c) 2016-2017 Alexander Motin <mav@FreeBSD.org>
3 .\" All rights reserved.
4 .\"
5 .\" Redistribution and use in source and binary forms, with or without
6 .\" modification, are permitted provided that the following conditions
7 .\" are met:
8 .\" 1. Redistributions of source code must retain the above copyright
9 .\"    notice, this list of conditions and the following disclaimer.
10 .\" 2. Redistributions in binary form must reproduce the above copyright
11 .\"    notice, this list of conditions and the following disclaimer in the
12 .\"    documentation and/or other materials provided with the distribution.
13 .\"
14 .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
15 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
18 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 .\" SUCH DAMAGE.
25 .\"
26 .\" $FreeBSD$
27 .\"
28 .Dd October 11, 2020
29 .Dt NTB_HW_INTEL 4
30 .Os
31 .Sh NAME
32 .Nm ntb_hw_intel
33 .Nd Intel(R) Non-Transparent Bridge driver
34 .Sh SYNOPSIS
35 To compile this driver into your kernel,
36 place the following lines in your kernel configuration file:
37 .Bd -ragged -offset indent
38 .Cd "device ntb"
39 .Cd "device ntb_hw_intel"
40 .Ed
41 .Pp
42 Or, to load the driver as a module at boot, place the following line in
43 .Xr loader.conf 5 :
44 .Bd -literal -offset indent
45 ntb_hw_intel_load="YES"
46 .Ed
47 .Sh DESCRIPTION
48 The
49 .Nm ntb_hw_intel
50 driver provides support for the Non-Transparent Bridge (NTB) hardware in
51 Intel Xeon E3/E5 and S1200 processor families, which allow one of their PCIe
52 ports to be switched from transparent to non-transparent bridge mode.
53 In this mode the bridge looks not like a PCI bridge, but like a PCI endpoint
54 device.
55 The driver hides hardware details, exposing memory windows, scratchpads
56 and doorbells of the other side via a hardware independent KPI to the
57 .Xr ntb 4
58 subsystem.
59 .Pp
60 The hardware provides 2 or 3 memory windows to the other system's memory,
61 16 scratchpad registers and 14, 31 or 34 doorbells to interrupt the other
62 system, depending on the platform.
63 On Xeon processors one of the memory windows is typically consumed by the driver
64 itself to work around multiple hardware errata.
65 .Sh CONFIGURATION
66 The NTB configuration should be set by BIOS.
67 It includes enabling NTB, choosing between NTB-to-NTB (back-to-back) or
68 NTB-to-Root Port mode,
69 enabling split BAR mode (one of two 64-bit BARs can be split into two 32-bit
70 ones) and configuring BAR sizes in bits (from 12 to 29/39) for both NTB sides.
71 .Pp
72 The recommended configuration is NTB-to-NTB mode, split bar enabled and
73 all BAR sizes set to 20 (1 MiB).
74 This needs to be done on both systems.
75 Note, on Xeon SkyLake and newer platforms, split bar mode is not available.
76 .Sh SEE ALSO
77 .Xr if_ntb 4 ,
78 .Xr ntb_transport 4 ,
79 .Xr ntb 4 ,
80 .Sh AUTHORS
81 .An -nosplit
82 The
83 .Nm
84 driver was developed by Intel and originally written by
85 .An Carl Delsey Aq Mt carl@FreeBSD.org .
86 Later improvements were done by
87 .An Conrad E. Meyer Aq Mt cem@FreeBSD.org
88 and
89 .An Alexander Motin Aq Mt mav@FreeBSD.org .
90 .Sh BUGS
91 NTB-to-Root Port mode is not yet supported, but it doesn't look very useful.
92 .Pp
93 On Xeon v2/v3/v4 processors split BAR mode should be enabled to allow
94 SB01BASE_LOCKUP errata workaround to be applied by the driver.
95 .Pp
96 There is no way to protect your system from malicious behavior on the other
97 system once the link is brought up.
98 Anyone with root or kernel access on the other system can read or write to
99 any location on your system.
100 In other words, only connect two systems that completely trust each other.