summaryrefslogtreecommitdiffstats
path: root/drivers/misc
diff options
context:
space:
mode:
authorTomas Winkler <tomas.winkler@intel.com>2013-05-23 03:03:13 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-05-30 08:44:41 -0400
commit7131799b145aa67984cc57e52d6379862c78afa3 (patch)
tree240e27f61f89a43ff0cd9dec0ea5e4f21cbd74bb /drivers/misc
parentf35c69b736e4f910d7447346980145212c283570 (diff)
mei: deprecate the mei_wd_state_independence_msg
wd independence is deprecated, remove it. Signed-off-by: Tomas Winkler <tomas.winkler@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/misc')
-rw-r--r--drivers/misc/mei/main.c25
-rw-r--r--drivers/misc/mei/mei_dev.h6
-rw-r--r--drivers/misc/mei/wd.c6
3 files changed, 0 insertions, 37 deletions
diff --git a/drivers/misc/mei/main.c b/drivers/misc/mei/main.c
index 053139f61086..b9ad5106f5e1 100644
--- a/drivers/misc/mei/main.c
+++ b/drivers/misc/mei/main.c
@@ -194,7 +194,6 @@ static ssize_t mei_read(struct file *file, char __user *ubuf,
194 struct mei_cl_cb *cb_pos = NULL; 194 struct mei_cl_cb *cb_pos = NULL;
195 struct mei_cl_cb *cb = NULL; 195 struct mei_cl_cb *cb = NULL;
196 struct mei_device *dev; 196 struct mei_device *dev;
197 int i;
198 int rets; 197 int rets;
199 int err; 198 int err;
200 199
@@ -210,20 +209,6 @@ static ssize_t mei_read(struct file *file, char __user *ubuf,
210 goto out; 209 goto out;
211 } 210 }
212 211
213 if ((cl->sm_state & MEI_WD_STATE_INDEPENDENCE_MSG_SENT) == 0) {
214 /* Do not allow to read watchdog client */
215 i = mei_me_cl_by_uuid(dev, &mei_wd_guid);
216 if (i >= 0) {
217 struct mei_me_client *me_client = &dev->me_clients[i];
218 if (cl->me_client_id == me_client->client_id) {
219 rets = -EBADF;
220 goto out;
221 }
222 }
223 } else {
224 cl->sm_state &= ~MEI_WD_STATE_INDEPENDENCE_MSG_SENT;
225 }
226
227 if (cl == &dev->iamthif_cl) { 212 if (cl == &dev->iamthif_cl) {
228 rets = mei_amthif_read(dev, file, ubuf, length, offset); 213 rets = mei_amthif_read(dev, file, ubuf, length, offset);
229 goto out; 214 goto out;
@@ -420,16 +405,6 @@ static ssize_t mei_write(struct file *file, const char __user *ubuf,
420 if (rets) 405 if (rets)
421 goto out; 406 goto out;
422 407
423 cl->sm_state = 0;
424 if (length == 4 &&
425 ((memcmp(mei_wd_state_independence_msg[0],
426 write_cb->request_buffer.data, 4) == 0) ||
427 (memcmp(mei_wd_state_independence_msg[1],
428 write_cb->request_buffer.data, 4) == 0) ||
429 (memcmp(mei_wd_state_independence_msg[2],
430 write_cb->request_buffer.data, 4) == 0)))
431 cl->sm_state |= MEI_WD_STATE_INDEPENDENCE_MSG_SENT;
432
433 if (cl == &dev->iamthif_cl) { 408 if (cl == &dev->iamthif_cl) {
434 rets = mei_amthif_write(dev, write_cb); 409 rets = mei_amthif_write(dev, write_cb);
435 410
diff --git a/drivers/misc/mei/mei_dev.h b/drivers/misc/mei/mei_dev.h
index 197ba6481bf5..80a90319fc29 100644
--- a/drivers/misc/mei/mei_dev.h
+++ b/drivers/misc/mei/mei_dev.h
@@ -56,11 +56,6 @@ extern const uuid_le mei_amthif_guid;
56extern const uuid_le mei_wd_guid; 56extern const uuid_le mei_wd_guid;
57 57
58/* 58/*
59 * Watchdog independence state message
60 */
61extern const u8 mei_wd_state_independence_msg[3][4];
62
63/*
64 * Number of Maximum MEI Clients 59 * Number of Maximum MEI Clients
65 */ 60 */
66#define MEI_CLIENTS_MAX 256 61#define MEI_CLIENTS_MAX 256
@@ -201,7 +196,6 @@ struct mei_cl {
201 u8 timer_count; 196 u8 timer_count;
202 enum mei_file_transaction_states reading_state; 197 enum mei_file_transaction_states reading_state;
203 enum mei_file_transaction_states writing_state; 198 enum mei_file_transaction_states writing_state;
204 int sm_state;
205 struct mei_cl_cb *read_cb; 199 struct mei_cl_cb *read_cb;
206 200
207 /* MEI CL bus data */ 201 /* MEI CL bus data */
diff --git a/drivers/misc/mei/wd.c b/drivers/misc/mei/wd.c
index 6251a4ee7067..b8921432e89d 100644
--- a/drivers/misc/mei/wd.c
+++ b/drivers/misc/mei/wd.c
@@ -31,12 +31,6 @@
31static const u8 mei_start_wd_params[] = { 0x02, 0x12, 0x13, 0x10 }; 31static const u8 mei_start_wd_params[] = { 0x02, 0x12, 0x13, 0x10 };
32static const u8 mei_stop_wd_params[] = { 0x02, 0x02, 0x14, 0x10 }; 32static const u8 mei_stop_wd_params[] = { 0x02, 0x02, 0x14, 0x10 };
33 33
34const u8 mei_wd_state_independence_msg[3][4] = {
35 {0x05, 0x02, 0x51, 0x10},
36 {0x05, 0x02, 0x52, 0x10},
37 {0x07, 0x02, 0x01, 0x10}
38};
39
40/* 34/*
41 * AMT Watchdog Device 35 * AMT Watchdog Device
42 */ 36 */