tools/build-R2_19_3/fsboot/cbl/common.c File Reference

#include <e100boot.h>
#include <ser_defs.h>
#include <config_defs.h>
#include <timer_defs.h>
#include <stdio.h>
#include <cbl.h>
#include <nand/rflflash.h>
#include <nandwr.h>

Include dependency graph for common.c:

Go to the source code of this file.

Functions

static void read_file (byte *addr, udword size)
static int memory_test (udword from, udword to, udword *failed_address)
static void memory_dump (udword *from, udword *to)
static void read_load_info (void)
static void decode_load_info (void)
static void toggle_led (void)
void next_level_boot (void)
static void packet_info (packet_info_T *packet_info)
static void set_register (set_register_T *set_register)
static void pause_loop (pause_loop_T *pause_loop)
static void get_register (get_register_T *get_register)
static void mem_verify (mem_verify_T *mem_verify)
static void mem_test (mem_test_T *mem_test)
static void mem_dump (mem_dump_T *mem_dump)
static void mem_clear (mem_clear_T *mem_clear)
static void jump (jump_T *jump)

Variables

byte __Stext []
byte __Edata []
FILE * stdin
FILE * stdout
FILE * stderr
udword seq
char svinto_boot_version []
byte change_baudrate
udword new_baudrate
reg_config_r_bootsel r_bootsel
void(*) send_ack (void) = send_net_ack
void(*) send_hex (udword h, byte nl) = send_net_hex
void(*) send_string (char *str) = send_net_string


Function Documentation

static void decode_load_info ( void   )  [static]

Definition at line 265 of file common.c.

References CRC_LEN, flash_write(), get_register(), jump(), mem_clear(), mem_dump(), mem_test(), mem_verify(), new_baudrate, packet_info(), pause_loop(), read_load_info(), rflflash_dump(), rflflash_dump_oob(), rflflash_ignore_bad(), rflflash_init(), rflflash_mark_bad(), rflflash_nand_do_erase(), rflflash_write(), send_hex, send_string, and set_register().

Referenced by read_load_info().

static void get_register ( get_register_T *  get_register  )  [static]

Definition at line 180 of file common.c.

References send_hex, and send_string.

Referenced by decode_load_info().

static void jump ( jump_T *  jump  )  [static]

Definition at line 245 of file common.c.

References send_hex, and send_string.

Referenced by decode_load_info().

static void mem_clear ( mem_clear_T *  mem_clear  )  [static]

Definition at line 230 of file common.c.

References send_hex, and send_string.

Referenced by decode_load_info().

static void mem_dump ( mem_dump_T *  mem_dump  )  [static]

Definition at line 221 of file common.c.

References memory_dump(), send_hex, and send_string.

Referenced by decode_load_info().

static void mem_test ( mem_test_T *  mem_test  )  [static]

Definition at line 203 of file common.c.

References memory_dump(), memory_test(), read_load_info(), send_hex, and send_string.

Referenced by decode_load_info().

static void mem_verify ( mem_verify_T *  mem_verify  )  [static]

Definition at line 190 of file common.c.

References read_load_info(), send_hex, and send_string.

Referenced by decode_load_info().

static void memory_dump ( udword *  from,
udword *  to 
) [static]

Definition at line 657 of file common.c.

Referenced by mem_dump(), and mem_test().

static int memory_test ( udword  from,
udword  to,
udword *  failed_address 
) [static]

Definition at line 601 of file common.c.

References send_hex, and send_string.

Referenced by mem_test().

void next_level_boot ( void   ) 

Definition at line 52 of file common.c.

References __Edata, __Stext, net_init(), r_bootsel, read_load_info(), send_ack, send_hex, send_string, stderr, stdout, and svinto_boot_version.

static void packet_info ( packet_info_T *  packet_info  )  [static]

Definition at line 146 of file common.c.

References read_file(), send_ack, send_hex, and send_string.

Referenced by decode_load_info().

static void pause_loop ( pause_loop_T *  pause_loop  )  [static]

Definition at line 170 of file common.c.

References send_hex, and send_string.

Referenced by decode_load_info().

static void read_file ( byte *  addr,
udword  size 
) [static]

Definition at line 484 of file common.c.

References CRC_LEN, r_bootsel, send_hex, send_string, and timeout.

Referenced by packet_info(), and read_load_info().

static void read_load_info ( void   )  [static]

Definition at line 111 of file common.c.

