xref: /wlan-dirver/qca-wifi-host-cmn/umac/cmn_services/crypto/src/wlan_crypto_ucfg_api.c (revision 1f55ed1a9f5050d8da228aa8dd3fff7c0242aa71)
1 /*
2  * Copyright (c) 2019 The Linux Foundation. All rights reserved.
3  *
4  * Permission to use, copy, modify, and/or distribute this software for
5  * any purpose with or without fee is hereby granted, provided that the
6  * above copyright notice and this permission notice appear in all
7  * copies.
8  *
9  * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL
10  * WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED
11  * WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE
12  * AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
13  * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
14  * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
15  * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
16  * PERFORMANCE OF THIS SOFTWARE.
17  */
18 
19 /*
20  * DOC: contains crypto north bound interface definitions
21  */
22 
23 #include <qdf_types.h>
24 #include <wlan_crypto_global_def.h>
25 #include <wlan_objmgr_vdev_obj.h>
26 #include <wlan_crypto_global_api.h>
27 QDF_STATUS ucfg_crypto_set_key_req(struct wlan_objmgr_vdev *vdev,
28 				   struct wlan_crypto_key *req, bool pairwise)
29 {
30 	/*
31 	 * It is the job of dispatcher to decide whether the
32 	 * request has to be sent to scheduler or should be
33 	 * sent as a offload request or process directly.
34 	 *
35 	 * Current requirement is to process set key request
36 	 * as run to completion without posting any messages.
37 	 * Hence the request handler is directly called from
38 	 * here.
39 	 */
40 	return wlan_crypto_set_key_req(vdev, req, pairwise);
41 }
42 
43