History

ipc: convert use of typedef ctl_table to struct ctl_table

This typedef is unnecessary and should just be removed.

Joe Perches committed 12 years ago

Commit a5c59281 parent d6f50c92 files · +13 −13Browse files

Unified · Split

2 files
  1. ipc/ipc_sysctl.c +7 −7
  2. ipc/mq_sysctl.c +6 −6
ipc/ipc_sysctl.c+7−7
@@ -18,7 +18,7 @@ · 17 unmodified lines
18#include <linux/msg.h>18#include <linux/msg.h>
19#include "util.h"19#include "util.h"
20 20
21static void *get_ipc(ctl_table *table)21static void *get_ipc(struct ctl_table *table)
22{22{
23 char *which = table->data;23 char *which = table->data;
24 struct ipc_namespace *ipc_ns = current->nsproxy->ipc_ns;24 struct ipc_namespace *ipc_ns = current->nsproxy->ipc_ns;
@@ -27,7 +27,7 @@ static void *get_ipc(ctl_table *table) · 2 unmodified lines
27}27}
28 28
29#ifdef CONFIG_PROC_SYSCTL29#ifdef CONFIG_PROC_SYSCTL
30static int proc_ipc_dointvec(ctl_table *table, int write,30static int proc_ipc_dointvec(struct ctl_table *table, int write,
31 void __user *buffer, size_t *lenp, loff_t *ppos)31 void __user *buffer, size_t *lenp, loff_t *ppos)
32{32{
33 struct ctl_table ipc_table;33 struct ctl_table ipc_table;
@@ -38,7 +38,7 @@ static int proc_ipc_dointvec(ctl_table *table, int write, · 4 unmodified lines
38 return proc_dointvec(&ipc_table, write, buffer, lenp, ppos);38 return proc_dointvec(&ipc_table, write, buffer, lenp, ppos);
39}39}
40 40
41static int proc_ipc_dointvec_minmax(ctl_table *table, int write,41static int proc_ipc_dointvec_minmax(struct ctl_table *table, int write,
42 void __user *buffer, size_t *lenp, loff_t *ppos)42 void __user *buffer, size_t *lenp, loff_t *ppos)
43{43{
44 struct ctl_table ipc_table;44 struct ctl_table ipc_table;
@@ -49,7 +49,7 @@ static int proc_ipc_dointvec_minmax(ctl_table *table, int write, · 4 unmodified lines
49 return proc_dointvec_minmax(&ipc_table, write, buffer, lenp, ppos);49 return proc_dointvec_minmax(&ipc_table, write, buffer, lenp, ppos);
50}50}
51 51
52static int proc_ipc_dointvec_minmax_orphans(ctl_table *table, int write,52static int proc_ipc_dointvec_minmax_orphans(struct ctl_table *table, int write,
53 void __user *buffer, size_t *lenp, loff_t *ppos)53 void __user *buffer, size_t *lenp, loff_t *ppos)
54{54{
55 struct ipc_namespace *ns = current->nsproxy->ipc_ns;55 struct ipc_namespace *ns = current->nsproxy->ipc_ns;
@@ -62,7 +62,7 @@ static int proc_ipc_dointvec_minmax_orphans(ctl_table *table, int write, · 6 unmodified lines
62 return err;62 return err;
63}63}
64 64
65static int proc_ipc_callback_dointvec_minmax(ctl_table *table, int write,65static int proc_ipc_callback_dointvec_minmax(struct ctl_table *table, int write,
66 void __user *buffer, size_t *lenp, loff_t *ppos)66 void __user *buffer, size_t *lenp, loff_t *ppos)
67{67{
68 struct ctl_table ipc_table;68 struct ctl_table ipc_table;
@@ -85,7 +85,7 @@ static int proc_ipc_callback_dointvec_minmax(ctl_table *table, int write, · 16 unmodified lines
85 return rc;85 return rc;
86}86}
87 87
88static int proc_ipc_doulongvec_minmax(ctl_table *table, int write,88static int proc_ipc_doulongvec_minmax(struct ctl_table *table, int write,
89 void __user *buffer, size_t *lenp, loff_t *ppos)89 void __user *buffer, size_t *lenp, loff_t *ppos)
90{90{
91 struct ctl_table ipc_table;91 struct ctl_table ipc_table;
@@ -119,7 +119,7 @@ static void ipc_auto_callback(int val) · 27 unmodified lines
119 }119 }
120}120}
121 121
122static int proc_ipcauto_dointvec_minmax(ctl_table *table, int write,122static int proc_ipcauto_dointvec_minmax(struct ctl_table *table, int write,
123 void __user *buffer, size_t *lenp, loff_t *ppos)123 void __user *buffer, size_t *lenp, loff_t *ppos)
124{124{
125 struct ctl_table ipc_table;125 struct ctl_table ipc_table;
ipc/mq_sysctl.c+6−6
@@ -14,7 +14,7 @@ · 13 unmodified lines
14#include <linux/sysctl.h>14#include <linux/sysctl.h>
15 15
16#ifdef CONFIG_PROC_SYSCTL16#ifdef CONFIG_PROC_SYSCTL
17static void *get_mq(ctl_table *table)17static void *get_mq(struct ctl_table *table)
18{18{
19 char *which = table->data;19 char *which = table->data;
20 struct ipc_namespace *ipc_ns = current->nsproxy->ipc_ns;20 struct ipc_namespace *ipc_ns = current->nsproxy->ipc_ns;
@@ -22,7 +22,7 @@ static void *get_mq(ctl_table *table) · 1 unmodified line
22 return which;22 return which;
23}23}
24 24
25static int proc_mq_dointvec(ctl_table *table, int write,25static int proc_mq_dointvec(struct ctl_table *table, int write,
26 void __user *buffer, size_t *lenp, loff_t *ppos)26 void __user *buffer, size_t *lenp, loff_t *ppos)
27{27{
28 struct ctl_table mq_table;28 struct ctl_table mq_table;
@@ -32,7 +32,7 @@ static int proc_mq_dointvec(ctl_table *table, int write, · 3 unmodified lines
32 return proc_dointvec(&mq_table, write, buffer, lenp, ppos);32 return proc_dointvec(&mq_table, write, buffer, lenp, ppos);
33}33}
34 34
35static int proc_mq_dointvec_minmax(ctl_table *table, int write,35static int proc_mq_dointvec_minmax(struct ctl_table *table, int write,
36 void __user *buffer, size_t *lenp, loff_t *ppos)36 void __user *buffer, size_t *lenp, loff_t *ppos)
37{37{
38 struct ctl_table mq_table;38 struct ctl_table mq_table;
@@ -53,7 +53,7 @@ static int msg_max_limit_max = HARD_MSGMAX; · 14 unmodified lines
53static int msg_maxsize_limit_min = MIN_MSGSIZEMAX;53static int msg_maxsize_limit_min = MIN_MSGSIZEMAX;
54static int msg_maxsize_limit_max = HARD_MSGSIZEMAX;54static int msg_maxsize_limit_max = HARD_MSGSIZEMAX;
55 55
56static ctl_table mq_sysctls[] = {56static struct ctl_table mq_sysctls[] = {
57 {57 {
58 .procname = "queues_max",58 .procname = "queues_max",
59 .data = &init_ipc_ns.mq_queues_max,59 .data = &init_ipc_ns.mq_queues_max,
@@ -100,7 +100,7 @@ static ctl_table mq_sysctls[] = { · 40 unmodified lines
100 {}100 {}
101};101};
102 102
103static ctl_table mq_sysctl_dir[] = {103static struct ctl_table mq_sysctl_dir[] = {
104 {104 {
105 .procname = "mqueue",105 .procname = "mqueue",
106 .mode = 0555,106 .mode = 0555,
@@ -109,7 +109,7 @@ static ctl_table mq_sysctl_dir[] = { · 2 unmodified lines
109 {}109 {}
110};110};
111 111
112static ctl_table mq_sysctl_root[] = {112static struct ctl_table mq_sysctl_root[] = {
113 {113 {
114 .procname = "fs",114 .procname = "fs",
115 .mode = 0555,115 .mode = 0555,

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t