References change_baudrate, CRC_LEN, decode_load_info(), new_baudrate, read_file(), send_ack, send_string, and toggle_led().

Referenced by decode_load_info(), mem_test(), mem_verify(), and next_level_boot().

static void set_register ( set_register_T *  set_register  )  [static]

Definition at line 159 of file common.c.

References send_hex, and send_string.

Referenced by decode_load_info().

static void toggle_led ( void   )  [static]

Definition at line 93 of file common.c.

References data_in, and data_out.

Referenced by read_load_info().


Variable Documentation

byte __Edata[]

Referenced by next_level_boot().

byte __Stext[]

*************************************************************************** ! ! FILE NAME : common.c ! ! DESCRIPTION: Level 2 loader common for serial and network boot. ! ! --------------------------------------------------------------------------- ! (C) Copyright 1998-2006, Axis Communications AB, LUND, SWEDEN !

Referenced by next_level_boot().

byte change_baudrate

Definition at line 30 of file common.c.

Referenced by read_load_info().

udword new_baudrate

Definition at line 31 of file common.c.

Referenced by decode_load_info(), and read_load_info().

reg_config_r_bootsel r_bootsel

Definition at line 32 of file common.c.

Referenced by next_level_boot(), and read_file().

void(*) send_ack(void) = send_net_ack

Definition at line 37 of file common.c.

Referenced by next_level_boot(), packet_info(), and read_load_info().

void(*) send_hex(udword h, byte nl) = send_net_hex

Definition at line 38 of file common.c.

Referenced by decode_load_info(), get_register(), jump(), mem_clear(), mem_dump(), mem_test(), mem_verify(), memory_test(), next_level_boot(), packet_info(), pause_loop(), read_file(), and set_register().

void(*) send_string(char *str) = send_net_string

Definition at line 39 of file common.c.

Referenced by decode_load_info(), get_register(), jump(), mem_clear(), mem_dump(), mem_test(), mem_verify(), memory_test(), next_level_boot(), packet_info(), pause_loop(), read_file(), read_load_info(), and set_register().

udword seq

Referenced by SendToDevice().

FILE* stderr

Definition at line 25 of file common.c.

Referenced by arping(), audio_end(), audio_finish(), audio_init(), audio_process(), audio_start(), calculateBeamParams(), camogm_debug(), camogm_end_mov(), camogm_frame_mov(), camogm_init(), camogm_set_audio_format(), camogm_set_audio_state(), camogm_start_mov(), camogm_status(), convert8to8(), DecodeSvintoBoot(), die(), dma2bmp(), dma2jpeg(), do_accept(), do_one_xcvr(), do_read(), error_msg(), error_msg_and_die(), errorMsgXML(), export_vrml(), exportIsolineCoord(), exportIsolineNode(), exportVRMLStart(), fillEdgesArray(), findNextEdge(), framePointersXML(), get_src_addr(), grab_and_send(), handle_DESCRIBE(), handle_PAUSE(), handle_PLAY(), handle_request(), initPalette(), initPixelBuffers(), initPseudoColor(), initVertexArray(), jpeg_session_start(), listener_loop(), listParams(), log(), main(), mdio_read(), mdio_write(), monitor_mii(), next_level_boot(), opt_parse(), parse_advertise(), printUsage(), recvpacket(), rtsp_listen(), rtsp_udp_setup(), run_daemon(), send_buf_image(), send_hardware_image(), send_html_data(), send_immed_image(), send_jpeg(), send_jpegfile_image(), send_quicktime(), send_quicktime_clip(), sendBuffer(), sendImage(), session_finish(), udp_exit4(), udp_init4(), usage(), verror_msg(), vperror_msg(), wave_begin(), and write_sdp().

FILE* stdin

Definition at line 23 of file common.c.

Referenced by CreateNewBootPacket(), and listener_loop().

FILE* stdout

Definition at line 24 of file common.c.

Referenced by camogm_debug(), camogm_status(), dma2bmp(), dma2jpeg(), exportVRMLStart(), listener_loop(), main(), monitor_mii(), monitor_status(), next_level_boot(), non_region_erase(), out1x1gif(), process_get(), region_erase(), run_daemon(), send_hardware_image(), send_quicktime(), send_quicktime_clip(), sendBuffer(), sendLastFrame(), verror_msg(), and write_png().

char svinto_boot_version[]

Referenced by next_level_boot().


Generated on Thu Aug 7 16:20:59 2008 for elphel by  doxygen 1.5.1