Lines Matching defs:oldlenp
173 sysctl_doprof(int *name, u_int namelen, user_addr_t oldp, size_t *oldlenp,
187 sysctl_struct(user_addr_t oldp, size_t *oldlenp, user_addr_t newp,
297 if (uap->oldlenp != USER_ADDR_NULL) {
298 uint64_t oldlen64 = fuulong(uap->oldlenp);
341 uap->oldlenp,
386 if (uap->oldlenp != USER_ADDR_NULL)
387 error = suulong(uap->oldlenp, oldlen);
602 kern_sysctl(int *name, u_int namelen, user_addr_t oldp, size_t *oldlenp,
632 return (sysctl_doproc(name + 1, namelen - 1, oldp, oldlenp));
635 return (sysctl_doprof(name + 1, namelen - 1, oldp, oldlenp,
639 return (kdebug_ops(name + 1, namelen - 1, oldp, oldlenp, p));
643 return (sysctl_procargs(name + 1, namelen - 1, oldp, oldlenp, p));
647 return (sysctl_procargs2(name + 1, namelen - 1, oldp, oldlenp, p));
650 return(sysctl_dopanicinfo(name + 1, namelen - 1, oldp, oldlenp,
654 return sysctl_affinity(name+1, namelen-1, oldp, oldlenp,
657 return sysctl_translate(name+1, namelen-1, oldp, oldlenp, newp,
663 oldlenp, newp, newlen, p);
675 error = sysctl_int(oldp, oldlenp, newp, newlen, &tmp);
730 debug_sysctl(int *name, u_int namelen, user_addr_t oldp, size_t *oldlenp,
745 return (sysctl_rdstring(oldp, oldlenp, newp, cdp->debugname));
747 return (sysctl_int(oldp, oldlenp, newp, newlen, cdp->debugvar));
770 sysctl_int(user_addr_t oldp, size_t *oldlenp,
775 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
777 if (oldp && *oldlenp < sizeof(int))
781 *oldlenp = sizeof(int);
795 sysctl_rdint(user_addr_t oldp, size_t *oldlenp, user_addr_t newp, int val)
799 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
801 if (oldp && *oldlenp < sizeof(int))
805 *oldlenp = sizeof(int);
816 sysctl_quad(user_addr_t oldp, size_t *oldlenp,
821 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
823 if (oldp && *oldlenp < sizeof(quad_t))
827 *oldlenp = sizeof(quad_t);
839 sysctl_rdquad(user_addr_t oldp, size_t *oldlenp, user_addr_t newp, quad_t val)
843 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
845 if (oldp && *oldlenp < sizeof(quad_t))
849 *oldlenp = sizeof(quad_t);
866 sysctl_trstring(user_addr_t oldp, size_t *oldlenp,
871 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
874 if (oldp && (len < 0 || *oldlenp < 1))
876 if (oldp && (*oldlenp < (size_t)len))
877 copylen = *oldlenp + 1;
880 *oldlenp = copylen - 1; /* deal with NULL strings correctly */
886 oldp += *oldlenp;
903 sysctl_string(user_addr_t oldp, size_t *oldlenp,
908 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
911 if (oldp && (len < 0 || *oldlenp < (size_t)len))
915 *oldlenp = len -1; /* deal with NULL strings correctly */
931 sysctl_rdstring(user_addr_t oldp, size_t *oldlenp,
936 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
939 if (oldp && *oldlenp < (size_t)len)
943 *oldlenp = len;
954 sysctl_struct(user_addr_t oldp, size_t *oldlenp,
959 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
961 if (oldp && (len < 0 || *oldlenp < (size_t)len))
966 *oldlenp = len;
979 sysctl_rdstruct(user_addr_t oldp, size_t *oldlenp,
984 if (oldp != USER_ADDR_NULL && oldlenp == NULL)
986 if (oldp && (len < 0 || *oldlenp < (size_t)len))
990 *oldlenp = len;
1670 /* when where (oldp from sysctl) is NULL and sizep (oldlenp from sysctl */