diff options
Diffstat (limited to 'net/atm')
-rw-r--r-- | net/atm/addr.c | 1 | ||||
-rw-r--r-- | net/atm/atm_sysfs.c | 1 | ||||
-rw-r--r-- | net/atm/br2684.c | 1 | ||||
-rw-r--r-- | net/atm/clip.c | 1 | ||||
-rw-r--r-- | net/atm/common.c | 1 | ||||
-rw-r--r-- | net/atm/lec.c | 1 | ||||
-rw-r--r-- | net/atm/mpc.c | 1 | ||||
-rw-r--r-- | net/atm/mpoa_caches.c | 1 | ||||
-rw-r--r-- | net/atm/mpoa_proc.c | 1 | ||||
-rw-r--r-- | net/atm/pppoatm.c | 1 | ||||
-rw-r--r-- | net/atm/proc.c | 11 | ||||
-rw-r--r-- | net/atm/raw.c | 1 | ||||
-rw-r--r-- | net/atm/resources.c | 1 | ||||
-rw-r--r-- | net/atm/signaling.c | 1 |
14 files changed, 15 insertions, 9 deletions
diff --git a/net/atm/addr.c b/net/atm/addr.c index cf3ae8b4757..dcda35c66f1 100644 --- a/net/atm/addr.c +++ b/net/atm/addr.c @@ -4,6 +4,7 @@ #include <linux/atm.h> #include <linux/atmdev.h> +#include <linux/slab.h> #include <linux/uaccess.h> #include "signaling.h" diff --git a/net/atm/atm_sysfs.c b/net/atm/atm_sysfs.c index f693b78eb46..799c631f0fe 100644 --- a/net/atm/atm_sysfs.c +++ b/net/atm/atm_sysfs.c @@ -1,6 +1,7 @@ /* ATM driver model support. */ #include <linux/kernel.h> +#include <linux/slab.h> #include <linux/init.h> #include <linux/kobject.h> #include <linux/atmdev.h> diff --git a/net/atm/br2684.c b/net/atm/br2684.c index 4d64d87e757..d6c7ceaf13e 100644 --- a/net/atm/br2684.c +++ b/net/atm/br2684.c @@ -18,6 +18,7 @@ #include <linux/rtnetlink.h> #include <linux/ip.h> #include <linux/uaccess.h> +#include <linux/slab.h> #include <net/arp.h> #include <linux/atm.h> #include <linux/atmdev.h> diff --git a/net/atm/clip.c b/net/atm/clip.c index ebfa022008f..313aba11316 100644 --- a/net/atm/clip.c +++ b/net/atm/clip.c @@ -30,6 +30,7 @@ #include <linux/seq_file.h> #include <linux/rcupdate.h> #include <linux/jhash.h> +#include <linux/slab.h> #include <net/route.h> /* for struct rtable and routing */ #include <net/icmp.h> /* icmp_send */ #include <linux/param.h> /* for HZ */ diff --git a/net/atm/common.c b/net/atm/common.c index 74d095a081e..97ed94aa0cb 100644 --- a/net/atm/common.c +++ b/net/atm/common.c @@ -18,6 +18,7 @@ #include <linux/skbuff.h> #include <linux/bitops.h> #include <linux/init.h> +#include <linux/slab.h> #include <net/sock.h> /* struct sock */ #include <linux/uaccess.h> #include <linux/poll.h> diff --git a/net/atm/lec.c b/net/atm/lec.c index 5da5753157f..feeaf571847 100644 --- a/net/atm/lec.c +++ b/net/atm/lec.c @@ -6,6 +6,7 @@ #define pr_fmt(fmt) KBUILD_MODNAME ":%s: " fmt, __func__ +#include <linux/slab.h> #include <linux/kernel.h> #include <linux/bitops.h> #include <linux/capability.h> diff --git a/net/atm/mpc.c b/net/atm/mpc.c index a6521c8aa88..436f2e17765 100644 --- a/net/atm/mpc.c +++ b/net/atm/mpc.c @@ -2,6 +2,7 @@ #include <linux/kernel.h> #include <linux/string.h> +#include <linux/slab.h> #include <linux/timer.h> #include <linux/init.h> #include <linux/bitops.h> diff --git a/net/atm/mpoa_caches.c b/net/atm/mpoa_caches.c index 4c141810eb6..e773d833691 100644 --- a/net/atm/mpoa_caches.c +++ b/net/atm/mpoa_caches.c @@ -1,5 +1,6 @@ #include <linux/types.h> #include <linux/atmmpc.h> +#include <linux/slab.h> #include <linux/time.h> #include "mpoa_caches.h" diff --git a/net/atm/mpoa_proc.c b/net/atm/mpoa_proc.c index b9bdb98427e..53e50029227 100644 --- a/net/atm/mpoa_proc.c +++ b/net/atm/mpoa_proc.c @@ -12,6 +12,7 @@ #include <linux/uaccess.h> #include <linux/atmmpc.h> #include <linux/atm.h> +#include <linux/gfp.h> #include "mpc.h" #include "mpoa_caches.h" diff --git a/net/atm/pppoatm.c b/net/atm/pppoatm.c index 400839273c6..e49bb6d948a 100644 --- a/net/atm/pppoatm.c +++ b/net/atm/pppoatm.c @@ -38,6 +38,7 @@ #include <linux/module.h> #include <linux/init.h> #include <linux/skbuff.h> +#include <linux/slab.h> #include <linux/atm.h> #include <linux/atmdev.h> #include <linux/capability.h> diff --git a/net/atm/proc.c b/net/atm/proc.c index 7a96b2376bd..6262aeae398 100644 --- a/net/atm/proc.c +++ b/net/atm/proc.c @@ -22,6 +22,7 @@ #include <linux/netdevice.h> #include <linux/atmclip.h> #include <linux/init.h> /* for __init */ +#include <linux/slab.h> #include <net/net_namespace.h> #include <net/atmclip.h> #include <linux/uaccess.h> @@ -406,7 +407,6 @@ EXPORT_SYMBOL(atm_proc_root); int atm_proc_dev_register(struct atm_dev *dev) { - int digits, num; int error; /* No proc info */ @@ -414,16 +414,9 @@ int atm_proc_dev_register(struct atm_dev *dev) return 0; error = -ENOMEM; - digits = 0; - for (num = dev->number; num; num /= 10) - digits++; - if (!digits) - digits++; - - dev->proc_name = kmalloc(strlen(dev->type) + digits + 2, GFP_KERNEL); + dev->proc_name = kasprintf(GFP_KERNEL, "%s:%d", dev->type, dev->number); if (!dev->proc_name) goto err_out; - sprintf(dev->proc_name, "%s:%d", dev->type, dev->number); dev->proc_entry = proc_create_data(dev->proc_name, 0, atm_proc_root, &proc_atm_dev_ops, dev); diff --git a/net/atm/raw.c b/net/atm/raw.c index d0c4bd047dc..b4f7b9ff3c7 100644 --- a/net/atm/raw.c +++ b/net/atm/raw.c @@ -10,6 +10,7 @@ #include <linux/kernel.h> #include <linux/skbuff.h> #include <linux/mm.h> +#include <linux/slab.h> #include "common.h" #include "protocols.h" diff --git a/net/atm/resources.c b/net/atm/resources.c index 90082904f20..d29e5826151 100644 --- a/net/atm/resources.c +++ b/net/atm/resources.c @@ -19,6 +19,7 @@ #include <linux/capability.h> #include <linux/delay.h> #include <linux/mutex.h> +#include <linux/slab.h> #include <net/sock.h> /* for struct sock */ diff --git a/net/atm/signaling.c b/net/atm/signaling.c index ad1d28ae512..6ba6e466ee5 100644 --- a/net/atm/signaling.c +++ b/net/atm/signaling.c @@ -14,6 +14,7 @@ #include <linux/atmsvc.h> #include <linux/atmdev.h> #include <linux/bitops.h> +#include <linux/slab.h> #include "resources.h" #include "signaling.h" |