Lines Matching defs:valsize

362 	int valsize;
393 valsize = prom_asr_list_keys_len();
396 opp->oprom_size = valsize;
402 valsize = prom_asr_list_keys_len();
405 if (valsize > userbufsize)
407 valbuf = (char *)kmem_zalloc(valsize + 1, KM_SLEEP);
409 kmem_free(valbuf, valsize + 1);
413 valsize + sizeof (uint_t) + 1, KM_SLEEP);
414 opp->oprom_size = valsize;
415 bcopy(valbuf, opp->oprom_array, valsize);
416 if (copyout(opp, (void *)arg, (valsize + sizeof (uint_t))) != 0)
418 kmem_free(valbuf, valsize + 1);
419 kmem_free(opp, valsize + sizeof (uint_t) + 1);
422 valsize = prom_asr_export_len();
425 if (valsize > userbufsize)
427 valbuf = (char *)kmem_zalloc(valsize + 1, KM_SLEEP);
429 kmem_free(valbuf, valsize + 1);
433 valsize + sizeof (uint_t) + 1, KM_SLEEP);
434 opp->oprom_size = valsize;
435 bcopy(valbuf, opp->oprom_array, valsize);
436 if (copyout(opp, (void *)arg, (valsize + sizeof (uint_t))) != 0)
438 kmem_free(valbuf, valsize + 1);
439 kmem_free(opp, valsize + sizeof (uint_t) + 1);
442 valsize = prom_asr_export_len();
445 opp->oprom_size = valsize;
561 valsize = prom_getproplen(node_id, propname);
567 valsize = -1;
570 int proplen = valsize;
576 opp->oprom_size = valsize = sizeof (int);
577 bcopy(&proplen, opp->oprom_array, valsize);
578 } else if (valsize > 0 && valsize <= userbufsize) {
579 bzero(opp->oprom_array, valsize + 1);
582 opp->oprom_size = valsize;
583 if (valsize < userbufsize)
584 ++valsize; /* Forces NULL termination */
596 valsize = 1;
598 if (copyout(opp, (void *)arg, (valsize + sizeof (uint_t))) != 0)
619 valsize = strlen(valbuf);
624 if ((cmd == OPROMNXTOPT) && valsize &&
628 valsize = strlen(valbuf);
631 if (valsize == 0) {
633 } else if (++valsize <= userbufsize) {
634 opp->oprom_size = valsize;
635 bzero((caddr_t)opp->oprom_array, (size_t)valsize);
637 (size_t)valsize);
640 if (copyout(opp, (void *)arg, valsize + sizeof (uint_t)) != 0)
727 valsize = strlen(kern_bootargs) + 1;
728 if (valsize > userbufsize) {
733 opp->oprom_size = valsize - 1;
735 if (copyout(opp, (void *)arg, valsize + sizeof (uint_t)) != 0)
748 valsize = strlen(bpath) + 1;
749 if (valsize > userbufsize) {
758 valsize = strlen(saved_cmdline) + 1;
759 if (valsize > userbufsize) {
765 opp->oprom_size = valsize - 1;
766 if (copyout(opp, (void *)arg, valsize + sizeof (uint_t)) != 0)
792 valsize = opp->oprom_size = strlen(dev_name);
793 if (++valsize > userbufsize) {
799 if (copyout(opp, (void *)arg, sizeof (uint_t) + valsize) != 0)
860 valsize = prom_version_name(opp->oprom_array, userbufsize);
861 if (valsize < 0) {
870 (size_t)(min((uint_t)valsize, userbufsize) +
887 valsize = opp->oprom_size = strlen(opp->oprom_array);
889 valsize + 1 + sizeof (uint_t)) != 0)
922 for (valsize = 0; valsize < userbufsize; valsize++) {
923 opp->oprom_array[valsize] = prom_name[valsize];
925 if ((valsize > 0) && (prom_name[valsize] == '\0') &&
926 (prom_name[valsize-1] == '\0')) {
930 opp->oprom_size = valsize;
933 if (copyout(opp, (void *)arg, sizeof (uint_t) + valsize) != 0)
968 valsize = valbuflen + 1; /* +1 for the '\0' */
974 valsize = (opp->oprom_array + userbufsize) - valbuf;
983 valbuf, valsize) < 0)
1000 valsize = userbufsize -
1003 i = prom_version_check(opr->message, valsize, &id);
1007 valsize = offsetof(struct openprom_opr64, message);
1008 valsize += strlen(opr->message) + 1;
1014 (size_t)(min((uint_t)valsize, userbufsize) +