40#define FNREC_MAGIC ( 'f' << 24 | 'n' << 16 | 'r' << 8 | 'e' )
43#define FNREC_NUM_ENTRIES 4096
49#define FNREC_PHYS_ADDRESS ( 17 * 1024 * 1024 )
145 printf (
"fnrec buffer dump:\n" );
152 ( (
unsigned long ) entry->
call_site ) ) +
157 printf (
" (checksum wrong at phys %08lx)",
158 virt_to_phys ( entry ) );
174 printf (
"fnrec buffer not found\n" );
static void fnrec_init(void)
Function tracer initialisation function.
#define FNREC_NUM_ENTRIES
Number of trace buffer entries.
static struct fnrec_entry * fnrec_append(void *called_fn, void *call_site)
Append an entry to the trace buffer.
#define FNREC_PHYS_ADDRESS
Trace buffer physical address.
static int fnrec_is_valid(void)
Test whether the trace buffer is valid.
static void fnrec_dump(void)
Print the contents of the trace buffer in chronological order.
static void fnrec_invalidate(void)
Invalidate the trace buffer.
void __cyg_profile_func_enter(void *called_fn, void *call_site)
static void fnrec_reset(void)
Reset the trace buffer and clear entries.
#define FNREC_MAGIC
Constant for identifying valid trace buffers.
void __cyg_profile_func_exit(void *called_fn, void *call_site)
#define INIT_NORMAL
Normal initialisation.
#define FILE_LICENCE(_licence)
Declare a particular licence as applying to a file.
void mb(void)
Memory barrier.
void * memset(void *dest, int character, size_t len) __nonnull
#define __init_fn(init_order)
Declare an initialisation functon.
Access to external ("user") memory.
uint8_t checksum
Checksum.
uint32_t magic
Constant for identifying valid trace buffers.
unsigned int idx
Next trace buffer entry to fill.
struct fnrec_entry data[FNREC_NUM_ENTRIES]
Trace buffer.
void * called_fn
Called function address.
void * call_site
Call site.
uint16_t entry_count
Entry count.
unsigned long checksum
Checksum.
uint16_t exit_count
Exit count.
An initialisation function.
int printf(const char *fmt,...)
Write a formatted string to the console.