Lines Matching refs:mem_name

100 static int mm_read_mem_name(intptr_t data, mem_name_t *mem_name);
637 mem_name_t mem_name;
645 if ((err = mm_read_mem_name(data, &mem_name)) < 0)
653 if ((err = cpu_get_mem_name(mem_name.m_synd, mem_name.m_type,
654 mem_name.m_addr, buf, bufsize, &len)) != 0) {
659 if (len >= mem_name.m_namelen) {
664 if (copyoutstr(buf, (char *)mem_name.m_name,
665 mem_name.m_namelen, NULL) != 0) {
703 mem_name_t mem_name;
713 if ((err = mm_read_mem_name(data, &mem_name)) < 0)
718 if (mem_name.m_namelen > 1024)
719 mem_name.m_namelen = 1024; /* cap at 1024 bytes */
721 name = kmem_alloc(mem_name.m_namelen, KM_SLEEP);
723 if ((err = copyinstr((char *)mem_name.m_name, (char *)name,
724 mem_name.m_namelen, &name_len)) != 0) {
726 kmem_free(name, mem_name.m_namelen);
735 kmem_free(name, mem_name.m_namelen);
739 if (len > mem_name.m_sidlen) {
741 kmem_free(name, mem_name.m_namelen);
745 if (copyoutstr(buf, (char *)mem_name.m_sid,
746 mem_name.m_sidlen, NULL) != 0) {
748 kmem_free(name, mem_name.m_namelen);
753 kmem_free(name, mem_name.m_namelen);
1077 * pointed to by the mem_name argument.
1080 mm_read_mem_name(intptr_t data, mem_name_t *mem_name)
1083 if (copyin((void *)data, mem_name, sizeof (mem_name_t)))
1092 mem_name->m_addr = mem_name32.m_addr;
1093 mem_name->m_synd = mem_name32.m_synd;
1094 mem_name->m_type[0] = mem_name32.m_type[0];
1095 mem_name->m_type[1] = mem_name32.m_type[1];
1096 mem_name->m_name = (caddr_t)(uintptr_t)mem_name32.m_name;
1097 mem_name->m_namelen = (size_t)mem_name32.m_namelen;
1098 mem_name->m_sid = (caddr_t)(uintptr_t)mem_name32.m_sid;
1099 mem_name->m_sidlen = (size_t)mem_name32.m_sidlen;