summaryrefslogtreecommitdiffstats
path: root/drivers/staging/tidspbridge
Commit message (Collapse)AuthorAgeFilesLines
* staging: ti dspbridge: avoid errors if stream id is zeroErnesto Ramos2010-08-021-2/+6
| | | | | | | | | As 'zero' can be a perfectly good id, it can be picked up as a NULL from userspace, avoid issues in API and user apps if stream handle is zero. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: use stream id instead of kernel addressErnesto Ramos2010-08-027-169/+192
| | | | | | | | | Send stream ids to the user instead of handles, then when the id is coming from user dspbridge can retrive the handle using id and avoid using invalid handles. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: use processor handle from context instead of user'sErnesto Ramos2010-08-021-21/+29
| | | | | | | | Make sure dspbridge driver uses a valid processor handle by using the handle stored in process context. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: avoid errors if node handle is zeroErnesto Ramos2010-08-021-2/+4
| | | | | | | | | As 'zero' can be a perfectly good id, it can be picked up as a NULL from userspace, avoid issues in API and user apps if node handle is zero. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: use node id instead of kernel addressErnesto Ramos2010-08-027-196/+257
| | | | | | | | | | | Use idr kernel library to send/receive node ids to the user instead of kernel address. This id will be use to access the node handles at the kernel side, if id does not match to any handle error -EFAULT is returned. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: avoid possible NULL dereference panicErnesto Ramos2010-08-021-6/+8
| | | | | | | | | | | When dsp_notifications array is received from user, dspbridge verifies the array has valid pointers and dsp_notification structures. However, these structures contain pointers that need to be checked for valid handles. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove find_gcf from nldr.cErnesto Ramos2010-07-281-18/+2
| | | | | | | | Remove find_gcf from nldr.c and use kernel function gcd(). Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove bridge_brd_delete functionErnesto Ramos2010-07-281-56/+1
| | | | | | | | Remove bridge_brd_delete() function since it is doing the same that bridge_brd_stop(). Signed-off-by: Ernesto Ramos <ernesto@ernesto-desktop.(none)> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: make sure IVA2 is OFF when dev is createdErnesto Ramos2010-07-281-1/+3
| | | | | | | | | Regardless the IVA2 power state before bridgedriver is installed, the driver must ensure that IVA2 power state is OFF when the device driver is created. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: proc_load/start should set IVA2 to OFF in case of failureErnesto Ramos2010-07-281-2/+4
| | | | | | | | When a base image is being loaded or started and by some reason the process fails, the IVA2 should be switched OFF. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: fix bridge_brd_stop so IVA2 is set OFFErnesto Ramos2010-07-281-4/+4
| | | | | | | | right now, bridge_brd_stop is not changing the IVA2 power state to OFF since PM_PWSTST_IVA2 is not 0 after calling this function. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_FAILED macro definitionErnesto Ramos2010-07-281-3/+0
| | | | | | | | | Since status succeeded is now 0 macro DSP_FAILED is not necessary anymore. This patch removes this define. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_FAILED macro from servicesErnesto Ramos2010-07-281-7/+6
| | | | | | | | Since status succeeded is 0, DSP_FAILED macro is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_FAILED macro from rmgrErnesto Ramos2010-07-2812-132/+129
| | | | | | | | Since status succeeded is 0, DSP_FAILED macro is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_FAILED macro from pmgrErnesto Ramos2010-07-287-41/+39
| | | | | | | | Since status succeeded is 0, DSP_FAILED macro is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_FAILED macro from coreErnesto Ramos2010-07-285-47/+47
| | | | | | | | Since status succeeded is 0, DSP_FAILED macro is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_SUCCEEDED macro definitionErnesto Ramos2010-07-281-2/+1
| | | | | | | | | Since status succeeded is now 0 macro DSP_SUCCEEDED is not necessary anymore. This patch removes this define. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_SUCCEEDED macro from servicesErnesto Ramos2010-07-281-5/+5
| | | | | | | | Since status succeeded is now 0 macro DSP_SUCCEEDED is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_SUCCEEDED macro from rmgrErnesto Ramos2010-07-2812-272/+260
| | | | | | | | Since status succeeded is now 0 macro DSP_SUCCEEDED is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_SUCCEEDED macro from pmgrErnesto Ramos2010-07-289-161/+139
| | | | | | | | Since status succeeded is now 0 macro DSP_SUCCEEDED is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove DSP_SUCCEEDED macro from coreErnesto Ramos2010-07-287-108/+91
| | | | | | | | Since status succeeded is now 0 macro DSP_SUCCEEDED is not necessary anymore. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: replace simple_strtoul by strict_strtoulErnesto Ramos2010-07-281-1/+5
| | | | | | | Replace simple_strtoul by strict_strtoul in atoi function. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove unnecessary volatile variablesErnesto Ramos2010-07-283-9/+10
| | | | | | | | Remove unnecessary volatile variables; use accessor functions __raw_readl/__raw_writel instead when applicable. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove function delete_strm_mgrErnesto Ramos2010-07-281-14/+2
| | | | | | | | Remove function delete_strm_mgr in strm.c and use kfree instead. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove unnecessary check for NULL pointer in cmm.cErnesto Ramos2010-07-281-6/+2
| | | | | | | Remove unnecessary check for NULL pointer in cmm.c. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging:ti dspbridge: remove unused typedef REG16Ernesto Ramos2010-07-281-2/+0
| | | | | | | Remove unused typedef REG16 in dspbridge. Signed-off-by: Ernesto Ramos <ernesto@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Remove unused macrosArmando Uribe2010-07-269-52/+0
| | | | | | | | This patch removes a couple of macros that are not being used Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Change macros to static inline functionsArmando Uribe2010-07-263-36/+20
| | | | | | | | | This patch changes preprocesing macros to static inline funcions. Also the function is_equal_uuid (IS_EQUAL_UUID) now uses the memcmp function. Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Remove macros used as castArmando Uribe2010-07-267-37/+16
| | | | | | | | This patch removes those macros that are used to perform casts Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Remove unused magic numberArmando Uribe2010-07-261-7/+0
| | | | | | | | This patch removes an unused magic number from the cod_manager structure. Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Remove redundant macro from cod.cArmando Uribe2010-07-261-15/+12
| | | | | | | | This patch removes a redundant macro from cod.c simply used to verify that a field was not NULL Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Change macros to static inline functions used in cloadArmando Uribe2010-07-263-18/+31
| | | | | | | | | This patch changes the macros to static inline function used in cload as well adds two definition of const to avoid using magic numbers Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Change macros to static inline functions in io_smArmando Uribe2010-07-262-11/+14
| | | | | | | | This patch change to macros to static inline functions, these macros are used to perform write/read operations in shared memory Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Remove redundant macros in io_sm.cArmando Uribe2010-07-262-52/+30
| | | | | | | | This patch removes 4 redundant macros used to perform read/write operations in shared memory region from io_sm.c. Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: Remove Redundant wrappersArmando Uribe2010-07-263-85/+17
| | | | | | | This patch removes redundant wrappers from io_sm.c file Signed-off-by: Armando Uribe <x0095078@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove dbdefs.hMenon, Nishanth2010-07-223-71/+0
| | | | | | | Remove yet another custom definition header Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove OUT defineMenon, Nishanth2010-07-2251-234/+234
| | | | | | | Remove OUT modifier which makes no sense for linux kernel Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove OPTIONALMenon, Nishanth2010-07-2211-30/+30
| | | | | | | OPTIONAL modifier makes no sense in linux kernel Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove IN modifierMenon, Nishanth2010-07-2251-241/+241
| | | | | | | IN modifier does not exist. remove it Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: replace CONST with c standard constMenon, Nishanth2010-07-2232-65/+65
| | | | | Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove GlobalTypes.hMenon, Nishanth2010-07-224-326/+0
| | | | | | | Remove custom globaltypes.h header Signed-off-by: Nishanth Menon <nm@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: check kmalloc() resultKulikov Vasiliy2010-07-221-0/+4
| | | | | | | If kmalloc() fails then exit with -ENOMEM. Signed-off-by: Kulikov Vasiliy <segooon@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove RET_OK RET_FAILNishanth Menon2010-07-222-32/+31
| | | | | | | | | RET_OK is 0 and RET_FAIL is a -1, replace these custom returns with a standard errno Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove custom typedef reg_uword32Nishanth Menon2010-07-224-106/+44
| | | | | | | | use readl, writel to get and set the register instead. Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove std.hNishanth Menon2010-07-2235-127/+41
| | | | | | | | | | | std.h introduces _TI_ _FLOAT_ _FIXED_ _TARGET_ ARG_TO_INT ARG_TO_PTR which are no longer being used anywhere. we dont really need the custom std.h header. remove it from the repo. where we need types, introduce standard types.h Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: no need for custom NULLNishanth Menon2010-07-224-25/+0
| | | | | | | | | kernel has it's own NULL define, we dont need to introduce our own custom NULL type! Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: tidspbridge: remove custom TRUE FALSENishanth Menon2010-07-229-34/+8
| | | | | | | | | bool has standard true and false, we dont need to introduce our own TRUE and FALSE macros. Signed-off-by: Nishanth Menon <nm@ti.com> Reviewed-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: make variables in prototypes match within functions ↵Rene Sapiens2010-07-2230-184/+195
| | | | | | | | | | definitions This patch renames the variables in the parameter lists and in the function definitions to make them match. Signed-off-by: Rene Sapiens <rene.sapiens@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: Rename words with camel caseRene Sapiens2010-07-227-127/+129
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The intention of this patch is to rename the remaining variables with camel case. Variables will be renamed avoiding camel case and Hungarian notation. The words to be renamed in this patch are: ======================================== validBit to valid_bit victimEntryNum to victim_entry_num virtualAddr to virtual_addr xType to xtype actualValue to actual_value EASIL1_MMUMMU_IRQSTATUSReadRegister32 to easil1_mmummu_irqstatus_read_register32 EASIL1_MMUMMU_LOCKBaseValueWrite32 to easil1_mmummu_lock_base_value_write32 easiNum to easi_num expectedValue to expected_value invalidValue to invalid_value L1_base to l1_base L2_base to l2_base lower16Bits to lower16_bits lower8Bits to lower8_bits lowerMiddle8Bits to lower_middle8_bits lowerUpper8Bits to lower_upper8_bits maxValidValue to max_valid_value minValidValue to min_valid_value newValue to new_value returnCodeIfMismatch to return_code_if_mismatch spyCodeIfMisMatch to spy_code_if_mis_match upper16Bits to upper16_bits upper8Bits to upper8_bits ======================================== Signed-off-by: Rene Sapiens <rene.sapiens@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* staging: ti dspbridge: Rename words with camel case.Rene Sapiens2010-07-2216-161/+161
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The intention of this patch is to rename the remaining variables with camel case. Variables will be renamed avoiding camel case and Hungarian notation. The words to be renamed in this patch are: ======================================== ulBrdState to brd_state ulChnl to chnl ulDspAddr to dsp_add ulDspDestAddr to dsp_dest_addr ulDspLoadAddr to dsp_load_addr ulDspRunAddr to dsp_run_addr ulDspSrcAddr to dsp_src_addr ulMapAttrs to map_attr ulMemType to mem_type ulRMSFxn to rms_fxn ulStatus to ret ulVirtAddr to virt_addr uNumDesc to num_desc uNumToDSP to num_to_dsp uPaSize to pa_size uPhase to phase uSegId to segm_id uStream1 to stream1 uStream2 to stream2 uZId to zid ======================================== Signed-off-by: Rene Sapiens <rene.sapiens@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
OpenPOWER on IntegriCloud