summaryrefslogtreecommitdiffstats
path: root/src/target/firmware/include
Commit message (Collapse)AuthorAgeFilesLines
* fw/layer1/l23_api: Add processing of the new audio_modeSylvain Munaut2011-07-282-0/+4
| | | | | | This currently just stores it into the l1 sync state struct Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/l1: Add a queue for traffic frame to send to network (TRAFFIC_REQ)Sylvain Munaut2011-07-281-0/+1
| | | | | | | | Also hard limit to maximum 4 pending frames (should not happen !), the upstream is supposed to do its own flow control. Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* [layer1] Adding neighbour cell measurement code to layer1.Andreas Eversberg2011-07-173-0/+14
| | | | | | When listening to BCCH, layer1 may measure the power level of neighbour cells. A list of neighbour cell frequencies need to be sent to layer1. After the measurement is done, the results are indicated to layer23.
* [rf] Adding rffe_set_gain() and rffe_get_gain() to get/set computed gainAndreas Eversberg2011-07-172-4/+12
| | | | | | | | | rffe_compute_gain() is the new name for rffe_set_gain(). I needed to change this, to solve the name collision with the rffe_set_gain() function, which actually sets the absolute gain. rffe_get_gain() will now read the absolute gain which has been computed by rffe_compute_gain() or set by rffe_set_gain().
* fw/l1a: Add a message to safely count the length of a txqueueAndreas Eversberg2011-06-251-0/+3
| | | | | | | (that is by locking) Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/rffe: Add function to query RF wiringSylvain Munaut2011-05-291-0/+14
| | | | | | | Depending on the chipset and the HW, not all ports are connected and we need to know what we can use when we have the choice ... Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* src: use namespace prefix osmo_timer*Pablo Neira Ayuso2011-05-151-6/+6
| | | | | | | | | | | | | | Summary of changes: s/struct timer_list/struct osmo_timer_list/g s/bsc_add_timer/osmo_timer_add/g s/bsc_schedule_timer/osmo_timer_schedule/g s/bsc_del_timer/osmo_timer_del/g s/bsc_timer_pending/osmo_timer_pending/g s/bsc_nearest_timer/osmo_timers_nearest/g s/bsc_prepare_timers/osmo_timers_prepare/g s/bsc_update_timers/osmo_timers_update/g s/bsc_timer_check/osmo_timers_check/g
* target/boards: add infrastructure for loaders for Mediatek platformsWolfram Sang2011-05-053-0/+311
| | | | | | | | | | We are just interested in the loaders here, no other applications needed. Split it from the compal-based phones. Add mt62xx as first user. Based on a patch by steve-m, but cleaned up and seperated from compal/calypso. Signed-off-by: Steve Markgraf <steve@steve-m.de> Signed-off-by: Wolfram Sang <wolfram@the-dreams.de>
* uart.h: move header out of calypso-directoryWolfram Sang2011-05-051-3/+3
| | | | | | | Everything defined is a pretty generic interface and can be used by mediatek, too. Signed-off-by: Wolfram Sang <wolfram@the-dreams.de>
* src: use new libosmogsm and include/osmocom/[gsm|core] path to headersPablo Neira Ayuso2011-04-269-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | This patch changes include paths to get osmocom-bb working with the current libosmocore tree. Among all these renames, you can notice several tweaks that I added on purpose, and that require some explanation, they are: * hexdump() in osmocon.c and osmoload.c has been renamed to avoid clashing with hexdump() defined in libosmocore. * gsmmap now depends on libosmogsm. Actually I had to cleanup Makefile.am because I was experiencing weird linking problems, probably due to a bug in the autotools. With the change included in this patch, I got it compiled and linked here correctly. This patch has been tested with the phone Motorola C123 and the following images files: * firmware/board/compal_e88/hello_world.compalram.bin * firmware/board/compal_e88/layer1.compalram.bin Using the osmocon, bcch_scan and mobile tools. Signed-off-by: Pablo Neira Ayuso <pablo@gnumonks.org>
* fw/calypso: Add a new driver for the buzzer controlSylvain Munaut2011-04-241-0/+34
| | | | | Written-by: Jose Luis Pereira <onaips@gmail.com> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Adding TAO loop to correct TPU window offsetAndreas Eversberg2011-03-202-0/+11
| | | | Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* target/fw: set the TRF6151 tsp IDs from the rffe initializationSteve Markgraf2011-01-242-1/+2
| | | Signed-off-by: Steve Markgraf <steve@steve-m.de>
* fixed typos in commentsThomas Waldmann2011-01-111-1/+1
| | | | Signed-off-by: Steve Markgraf <steve@steve-m.de>
* stdint.h: Next attempt at making this work with various compilersHolger Hans Peter Freyther2010-12-201-0/+7
| | | | | | | | | | | | Newer GCC with GNU LIBC do not like our minimalistic version of stdint.h and will have conflicts. Older GCC with older C Libs do not have a stdint.h yet and the #include_next trick is failing. To make matters worse NEWLIB does not export its version via the pre-processor. We will have to guess once more about the compiler. This code now assumes that if we have a GCC < 4 that it does not have a stdint.h and we will not try to include the next stdint.h file.
* [mtk] Add initial / unfinished MT6139 driverHarald Welte2010-12-121-0/+60
|
* add definitions for sciphone G2Harald Welte2010-11-092-0/+40
|
* add some header files about MTK GSM related peripheralsHarald Welte2010-11-094-0/+226
|
* target/fw/l1: Fix TCH/H by properly scheduling the TCHD task during 'off' slotsSylvain Munaut2010-11-071-0/+1
| | | | | | | Apparently the DSP needs to be run even during the slots without actual bursts exchange. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* target/fw/layer1: Change L1CTL RACH req to properly use all slotsAndreas.Eversberg2010-10-302-3/+3
| | | | | Written-by: Andreas Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* target/fw/layer1: Add support for the various TCH multi frame tasksSylvain Munaut2010-10-251-0/+5
| | | | Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* target/fw/layer1: Add initial version of TCH primitivesSylvain Munaut2010-10-252-1/+6
| | | | | | | | | | The initial bringup is mainly Dieter Spaar's work. I took the logic and rewrote it, adapting to later scheduler changes and adding support for several other things (tch_mode, initial HR support, various cleanup, ...). Initially-Written-by: Dieter Spaar <spaar@mirider.augusta.de> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* target/fw/include: Fix missing apc helper declarationSylvain Munaut2010-10-251-0/+2
| | | | Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* target/fw/dsp: Add utility function to memcpy to/from the APISylvain Munaut2010-10-251-0/+2
| | | | | | | | | | | Copying to/from the DSP API shared memory must be done using 16 bits word only. Using those method, we avoid the hassle of repeating the code when we copy buffer back and forth. API address must be 16 bits aligned but for our purpose, it's good enough. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Process the tch_mode and store it for later useSylvain Munaut2010-09-282-0/+6
| | | | | | | Currently unused since no TCH support ... Will be used by future commits. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Add support for proper meas. report (and use in prim_tx_nb)Sylvain Munaut2010-09-281-0/+2
| | | | | | Rewritten based on an original patch by Andreas.Eversberg. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Add support for measurement messages from layer2/3Andreas.Eversberg2010-09-282-0/+2
| | | | | Written-by: Andreas.Eversberg <jolly@eversberg.eu> Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Introduce prim_utils.c for shared helper betwee primitivesSylvain Munaut2010-09-281-0/+3
| | | | | | Currently only share the idle frame pattern. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Introduce prim.h for all primitive related thingsSylvain Munaut2010-09-282-5/+24
| | | | Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* target/layer1: Implement host-driven Tx power controlSylvain Munaut2010-09-262-0/+12
| | | | | | | | | | It's up to L23 to change the parameters using the appropriate L1CTL call. This is a mix between Harald's version and Dieter's version of the TX control code. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/dsp: Add function to load dsp ciphering parametersSylvain Munaut2010-09-171-0/+1
| | | | Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw: Update dsl_load_tch_params to set the fn_sid, fn_report and fn_a5Sylvain Munaut2010-09-171-2/+5
| | | | | | Mix between Dieter's version in tch branch and how the TSM30 does it. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw: Move channel type/mode definitions in common headerSylvain Munaut2010-09-171-0/+20
| | | | | | We'll need them later elsewhere than the tx prim Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Increase tdma_sched bucket sizeSylvain Munaut2010-09-171-1/+1
| | | | | | We can now have a bunch more stuff scheduled ! Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Add common TPU win setup/cleanup codeSylvain Munaut2010-09-171-2/+3
| | | | | | | | | | | | Instead of each primitive doing it independently, if there is a TPU scenario in one of the item, we do a common setup with the base tn returned by rfch_get_params. Then each rx / tx window setup is relative to that 'base tn'. For TX window, you have to explicitely request an offset of 3. (this would allow for some test code to TX on ts=0 for eg.) Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Add some sched items flags to signal DSP & TPU scenariosSylvain Munaut2010-09-171-0/+5
| | | | | | | If those flags are set in one of the item of the current frame, we end the tpu & dsp scenario in common code. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Add a 'flags' field to sched_items and the infra to use itSylvain Munaut2010-09-171-1/+5
| | | | | | This is only preparation Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* fw/layer1: Add a priority field for sched_itemSylvain Munaut2010-09-171-2/+4
| | | | | | | | | | | | | | | | | | | Each item has a priority associated to it. The standard is : -4 -> Responses processing -3 -> L1S parameters changes -2 -> [Reserved for TPU window setup] -1 -> (anything) 0..7 -> Commands relative to time slot n (relative to current l1s main timeslot) 8 -> (anything) 9 -> [Reserved for TPU window cleanup] 10 -> (anthing) Note that with this modification, an item scheduled for the current frame from within a call back won't have its priority respected ! Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* [layer1] Fixed memory leak issue after releasing dedicated modeAndreas.Eversberg2010-09-141-0/+3
| | | | | | While releasing dedicated mode, pending SDCCH and SACCH messages need to be flushed. Without it, it would also cause old pending messages to be sent during next dedicated mode.
* [layer1] Fixed double IRQ bugAndreas.Eversberg2010-09-121-0/+5
| | | | | | | | | | | | | | | | | | | | During IRQ handling, disabling and enabling IRQ may cause the same IRQ to fire again. This is because the condition for this IRQ may be fullfilled again, while still handling it. Using local_firq_save() and local_irq_resore() intead, the IRQ handling will be completed before it is cleared, and may then fire again. The problem was detected during process of messages from layer23 to layer1. In the IRQ context, the TX-functions of l23_api.c are called. There, messages are queued and events are scheduled. During access to a queue or a scheduler from any IRQ context or from normal context, interrupts must be locked to prevent nested calls. If it is not desired to call l23_api.c inside IRQ context, a message queue must be used. If a message is written to that queue, it must be locked. Afterwards a signal must be sent to the main process. The main process locks the queue and de-queues the message. This is how it is done by all layer 1 drivers of mISDN.
* [layer1] Added frequency change control to layer 1 (L1CTL_FREQ_REQ)Andreas.Eversberg2010-09-112-9/+25
| | | | | | | | The given new frequency set will be used at given frame number. If the frame number is already reached, the frequency set will be changed directly. The functionality has been successfully tested.
* include: Rename l1a_l23_interface.h to l1ctl_proto.hSylvain Munaut2010-07-272-2/+2
| | | | | | | | The interface between l1 and upper layer is called by several name. IMHO l1ctl is shorted and sounds good so try to unify using that. Signed-off-by: Sylvain Munaut <tnt@246tNt.com>
* [display] add driver for the Toppoly TD014, as used in the C139/C140Steve Markgraf2010-07-201-0/+1
| | | | Signed-off-by: Steve Markgraf <steve@steve-m.de>
* firmware: moved cfi_flash header to flash subdirectoryIngo Albrecht2010-07-201-0/+0
|
* firmware: board init with a ctor does not seem a good idea to me because i ↵Ingo Albrecht2010-07-201-0/+2
| | | | need binaries without board init
* firmware: removed obsolete commentIngo Albrecht2010-07-201-1/+0Star
|
* firmware: establish a ramtext section for code that must be in ramIngo Albrecht2010-07-201-3/+1Star
|
* loader: flash locking commands, various flash reworkIngo Albrecht2010-07-201-52/+23Star
|
* flash: fixed up headerIngo Albrecht2010-07-201-5/+7
|
* [firmware] TRF6151: fix VGA gain calculation bugHarald Welte2010-07-191-7/+0Star
| | | | | | | | We've had two sets of TRF6151 GAIN related #defines which were used in an incorrect manner, resulting in a vga_gain of 60, which is outside of the allowed gain range. Thanks to Dieter Spaar for spotting this bug