Lines Matching refs:iwp
736 static int ioctl_standard_iw_point(struct iw_point *iwp, unsigned int cmd,
755 if (iwp->length == descr->max_tokens + 1)
757 else if (IW_IS_SET(cmd) && (iwp->length != 0)) {
760 len = iwp->length * descr->token_size;
765 err = copy_from_user(essid, iwp->pointer, len);
769 if (essid[iwp->length - 1] == '\0')
777 iwp->length -= essid_compat;
782 if (!iwp->pointer && iwp->length != 0)
785 if (iwp->length > descr->max_tokens)
787 if (iwp->length < descr->min_tokens)
791 if (!iwp->pointer)
794 user_length = iwp->length;
830 if (IW_IS_SET(cmd) && (iwp->length != 0)) {
831 if (copy_from_user(extra, iwp->pointer,
832 iwp->length *
841 if (iwp->length < sizeof(*ee) + ee->key_len) {
855 * provided, and it may check iwp->length rather than having
857 * iwp->length, this ioctl just copies back max_token tokens
861 iwp->length = descr->max_tokens;
864 err = handler(dev, info, (union iwreq_data *) iwp, extra);
866 iwp->length += essid_compat;
871 if (user_length < iwp->length) {
876 if (copy_to_user(iwp->pointer, extra,
877 iwp->length *
887 union iwreq_data *data = (union iwreq_data *) iwp;
1094 struct iw_point iwp;
1103 iwp.pointer = compat_ptr(iwp_compat->pointer);
1104 iwp.length = iwp_compat->length;
1105 iwp.flags = iwp_compat->flags;
1107 err = ioctl_standard_iw_point(&iwp, cmd, descr, handler, dev, info);
1109 iwp_compat->pointer = ptr_to_compat(iwp.pointer);
1110 iwp_compat->length = iwp.length;
1111 iwp_compat->flags = iwp.flags;