1 /***************************************************************************** 2 * Copyright ©2017-2019 Gemalto – a Thales Company. All rights Reserved. 3 * 4 * This copy is licensed under the Apache License, Version 2.0 (the "License"); 5 * You may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at: 7 * http://www.apache.org/licenses/LICENSE-2.0 or https://www.apache.org/licenses/LICENSE-2.0.html 8 * 9 * Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 10 * See the License for the specific language governing permissions and limitations under the License. 11 12 ****************************************************************************/ 13 14 /** 15 * @file 16 * $Author$ 17 * $Revision$ 18 * $Date$ 19 * 20 * Internal of libspiplus. 21 * 22 */ 23 24 #ifndef LIBSE_GTO_PRIVATE_H 25 #define LIBSE_GTO_PRIVATE_H 26 27 #include <se-gto/libse-gto.h> 28 #include "iso7816_t1.h" 29 30 #define SE_GTO_EXPORT __attribute__((visibility("default"))) 31 32 /** 33 * SECTION:libspiplus 34 * @short_description: libspiplus context 35 * 36 * The context contains the default values for the library user, 37 * and is passed to all library operations. 38 */ 39 struct se_gto_ctx { 40 void *userdata; 41 42 int log_level; 43 se_gto_log_fn *log_fn; 44 char *log_buf; 45 46 const char *gtodev; 47 48 void *spi_buffer; 49 int spi_nbuffer; 50 51 struct t1_state t1; 52 53 uint8_t check_alive; 54 }; 55 56 #include "log.h" 57 58 #endif /* ifndef LIBSE_GTO_PRIVATE_H */ 59