From: Ankita Garg Enable lkdtm to be built on s390 Signed-off-by: Ankita Garg Signed-off-by: Andrew Morton --- drivers/misc/lkdtm.c | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-) diff -puN drivers/misc/lkdtm.c~linux-kernel-dump-test-module-fixes drivers/misc/lkdtm.c --- a/drivers/misc/lkdtm.c~linux-kernel-dump-test-module-fixes +++ a/drivers/misc/lkdtm.c @@ -43,15 +43,18 @@ * to trigger an action. The default is 10. */ -#include -#include -#include -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include +#include +#include + +#ifdef CONFIG_IDE +#include +#endif #define NUM_CPOINTS 8 #define NUM_CPOINT_TYPES 5 @@ -176,6 +179,7 @@ int jp_scsi_dispatch_cmd(struct scsi_cmn return 0; } +#ifdef CONFIG_IDE int jp_generic_ide_ioctl(ide_drive_t *drive, struct file *file, struct block_device *bdev, unsigned int cmd, unsigned long arg) @@ -184,7 +188,7 @@ int jp_generic_ide_ioctl(ide_drive_t *dr jprobe_return(); return 0; } - +#endif static int lkdtm_parse_commandline(void) { @@ -304,8 +308,12 @@ int lkdtm_module_init(void) lkdtm.entry = (kprobe_opcode_t*) jp_scsi_dispatch_cmd; break; case IDE_CORE_CP: +#ifdef CONFIG_IDE lkdtm.kp.symbol_name = "generic_ide_ioctl"; lkdtm.entry = (kprobe_opcode_t*) jp_generic_ide_ioctl; +#else + printk(KERN_INFO "lkdtm : Crash point not available\n"); +#endif break; default: printk(KERN_INFO "lkdtm : Invalid Crash Point\n"); _