lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Message-Id: <1464120221-28151-4-git-send-email-tomas.winkler@intel.com> Date: Tue, 24 May 2016 16:03:37 -0400 From: Tomas Winkler <tomas.winkler@...el.com> To: Greg Kroah-Hartman <gregkh@...uxfoundation.org> Cc: Alexander Usyskin <alexander.usyskin@...el.com>, linux-kernel@...r.kernel.org, Tomas Winkler <tomas.winkler@...el.com> Subject: [char-misc-next 3/7] mei: amthif: drop iamthif_current_cb From: Alexander Usyskin <alexander.usyskin@...el.com> iamthif_current_cb was used in request cancel in amthif code. Now a canceled request is discarded only at the end of the processing and the variable lost its purpose and can be safely removed. Signed-off-by: Alexander Usyskin <alexander.usyskin@...el.com> Signed-off-by: Tomas Winkler <tomas.winkler@...el.com> --- drivers/misc/mei/amthif.c | 5 ----- drivers/misc/mei/interrupt.c | 3 --- drivers/misc/mei/mei_dev.h | 2 -- 3 files changed, 10 deletions(-) diff --git a/drivers/misc/mei/amthif.c b/drivers/misc/mei/amthif.c index 0cded8aa72c0..b602fd3b914c 100644 --- a/drivers/misc/mei/amthif.c +++ b/drivers/misc/mei/amthif.c @@ -47,7 +47,6 @@ const uuid_le mei_amthif_guid = UUID_LE(0x12f80028, 0xb4b7, 0x4b2d, void mei_amthif_reset_params(struct mei_device *dev) { /* reset iamthif parameters. */ - dev->iamthif_current_cb = NULL; dev->iamthif_canceled = false; dev->iamthif_state = MEI_IAMTHIF_IDLE; dev->iamthif_stall_timer = 0; @@ -213,7 +212,6 @@ static int mei_amthif_read_start(struct mei_cl *cl, const struct file *file) dev->iamthif_state = MEI_IAMTHIF_READING; dev->iamthif_fp = cb->fp; - dev->iamthif_current_cb = cb; return 0; err: @@ -240,7 +238,6 @@ static int mei_amthif_send_cmd(struct mei_cl *cl, struct mei_cl_cb *cb) dev = cl->dev; dev->iamthif_state = MEI_IAMTHIF_WRITING; - dev->iamthif_current_cb = cb; dev->iamthif_fp = cb->fp; dev->iamthif_canceled = false; @@ -407,7 +404,6 @@ void mei_amthif_complete(struct mei_cl *cl, struct mei_cl_cb *cb) mei_io_cb_free(cb); return; } - dev->iamthif_current_cb = NULL; dev->iamthif_state = MEI_IAMTHIF_IDLE; dev->iamthif_fp = NULL; if (!dev->iamthif_canceled) { @@ -430,7 +426,6 @@ void mei_amthif_complete(struct mei_cl *cl, struct mei_cl_cb *cb) mei_io_cb_free(cb); } - dev->iamthif_current_cb = NULL; dev->iamthif_stall_timer = 0; mei_amthif_run_next_cmd(dev); break; diff --git a/drivers/misc/mei/interrupt.c b/drivers/misc/mei/interrupt.c index 38db1c3d4f14..436ecda3935e 100644 --- a/drivers/misc/mei/interrupt.c +++ b/drivers/misc/mei/interrupt.c @@ -515,9 +515,6 @@ void mei_timer(struct work_struct *work) dev_err(dev->dev, "timer: amthif hanged.\n"); mei_reset(dev); - mei_io_cb_free(dev->iamthif_current_cb); - dev->iamthif_current_cb = NULL; - dev->iamthif_fp = NULL; mei_amthif_run_next_cmd(dev); } diff --git a/drivers/misc/mei/mei_dev.h b/drivers/misc/mei/mei_dev.h index fa6007707048..d7b68063ace1 100644 --- a/drivers/misc/mei/mei_dev.h +++ b/drivers/misc/mei/mei_dev.h @@ -400,7 +400,6 @@ const char *mei_pg_state_str(enum mei_pg_state state); * @amthif_cmd_list : amthif list for cmd waiting * @iamthif_fp : file for current amthif operation * @iamthif_cl : amthif host client - * @iamthif_current_cb : amthif current operation callback * @iamthif_open_count : number of opened amthif connections * @iamthif_stall_timer : timer to detect amthif hang * @iamthif_state : amthif processor state @@ -485,7 +484,6 @@ struct mei_device { /* driver managed amthif list for reading completed amthif cmd data */ const struct file *iamthif_fp; struct mei_cl iamthif_cl; - struct mei_cl_cb *iamthif_current_cb; long iamthif_open_count; u32 iamthif_stall_timer; enum iamthif_states iamthif_state; -- 2.5.5
Powered by blists - more mailing lists