X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=datapath%2Fbrcompat.c;h=be361ece2026be3498d521c9228248b91892d760;hb=449776d81d7b03d9b5f552b402c8a619323e8aa2;hp=db0a70f53cc3b9712b0beb3d3fc5c43d663e3f0c;hpb=3c303e5fe1061b8715be018ae8e535cbc24303c9;p=openvswitch diff --git a/datapath/brcompat.c b/datapath/brcompat.c index db0a70f5..be361ece 100644 --- a/datapath/brcompat.c +++ b/datapath/brcompat.c @@ -20,7 +20,6 @@ #include "compat.h" #include "openvswitch/brcompat-netlink.h" #include "brc_procfs.h" -#include "brc_sysfs.h" #include "datapath.h" #include "dp_dev.h" @@ -523,27 +522,6 @@ error: return ERR_PTR(error); } -int brc_add_dp(struct datapath *dp) -{ - if (!try_module_get(THIS_MODULE)) - return -ENODEV; -#ifdef SUPPORT_SYSFS - brc_sysfs_add_dp(dp); -#endif - - return 0; -} - -int brc_del_dp(struct datapath *dp) -{ -#ifdef SUPPORT_SYSFS - brc_sysfs_del_dp(dp); -#endif - module_put(THIS_MODULE); - - return 0; -} - static int __init brc_init(void) { @@ -568,16 +546,6 @@ __init brc_init(void) /* Set the openvswitch_mod device ioctl handler */ dp_ioctl_hook = brc_dev_ioctl; - /* Register hooks for datapath adds and deletes */ - dp_add_dp_hook = brc_add_dp; - dp_del_dp_hook = brc_del_dp; - - /* Register hooks for interface adds and deletes */ -#ifdef SUPPORT_SYSFS - dp_add_if_hook = brc_sysfs_add_if; - dp_del_if_hook = brc_sysfs_del_if; -#endif - /* Randomize the initial sequence number. This is not a security * feature; it only helps avoid crossed wires between userspace and * the kernel when the module is unloaded and reloaded. */ @@ -618,14 +586,6 @@ error: static void brc_cleanup(void) { - /* Unregister hooks for datapath adds and deletes */ - dp_add_dp_hook = NULL; - dp_del_dp_hook = NULL; - - /* Unregister hooks for interface adds and deletes */ - dp_add_if_hook = NULL; - dp_del_if_hook = NULL; - /* Unregister ioctl hooks */ dp_ioctl_hook = NULL; brioctl_set(NULL);