diff options
| author | Giampaolo Rodola' <g.rodola@gmail.com> | 2013-12-27 00:49:01 +0100 |
|---|---|---|
| committer | Giampaolo Rodola' <g.rodola@gmail.com> | 2013-12-27 00:49:01 +0100 |
| commit | 750cc034faa5b773c9eb053b4a5a73961af96e3f (patch) | |
| tree | 87af6b4b183d4af5b6610740770583f794268c75 /psutil/_psutil_linux.c | |
| parent | ad7f24d07dd7631ee9501cbae047e51790bbdf32 (diff) | |
| download | psutil-750cc034faa5b773c9eb053b4a5a73961af96e3f.tar.gz | |
other renames (linux)
Diffstat (limited to 'psutil/_psutil_linux.c')
| -rw-r--r-- | psutil/_psutil_linux.c | 34 |
1 files changed, 20 insertions, 14 deletions
diff --git a/psutil/_psutil_linux.c b/psutil/_psutil_linux.c index 70c3b84d..b5ab7115 100644 --- a/psutil/_psutil_linux.c +++ b/psutil/_psutil_linux.c @@ -230,7 +230,7 @@ error: * A wrapper around sysinfo(), return system memory usage statistics. */ static PyObject * -psutil_sysinfo(PyObject *self, PyObject *args) +psutil_linux_sysinfo(PyObject *self, PyObject *args) { struct sysinfo info; if (sysinfo(&info) != 0) { @@ -384,30 +384,36 @@ static PyMethodDef PsutilMethods[] = { // --- per-process functions + #if HAVE_IOPRIO - {"ioprio_get", psutil_proc_ioprio_get, METH_VARARGS, + {"proc_ioprio_get", psutil_proc_ioprio_get, METH_VARARGS, "Get process I/O priority"}, - {"ioprio_set", psutil_proc_ioprio_set, METH_VARARGS, + {"proc_ioprio_set", psutil_proc_ioprio_set, METH_VARARGS, "Set process I/O priority"}, #endif -#if HAVE_PRLIMIT - {"prlimit", psutil_linux_prlimit, METH_VARARGS, - "Get or set process resource limits."}, -#endif - {"set_proc_cpu_affinity", psutil_proc_cpu_affinity_set, METH_VARARGS, + {"proc_cpu_affinity_get", psutil_proc_cpu_affinity_get, METH_VARARGS, + "Return process CPU affinity as a Python long (the bitmask)."}, + {"proc_cpu_affinity_set", psutil_proc_cpu_affinity_set, METH_VARARGS, "Set process CPU affinity; expects a bitmask."}, // --- system related functions - {"get_disk_partitions", psutil_disk_partitions, METH_VARARGS, + + {"disk_partitions", psutil_disk_partitions, METH_VARARGS, "Return disk mounted partitions as a list of tuples including " "device, mount point and filesystem type"}, - {"get_sysinfo", psutil_sysinfo, METH_VARARGS, - "A wrapper around sysinfo(), return system memory usage statistics"}, - {"get_proc_cpu_affinity", psutil_proc_cpu_affinity_get, METH_VARARGS, - "Return process CPU affinity as a Python long (the bitmask)."}, - {"get_users", psutil_users, METH_VARARGS, + {"users", psutil_users, METH_VARARGS, "Return currently connected users as a list of tuples"}, + // --- linux specific + + {"linux_sysinfo", psutil_linux_sysinfo, METH_VARARGS, + "A wrapper around sysinfo(), return system memory usage statistics"}, +#if HAVE_PRLIMIT + {"linux_prlimit", psutil_linux_prlimit, METH_VARARGS, + "Get or set process resource limits."}, +#endif + + {NULL, NULL, 0, NULL} }; |
