bus.c (a1f9ae2bd264e3aed95aacd0102bd22a0422b8d1) bus.c (850f8940a6a38563ff401073fd845414ab49c5ed)
1/*
2 * Intel Management Engine Interface (Intel MEI) Linux driver
3 * Copyright (c) 2012-2013, Intel Corporation.
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms and conditions of the GNU General Public License,
7 * version 2, as published by the Free Software Foundation.
8 *

--- 216 unchanged lines hidden (view full) ---

225 if (cldev->events_mask & BIT(MEI_CL_EVENT_RX))
226 mei_cl_read_start(cldev->cl, 0, NULL);
227}
228
229/**
230 * mei_cl_bus_notify_event - schedule notify cb on bus client
231 *
232 * @cl: host client
1/*
2 * Intel Management Engine Interface (Intel MEI) Linux driver
3 * Copyright (c) 2012-2013, Intel Corporation.
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms and conditions of the GNU General Public License,
7 * version 2, as published by the Free Software Foundation.
8 *

--- 216 unchanged lines hidden (view full) ---

225 if (cldev->events_mask & BIT(MEI_CL_EVENT_RX))
226 mei_cl_read_start(cldev->cl, 0, NULL);
227}
228
229/**
230 * mei_cl_bus_notify_event - schedule notify cb on bus client
231 *
232 * @cl: host client
233 *
234 * Return: true if event was scheduled
235 * false if the client is not waiting for event
233 */
236 */
234void mei_cl_bus_notify_event(struct mei_cl *cl)
237bool mei_cl_bus_notify_event(struct mei_cl *cl)
235{
236 struct mei_cl_device *cldev = cl->cldev;
237
238 if (!cldev || !cldev->event_cb)
238{
239 struct mei_cl_device *cldev = cl->cldev;
240
241 if (!cldev || !cldev->event_cb)
239 return;
242 return false;
240
241 if (!(cldev->events_mask & BIT(MEI_CL_EVENT_NOTIF)))
243
244 if (!(cldev->events_mask & BIT(MEI_CL_EVENT_NOTIF)))
242 return;
245 return false;
243
244 if (!cl->notify_ev)
246
247 if (!cl->notify_ev)
245 return;
248 return false;
246
247 set_bit(MEI_CL_EVENT_NOTIF, &cldev->events);
248
249 schedule_work(&cldev->event_work);
250
251 cl->notify_ev = false;
249
250 set_bit(MEI_CL_EVENT_NOTIF, &cldev->events);
251
252 schedule_work(&cldev->event_work);
253
254 cl->notify_ev = false;
255
256 return true;
252}
253
254/**
255 * mei_cl_bus_rx_event - schedule rx event
256 *
257 * @cl: host client
258 *
259 * Return: true if event was scheduled

--- 743 unchanged lines hidden ---
257}
258
259/**
260 * mei_cl_bus_rx_event - schedule rx event
261 *
262 * @cl: host client
263 *
264 * Return: true if event was scheduled

--- 743 unchanged lines hidden ---