Git init
[framework/connectivity/bluez.git] / sap / sap-dummy.c
1 /*
2  *  BlueZ - Bluetooth protocol stack for Linux
3  *
4  *  Copyright (C) 2010 ST-Ericsson SA
5  *
6  *  Author: Waldemar Rymarkiewicz <waldemar.rymarkiewicz@tieto.com>
7  *          for ST-Ericsson
8  *
9  *  This program is free software; you can redistribute it and/or modify
10  *  it under the terms of the GNU General Public License as published by
11  *  the Free Software Foundation; either version 2 of the License, or
12  *  (at your option) any later version.
13  *
14  *  This program is distributed in the hope that it will be useful,
15  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
16  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
17  *  GNU General Public License for more details.
18  *
19  *  You should have received a copy of the GNU General Public License
20  *  along with this program; if not, write to the Free Software
21  *  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
22  */
23
24 #include "log.h"
25 #include "sap.h"
26
27 void sap_connect_req(void *sap_device, uint16_t maxmsgsize)
28 {
29         sap_connect_rsp(sap_device, SAP_STATUS_OK, maxmsgsize);
30         sap_status_ind(sap_device, SAP_STATUS_CHANGE_CARD_RESET);
31 }
32
33 void sap_disconnect_req(void *sap_device, uint8_t linkloss)
34 {
35         sap_disconnect_rsp(sap_device);
36 }
37
38 void sap_transfer_apdu_req(void *sap_device, struct sap_parameter *param)
39 {
40         sap_transfer_apdu_rsp(sap_device, SAP_RESULT_OK, NULL, 0);
41 }
42
43 void sap_transfer_atr_req(void *sap_device)
44 {
45         sap_transfer_atr_rsp(sap_device, SAP_RESULT_OK, NULL, 0);
46 }
47
48 void sap_power_sim_off_req(void *sap_device)
49 {
50         sap_power_sim_off_rsp(sap_device, SAP_RESULT_OK);
51 }
52
53 void sap_power_sim_on_req(void *sap_device)
54 {
55         sap_power_sim_on_rsp(sap_device, SAP_RESULT_OK);
56 }
57
58 void sap_reset_sim_req(void *sap_device)
59 {
60         sap_reset_sim_rsp(sap_device, SAP_RESULT_OK);
61         sap_status_ind(sap_device, SAP_STATUS_CHANGE_CARD_RESET);
62 }
63
64 void sap_transfer_card_reader_status_req(void *sap_device)
65 {
66         sap_transfer_card_reader_status_rsp(sap_device, SAP_RESULT_OK,
67                                                 ICC_READER_CARD_POWERED_ON);
68 }
69
70 void sap_set_transport_protocol_req(void *sap_device,
71                                         struct sap_parameter *param)
72 {
73         sap_transport_protocol_rsp(sap_device, SAP_RESULT_NOT_SUPPORTED);
74 }
75
76 int sap_init(void)
77 {
78         DBG("SAP driver init.");
79         return 0;
80 }
81
82 void sap_exit(void)
83 {
84         DBG("SAP driver exit.");
85 }