Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 27 May 2013 19:15:05 +0300
From:      Konstantin Belousov <kostikbel@gmail.com>
To:        arch@freebsd.org, amd64@freebsd.org
Subject:   Re: x86 IOMMU support (DMAR)
Message-ID:  <20130527161505.GE3047@kib.kiev.ua>
In-Reply-To: <20130527122700.GD70224@caravan.chchile.org>
References:  <20130527105844.GC3047@kib.kiev.ua> <20130527122700.GD70224@caravan.chchile.org>

next in thread | previous in thread | raw e-mail | index | archive | help

--/liuGKheDV9E18bs
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, May 27, 2013 at 02:27:00PM +0200, Jeremie Le Hen wrote:
> Hi kib,
>=20
> On Mon, May 27, 2013 at 01:58:44PM +0300, Konstantin Belousov wrote:
> > For the several months, I worked (and continue the work now) on the
> > driver for the Intel VT-d for FreeBSD.  The VT-d is sold as the I/O
> > Virtualization technology, but in essence it is a DMA addresses
> > remapping engine, i.e. it is advanced and improved I/O MMU, as also
> > found on other big-iron machines, e.g. PowerPC or Sparc.  See the
> > Intel document titled 'Intel Virtualization Technology for Directed
> > I/O Architecture Specification' and chipsets datasheets for the
> > description of the facility.
> >=20
> > [...]
> >=20
> > http://people.freebsd.org/~kib/misc/DMAR.1.patch
>=20
> Which CPU flag is needed to be able to test this?
>=20
> My -CURRENT machine has:
>=20
> CPU: Intel(R) Core(TM)2 CPU          6320  @ 1.86GHz (1869.90-MHz K8-clas=
s CPU)
>   Origin =3D "GenuineIntel"  Id =3D 0x6f6  Family =3D 0x6  Model =3D 0xf =
 Stepping =3D 6
>   Features=3D0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,=
PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
>   Features2=3D0xe3bd<SSE3,DTES64,MON,DS_CPL,VMX,EST,TM2,SSSE3,CX16,xTPR,P=
DCM>
>   AMD Features=3D0x20100800<SYSCALL,NX,LM>
>   AMD Features2=3D0x1<LAHF>

The feature is announced by the ACPI table.  You should use recent HEAD,
and do acpidump -t | grep DMAR.  If the DMAR table is present, you have
VT-d enabled.

Presence of VT-d is determined by:
- north bridge.  In other words, for older machines with Core2 and earlier
  CPUs, north bridge chip of the chipset should support VT-d, for newer
  Core iX, the north bridge inside the CPU.
- motherboard manufacturer, by the way of BIOS properly configuring the
  DMARs and filling the right table.  Some motherboard vendors offer the
  knob in the BIOS setup, which enables VT-d.

One note: KMS-enabled Intel GPU driver is completely incompatible with
VT-d right now.  Besides the fact the GPU MMU does not make the calls
to configure remapper, there are many erratas regarding interaction
between IOMMU and GPU, for all generations of chipsets, except possible
Ivy Bridge.

--/liuGKheDV9E18bs
Content-Type: application/pgp-signature

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.20 (FreeBSD)

iQIcBAEBAgAGBQJRo4aIAAoJEJDCuSvBvK1BupEP/jrkM4UbYL67/r58ctSVHFOJ
o+yIn44QieqkVZ6TTx8FpR2kMaRM/oOf1gJrIETXtcUOXE7b38mPmnECnVMUyBUN
l2PGXuBNud0qzzkESWnY/Kvgh7oYq8mCUC7E2c8hIgrpNrbgsbOBFO6neozI3ice
eUlLCA6nXSl3NSbM3kGwGEMimqoCGZvNFNOJPr+8sDvW4LSmYduJ92afwcbYCm7E
TxekMNC/PbqXGCyP6nFLmYSZvpNa3rJdAYX9AIjIrBfjINg14MNaTxNj/qanR2kS
/vqEhEjsnhPK7ulwexWmT17wRqDGkT8BPaAd+Qh8+yWw98UrwFlDuOkPQ6YqYlV0
YOAiVoXjUvsFtBi4Mac/rUjnzdKj2eq9K/w38alK4DZEwScXDHAtPS2EPP/sBb2M
8VAssK6qL+LifdGSBycOwJboUykCgdvxkmpGEMXWwkHhqqE5OncfEm+R9udCUrqK
S3eTNv9nffxv9T8cHzwtwAFU1auUUhTNpS3heQAWv4KqQnJ+EkJZPRBmCewFEX6I
NlqllWD4mbuT5Y1nMv90Dd8yzZ/kQZZKxfizszKtlY04n/OvqSGZPH/Sbti/UYw9
dpF4wgY3QGD/g7IrjoPX3T4r8YSqAJOsfOWaUO5WGxz6zxwRzBvxyxQCWp0pK3no
UISgUlaIR3SfhodbRTmQ
=JkOh
-----END PGP SIGNATURE-----

--/liuGKheDV9E18bs--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130527161505.GE3047>