diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2016-12-13 12:11:01 -0800 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2016-12-13 12:11:01 -0800 |
commit | b78b499a67c3f77aeb6cd0b54724bc38b141255d (patch) | |
tree | 8ebdb5303bb1552577182d9fe4086910b8648d22 /tools | |
parent | 098c30557a9a19827240aaadc137e4668157dc6b (diff) | |
parent | 190cc65e912de7e8f7ebddcecfbf55a610281a8c (diff) | |
download | linux-exynos-b78b499a67c3f77aeb6cd0b54724bc38b141255d.tar.gz linux-exynos-b78b499a67c3f77aeb6cd0b54724bc38b141255d.tar.bz2 linux-exynos-b78b499a67c3f77aeb6cd0b54724bc38b141255d.zip |
Merge tag 'char-misc-4.10-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc
Pull char/misc driver updates from Greg KH:
"Here's the big char/misc driver patches for 4.10-rc1. Lots of tiny
changes over lots of "minor" driver subsystems, the largest being some
new FPGA drivers. Other than that, a few other new drivers, but no new
driver subsystems added for this kernel cycle, a nice change.
All of these have been in linux-next with no reported issues"
* tag 'char-misc-4.10-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: (107 commits)
uio-hv-generic: store physical addresses instead of virtual
Tools: hv: kvp: configurable external scripts path
uio-hv-generic: new userspace i/o driver for VMBus
vmbus: add support for dynamic device id's
hv: change clockevents unbind tactics
hv: acquire vmbus_connection.channel_mutex in vmbus_free_channels()
hyperv: Fix spelling of HV_UNKOWN
mei: bus: enable non-blocking RX
mei: fix the back to back interrupt handling
mei: synchronize irq before initiating a reset.
VME: Remove shutdown entry from vme_driver
auxdisplay: ht16k33: select framebuffer helper modules
MAINTAINERS: add git url for fpga
fpga: Clarify how write_init works streaming modes
fpga zynq: Fix incorrect ISR state on bootup
fpga zynq: Remove priv->dev
fpga zynq: Add missing \n to messages
fpga: Add COMPILE_TEST to all drivers
uio: pruss: add clk_disable()
char/pcmcia: add some error checking in scr24x_read()
...
Diffstat (limited to 'tools')
-rw-r--r-- | tools/hv/Makefile | 3 | ||||
-rw-r--r-- | tools/hv/hv_fcopy_daemon.c | 7 | ||||
-rw-r--r-- | tools/hv/hv_kvp_daemon.c | 20 |
3 files changed, 10 insertions, 20 deletions
diff --git a/tools/hv/Makefile b/tools/hv/Makefile index a8c4644022a6..0d1e61b81844 100644 --- a/tools/hv/Makefile +++ b/tools/hv/Makefile @@ -1,9 +1,8 @@ # Makefile for Hyper-V tools CC = $(CROSS_COMPILE)gcc -PTHREAD_LIBS = -lpthread WARNINGS = -Wall -Wextra -CFLAGS = $(WARNINGS) -g $(PTHREAD_LIBS) $(shell getconf LFS_CFLAGS) +CFLAGS = $(WARNINGS) -g $(shell getconf LFS_CFLAGS) CFLAGS += -D__EXPORTED_HEADERS__ -I../../include/uapi -I../../include diff --git a/tools/hv/hv_fcopy_daemon.c b/tools/hv/hv_fcopy_daemon.c index fdc9ca4c0356..26ae609a9448 100644 --- a/tools/hv/hv_fcopy_daemon.c +++ b/tools/hv/hv_fcopy_daemon.c @@ -18,21 +18,14 @@ #include <sys/types.h> -#include <sys/socket.h> -#include <sys/poll.h> -#include <linux/types.h> -#include <linux/kdev_t.h> #include <stdio.h> #include <stdlib.h> #include <unistd.h> -#include <string.h> -#include <ctype.h> #include <errno.h> #include <linux/hyperv.h> #include <syslog.h> #include <sys/stat.h> #include <fcntl.h> -#include <dirent.h> #include <getopt.h> static int target_fd; diff --git a/tools/hv/hv_kvp_daemon.c b/tools/hv/hv_kvp_daemon.c index bc7adb84e679..f1758fcbc37d 100644 --- a/tools/hv/hv_kvp_daemon.c +++ b/tools/hv/hv_kvp_daemon.c @@ -22,8 +22,6 @@ */ -#include <sys/types.h> -#include <sys/socket.h> #include <sys/poll.h> #include <sys/utsname.h> #include <stdio.h> @@ -34,7 +32,6 @@ #include <errno.h> #include <arpa/inet.h> #include <linux/hyperv.h> -#include <linux/netlink.h> #include <ifaddrs.h> #include <netdb.h> #include <syslog.h> @@ -96,13 +93,13 @@ static struct utsname uts_buf; #define KVP_CONFIG_LOC "/var/lib/hyperv" +#ifndef KVP_SCRIPTS_PATH +#define KVP_SCRIPTS_PATH "/usr/libexec/hypervkvpd/" +#endif + #define MAX_FILE_NAME 100 #define ENTRIES_PER_BLOCK 50 -#ifndef SOL_NETLINK -#define SOL_NETLINK 270 -#endif - struct kvp_record { char key[HV_KVP_EXCHANGE_MAX_KEY_SIZE]; char value[HV_KVP_EXCHANGE_MAX_VALUE_SIZE]; @@ -702,7 +699,7 @@ static char *kvp_mac_to_if_name(char *mac) if (dir == NULL) return NULL; - snprintf(dev_id, sizeof(dev_id), kvp_net_dir); + snprintf(dev_id, sizeof(dev_id), "%s", kvp_net_dir); q = dev_id + strlen(kvp_net_dir); while ((entry = readdir(dir)) != NULL) { @@ -825,7 +822,7 @@ static void kvp_get_ipconfig_info(char *if_name, * . */ - sprintf(cmd, "%s", "hv_get_dns_info"); + sprintf(cmd, KVP_SCRIPTS_PATH "%s", "hv_get_dns_info"); /* * Execute the command to gather DNS info. @@ -842,7 +839,7 @@ static void kvp_get_ipconfig_info(char *if_name, * Enabled: DHCP enabled. */ - sprintf(cmd, "%s %s", "hv_get_dhcp_info", if_name); + sprintf(cmd, KVP_SCRIPTS_PATH "%s %s", "hv_get_dhcp_info", if_name); file = popen(cmd, "r"); if (file == NULL) @@ -1348,7 +1345,8 @@ static int kvp_set_ip_info(char *if_name, struct hv_kvp_ipaddr_value *new_val) * invoke the external script to do its magic. */ - snprintf(cmd, sizeof(cmd), "%s %s", "hv_set_ifconfig", if_file); + snprintf(cmd, sizeof(cmd), KVP_SCRIPTS_PATH "%s %s", + "hv_set_ifconfig", if_file); if (system(cmd)) { syslog(LOG_ERR, "Failed to execute cmd '%s'; error: %d %s", cmd, errno, strerror(errno)); |