Changeset View
Changeset View
Standalone View
Standalone View
head/sys/compat/freebsd32/freebsd32_misc.c
Show First 20 Lines • Show All 3,160 Lines • ▼ Show 20 Lines | freebsd32_copyout_strings(struct image_params *imgp) | ||||
imgp->pagesizes = destp; | imgp->pagesizes = destp; | ||||
copyout(pagesizes32, (void *)destp, sizeof(pagesizes32)); | copyout(pagesizes32, (void *)destp, sizeof(pagesizes32)); | ||||
imgp->pagesizeslen = sizeof(pagesizes32); | imgp->pagesizeslen = sizeof(pagesizes32); | ||||
destp -= ARG_MAX - imgp->args->stringspace; | destp -= ARG_MAX - imgp->args->stringspace; | ||||
destp = rounddown2(destp, sizeof(uint32_t)); | destp = rounddown2(destp, sizeof(uint32_t)); | ||||
vectp = (uint32_t *)destp; | vectp = (uint32_t *)destp; | ||||
if (imgp->sysent->sv_stackgap != NULL) | |||||
imgp->sysent->sv_stackgap(imgp, (u_long *)&vectp); | |||||
if (imgp->auxargs) { | if (imgp->auxargs) { | ||||
/* | /* | ||||
* Allocate room on the stack for the ELF auxargs | * Allocate room on the stack for the ELF auxargs | ||||
* array. It has up to AT_COUNT entries. | * array. It has up to AT_COUNT entries. | ||||
*/ | */ | ||||
vectp -= howmany(AT_COUNT * sizeof(Elf32_Auxinfo), | vectp -= howmany(AT_COUNT * sizeof(Elf32_Auxinfo), | ||||
sizeof(*vectp)); | sizeof(*vectp)); | ||||
} | } | ||||
▲ Show 20 Lines • Show All 308 Lines • Show Last 20 Lines |