Also, strip struct idetape_config down to a single int due to unused/removed members. Signed-off-by: Borislav Petkov <petkovbb@xxxxxxxxx> --- drivers/ide/ide-tape.c | 17 +++++------------ 1 files changed, 5 insertions(+), 12 deletions(-) diff --git a/drivers/ide/ide-tape.c b/drivers/ide/ide-tape.c index 447b7b4..0ebb745 100644 --- a/drivers/ide/ide-tape.c +++ b/drivers/ide/ide-tape.c @@ -2384,26 +2384,19 @@ static int idetape_blkdev_ioctl(ide_drive_t *drive, unsigned int cmd, { idetape_tape_t *tape = drive->driver_data; void __user *argp = (void __user *)arg; - - struct idetape_config { - int dsc_rw_frequency; - int dsc_media_access_frequency; - int nr_stages; - } config; + int dsc_rw_frequency; debug_log(DBG_PROCS, "Enter %s\n", __func__); switch (cmd) { case 0x0340: - if (copy_from_user(&config, argp, sizeof(config))) + if (copy_from_user(&dsc_rw_frequency, argp, sizeof(int))) return -EFAULT; - tape->best_dsc_rw_freq = config.dsc_rw_frequency; - tape->max_stages = config.nr_stages; + tape->best_dsc_rw_freq = dsc_rw_frequency; break; case 0x0350: - config.dsc_rw_frequency = (int) tape->best_dsc_rw_freq; - config.nr_stages = tape->max_stages; - if (copy_to_user(argp, &config, sizeof(config))) + dsc_rw_frequency = (int) tape->best_dsc_rw_freq; + if (copy_to_user(argp, &dsc_rw_frequency, sizeof(int))) return -EFAULT; break; default: -- 1.5.4.1 -- To unsubscribe from this list: send the line "unsubscribe linux-ide" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html