Lines Matching full:client
18 struct iavf_client *client,
22 struct iavf_client *client,
31 * iavf_client_get_params - retrieve relevant client parameters
33 * @params: client param struct
51 * iavf_notify_client_message - call the client message receive callback
52 * @vsi: the VSI associated with this client
56 * If there is a client to this VSI, call the client
66 if (!cinst || !cinst->client || !cinst->client->ops || in iavf_notify_client_message()
67 !cinst->client->ops->virtchnl_receive) { in iavf_notify_client_message()
69 "Cannot locate client instance virtchnl_receive function\n"); in iavf_notify_client_message()
72 cinst->client->ops->virtchnl_receive(&cinst->lan_info, cinst->client, in iavf_notify_client_message()
77 * iavf_notify_client_l2_params - call the client notify callback
80 * If there is a client to this VSI, call the client
92 if (!cinst || !cinst->client || !cinst->client->ops || in iavf_notify_client_l2_params()
93 !cinst->client->ops->l2_param_change) { in iavf_notify_client_l2_params()
95 "Cannot locate client instance l2_param_change function\n"); in iavf_notify_client_l2_params()
100 cinst->client->ops->l2_param_change(&cinst->lan_info, cinst->client, in iavf_notify_client_l2_params()
105 * iavf_notify_client_open - call the client open callback
108 * If there is a client to this netdev, call the client with open
116 if (!cinst || !cinst->client || !cinst->client->ops || in iavf_notify_client_open()
117 !cinst->client->ops->open) { in iavf_notify_client_open()
119 "Cannot locate client instance open function\n"); in iavf_notify_client_open()
123 ret = cinst->client->ops->open(&cinst->lan_info, cinst->client); in iavf_notify_client_open()
156 * iavf_notify_client_close - call the client close callback
160 * If there is a client to this netdev, call the client with close
167 if (!cinst || !cinst->client || !cinst->client->ops || in iavf_notify_client_close()
168 !cinst->client->ops->close) { in iavf_notify_client_close()
170 "Cannot locate client instance close function\n"); in iavf_notify_client_close()
173 cinst->client->ops->close(&cinst->lan_info, cinst->client, reset); in iavf_notify_client_close()
179 * iavf_client_add_instance - add a client instance to the instance list
229 cinst->client = vf_registered_client; in iavf_client_add_instance()
236 * iavf_client_del_instance - removes a client instance from the list
248 * iavf_client_subtask - client maintenance work
253 struct iavf_client *client = vf_registered_client; in iavf_client_subtask() local
260 /* first check client is registered */ in iavf_client_subtask()
261 if (!client) in iavf_client_subtask()
264 /* Add the client instance to the instance list */ in iavf_client_subtask()
269 dev_info(&adapter->pdev->dev, "Added instance of Client %s\n", in iavf_client_subtask()
270 client->name); in iavf_client_subtask()
273 /* Send an Open request to the client */ in iavf_client_subtask()
275 if (client->ops && client->ops->open) in iavf_client_subtask()
276 ret = client->ops->open(&cinst->lan_info, client); in iavf_client_subtask()
281 /* remove client instance */ in iavf_client_subtask()
356 * iavf_client_release - release client specific resources
357 * @client: pointer to the registered client
360 static void iavf_client_release(struct iavf_client *client) in iavf_client_release() argument
373 if (client->ops && client->ops->close) in iavf_client_release()
374 client->ops->close(&cinst->lan_info, client, in iavf_client_release()
380 "Client %s instance closed\n", client->name); in iavf_client_release()
382 /* delete the client instance */ in iavf_client_release()
384 dev_info(&adapter->pdev->dev, "Deleted client instance of Client %s\n", in iavf_client_release()
385 client->name); in iavf_client_release()
391 * iavf_client_prepare - prepare client specific resources
392 * @client: pointer to the registered client
395 static void iavf_client_prepare(struct iavf_client *client) in iavf_client_prepare() argument
403 /* Signal the watchdog to service the client */ in iavf_client_prepare()
412 * @client: Client pointer.
419 struct iavf_client *client, in iavf_client_virtchnl_send() argument
440 * @client: Client pointer.
446 struct iavf_client *client, in iavf_client_setup_qvlist() argument
459 /* A quick check on whether the vectors belong to the client */ in iavf_client_setup_qvlist()
501 * iavf_register_client - Register a iavf client driver with the L2 driver
502 * @client: pointer to the iavf_client struct
506 int iavf_register_client(struct iavf_client *client) in iavf_register_client() argument
510 if (!client) { in iavf_register_client()
515 if (strlen(client->name) == 0) { in iavf_register_client()
516 pr_info("iavf: Failed to register client with no name\n"); in iavf_register_client()
522 pr_info("iavf: Client %s has already been registered!\n", in iavf_register_client()
523 client->name); in iavf_register_client()
528 if ((client->version.major != IAVF_CLIENT_VERSION_MAJOR) || in iavf_register_client()
529 (client->version.minor != IAVF_CLIENT_VERSION_MINOR)) { in iavf_register_client()
530 pr_info("iavf: Failed to register client %s due to mismatched client interface version\n", in iavf_register_client()
531 client->name); in iavf_register_client()
532 pr_info("Client is using version: %02d.%02d.%02d while LAN driver supports %s\n", in iavf_register_client()
533 client->version.major, client->version.minor, in iavf_register_client()
534 client->version.build, in iavf_register_client()
540 vf_registered_client = client; in iavf_register_client()
542 iavf_client_prepare(client); in iavf_register_client()
544 pr_info("iavf: Registered client %s with return code %d\n", in iavf_register_client()
545 client->name, ret); in iavf_register_client()
552 * iavf_unregister_client - Unregister a iavf client driver with the L2 driver
553 * @client: pointer to the iavf_client struct
557 int iavf_unregister_client(struct iavf_client *client) in iavf_unregister_client() argument
562 * a close for each of the client instances that were opened. in iavf_unregister_client()
565 iavf_client_release(client); in iavf_unregister_client()
567 if (vf_registered_client != client) { in iavf_unregister_client()
568 pr_info("iavf: Client %s has not been registered\n", in iavf_unregister_client()
569 client->name); in iavf_unregister_client()
574 pr_info("iavf: Unregistered client %s\n", client->name); in iavf_unregister_client()