Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F151139700
D23062.id66498.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D23062.id66498.diff
View Options
Index: head/sys/compat/linprocfs/linprocfs.c
===================================================================
--- head/sys/compat/linprocfs/linprocfs.c
+++ head/sys/compat/linprocfs/linprocfs.c
@@ -1146,7 +1146,7 @@
vm_map_entry_t entry, tmp_entry;
vm_object_t obj, tobj, lobj;
vm_offset_t e_start, e_end;
- vm_ooffset_t off = 0;
+ vm_ooffset_t off;
vm_prot_t e_prot;
unsigned int last_timestamp;
char *name = "", *freename = NULL;
@@ -1156,6 +1156,7 @@
int error;
struct vnode *vp;
struct vattr vat;
+ bool private;
PROC_LOCK(p);
error = p_candebug(td, p);
@@ -1186,17 +1187,20 @@
e_start = entry->start;
e_end = entry->end;
obj = entry->object.vm_object;
- for (lobj = tobj = obj; tobj; tobj = tobj->backing_object) {
+ off = entry->offset;
+ for (lobj = tobj = obj; tobj != NULL;
+ lobj = tobj, tobj = tobj->backing_object) {
VM_OBJECT_RLOCK(tobj);
+ off += lobj->backing_object_offset;
if (lobj != obj)
VM_OBJECT_RUNLOCK(lobj);
- lobj = tobj;
}
+ private = (entry->eflags & MAP_ENTRY_COW) != 0 || obj == NULL ||
+ (obj->flags & OBJ_ANON) != 0;
last_timestamp = map->timestamp;
vm_map_unlock_read(map);
ino = 0;
if (lobj) {
- off = IDX_TO_OFF(lobj->size);
vp = vm_object_vnode(lobj);
if (vp != NULL)
vref(vp);
@@ -1233,7 +1237,7 @@
(e_prot & VM_PROT_READ)?"r":"-",
(e_prot & VM_PROT_WRITE)?"w":"-",
(e_prot & VM_PROT_EXECUTE)?"x":"-",
- "p",
+ private ? "p" : "s",
(u_long)off,
0,
0,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Apr 7, 8:53 AM (49 m, 53 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
30900323
Default Alt Text
D23062.id66498.diff (1 KB)
Attached To
Mode
D23062: Fix some issues in the linprocfs maps file.
Attached
Detach File
Event Timeline
Log In to Comment