diff options
author | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-06-10 15:22:49 +0000 |
---|---|---|
committer | patacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3> | 2009-06-10 15:22:49 +0000 |
commit | a40fde233cc74a5ee67442c4575448224f995b1d (patch) | |
tree | 9edc06d138a9bb3f36638ba6604f748b50634043 | |
parent | 222b94e8cf815b57199fba647bfdc83478a59140 (diff) | |
download | px4-nuttx-a40fde233cc74a5ee67442c4575448224f995b1d.tar.gz px4-nuttx-a40fde233cc74a5ee67442c4575448224f995b1d.tar.bz2 px4-nuttx-a40fde233cc74a5ee67442c4575448224f995b1d.zip |
All file_operations vtables should be static const
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@1871 42af7a65-404d-4744-a932-0658087f49c3
-rw-r--r-- | nuttx/arch/arm/src/c5471/c5471_watchdog.c | 2 | ||||
-rw-r--r-- | nuttx/arch/sim/src/up_devconsole.c | 2 | ||||
-rw-r--r-- | nuttx/drivers/bch/bchdev_driver.c | 2 | ||||
-rw-r--r-- | nuttx/drivers/can.c | 2 | ||||
-rw-r--r-- | nuttx/drivers/dev_null.c | 2 | ||||
-rw-r--r-- | nuttx/drivers/dev_zero.c | 2 | ||||
-rw-r--r-- | nuttx/drivers/fifo.c | 2 | ||||
-rwxr-xr-x | nuttx/drivers/lowconsole.c | 2 | ||||
-rw-r--r-- | nuttx/drivers/pipe.c | 2 | ||||
-rw-r--r-- | nuttx/drivers/serial.c | 2 | ||||
-rw-r--r-- | nuttx/examples/pashello/device.c | 2 |
11 files changed, 11 insertions, 11 deletions
diff --git a/nuttx/arch/arm/src/c5471/c5471_watchdog.c b/nuttx/arch/arm/src/c5471/c5471_watchdog.c index 4a17e9b78..8983b7549 100644 --- a/nuttx/arch/arm/src/c5471/c5471_watchdog.c +++ b/nuttx/arch/arm/src/c5471/c5471_watchdog.c @@ -102,7 +102,7 @@ static int wdt_ioctl(struct file *filep, int cmd, uint32 arg); static boolean g_wdtopen; -struct file_operations g_wdtops = +static const struct file_operations g_wdtops = { .open = wdt_open, .close = wdt_close, diff --git a/nuttx/arch/sim/src/up_devconsole.c b/nuttx/arch/sim/src/up_devconsole.c index 551d21600..4ce89bce1 100644 --- a/nuttx/arch/sim/src/up_devconsole.c +++ b/nuttx/arch/sim/src/up_devconsole.c @@ -62,7 +62,7 @@ static int devconsole_poll(FAR struct file *filep, FAR struct pollfd *fds, * Private Data ****************************************************************************/ -static struct file_operations devconsole_fops = +static const struct file_operations devconsole_fops = { .read = devconsole_read, .write = devconsole_write, diff --git a/nuttx/drivers/bch/bchdev_driver.c b/nuttx/drivers/bch/bchdev_driver.c index cf5ab4025..42d9825db 100644 --- a/nuttx/drivers/bch/bchdev_driver.c +++ b/nuttx/drivers/bch/bchdev_driver.c @@ -78,7 +78,7 @@ static int bch_ioctl(FAR struct file *filp, int cmd, unsigned long arg); * Public Data ****************************************************************************/ -struct file_operations bch_fops = +static const struct file_operations bch_fops = { bch_open, /* open */ bch_close, /* close */ diff --git a/nuttx/drivers/can.c b/nuttx/drivers/can.c index 3d21634ee..509210a8f 100644 --- a/nuttx/drivers/can.c +++ b/nuttx/drivers/can.c @@ -81,7 +81,7 @@ static int can_ioctl(FAR struct file *filep, int cmd, unsigned long a * Private Data ****************************************************************************/ -struct file_operations g_canops = +static const struct file_operations g_canops = { can_open, /* open */ can_close, /* close */ diff --git a/nuttx/drivers/dev_null.c b/nuttx/drivers/dev_null.c index a8a8bb01c..2208823e6 100644 --- a/nuttx/drivers/dev_null.c +++ b/nuttx/drivers/dev_null.c @@ -64,7 +64,7 @@ static int devnull_poll(FAR struct file *filp, FAR struct pollfd *fds, * Private Data ****************************************************************************/ -static struct file_operations devnull_fops = +static const struct file_operations devnull_fops = { 0, /* open */ 0, /* close */ diff --git a/nuttx/drivers/dev_zero.c b/nuttx/drivers/dev_zero.c index fff88fd8d..2a85e134a 100644 --- a/nuttx/drivers/dev_zero.c +++ b/nuttx/drivers/dev_zero.c @@ -64,7 +64,7 @@ static int devzero_poll(FAR struct file *filp, FAR struct pollfd *fds, * Private Data ****************************************************************************/ -static struct file_operations devzero_fops = +static const struct file_operations devzero_fops = { 0, /* open */ 0, /* close */ diff --git a/nuttx/drivers/fifo.c b/nuttx/drivers/fifo.c index 7775af9ae..4e0bbf49c 100644 --- a/nuttx/drivers/fifo.c +++ b/nuttx/drivers/fifo.c @@ -67,7 +67,7 @@ * Private Data ****************************************************************************/ -static struct file_operations fifo_fops = +static const struct file_operations fifo_fops = { pipecommon_open, /* open */ pipecommon_close, /* close */ diff --git a/nuttx/drivers/lowconsole.c b/nuttx/drivers/lowconsole.c index c89183cd2..15f639391 100755 --- a/nuttx/drivers/lowconsole.c +++ b/nuttx/drivers/lowconsole.c @@ -68,7 +68,7 @@ static int lowconsole_ioctl(struct file *filep, int cmd, unsigned long arg); * Private Variables ****************************************************************************/ -struct file_operations g_consoleops = +static const struct file_operations g_consoleops = { 0, /* open */ 0, /* close */ diff --git a/nuttx/drivers/pipe.c b/nuttx/drivers/pipe.c index 4ad5f0f99..f51b4db2f 100644 --- a/nuttx/drivers/pipe.c +++ b/nuttx/drivers/pipe.c @@ -75,7 +75,7 @@ static int pipe_close(FAR struct file *filep); * Private Data ****************************************************************************/ -static struct file_operations pipe_fops = +static const struct file_operations pipe_fops = { pipecommon_open, /* open */ pipe_close, /* close */ diff --git a/nuttx/drivers/serial.c b/nuttx/drivers/serial.c index 2dc7d8151..98ba07e21 100644 --- a/nuttx/drivers/serial.c +++ b/nuttx/drivers/serial.c @@ -86,7 +86,7 @@ static int uart_poll(FAR struct file *filep, FAR struct pollfd *fds, boolean * Private Variables ************************************************************************************/ -struct file_operations g_serialops = +static const struct file_operations g_serialops = { uart_open, /* open */ uart_close, /* close */ diff --git a/nuttx/examples/pashello/device.c b/nuttx/examples/pashello/device.c index fb2deff65..b4401531a 100644 --- a/nuttx/examples/pashello/device.c +++ b/nuttx/examples/pashello/device.c @@ -61,7 +61,7 @@ static ssize_t hello_read(struct file *, char *, size_t); * Private Data ****************************************************************************/ -static struct file_operations hello_fops = +static const struct file_operations hello_fops = { 0, /* open */ 0, /* close */ |