aboutsummaryrefslogtreecommitdiffstats
path: root/ipc
diff options
context:
space:
mode:
Diffstat (limited to 'ipc')
-rw-r--r--ipc/msg.c34
-rw-r--r--ipc/sem.c26
-rw-r--r--ipc/shm.c42
-rw-r--r--ipc/util.c6
4 files changed, 58 insertions, 50 deletions
diff --git a/ipc/msg.c b/ipc/msg.c
index a7261d5cbc89..2b6fdbb9e0e9 100644
--- a/ipc/msg.c
+++ b/ipc/msg.c
@@ -1015,22 +1015,24 @@ static int sysvipc_msg_proc_show(struct seq_file *s, void *it)
1015 struct user_namespace *user_ns = seq_user_ns(s); 1015 struct user_namespace *user_ns = seq_user_ns(s);
1016 struct msg_queue *msq = it; 1016 struct msg_queue *msq = it;
1017 1017
1018 return seq_printf(s, 1018 seq_printf(s,
1019 "%10d %10d %4o %10lu %10lu %5u %5u %5u %5u %5u %5u %10lu %10lu %10lu\n", 1019 "%10d %10d %4o %10lu %10lu %5u %5u %5u %5u %5u %5u %10lu %10lu %10lu\n",
1020 msq->q_perm.key, 1020 msq->q_perm.key,
1021 msq->q_perm.id, 1021 msq->q_perm.id,
1022 msq->q_perm.mode, 1022 msq->q_perm.mode,
1023 msq->q_cbytes, 1023 msq->q_cbytes,
1024 msq->q_qnum, 1024 msq->q_qnum,
1025 msq->q_lspid, 1025 msq->q_lspid,
1026 msq->q_lrpid, 1026 msq->q_lrpid,
1027 from_kuid_munged(user_ns, msq->q_perm.uid), 1027 from_kuid_munged(user_ns, msq->q_perm.uid),
1028 from_kgid_munged(user_ns, msq->q_perm.gid), 1028 from_kgid_munged(user_ns, msq->q_perm.gid),
1029 from_kuid_munged(user_ns, msq->q_perm.cuid), 1029 from_kuid_munged(user_ns, msq->q_perm.cuid),
1030 from_kgid_munged(user_ns, msq->q_perm.cgid), 1030 from_kgid_munged(user_ns, msq->q_perm.cgid),
1031 msq->q_stime, 1031 msq->q_stime,
1032 msq->q_rtime, 1032 msq->q_rtime,
1033 msq->q_ctime); 1033 msq->q_ctime);
1034
1035 return 0;
1034} 1036}
1035#endif 1037#endif
1036 1038
diff --git a/ipc/sem.c b/ipc/sem.c
index 92842113c6a9..d1a6edd17eba 100644
--- a/ipc/sem.c
+++ b/ipc/sem.c
@@ -2170,17 +2170,19 @@ static int sysvipc_sem_proc_show(struct seq_file *s, void *it)
2170 2170
2171 sem_otime = get_semotime(sma); 2171 sem_otime = get_semotime(sma);
2172 2172
2173 return seq_printf(s, 2173 seq_printf(s,
2174 "%10d %10d %4o %10u %5u %5u %5u %5u %10lu %10lu\n", 2174 "%10d %10d %4o %10u %5u %5u %5u %5u %10lu %10lu\n",
2175 sma->sem_perm.key, 2175 sma->sem_perm.key,
2176 sma->sem_perm.id, 2176 sma->sem_perm.id,
2177 sma->sem_perm.mode, 2177 sma->sem_perm.mode,
2178 sma->sem_nsems, 2178 sma->sem_nsems,
2179 from_kuid_munged(user_ns, sma->sem_perm.uid), 2179 from_kuid_munged(user_ns, sma->sem_perm.uid),
2180 from_kgid_munged(user_ns, sma->sem_perm.gid), 2180 from_kgid_munged(user_ns, sma->sem_perm.gid),
2181 from_kuid_munged(user_ns, sma->sem_perm.cuid), 2181 from_kuid_munged(user_ns, sma->sem_perm.cuid),
2182 from_kgid_munged(user_ns, sma->sem_perm.cgid), 2182 from_kgid_munged(user_ns, sma->sem_perm.cgid),
2183 sem_otime, 2183 sem_otime,
2184 sma->sem_ctime); 2184 sma->sem_ctime);
2185
2186 return 0;
2185} 2187}
2186#endif 2188#endif
diff --git a/ipc/shm.c b/ipc/shm.c
index 19633b4a2350..d280a74af2ef 100644
--- a/ipc/shm.c
+++ b/ipc/shm.c
@@ -1342,25 +1342,27 @@ static int sysvipc_shm_proc_show(struct seq_file *s, void *it)
1342#define SIZE_SPEC "%21lu" 1342#define SIZE_SPEC "%21lu"
1343#endif 1343#endif
1344 1344
1345 return seq_printf(s, 1345 seq_printf(s,
1346 "%10d %10d %4o " SIZE_SPEC " %5u %5u " 1346 "%10d %10d %4o " SIZE_SPEC " %5u %5u "
1347 "%5lu %5u %5u %5u %5u %10lu %10lu %10lu " 1347 "%5lu %5u %5u %5u %5u %10lu %10lu %10lu "
1348 SIZE_SPEC " " SIZE_SPEC "\n", 1348 SIZE_SPEC " " SIZE_SPEC "\n",
1349 shp->shm_perm.key, 1349 shp->shm_perm.key,
1350 shp->shm_perm.id, 1350 shp->shm_perm.id,
1351 shp->shm_perm.mode, 1351 shp->shm_perm.mode,
1352 shp->shm_segsz, 1352 shp->shm_segsz,
1353 shp->shm_cprid, 1353 shp->shm_cprid,
1354 shp->shm_lprid, 1354 shp->shm_lprid,
1355 shp->shm_nattch, 1355 shp->shm_nattch,
1356 from_kuid_munged(user_ns, shp->shm_perm.uid), 1356 from_kuid_munged(user_ns, shp->shm_perm.uid),
1357 from_kgid_munged(user_ns, shp->shm_perm.gid), 1357 from_kgid_munged(user_ns, shp->shm_perm.gid),
1358 from_kuid_munged(user_ns, shp->shm_perm.cuid), 1358 from_kuid_munged(user_ns, shp->shm_perm.cuid),
1359 from_kgid_munged(user_ns, shp->shm_perm.cgid), 1359 from_kgid_munged(user_ns, shp->shm_perm.cgid),
1360 shp->shm_atim, 1360 shp->shm_atim,
1361 shp->shm_dtim, 1361 shp->shm_dtim,
1362 shp->shm_ctim, 1362 shp->shm_ctim,
1363 rss * PAGE_SIZE, 1363 rss * PAGE_SIZE,
1364 swp * PAGE_SIZE); 1364 swp * PAGE_SIZE);
1365
1366 return 0;
1365} 1367}
1366#endif 1368#endif
diff --git a/ipc/util.c b/ipc/util.c
index 106bed0378ab..ff3323ef8d8b 100644
--- a/ipc/util.c
+++ b/ipc/util.c
@@ -837,8 +837,10 @@ static int sysvipc_proc_show(struct seq_file *s, void *it)
837 struct ipc_proc_iter *iter = s->private; 837 struct ipc_proc_iter *iter = s->private;
838 struct ipc_proc_iface *iface = iter->iface; 838 struct ipc_proc_iface *iface = iter->iface;
839 839
840 if (it == SEQ_START_TOKEN) 840 if (it == SEQ_START_TOKEN) {
841 return seq_puts(s, iface->header); 841 seq_puts(s, iface->header);
842 return 0;
843 }
842 844
843 return iface->show(s, it); 845 return iface->show(s, it);
844} 846}