addr.c
上传用户:lgb322
上传日期:2013-02-24
资源大小:30529k
文件大小:3k
- /* net/atm/addr.c - Local ATM address registry */
- /* Written 1995-2000 by Werner Almesberger, EPFL LRC/ICA */
- #include <linux/atm.h>
- #include <linux/atmdev.h>
- #include <linux/sched.h>
- #include <asm/uaccess.h>
- #include "signaling.h"
- #include "addr.h"
- static int check_addr(struct sockaddr_atmsvc *addr)
- {
- int i;
- if (addr->sas_family != AF_ATMSVC) return -EAFNOSUPPORT;
- if (!*addr->sas_addr.pub)
- return *addr->sas_addr.prv ? 0 : -EINVAL;
- for (i = 1; i < ATM_E164_LEN+1; i++) /* make sure it's