mirror of
https://github.com/apache/nuttx.git
synced 2026-06-06 16:50:55 +08:00
Add ftruncate into file operation calls
- Add truncate into file_operations - Move truncate to be common for mountpt_operations and file_operations - Modify all drivers to initialize the operations struct accordingly Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
This commit is contained in:
committed by
Alan Carvalho de Assis
parent
36528eed64
commit
41e9df2f3e
@@ -122,6 +122,7 @@ static const struct file_operations ads7843e_fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
ads7843e_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
ads7843e_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -135,6 +135,7 @@ static const struct file_operations ajoy_fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
ajoy_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
ajoy_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -133,6 +133,7 @@ static const struct file_operations btn_fops =
|
||||
btn_write, /* write */
|
||||
NULL, /* seek */
|
||||
btn_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
btn_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -224,6 +224,7 @@ static const struct file_operations g_mbr3108_fileops =
|
||||
mbr3108_write, /* write */
|
||||
NULL, /* seek */
|
||||
NULL, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
mbr3108_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -135,6 +135,7 @@ static const struct file_operations djoy_fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
djoy_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
djoy_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -176,6 +176,7 @@ static const struct file_operations ft5x06_fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
ft5x06_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
ft5x06_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -88,6 +88,7 @@ static const struct file_operations g_keyboard_fops =
|
||||
keyboard_write, /* write */
|
||||
NULL, /* seek */
|
||||
NULL, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
keyboard_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -115,6 +115,7 @@ static const struct file_operations max11802_fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
max11802_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
max11802_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -280,6 +280,7 @@ static const struct file_operations mxt_fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
mxt_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
mxt_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -255,6 +255,7 @@ static const struct file_operations g_hidkbd_fops =
|
||||
spq10kbd_write, /* write */
|
||||
NULL, /* seek */
|
||||
NULL, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
spq10kbd_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -124,6 +124,7 @@ static const struct file_operations g_stmpe811fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
stmpe811_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
stmpe811_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -90,6 +90,7 @@ static const struct file_operations g_touch_fops =
|
||||
touch_write, /* write */
|
||||
NULL, /* seek */
|
||||
touch_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
touch_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
@@ -209,6 +209,7 @@ static const struct file_operations tsc2007_fops =
|
||||
NULL, /* write */
|
||||
NULL, /* seek */
|
||||
tsc2007_ioctl, /* ioctl */
|
||||
NULL, /* truncate */
|
||||
tsc2007_poll /* poll */
|
||||
#ifndef CONFIG_DISABLE_PSEUDOFS_OPERATIONS
|
||||
, NULL /* unlink */
|
||||
|
||||
Reference in New Issue
Block a user