Lines Matching +full:- +full:- +full:retry +full:- +full:delay
1 // SPDX-License-Identifier: GPL-2.0
3 * Copyright © 2020 - 2021 Intel Corporation
14 #include <linux/delay.h>
45 * mei_pxp_send_message() - Sends a PXP message to ME FW.
52 * -ENODEV: Client was not connected.
54 * -ENOMEM: Internal memory allocation failure experienced.
56 * -EINTR : Calling thread received a signal. Caller may choose
58 * -ETIME : Request is timed out.
69 return -EINVAL; in mei_pxp_send_message()
77 case -ENOMEM: in mei_pxp_send_message()
79 case -ENODEV: in mei_pxp_send_message()
81 case -ETIME: in mei_pxp_send_message()
94 * mei_pxp_receive_message() - Receives a PXP message from ME FW.
101 * -ENODEV: Client was not connected.
103 * -ENOMEM: Internal memory allocation failure experienced.
105 * -EINTR : Calling thread received a signal. Caller will need to repeat calling
108 * -ETIME : Request is timed out.
116 bool retry = false; in mei_pxp_receive_message() local
120 return -EINVAL; in mei_pxp_receive_message()
124 retry: in mei_pxp_receive_message()
129 case -ENOMEM: in mei_pxp_receive_message()
130 /* Retry the read when pages are reclaimed */ in mei_pxp_receive_message()
132 if (!retry) { in mei_pxp_receive_message()
133 retry = true; in mei_pxp_receive_message()
134 goto retry; in mei_pxp_receive_message()
137 case -ENODEV: in mei_pxp_receive_message()
139 case -ETIME: in mei_pxp_receive_message()
151 * mei_pxp_gsc_command() - sends a gsc command, by sending
187 comp_master->ops = &mei_pxp_ops; in mei_component_master_bind()
188 comp_master->tee_dev = dev; in mei_component_master_bind()
210 * mei_pxp_component_match - compare function for matching mei pxp.
221 * * 1 - if components match
222 * * 0 - otherwise
232 if (!dev->driver || strcmp(dev->driver->name, "i915") || in mei_pxp_component_match()
236 base = base->parent; in mei_pxp_component_match()
240 base = base->parent; /* pci device */ in mei_pxp_component_match()
246 dev = dev->parent; in mei_pxp_component_match()
259 dev_err(&cldev->dev, "mei_cldev_enable Failed. %d\n", ret); in mei_pxp_probe()
265 ret = -ENOMEM; in mei_pxp_probe()
270 component_match_add_typed(&cldev->dev, &master_match, in mei_pxp_probe()
271 mei_pxp_component_match, &cldev->dev); in mei_pxp_probe()
273 ret = -ENOMEM; in mei_pxp_probe()
278 ret = component_master_add_with_match(&cldev->dev, in mei_pxp_probe()
282 dev_err(&cldev->dev, "Master comp add failed %d\n", ret); in mei_pxp_probe()
301 component_master_del(&cldev->dev, &mei_component_master_ops); in mei_pxp_remove()
307 dev_warn(&cldev->dev, "mei_cldev_disable() failed\n"); in mei_pxp_remove()
310 /* fbf6fcf1-96cf-4e2e-a6a6-1bab8cbe36b1 : PAVP GUID*/