Commit 82b0945c authored by Saurabh Sengar's avatar Saurabh Sengar Committed by Greg Kroah-Hartman

tools: hv: Add new fcopy application based on uio driver

New fcopy application using uio_hv_generic driver. This application
copies file from Hyper-V host to guest VM.

A big part of this code is copied from tools/hv/hv_fcopy_daemon.c
which this new application is replacing.
Signed-off-by: default avatarSaurabh Sengar <ssengar@linux.microsoft.com>
Reviewed-by: default avatarLong Li <longli@microsoft.com>
Link: https://lore.kernel.org/r/1711788723-8593-6-git-send-email-ssengar@linux.microsoft.comSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 45bab4d7
hv_kvp_daemon-y += hv_kvp_daemon.o hv_kvp_daemon-y += hv_kvp_daemon.o
hv_vss_daemon-y += hv_vss_daemon.o hv_vss_daemon-y += hv_vss_daemon.o
hv_fcopy_daemon-y += hv_fcopy_daemon.o hv_fcopy_uio_daemon-y += hv_fcopy_uio_daemon.o
hv_fcopy_uio_daemon-y += vmbus_bufring.o
...@@ -2,6 +2,7 @@ ...@@ -2,6 +2,7 @@
# Makefile for Hyper-V tools # Makefile for Hyper-V tools
include ../scripts/Makefile.include include ../scripts/Makefile.include
ARCH := $(shell uname -m 2>/dev/null)
sbindir ?= /usr/sbin sbindir ?= /usr/sbin
libexecdir ?= /usr/libexec libexecdir ?= /usr/libexec
sharedstatedir ?= /var/lib sharedstatedir ?= /var/lib
...@@ -17,7 +18,10 @@ MAKEFLAGS += -r ...@@ -17,7 +18,10 @@ MAKEFLAGS += -r
override CFLAGS += -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include override CFLAGS += -O2 -Wall -g -D_GNU_SOURCE -I$(OUTPUT)include
ALL_TARGETS := hv_kvp_daemon hv_vss_daemon hv_fcopy_daemon ALL_TARGETS := hv_kvp_daemon hv_vss_daemon
ifneq ($(ARCH), aarch64)
ALL_TARGETS += hv_fcopy_uio_daemon
endif
ALL_PROGRAMS := $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS)) ALL_PROGRAMS := $(patsubst %,$(OUTPUT)%,$(ALL_TARGETS))
ALL_SCRIPTS := hv_get_dhcp_info.sh hv_get_dns_info.sh hv_set_ifconfig.sh ALL_SCRIPTS := hv_get_dhcp_info.sh hv_get_dns_info.sh hv_set_ifconfig.sh
...@@ -39,10 +43,10 @@ $(HV_VSS_DAEMON_IN): FORCE ...@@ -39,10 +43,10 @@ $(HV_VSS_DAEMON_IN): FORCE
$(OUTPUT)hv_vss_daemon: $(HV_VSS_DAEMON_IN) $(OUTPUT)hv_vss_daemon: $(HV_VSS_DAEMON_IN)
$(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $< -o $@ $(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $< -o $@
HV_FCOPY_DAEMON_IN := $(OUTPUT)hv_fcopy_daemon-in.o HV_FCOPY_UIO_DAEMON_IN := $(OUTPUT)hv_fcopy_uio_daemon-in.o
$(HV_FCOPY_DAEMON_IN): FORCE $(HV_FCOPY_UIO_DAEMON_IN): FORCE
$(Q)$(MAKE) $(build)=hv_fcopy_daemon $(Q)$(MAKE) $(build)=hv_fcopy_uio_daemon
$(OUTPUT)hv_fcopy_daemon: $(HV_FCOPY_DAEMON_IN) $(OUTPUT)hv_fcopy_uio_daemon: $(HV_FCOPY_UIO_DAEMON_IN)
$(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $< -o $@ $(QUIET_LINK)$(CC) $(CFLAGS) $(LDFLAGS) $< -o $@
clean: clean:
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment