From: Jakub Kicinski Date: Thu, 26 Jul 2018 21:25:26 +0000 (-0700) Subject: netdevsim: make debug dirs' dentries static X-Git-Tag: Ubuntu-5.4-5.4.0-11.14~4765^2~232 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=f61b6db378539e69d8525a1b5001637df1e13040;p=mirror_ubuntu-focal-kernel.git netdevsim: make debug dirs' dentries static The root directories of netdevsim should only be used by the core to create per-device subdirectories, so limit their visibility to the core file. Signed-off-by: Jakub Kicinski Reviewed-by: Quentin Monnet Signed-off-by: David S. Miller --- diff --git a/drivers/net/netdevsim/netdev.c b/drivers/net/netdevsim/netdev.c index 2d244551298b..8d8e2b3f263e 100644 --- a/drivers/net/netdevsim/netdev.c +++ b/drivers/net/netdevsim/netdev.c @@ -41,6 +41,9 @@ struct nsim_vf_config { static u32 nsim_dev_id; +static struct dentry *nsim_ddir; +static struct dentry *nsim_sdev_ddir; + static int nsim_num_vf(struct device *dev) { struct netdevsim *ns = to_nsim(dev); @@ -566,9 +569,6 @@ static struct rtnl_link_ops nsim_link_ops __read_mostly = { .dellink = nsim_dellink, }; -struct dentry *nsim_ddir; -struct dentry *nsim_sdev_ddir; - static int __init nsim_module_init(void) { int err; diff --git a/drivers/net/netdevsim/netdevsim.h b/drivers/net/netdevsim/netdevsim.h index 02be199eb005..384c254fafc5 100644 --- a/drivers/net/netdevsim/netdevsim.h +++ b/drivers/net/netdevsim/netdevsim.h @@ -103,9 +103,6 @@ struct netdevsim { struct nsim_ipsec ipsec; }; -extern struct dentry *nsim_ddir; -extern struct dentry *nsim_sdev_ddir; - #ifdef CONFIG_BPF_SYSCALL int nsim_bpf_init(struct netdevsim *ns); void nsim_bpf_uninit(struct netdevsim *ns);