Christopher Ferris | 7fb2287 | 2013-09-27 12:43:15 -0700 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2013 The Android Open Source Project |
| 3 | * |
| 4 | * 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 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | #define LOG_TAG "libbacktrace" |
| 18 | |
| 19 | #include <cutils/log.h> |
| 20 | #include <backtrace/backtrace.h> |
| 21 | |
| 22 | bool backtrace_get_data(backtrace_t* backtrace, pid_t tid) { |
| 23 | ALOGW("backtrace_get_data: unsupported architecture.\n"); |
| 24 | return true; |
| 25 | } |
| 26 | |
| 27 | void backtrace_free_data(backtrace_t* backtrace) { |
| 28 | ALOGW("backtrace_free_data: unsupported architecture.\n"); |
| 29 | } |
| 30 | |
| 31 | bool backtrace_read_word(const backtrace_t* backtrace, uintptr_t ptr, |
| 32 | uint32_t* out_value) { |
| 33 | ALOGW("backtrace_read_word: unsupported architecture.\n"); |
| 34 | return false; |
| 35 | } |
| 36 | |
| 37 | const char *backtrace_get_map_info(const backtrace_t* backtrace, |
| 38 | uintptr_t pc, uintptr_t* start_pc) { |
| 39 | ALOGW("backtrace_get_map_info: unsupported architecture.\n"); |
| 40 | return NULL; |
| 41 | } |
| 42 | |
| 43 | char* backtrace_get_proc_name(const backtrace_t* backtrace, uintptr_t pc, |
| 44 | uintptr_t* offset) { |
| 45 | ALOGW("backtrace_get_proc_name: unsupported architecture.\n"); |
| 46 | return NULL; |
| 47 | } |
| 48 | |
| 49 | void backtrace_format_frame_data( |
| 50 | const backtrace_frame_data_t* frame, size_t frame_num, char *buf, size_t buf_size) { |
| 51 | ALOGW("backtrace_format_frame_data: unsupported architecture.\n"); |
| 52 | buf[0] = '\0'; |
| 53 | } |