64730b7ec2
Example of configuration: ctl.conf: portal-group pg0 { discovery-auth-group no-authentication listen 0.0.0.0 listen [::] } target iqn.2012-06.com.example:target0 { auth-group no-authentication portal-group pg0 port ioctl/5/3 lun 0 { path /z/test.img size 8G } lun 1 { path /z/test1.img size 8G } } bhyve <...> -s 4,virtio-scsi,/dev/cam/ctl5.3,iid=3 <VM_NAME> From inside guest: root@:~ # zpool status test pool: test state: ONLINE scan: none requested config: NAME STATE READ WRITE CKSUM test ONLINE 0 0 0 da0 ONLINE 0 0 0 da1 ONLINE 0 0 0 dmesg: da0 at vtscsi0 bus 0 scbus0 target 0 lun 0 da0: <FREEBSD CTLDISK 0001> Fixed Direct Access SPC-5 SCSI device da0: Serial Number MYSERIAL0000 da0: 300.000MB/s transfers da0: Command Queueing enabled da0: 8192MB (16777216 512 byte sectors) da1 at vtscsi0 bus 0 scbus0 target 0 lun 1 da1: <FREEBSD CTLDISK 0001> Fixed Direct Access SPC-5 SCSI device da1: Serial Number MYSERIAL0001 da1: 300.000MB/s transfers da1: Command Queueing enabled da1: 8192MB (16777216 512 byte sectors) Discussed with: grehan Reviewed by: mav Obtained from: TrueOS Relnotes: Yes Sponsored by: iXsystems Inc. Tested with: FreeBSD HEAD, Fedora 28 (Workstation) and Ubuntu 18.04. Differential Revision: https://reviews.freebsd.org/D15276
92 lines
1.3 KiB
Makefile
92 lines
1.3 KiB
Makefile
#
|
|
# $FreeBSD$
|
|
#
|
|
|
|
.include <src.opts.mk>
|
|
CFLAGS+=-I${SRCTOP}/sys
|
|
.PATH: ${SRCTOP}/sys/cam/ctl
|
|
|
|
PROG= bhyve
|
|
PACKAGE= bhyve
|
|
|
|
DEBUG_FLAGS= -g -O0
|
|
|
|
MAN= bhyve.8
|
|
|
|
BHYVE_SYSDIR?=${SRCTOP}
|
|
|
|
SRCS= \
|
|
atkbdc.c \
|
|
acpi.c \
|
|
bhyvegc.c \
|
|
bhyverun.c \
|
|
block_if.c \
|
|
bootrom.c \
|
|
console.c \
|
|
consport.c \
|
|
ctl_util.c \
|
|
ctl_scsi_all.c \
|
|
dbgport.c \
|
|
fwctl.c \
|
|
gdb.c \
|
|
inout.c \
|
|
ioapic.c \
|
|
mem.c \
|
|
mevent.c \
|
|
mptbl.c \
|
|
pci_ahci.c \
|
|
pci_e82545.c \
|
|
pci_emul.c \
|
|
pci_fbuf.c \
|
|
pci_hostbridge.c \
|
|
pci_irq.c \
|
|
pci_lpc.c \
|
|
pci_passthru.c \
|
|
pci_virtio_block.c \
|
|
pci_virtio_console.c \
|
|
pci_virtio_net.c \
|
|
pci_virtio_rnd.c \
|
|
pci_virtio_scsi.c \
|
|
pci_uart.c \
|
|
pci_xhci.c \
|
|
pm.c \
|
|
post.c \
|
|
ps2kbd.c \
|
|
ps2mouse.c \
|
|
rfb.c \
|
|
rtc.c \
|
|
smbiostbl.c \
|
|
sockstream.c \
|
|
task_switch.c \
|
|
uart_emul.c \
|
|
usb_emul.c \
|
|
usb_mouse.c \
|
|
virtio.c \
|
|
vga.c \
|
|
xmsr.c \
|
|
spinup_ap.c \
|
|
iov.c
|
|
|
|
.PATH: ${BHYVE_SYSDIR}/sys/amd64/vmm
|
|
SRCS+= vmm_instruction_emul.c
|
|
|
|
LIBADD= vmmapi md pthread z util sbuf cam
|
|
|
|
.if ${MK_OPENSSL} == "no"
|
|
CFLAGS+=-DNO_OPENSSL
|
|
.else
|
|
LIBADD+= crypto
|
|
.endif
|
|
|
|
CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/e1000
|
|
CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/mii
|
|
CFLAGS+= -I${BHYVE_SYSDIR}/sys/dev/usb/controller
|
|
|
|
.ifdef GDB_LOG
|
|
CFLAGS+=-DGDB_LOG
|
|
.endif
|
|
|
|
WARNS?= 2
|
|
|
|
.include <bsd.prog.mk>
|