aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2010-07-06 13:10:26 -0400
committerArnd Bergmann <arnd@arndb.de>2010-09-16 04:33:09 -0400
commit05271ec424d526968d75b4dd9860f8078bcff0a6 (patch)
treeb1002d281a52eceb9127911b539992e04835d033 /drivers/misc
parent2b18ab36cf7e956fb5b5ee12847e94fc66d496f4 (diff)
lkdtm: use generic_file_llseek in debugfs
When the default llseek behavior gets changed to not allowing seek, all file operations that rely on the current behaviour need to use an explicit .llseek operation. The files that lkdtm uses in debugfs are regular files and they get read using simple_read_from_buffer, so generic_file_llseek is the right operation. Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/lkdtm.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/drivers/misc/lkdtm.c b/drivers/misc/lkdtm.c
index ef34de7a8026..343b5d8ea697 100644
--- a/drivers/misc/lkdtm.c
+++ b/drivers/misc/lkdtm.c
@@ -575,30 +575,39 @@ struct crash_entry {
575 575
576static const struct crash_entry crash_entries[] = { 576static const struct crash_entry crash_entries[] = {
577 {"DIRECT", {.read = lkdtm_debugfs_read, 577 {"DIRECT", {.read = lkdtm_debugfs_read,
578 .llseek = generic_file_llseek,
578 .open = lkdtm_debugfs_open, 579 .open = lkdtm_debugfs_open,
579 .write = direct_entry} }, 580 .write = direct_entry} },
580 {"INT_HARDWARE_ENTRY", {.read = lkdtm_debugfs_read, 581 {"INT_HARDWARE_ENTRY", {.read = lkdtm_debugfs_read,
582 .llseek = generic_file_llseek,
581 .open = lkdtm_debugfs_open, 583 .open = lkdtm_debugfs_open,
582 .write = int_hardware_entry} }, 584 .write = int_hardware_entry} },
583 {"INT_HW_IRQ_EN", {.read = lkdtm_debugfs_read, 585 {"INT_HW_IRQ_EN", {.read = lkdtm_debugfs_read,
586 .llseek = generic_file_llseek,
584 .open = lkdtm_debugfs_open, 587 .open = lkdtm_debugfs_open,
585 .write = int_hw_irq_en} }, 588 .write = int_hw_irq_en} },
586 {"INT_TASKLET_ENTRY", {.read = lkdtm_debugfs_read, 589 {"INT_TASKLET_ENTRY", {.read = lkdtm_debugfs_read,
590 .llseek = generic_file_llseek,
587 .open = lkdtm_debugfs_open, 591 .open = lkdtm_debugfs_open,
588 .write = int_tasklet_entry} }, 592 .write = int_tasklet_entry} },
589 {"FS_DEVRW", {.read = lkdtm_debugfs_read, 593 {"FS_DEVRW", {.read = lkdtm_debugfs_read,
594 .llseek = generic_file_llseek,
590 .open = lkdtm_debugfs_open, 595 .open = lkdtm_debugfs_open,
591 .write = fs_devrw_entry} }, 596 .write = fs_devrw_entry} },
592 {"MEM_SWAPOUT", {.read = lkdtm_debugfs_read, 597 {"MEM_SWAPOUT", {.read = lkdtm_debugfs_read,
598 .llseek = generic_file_llseek,
593 .open = lkdtm_debugfs_open, 599 .open = lkdtm_debugfs_open,
594 .write = mem_swapout_entry} }, 600 .write = mem_swapout_entry} },
595 {"TIMERADD", {.read = lkdtm_debugfs_read, 601 {"TIMERADD", {.read = lkdtm_debugfs_read,
602 .llseek = generic_file_llseek,
596 .open = lkdtm_debugfs_open, 603 .open = lkdtm_debugfs_open,
597 .write = timeradd_entry} }, 604 .write = timeradd_entry} },
598 {"SCSI_DISPATCH_CMD", {.read = lkdtm_debugfs_read, 605 {"SCSI_DISPATCH_CMD", {.read = lkdtm_debugfs_read,
606 .llseek = generic_file_llseek,
599 .open = lkdtm_debugfs_open, 607 .open = lkdtm_debugfs_open,
600 .write = scsi_dispatch_cmd_entry} }, 608 .write = scsi_dispatch_cmd_entry} },
601 {"IDE_CORE_CP", {.read = lkdtm_debugfs_read, 609 {"IDE_CORE_CP", {.read = lkdtm_debugfs_read,
610 .llseek = generic_file_llseek,
602 .open = lkdtm_debugfs_open, 611 .open = lkdtm_debugfs_open,
603 .write = ide_core_cp_entry} }, 612 .write = ide_core_cp_entry} },
604}; 613};