From 6280238c13e16a105fe658e1b6e68380cbc9f055 Mon Sep 17 00:00:00 2001 From: Omar Ramirez Luna Date: Wed, 23 Jun 2010 16:12:23 +0300 Subject: staging: ti dspbridge: add header files Add TI's DSP Bridge driver header files Signed-off-by: Omar Ramirez Luna Signed-off-by: Kanigeri, Hari Signed-off-by: Ameya Palande Signed-off-by: Guzman Lugo, Fernando Signed-off-by: Hebbar, Shivananda Signed-off-by: Ramos Falcon, Ernesto Signed-off-by: Felipe Contreras Signed-off-by: Anna, Suman Signed-off-by: Gupta, Ramesh Signed-off-by: Gomez Castellanos, Ivan Signed-off-by: Andy Shevchenko Signed-off-by: Armando Uribe De Leon Signed-off-by: Deepak Chitriki Signed-off-by: Menon, Nishanth Signed-off-by: Phil Carmody Signed-off-by: Ohad Ben-Cohen Signed-off-by: Greg Kroah-Hartman --- .../staging/tidspbridge/include/dspbridge/dspapi.h | 167 +++++++++++++++++++++ 1 file changed, 167 insertions(+) create mode 100644 drivers/staging/tidspbridge/include/dspbridge/dspapi.h (limited to 'drivers/staging/tidspbridge/include/dspbridge/dspapi.h') diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspapi.h b/drivers/staging/tidspbridge/include/dspbridge/dspapi.h new file mode 100644 index 000000000000..f84ac6986b1f --- /dev/null +++ b/drivers/staging/tidspbridge/include/dspbridge/dspapi.h @@ -0,0 +1,167 @@ +/* + * dspapi.h + * + * DSP-BIOS Bridge driver support functions for TI OMAP processors. + * + * Includes the wrapper functions called directly by the + * DeviceIOControl interface. + * + * Notes: + * Bridge services exported to Bridge driver are initialized by the DSPAPI on + * behalf of the Bridge driver. Bridge driver must not call module Init/Exit + * functions. + * + * To ensure Bridge driver binary compatibility across different platforms, + * for the same processor, a Bridge driver must restrict its usage of system + * services to those exported by the DSPAPI library. + * + * Copyright (C) 2005-2006 Texas Instruments, Inc. + * + * This package is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License version 2 as + * published by the Free Software Foundation. + * + * THIS PACKAGE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR + * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED + * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. + */ + +#ifndef DSPAPI_ +#define DSPAPI_ + +#include + +/* This BRD API Library Version: */ +#define BRD_API_MAJOR_VERSION (u32)8 /* .8x - Alpha, .9x - Beta, 1.x FCS */ +#define BRD_API_MINOR_VERSION (u32)0 + +/* + * ======== api_call_dev_ioctl ======== + * Purpose: + * Call the (wrapper) function for the corresponding API IOCTL. + * Parameters: + * cmd: IOCTL id, base 0. + * args: Argument structure. + * pResult: + * Returns: + * 0 if command called; -EINVAL if command not in IOCTL + * table. + * Requires: + * Ensures: + */ +extern int api_call_dev_ioctl(unsigned int cmd, + union Trapped_Args *args, + u32 *pResult, void *pr_ctxt); + +/* + * ======== api_init ======== + * Purpose: + * Initialize modules used by Bridge API. + * This procedure is called when the driver is loaded. + * Parameters: + * Returns: + * TRUE if success; FALSE otherwise. + * Requires: + * Ensures: + */ +extern bool api_init(void); + +/* + * ======== api_init_complete2 ======== + * Purpose: + * Perform any required bridge initialization which cannot + * be performed in api_init() or dev_start_device() due + * to the fact that some services are not yet + * completely initialized. + * Parameters: + * Returns: + * 0: Allow this device to load + * -EPERM: Failure. + * Requires: + * Bridge API initialized. + * Ensures: + */ +extern int api_init_complete2(void); + +/* + * ======== api_exit ======== + * Purpose: + * Exit all modules initialized in api_init(void). + * This procedure is called when the driver is unloaded. + * Parameters: + * Returns: + * Requires: + * api_init(void) was previously called. + * Ensures: + * Resources acquired in api_init(void) are freed. + */ +extern void api_exit(void); + +/* MGR wrapper functions */ +extern u32 mgrwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt); +extern u32 mgrwrap_enum_proc_info(union Trapped_Args *args, void *pr_ctxt); +extern u32 mgrwrap_register_object(union Trapped_Args *args, void *pr_ctxt); +extern u32 mgrwrap_unregister_object(union Trapped_Args *args, void *pr_ctxt); +extern u32 mgrwrap_wait_for_bridge_events(union Trapped_Args *args, + void *pr_ctxt); + +extern u32 mgrwrap_get_process_resources_info(union Trapped_Args *args, + void *pr_ctxt); + +/* CPRC (Processor) wrapper Functions */ +extern u32 procwrap_attach(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_ctrl(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_detach(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_enum_resources(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_get_state(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_get_trace(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_load(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_register_notify(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_start(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_reserve_memory(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_un_reserve_memory(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_map(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_un_map(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_flush_memory(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_stop(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_invalidate_memory(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_begin_dma(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_end_dma(union Trapped_Args *args, void *pr_ctxt); + +/* NODE wrapper functions */ +extern u32 nodewrap_allocate(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_alloc_msg_buf(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_change_priority(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_connect(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_create(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_delete(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_free_msg_buf(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_get_attr(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_get_message(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_pause(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_put_message(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_register_notify(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_run(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_terminate(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_get_uuid_props(union Trapped_Args *args, void *pr_ctxt); + +/* STRM wrapper functions */ +extern u32 strmwrap_allocate_buffer(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_close(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_free_buffer(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_get_event_handle(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_get_info(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_idle(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_issue(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_open(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_reclaim(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_register_notify(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_select(union Trapped_Args *args, void *pr_ctxt); + +extern u32 cmmwrap_calloc_buf(union Trapped_Args *args, void *pr_ctxt); +extern u32 cmmwrap_free_buf(union Trapped_Args *args, void *pr_ctxt); +extern u32 cmmwrap_get_handle(union Trapped_Args *args, void *pr_ctxt); +extern u32 cmmwrap_get_info(union Trapped_Args *args, void *pr_ctxt); + +#endif /* DSPAPI_ */ -- cgit v1.2.3-55-g7522 From 13b18c29ec01068dce4b266cc179d4e90e79d0e9 Mon Sep 17 00:00:00 2001 From: Rene Sapiens Date: Fri, 9 Jul 2010 21:24:03 -0500 Subject: staging: ti dspbridge: Rename words with camel case. 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: ======================================== pPhysAddr to phys_addr pPhysicalAddress to physical_address ppIntfFxns to if_fxns pProcLoadStat to proc_load_stat pProcStat to proc_lstat ppSym to sym_val pRefData to ref_data pRef to ref preservedBit to preserved_bit pResult to result procID to proc_id pSectInfo to sect_inf pSrc to src pstrContent to str_content pstrDummyFile to str_dummy_file pstrExecFile to str_exec_file ======================================== Signed-off-by: Rene Sapiens Signed-off-by: Greg Kroah-Hartman --- drivers/staging/tidspbridge/core/io_sm.c | 33 +++++++++++----------- drivers/staging/tidspbridge/hw/hw_mmu.c | 12 ++++---- drivers/staging/tidspbridge/hw/hw_mmu.h | 2 +- .../staging/tidspbridge/include/dspbridge/cfg.h | 10 +++---- .../staging/tidspbridge/include/dspbridge/cod.h | 8 +++--- .../staging/tidspbridge/include/dspbridge/dbll.h | 4 +-- .../tidspbridge/include/dspbridge/dblldefs.h | 12 ++++---- .../staging/tidspbridge/include/dspbridge/dev.h | 10 +++---- .../staging/tidspbridge/include/dspbridge/drv.h | 10 +++---- .../staging/tidspbridge/include/dspbridge/dspapi.h | 4 +-- .../tidspbridge/include/dspbridge/dspdefs.h | 4 +-- .../staging/tidspbridge/include/dspbridge/dspio.h | 2 +- .../staging/tidspbridge/include/dspbridge/io_sm.h | 6 ++-- .../staging/tidspbridge/include/dspbridge/proc.h | 4 +-- drivers/staging/tidspbridge/pmgr/cod.c | 8 +++--- drivers/staging/tidspbridge/pmgr/dbll.c | 14 ++++----- drivers/staging/tidspbridge/pmgr/dev.c | 14 ++++----- drivers/staging/tidspbridge/rmgr/drv.c | 18 ++++++------ drivers/staging/tidspbridge/rmgr/nldr.c | 22 +++++++-------- drivers/staging/tidspbridge/rmgr/proc.c | 4 +-- drivers/staging/tidspbridge/services/cfg.c | 8 +++--- 21 files changed, 105 insertions(+), 104 deletions(-) (limited to 'drivers/staging/tidspbridge/include/dspbridge/dspapi.h') diff --git a/drivers/staging/tidspbridge/core/io_sm.c b/drivers/staging/tidspbridge/core/io_sm.c index 5090ff151795..6a8bdd205a94 100644 --- a/drivers/staging/tidspbridge/core/io_sm.c +++ b/drivers/staging/tidspbridge/core/io_sm.c @@ -148,9 +148,9 @@ static void output_msg(struct io_mgr *pio_mgr, struct msg_mgr *hmsg_mgr); static u32 find_ready_output(struct chnl_mgr *chnl_mgr_obj, struct chnl_object *pchnl, u32 mask); static u32 read_data(struct bridge_dev_context *dev_ctxt, void *dest, - void *pSrc, u32 usize); + void *src, u32 usize); static u32 write_data(struct bridge_dev_context *dev_ctxt, void *dest, - void *pSrc, u32 usize); + void *src, u32 usize); /* Bus Addr (cached kernel) */ static int register_shm_segs(struct io_mgr *hio_mgr, @@ -919,9 +919,9 @@ static void io_dispatch_pm(struct io_mgr *pio_mgr) * out the dispatch of I/O as a non-preemptible event.It can only be * pre-empted by an ISR. */ -void io_dpc(IN OUT unsigned long pRefData) +void io_dpc(IN OUT unsigned long ref_data) { - struct io_mgr *pio_mgr = (struct io_mgr *)pRefData; + struct io_mgr *pio_mgr = (struct io_mgr *)ref_data; struct chnl_mgr *chnl_mgr_obj; struct msg_mgr *msg_mgr_obj; struct deh_mgr *hdeh_mgr; @@ -1702,9 +1702,9 @@ func_end: * Copies buffers from the shared memory to the host buffer. */ static u32 read_data(struct bridge_dev_context *dev_ctxt, void *dest, - void *pSrc, u32 usize) + void *src, u32 usize) { - memcpy(dest, pSrc, usize); + memcpy(dest, src, usize); return usize; } @@ -1713,9 +1713,9 @@ static u32 read_data(struct bridge_dev_context *dev_ctxt, void *dest, * Copies buffers from the host side buffer to the shared memory. */ static u32 write_data(struct bridge_dev_context *dev_ctxt, void *dest, - void *pSrc, u32 usize) + void *src, u32 usize) { - memcpy(dest, pSrc, usize); + memcpy(dest, src, usize); return usize; } @@ -1793,20 +1793,21 @@ int io_sh_msetting(struct io_mgr *hio_mgr, u8 desc, void *pargs) * Gets the Processor's Load information */ int bridge_io_get_proc_load(IN struct io_mgr *hio_mgr, - OUT struct dsp_procloadstat *pProcStat) + OUT struct dsp_procloadstat *proc_lstat) { - pProcStat->curr_load = hio_mgr->shared_mem->load_mon_info.curr_dsp_load; - pProcStat->predicted_load = + proc_lstat->curr_load = + hio_mgr->shared_mem->load_mon_info.curr_dsp_load; + proc_lstat->predicted_load = hio_mgr->shared_mem->load_mon_info.pred_dsp_load; - pProcStat->curr_dsp_freq = + proc_lstat->curr_dsp_freq = hio_mgr->shared_mem->load_mon_info.curr_dsp_freq; - pProcStat->predicted_freq = + proc_lstat->predicted_freq = hio_mgr->shared_mem->load_mon_info.pred_dsp_freq; dev_dbg(bridge, "Curr Load = %d, Pred Load = %d, Curr Freq = %d, " - "Pred Freq = %d\n", pProcStat->curr_load, - pProcStat->predicted_load, pProcStat->curr_dsp_freq, - pProcStat->predicted_freq); + "Pred Freq = %d\n", proc_lstat->curr_load, + proc_lstat->predicted_load, proc_lstat->curr_dsp_freq, + proc_lstat->predicted_freq); return 0; } diff --git a/drivers/staging/tidspbridge/hw/hw_mmu.c b/drivers/staging/tidspbridge/hw/hw_mmu.c index 84a6332e7388..668fb8a4bb9c 100644 --- a/drivers/staging/tidspbridge/hw/hw_mmu.c +++ b/drivers/staging/tidspbridge/hw/hw_mmu.c @@ -85,7 +85,7 @@ static hw_status mmu_flush_entry(const void __iomem *base_address); * TypE : const u32 * Description : It indicates the page size * - * Identifier : preservedBit + * Identifier : preserved_bit * Type : const u32 * Description : It indicates the TLB entry is preserved entry * or not @@ -114,7 +114,7 @@ static hw_status mmu_flush_entry(const void __iomem *base_address); */ static hw_status mmu_set_cam_entry(const void __iomem *base_address, const u32 page_sz, - const u32 preservedBit, + const u32 preserved_bit, const u32 validBit, const u32 virtual_addr_tag); @@ -337,7 +337,7 @@ hw_status hw_mmu_tlb_add(const void __iomem *base_address, u32 page_sz, u32 entry_num, struct hw_mmu_map_attrs_t *map_attrs, - s8 preservedBit, s8 validBit) + s8 preserved_bit, s8 validBit) { hw_status status = RET_OK; u32 lock_reg; @@ -380,7 +380,7 @@ hw_status hw_mmu_tlb_add(const void __iomem *base_address, virtual_addr_tag = ((virtualAddr & MMU_ADDR_MASK) >> 12); /* Write the fields in the CAM Entry Register */ - mmu_set_cam_entry(base_address, mmu_pg_size, preservedBit, validBit, + mmu_set_cam_entry(base_address, mmu_pg_size, preserved_bit, validBit, virtual_addr_tag); /* Write the different fields of the RAM Entry Register */ @@ -538,7 +538,7 @@ static hw_status mmu_flush_entry(const void __iomem *base_address) /* mmu_set_cam_entry */ static hw_status mmu_set_cam_entry(const void __iomem *base_address, const u32 page_sz, - const u32 preservedBit, + const u32 preserved_bit, const u32 validBit, const u32 virtual_addr_tag) { @@ -551,7 +551,7 @@ static hw_status mmu_set_cam_entry(const void __iomem *base_address, mmu_cam_reg = (virtual_addr_tag << 12); mmu_cam_reg = (mmu_cam_reg) | (page_sz) | (validBit << 2) | - (preservedBit << 3); + (preserved_bit << 3); /* write values to register */ MMUMMU_CAM_WRITE_REGISTER32(base_address, mmu_cam_reg); diff --git a/drivers/staging/tidspbridge/hw/hw_mmu.h b/drivers/staging/tidspbridge/hw/hw_mmu.h index 063efbb2afaa..25f1954ae4c8 100644 --- a/drivers/staging/tidspbridge/hw/hw_mmu.h +++ b/drivers/staging/tidspbridge/hw/hw_mmu.h @@ -85,7 +85,7 @@ extern hw_status hw_mmu_tlb_add(const void __iomem *base_address, u32 page_sz, u32 entry_num, struct hw_mmu_map_attrs_t *map_attrs, - s8 preservedBit, s8 validBit); + s8 preserved_bit, s8 validBit); /* For PTEs */ extern hw_status hw_mmu_pte_set(const u32 pg_tbl_va, diff --git a/drivers/staging/tidspbridge/include/dspbridge/cfg.h b/drivers/staging/tidspbridge/include/dspbridge/cfg.h index 6fdd229cfa27..98cadb17cfae 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/cfg.h +++ b/drivers/staging/tidspbridge/include/dspbridge/cfg.h @@ -100,20 +100,20 @@ extern int cfg_get_dev_object(IN struct cfg_devnode *dev_node_obj, * Parameters: * dev_node_obj: Handle to the dev_node who's driver we are querying. * buf_size: Size of buffer. - * pstrExecFile: Ptr to character buf to hold ExecFile. + * str_exec_file: Ptr to character buf to hold ExecFile. * Returns: * 0: Success. - * -EFAULT: dev_node_obj is invalid or pstrExecFile is invalid. + * -EFAULT: dev_node_obj is invalid or str_exec_file is invalid. * -ENODATA: The resource is not available. * Requires: * CFG initialized. * Ensures: - * 0: Not more than buf_size bytes were copied into pstrExecFile, - * and *pstrExecFile contains default executable for this + * 0: Not more than buf_size bytes were copied into str_exec_file, + * and *str_exec_file contains default executable for this * devnode. */ extern int cfg_get_exec_file(IN struct cfg_devnode *dev_node_obj, - IN u32 buf_size, OUT char *pstrExecFile); + IN u32 buf_size, OUT char *str_exec_file); /* * ======== cfg_get_object ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/cod.h b/drivers/staging/tidspbridge/include/dspbridge/cod.h index 0cc1bd2bffd0..f8cbb21c182e 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/cod.h +++ b/drivers/staging/tidspbridge/include/dspbridge/cod.h @@ -350,7 +350,7 @@ extern int cod_open_base(struct cod_manager *hmgr, IN char *pszCoffPath, * Parameters: * cod_mgr_obj - manager in which to search for the symbol * pstrSect - name of the section, with or without leading "." - * pstrContent - buffer to store content of the section. + * str_content - buffer to store content of the section. * Returns: * 0: on success, error code on failure * -ESPIPE: Symbols have not been loaded onto the board. @@ -358,12 +358,12 @@ extern int cod_open_base(struct cod_manager *hmgr, IN char *pszCoffPath, * COD module initialized. * valid cod_mgr_obj. * pstrSect != NULL; - * pstrContent != NULL; + * str_content != NULL; * Ensures: - * 0: *pstrContent stores the content of the named section. + * 0: *str_content stores the content of the named section. */ extern int cod_read_section(struct cod_libraryobj *lib, IN char *pstrSect, - OUT char *pstrContent, IN u32 content_size); + OUT char *str_content, IN u32 content_size); #endif /* COD_ */ diff --git a/drivers/staging/tidspbridge/include/dspbridge/dbll.h b/drivers/staging/tidspbridge/include/dspbridge/dbll.h index 63785558e35a..a4dea0c110d6 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dbll.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dbll.h @@ -31,11 +31,11 @@ extern int dbll_create(struct dbll_tar_obj **target_obj, extern void dbll_delete(struct dbll_tar_obj *target); extern void dbll_exit(void); extern bool dbll_get_addr(struct dbll_library_obj *lib, char *name, - struct dbll_sym_val **ppSym); + struct dbll_sym_val **sym_val); extern void dbll_get_attrs(struct dbll_tar_obj *target, struct dbll_attrs *pattrs); extern bool dbll_get_c_addr(struct dbll_library_obj *lib, char *name, - struct dbll_sym_val **ppSym); + struct dbll_sym_val **sym_val); extern int dbll_get_sect(struct dbll_library_obj *lib, char *name, u32 *paddr, u32 *psize); extern bool dbll_init(void); diff --git a/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h b/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h index 23eca159563c..b827320e4501 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h @@ -239,7 +239,7 @@ typedef void (*dbll_exit_fxn) (void); * Parameters: * lib - Handle returned from dbll_open(). * name - Name of symbol - * ppSym - Location to store symbol address on output. + * sym_val - Location to store symbol address on output. * Returns: * TRUE: Success. * FALSE: Symbol not found. @@ -247,11 +247,11 @@ typedef void (*dbll_exit_fxn) (void); * DBL initialized. * Valid library. * name != NULL. - * ppSym != NULL. + * sym_val != NULL. * Ensures: */ typedef bool(*dbll_get_addr_fxn) (struct dbll_library_obj *lib, char *name, - struct dbll_sym_val **ppSym); + struct dbll_sym_val **sym_val); /* * ======== dbll_get_attrs ======== @@ -275,7 +275,7 @@ typedef void (*dbll_get_attrs_fxn) (struct dbll_tar_obj *target, * Parameters: * lib - Handle returned from dbll_open(). * name - Name of symbol - * ppSym - Location to store symbol address on output. + * sym_val - Location to store symbol address on output. * Returns: * TRUE: Success. * FALSE: Symbol not found. @@ -283,11 +283,11 @@ typedef void (*dbll_get_attrs_fxn) (struct dbll_tar_obj *target, * DBL initialized. * Valid target. * name != NULL. - * ppSym != NULL. + * sym_val != NULL. * Ensures: */ typedef bool(*dbll_get_c_addr_fxn) (struct dbll_library_obj *lib, char *name, - struct dbll_sym_val **ppSym); + struct dbll_sym_val **sym_val); /* * ======== dbll_get_sect ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/dev.h b/drivers/staging/tidspbridge/include/dspbridge/dev.h index a646402fb703..d658df521d1f 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dev.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dev.h @@ -367,20 +367,20 @@ extern struct dev_object *dev_get_first(void); * Parameters: * hdev_obj: Handle to device object created with * dev_create_device(). - * *ppIntfFxns: Ptr to location to store fxn interface. + * *if_fxns: Ptr to location to store fxn interface. * Returns: * 0: Success. * -EFAULT: Invalid hdev_obj. * Requires: - * ppIntfFxns != NULL. + * if_fxns != NULL. * DEV Initialized. * Ensures: - * 0: *ppIntfFxns contains a pointer to the Bridge + * 0: *if_fxns contains a pointer to the Bridge * driver interface; - * else: *ppIntfFxns is NULL. + * else: *if_fxns is NULL. */ extern int dev_get_intf_fxns(struct dev_object *hdev_obj, - OUT struct bridge_drv_interface **ppIntfFxns); + OUT struct bridge_drv_interface **if_fxns); /* * ======== dev_get_io_mgr ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/drv.h b/drivers/staging/tidspbridge/include/dspbridge/drv.h index 604c15bda5f9..b43d22f8e512 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/drv.h +++ b/drivers/staging/tidspbridge/include/dspbridge/drv.h @@ -451,7 +451,7 @@ extern void mem_ext_phys_pool_release(void); * Parameters: * byte_size: Number of bytes to allocate. * ulAlign: Alignment Mask. - * pPhysicalAddress: Physical address of allocated memory. + * physical_address: Physical address of allocated memory. * Returns: * Pointer to a block of memory; * NULL if memory couldn't be allocated, or if byte_size == 0. @@ -463,7 +463,7 @@ extern void mem_ext_phys_pool_release(void); * location of memory. */ extern void *mem_alloc_phys_mem(IN u32 byte_size, - IN u32 ulAlign, OUT u32 *pPhysicalAddress); + IN u32 ulAlign, OUT u32 *physical_address); /* * ======== mem_free_phys_mem ======== @@ -472,7 +472,7 @@ extern void *mem_alloc_phys_mem(IN u32 byte_size, * Parameters: * pVirtualAddress: Pointer to virtual memory region allocated * by mem_alloc_phys_mem(). - * pPhysicalAddress: Pointer to physical memory region allocated + * physical_address: Pointer to physical memory region allocated * by mem_alloc_phys_mem(). * byte_size: Size of the memory region allocated by mem_alloc_phys_mem(). * Returns: @@ -484,14 +484,14 @@ extern void *mem_alloc_phys_mem(IN u32 byte_size, * pVirtualAddress is no longer a valid pointer to memory. */ extern void mem_free_phys_mem(void *pVirtualAddress, - u32 pPhysicalAddress, u32 byte_size); + u32 physical_address, u32 byte_size); /* * ======== MEM_LINEAR_ADDRESS ======== * Purpose: * Get the linear address corresponding to the given physical address. * Parameters: - * pPhysAddr: Physical address to be mapped. + * phys_addr: Physical address to be mapped. * byte_size: Number of bytes in physical range to map. * Returns: * The corresponding linear address, or NULL if unsuccessful. diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspapi.h b/drivers/staging/tidspbridge/include/dspbridge/dspapi.h index f84ac6986b1f..765a175a28be 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dspapi.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dspapi.h @@ -42,7 +42,7 @@ * Parameters: * cmd: IOCTL id, base 0. * args: Argument structure. - * pResult: + * result: * Returns: * 0 if command called; -EINVAL if command not in IOCTL * table. @@ -51,7 +51,7 @@ */ extern int api_call_dev_ioctl(unsigned int cmd, union Trapped_Args *args, - u32 *pResult, void *pr_ctxt); + u32 *result, void *pr_ctxt); /* * ======== api_init ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h b/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h index 04df01d9ff7e..ed6388e4cebf 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h @@ -787,7 +787,7 @@ typedef int(*fxn_io_onloaded) (struct io_mgr *hio_mgr); * Called to get the Processor's current and predicted load * Parameters: * hio_mgr: IO Manager. - * pProcLoadStat Processor Load statistics + * proc_load_stat Processor Load statistics * Returns: * 0: Success. * -EPERM: Internal failure occurred. @@ -797,7 +797,7 @@ typedef int(*fxn_io_onloaded) (struct io_mgr *hio_mgr); */ typedef int(*fxn_io_getprocload) (struct io_mgr *hio_mgr, struct dsp_procloadstat * - pProcLoadStat); + proc_load_stat); /* * ======== bridge_msg_create ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspio.h b/drivers/staging/tidspbridge/include/dspbridge/dspio.h index 93dc5926fc21..2b9e19c25c74 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dspio.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dspio.h @@ -36,6 +36,6 @@ extern int bridge_io_on_loaded(struct io_mgr *hio_mgr); extern int iva_io_on_loaded(struct io_mgr *hio_mgr); extern int bridge_io_get_proc_load(IN struct io_mgr *hio_mgr, - OUT struct dsp_procloadstat *pProcStat); + OUT struct dsp_procloadstat *proc_lstat); #endif /* DSPIO_ */ diff --git a/drivers/staging/tidspbridge/include/dspbridge/io_sm.h b/drivers/staging/tidspbridge/include/dspbridge/io_sm.h index 7e598ee57571..1627e0ae92fa 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/io_sm.h +++ b/drivers/staging/tidspbridge/include/dspbridge/io_sm.h @@ -68,7 +68,7 @@ extern void io_cancel_chnl(struct io_mgr *hio_mgr, u32 ulChnl); * Deferred procedure call for shared memory channel driver ISR. Carries * out the dispatch of I/O. * Parameters: - * pRefData: Pointer to reference data registered via a call to + * ref_data: Pointer to reference data registered via a call to * DPC_Create(). * Returns: * Requires: @@ -78,7 +78,7 @@ extern void io_cancel_chnl(struct io_mgr *hio_mgr, u32 ulChnl); * Ensures: * Non-preemptible (but interruptible). */ -extern void io_dpc(IN OUT unsigned long pRefData); +extern void io_dpc(IN OUT unsigned long ref_data); /* * ======== io_mbox_msg ======== @@ -87,7 +87,7 @@ extern void io_dpc(IN OUT unsigned long pRefData); * Calls the Bridge's chnlsm_isr to determine if this interrupt is ours, * then schedules a DPC to dispatch I/O. * Parameters: - * pRefData: Pointer to the channel manager object for this board. + * ref_data: Pointer to the channel manager object for this board. * Set in an initial call to ISR_Install(). * Returns: * TRUE if interrupt handled; FALSE otherwise. diff --git a/drivers/staging/tidspbridge/include/dspbridge/proc.h b/drivers/staging/tidspbridge/include/dspbridge/proc.h index cbd26dc9b5a6..5583bd51b45f 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/proc.h +++ b/drivers/staging/tidspbridge/include/dspbridge/proc.h @@ -265,7 +265,7 @@ extern int proc_get_state(void *hprocessor, OUT struct dsp_processorstate * Report the state of the specified DSP processor. * Parameters: * hprocessor : The processor handle. - * procID : Processor ID + * proc_id : Processor ID * * Returns: * 0 : Success. @@ -278,7 +278,7 @@ extern int proc_get_state(void *hprocessor, OUT struct dsp_processorstate * Ensures: * Details: */ -extern int proc_get_processor_id(void *hprocessor, u32 * procID); +extern int proc_get_processor_id(void *hprocessor, u32 * proc_id); /* * ======== proc_get_trace ======== diff --git a/drivers/staging/tidspbridge/pmgr/cod.c b/drivers/staging/tidspbridge/pmgr/cod.c index ab54388c6c69..e4fc065b34d4 100644 --- a/drivers/staging/tidspbridge/pmgr/cod.c +++ b/drivers/staging/tidspbridge/pmgr/cod.c @@ -215,7 +215,7 @@ void cod_close(struct cod_libraryobj *lib) * dynamically loaded object files. * */ -int cod_create(OUT struct cod_manager **mgr, char *pstrDummyFile, +int cod_create(OUT struct cod_manager **mgr, char *str_dummy_file, IN OPTIONAL CONST struct cod_attrs *attrs) { struct cod_manager *mgr_new; @@ -626,7 +626,7 @@ int cod_open_base(struct cod_manager *hmgr, IN char *pszCoffPath, * Retrieve the content of a code section given the section name. */ int cod_read_section(struct cod_libraryobj *lib, IN char *pstrSect, - OUT char *pstrContent, IN u32 content_size) + OUT char *str_content, IN u32 content_size) { int status = 0; @@ -634,12 +634,12 @@ int cod_read_section(struct cod_libraryobj *lib, IN char *pstrSect, DBC_REQUIRE(lib != NULL); DBC_REQUIRE(IS_VALID(lib->cod_mgr)); DBC_REQUIRE(pstrSect != NULL); - DBC_REQUIRE(pstrContent != NULL); + DBC_REQUIRE(str_content != NULL); if (lib != NULL) status = lib->cod_mgr->fxns.read_sect_fxn(lib->dbll_lib, pstrSect, - pstrContent, content_size); + str_content, content_size); else status = -ESPIPE; diff --git a/drivers/staging/tidspbridge/pmgr/dbll.c b/drivers/staging/tidspbridge/pmgr/dbll.c index 45133e099272..e94ef6b6f6de 100644 --- a/drivers/staging/tidspbridge/pmgr/dbll.c +++ b/drivers/staging/tidspbridge/pmgr/dbll.c @@ -300,7 +300,7 @@ void dbll_exit(void) * Get address of name in the specified library. */ bool dbll_get_addr(struct dbll_library_obj *zl_lib, char *name, - struct dbll_sym_val **ppSym) + struct dbll_sym_val **sym_val) { struct dbll_symbol *sym; bool status = false; @@ -308,17 +308,17 @@ bool dbll_get_addr(struct dbll_library_obj *zl_lib, char *name, DBC_REQUIRE(refs > 0); DBC_REQUIRE(zl_lib); DBC_REQUIRE(name != NULL); - DBC_REQUIRE(ppSym != NULL); + DBC_REQUIRE(sym_val != NULL); DBC_REQUIRE(zl_lib->sym_tab != NULL); sym = (struct dbll_symbol *)gh_find(zl_lib->sym_tab, name); if (sym != NULL) { - *ppSym = &sym->value; + *sym_val = &sym->value; status = true; } dev_dbg(bridge, "%s: lib: %p name: %s paddr: %p, status 0x%x\n", - __func__, zl_lib, name, ppSym, status); + __func__, zl_lib, name, sym_val, status); return status; } @@ -344,7 +344,7 @@ void dbll_get_attrs(struct dbll_tar_obj *target, struct dbll_attrs *pattrs) * Get address of a "C" name in the specified library. */ bool dbll_get_c_addr(struct dbll_library_obj *zl_lib, char *name, - struct dbll_sym_val **ppSym) + struct dbll_sym_val **sym_val) { struct dbll_symbol *sym; char cname[MAXEXPR + 1]; @@ -352,7 +352,7 @@ bool dbll_get_c_addr(struct dbll_library_obj *zl_lib, char *name, DBC_REQUIRE(refs > 0); DBC_REQUIRE(zl_lib); - DBC_REQUIRE(ppSym != NULL); + DBC_REQUIRE(sym_val != NULL); DBC_REQUIRE(zl_lib->sym_tab != NULL); DBC_REQUIRE(name != NULL); @@ -365,7 +365,7 @@ bool dbll_get_c_addr(struct dbll_library_obj *zl_lib, char *name, sym = (struct dbll_symbol *)gh_find(zl_lib->sym_tab, cname); if (sym != NULL) { - *ppSym = &sym->value; + *sym_val = &sym->value; status = true; } diff --git a/drivers/staging/tidspbridge/pmgr/dev.c b/drivers/staging/tidspbridge/pmgr/dev.c index 50fedccc964f..5098f7f2d78f 100644 --- a/drivers/staging/tidspbridge/pmgr/dev.c +++ b/drivers/staging/tidspbridge/pmgr/dev.c @@ -585,26 +585,26 @@ struct dev_object *dev_get_first(void) * ======== dev_get_intf_fxns ======== * Purpose: * Retrieve the Bridge interface function structure for the loaded driver. - * ppIntfFxns != NULL. + * if_fxns != NULL. */ int dev_get_intf_fxns(struct dev_object *hdev_obj, - OUT struct bridge_drv_interface **ppIntfFxns) + OUT struct bridge_drv_interface **if_fxns) { int status = 0; struct dev_object *dev_obj = hdev_obj; DBC_REQUIRE(refs > 0); - DBC_REQUIRE(ppIntfFxns != NULL); + DBC_REQUIRE(if_fxns != NULL); if (hdev_obj) { - *ppIntfFxns = &dev_obj->bridge_interface; + *if_fxns = &dev_obj->bridge_interface; } else { - *ppIntfFxns = NULL; + *if_fxns = NULL; status = -EFAULT; } - DBC_ENSURE(DSP_SUCCEEDED(status) || ((ppIntfFxns != NULL) && - (*ppIntfFxns == NULL))); + DBC_ENSURE(DSP_SUCCEEDED(status) || ((if_fxns != NULL) && + (*if_fxns == NULL))); return status; } diff --git a/drivers/staging/tidspbridge/rmgr/drv.c b/drivers/staging/tidspbridge/rmgr/drv.c index ef147b77a8f0..f38123dee898 100644 --- a/drivers/staging/tidspbridge/rmgr/drv.c +++ b/drivers/staging/tidspbridge/rmgr/drv.c @@ -969,7 +969,7 @@ void mem_ext_phys_pool_release(void) * Allocate physically contiguous, uncached memory from external memory pool */ -static void *mem_ext_phys_mem_alloc(u32 bytes, u32 align, OUT u32 * pPhysAddr) +static void *mem_ext_phys_mem_alloc(u32 bytes, u32 align, OUT u32 * phys_addr) { u32 new_alloc_ptr; u32 offset; @@ -980,7 +980,7 @@ static void *mem_ext_phys_mem_alloc(u32 bytes, u32 align, OUT u32 * pPhysAddr) if (bytes > ((ext_mem_pool.phys_mem_base + ext_mem_pool.phys_mem_size) - ext_mem_pool.next_phys_alloc_ptr)) { - pPhysAddr = NULL; + phys_addr = NULL; return NULL; } else { offset = (ext_mem_pool.next_phys_alloc_ptr & (align - 1)); @@ -992,7 +992,7 @@ static void *mem_ext_phys_mem_alloc(u32 bytes, u32 align, OUT u32 * pPhysAddr) if ((new_alloc_ptr + bytes) <= (ext_mem_pool.phys_mem_base + ext_mem_pool.phys_mem_size)) { /* we can allocate */ - *pPhysAddr = new_alloc_ptr; + *phys_addr = new_alloc_ptr; ext_mem_pool.next_phys_alloc_ptr = new_alloc_ptr + bytes; virt_addr = @@ -1001,7 +1001,7 @@ static void *mem_ext_phys_mem_alloc(u32 bytes, u32 align, OUT u32 * pPhysAddr) phys_mem_base); return (void *)virt_addr; } else { - *pPhysAddr = 0; + *phys_addr = 0; return NULL; } } @@ -1012,7 +1012,7 @@ static void *mem_ext_phys_mem_alloc(u32 bytes, u32 align, OUT u32 * pPhysAddr) * Purpose: * Allocate physically contiguous, uncached memory */ -void *mem_alloc_phys_mem(u32 byte_size, u32 ulAlign, OUT u32 * pPhysicalAddress) +void *mem_alloc_phys_mem(u32 byte_size, u32 ulAlign, OUT u32 * physical_address) { void *va_mem = NULL; dma_addr_t pa_mem; @@ -1025,9 +1025,9 @@ void *mem_alloc_phys_mem(u32 byte_size, u32 ulAlign, OUT u32 * pPhysicalAddress) va_mem = dma_alloc_coherent(NULL, byte_size, &pa_mem, GFP_KERNEL); if (va_mem == NULL) - *pPhysicalAddress = 0; + *physical_address = 0; else - *pPhysicalAddress = pa_mem; + *physical_address = pa_mem; } return va_mem; } @@ -1037,12 +1037,12 @@ void *mem_alloc_phys_mem(u32 byte_size, u32 ulAlign, OUT u32 * pPhysicalAddress) * Purpose: * Free the given block of physically contiguous memory. */ -void mem_free_phys_mem(void *pVirtualAddress, u32 pPhysicalAddress, +void mem_free_phys_mem(void *pVirtualAddress, u32 physical_address, u32 byte_size) { DBC_REQUIRE(pVirtualAddress != NULL); if (!ext_phys_mem_pool_enabled) dma_free_coherent(NULL, byte_size, pVirtualAddress, - pPhysicalAddress); + physical_address); } diff --git a/drivers/staging/tidspbridge/rmgr/nldr.c b/drivers/staging/tidspbridge/rmgr/nldr.c index f385cbce7c32..0c8a16567f07 100644 --- a/drivers/staging/tidspbridge/rmgr/nldr.c +++ b/drivers/staging/tidspbridge/rmgr/nldr.c @@ -289,7 +289,7 @@ static int add_ovly_node(struct dsp_uuid *uuid_obj, enum dsp_dcdobjtype obj_type, IN void *handle); static int add_ovly_sect(struct nldr_object *nldr_obj, struct ovly_sect **lst, - struct dbll_sect_info *pSectInfo, + struct dbll_sect_info *sect_inf, bool *exists, u32 addr, u32 bytes); static s32 fake_ovly_write(void *handle, u32 dsp_address, void *buf, u32 bytes, s32 mtype); @@ -304,11 +304,11 @@ static int load_lib(struct nldr_nodeobject *nldr_node_obj, enum nldr_phase phase, u16 depth); static int load_ovly(struct nldr_nodeobject *nldr_node_obj, enum nldr_phase phase); -static int remote_alloc(void **pRef, u16 mem_sect_type, u32 size, +static int remote_alloc(void **ref, u16 mem_sect_type, u32 size, u32 align, u32 *dsp_address, OPTIONAL s32 segmentId, OPTIONAL s32 req, bool reserve); -static int remote_free(void **pRef, u16 space, u32 dsp_address, u32 size, +static int remote_free(void **ref, u16 space, u32 dsp_address, u32 size, bool reserve); static void unload_lib(struct nldr_nodeobject *nldr_node_obj, @@ -1072,7 +1072,7 @@ func_end: */ static int add_ovly_sect(struct nldr_object *nldr_obj, struct ovly_sect **lst, - struct dbll_sect_info *pSectInfo, + struct dbll_sect_info *sect_inf, bool *exists, u32 addr, u32 bytes) { struct ovly_sect *new_sect = NULL; @@ -1103,10 +1103,10 @@ static int add_ovly_sect(struct nldr_object *nldr_obj, status = -ENOMEM; } else { new_sect->sect_load_addr = addr; - new_sect->sect_run_addr = pSectInfo->sect_run_addr + - (addr - pSectInfo->sect_load_addr); + new_sect->sect_run_addr = sect_inf->sect_run_addr + + (addr - sect_inf->sect_load_addr); new_sect->size = bytes; - new_sect->page = pSectInfo->type; + new_sect->page = sect_inf->type; } /* Add to the list */ @@ -1623,12 +1623,12 @@ func_end: /* * ======== remote_alloc ======== */ -static int remote_alloc(void **pRef, u16 space, u32 size, +static int remote_alloc(void **ref, u16 space, u32 size, u32 align, u32 *dsp_address, OPTIONAL s32 segmentId, OPTIONAL s32 req, bool reserve) { - struct nldr_nodeobject *hnode = (struct nldr_nodeobject *)pRef; + struct nldr_nodeobject *hnode = (struct nldr_nodeobject *)ref; struct nldr_object *nldr_obj; struct rmm_target_obj *rmm; u16 mem_phase_bit = MAXFLAGS; @@ -1744,10 +1744,10 @@ func_cont: return status; } -static int remote_free(void **pRef, u16 space, u32 dsp_address, +static int remote_free(void **ref, u16 space, u32 dsp_address, u32 size, bool reserve) { - struct nldr_object *nldr_obj = (struct nldr_object *)pRef; + struct nldr_object *nldr_obj = (struct nldr_object *)ref; struct rmm_target_obj *rmm; u32 word_size; int status = -ENOMEM; /* Set to fail */ diff --git a/drivers/staging/tidspbridge/rmgr/proc.c b/drivers/staging/tidspbridge/rmgr/proc.c index 20f887b690bf..eb8164527d87 100644 --- a/drivers/staging/tidspbridge/rmgr/proc.c +++ b/drivers/staging/tidspbridge/rmgr/proc.c @@ -1921,13 +1921,13 @@ func_end: * Purpose: * Retrieves the processor ID. */ -int proc_get_processor_id(void *proc, u32 * procID) +int proc_get_processor_id(void *proc, u32 * proc_id) { int status = 0; struct proc_object *p_proc_object = (struct proc_object *)proc; if (p_proc_object) - *procID = p_proc_object->processor_id; + *proc_id = p_proc_object->processor_id; else status = -EFAULT; diff --git a/drivers/staging/tidspbridge/services/cfg.c b/drivers/staging/tidspbridge/services/cfg.c index 53ede23011ce..ac23b0917cd9 100644 --- a/drivers/staging/tidspbridge/services/cfg.c +++ b/drivers/staging/tidspbridge/services/cfg.c @@ -112,7 +112,7 @@ int cfg_get_dev_object(struct cfg_devnode *dev_node_obj, * Retreive the default executable, if any, for this board. */ int cfg_get_exec_file(struct cfg_devnode *dev_node_obj, u32 ul_buf_size, - OUT char *pstrExecFile) + OUT char *str_exec_file) { int status = 0; struct drv_data *drv_datap = dev_get_drvdata(bridge); @@ -120,19 +120,19 @@ int cfg_get_exec_file(struct cfg_devnode *dev_node_obj, u32 ul_buf_size, if (!dev_node_obj) status = -EFAULT; - else if (!pstrExecFile || !drv_datap) + else if (!str_exec_file || !drv_datap) status = -EFAULT; if (strlen(drv_datap->base_img) > ul_buf_size) status = -EINVAL; if (DSP_SUCCEEDED(status) && drv_datap->base_img) - strcpy(pstrExecFile, drv_datap->base_img); + strcpy(str_exec_file, drv_datap->base_img); if (DSP_FAILED(status)) pr_err("%s: Failed, status 0x%x\n", __func__, status); DBC_ENSURE(((status == 0) && - (strlen(pstrExecFile) <= ul_buf_size)) + (strlen(str_exec_file) <= ul_buf_size)) || (status != 0)); return status; } -- cgit v1.2.3-55-g7522 From 0cd343a42f60a965cece191efaefe51e01e58f64 Mon Sep 17 00:00:00 2001 From: Rene Sapiens Date: Fri, 9 Jul 2010 21:24:06 -0500 Subject: staging: ti dspbridge: Rename words with camel case 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: ======================================== segmentId to segmnt_id SetPageDirty to set_page_dirty sizeInBytes to size_in_bytes sleepCode to sleep_code Status to status symName to sym_name szVar to sz_var Trapped_Args to trapped_args TTBPhysAddr to ttb_phys_addr uChirps to chirps uChnlId to ch_id uChnlID to ch_id uContentSize to cont_size uDDMAChnlId to ddma_chnl_id uEvents to events ulAlign to align_mask ======================================== Signed-off-by: Rene Sapiens Signed-off-by: Greg Kroah-Hartman --- drivers/staging/tidspbridge/core/chnl_sm.c | 30 +++--- drivers/staging/tidspbridge/core/tiomap3430.c | 4 +- drivers/staging/tidspbridge/hw/hw_mmu.c | 4 +- drivers/staging/tidspbridge/hw/hw_mmu.h | 2 +- .../staging/tidspbridge/include/dspbridge/dbdefs.h | 4 +- .../tidspbridge/include/dspbridge/dblldefs.h | 2 +- .../staging/tidspbridge/include/dspbridge/drv.h | 4 +- .../tidspbridge/include/dspbridge/dspapi-ioctl.h | 2 +- .../staging/tidspbridge/include/dspbridge/dspapi.h | 112 ++++++++++---------- .../tidspbridge/include/dspbridge/dspchnl.h | 4 +- .../tidspbridge/include/dspbridge/dspdefs.h | 8 +- .../staging/tidspbridge/include/dspbridge/io_sm.h | 20 ++-- .../staging/tidspbridge/include/dspbridge/proc.h | 12 +-- .../staging/tidspbridge/include/dspbridge/pwr.h | 6 +- drivers/staging/tidspbridge/pmgr/dspapi.c | 116 ++++++++++----------- drivers/staging/tidspbridge/rmgr/drv.c | 5 +- drivers/staging/tidspbridge/rmgr/drv_interface.c | 6 +- drivers/staging/tidspbridge/rmgr/nldr.c | 12 +-- drivers/staging/tidspbridge/rmgr/proc.c | 18 ++-- drivers/staging/tidspbridge/rmgr/pwr.c | 6 +- 20 files changed, 189 insertions(+), 188 deletions(-) (limited to 'drivers/staging/tidspbridge/include/dspbridge/dspapi.h') diff --git a/drivers/staging/tidspbridge/core/chnl_sm.c b/drivers/staging/tidspbridge/core/chnl_sm.c index 97eeda9264af..ac393b894cf6 100644 --- a/drivers/staging/tidspbridge/core/chnl_sm.c +++ b/drivers/staging/tidspbridge/core/chnl_sm.c @@ -73,7 +73,7 @@ #define MAILBOX_IRQ INT_MAIL_MPU_IRQ /* ----------------------------------- Function Prototypes */ -static struct lst_list *create_chirp_list(u32 uChirps); +static struct lst_list *create_chirp_list(u32 chirps); static void free_chirp_list(struct lst_list *lst); @@ -709,18 +709,18 @@ func_end: * ======== bridge_chnl_get_mgr_info ======== * Retrieve information related to the channel manager. */ -int bridge_chnl_get_mgr_info(struct chnl_mgr *hchnl_mgr, u32 uChnlID, +int bridge_chnl_get_mgr_info(struct chnl_mgr *hchnl_mgr, u32 ch_id, OUT struct chnl_mgrinfo *mgr_info) { int status = 0; struct chnl_mgr *chnl_mgr_obj = (struct chnl_mgr *)hchnl_mgr; if (mgr_info != NULL) { - if (uChnlID <= CHNL_MAXCHANNELS) { + if (ch_id <= CHNL_MAXCHANNELS) { if (hchnl_mgr) { /* Return the requested information: */ mgr_info->chnl_obj = - chnl_mgr_obj->ap_channel[uChnlID]; + chnl_mgr_obj->ap_channel[ch_id]; mgr_info->open_channels = chnl_mgr_obj->open_channels; mgr_info->dw_type = chnl_mgr_obj->dw_type; @@ -776,7 +776,7 @@ int bridge_chnl_idle(struct chnl_object *chnl_obj, u32 timeout, */ int bridge_chnl_open(OUT struct chnl_object **chnl, struct chnl_mgr *hchnl_mgr, s8 chnl_mode, - u32 uChnlId, CONST IN struct chnl_attr *pattrs) + u32 ch_id, CONST IN struct chnl_attr *pattrs) { int status = 0; struct chnl_mgr *chnl_mgr_obj = hchnl_mgr; @@ -794,23 +794,23 @@ int bridge_chnl_open(OUT struct chnl_object **chnl, if (!hchnl_mgr) { status = -EFAULT; } else { - if (uChnlId != CHNL_PICKFREE) { - if (uChnlId >= chnl_mgr_obj->max_channels) + if (ch_id != CHNL_PICKFREE) { + if (ch_id >= chnl_mgr_obj->max_channels) status = -ECHRNG; - else if (chnl_mgr_obj->ap_channel[uChnlId] != + else if (chnl_mgr_obj->ap_channel[ch_id] != NULL) status = -EALREADY; } else { /* Check for free channel */ status = - search_free_channel(chnl_mgr_obj, &uChnlId); + search_free_channel(chnl_mgr_obj, &ch_id); } } } if (DSP_FAILED(status)) goto func_end; - DBC_ASSERT(uChnlId < chnl_mgr_obj->max_channels); + DBC_ASSERT(ch_id < chnl_mgr_obj->max_channels); /* Create channel object: */ pchnl = kzalloc(sizeof(struct chnl_object), GFP_KERNEL); if (!pchnl) { @@ -846,7 +846,7 @@ int bridge_chnl_open(OUT struct chnl_object **chnl, pchnl->free_packets_list) { /* Initialize CHNL object fields: */ pchnl->chnl_mgr_obj = chnl_mgr_obj; - pchnl->chnl_id = uChnlId; + pchnl->chnl_id = ch_id; pchnl->chnl_mode = chnl_mode; pchnl->user_event = sync_event; pchnl->sync_event = sync_event; @@ -926,13 +926,13 @@ int bridge_chnl_register_notify(struct chnl_object *chnl_obj, * Purpose: * Initialize a queue of channel I/O Request/Completion packets. * Parameters: - * uChirps: Number of Chirps to allocate. + * chirps: Number of Chirps to allocate. * Returns: * Pointer to queue of IRPs, or NULL. * Requires: * Ensures: */ -static struct lst_list *create_chirp_list(u32 uChirps) +static struct lst_list *create_chirp_list(u32 chirps) { struct lst_list *chirp_list; struct chnl_irp *chnl_packet_obj; @@ -943,14 +943,14 @@ static struct lst_list *create_chirp_list(u32 uChirps) if (chirp_list) { INIT_LIST_HEAD(&chirp_list->head); /* Make N chirps and place on queue. */ - for (i = 0; (i < uChirps) + for (i = 0; (i < chirps) && ((chnl_packet_obj = make_new_chirp()) != NULL); i++) { lst_put_tail(chirp_list, (struct list_head *)chnl_packet_obj); } /* If we couldn't allocate all chirps, free those allocated: */ - if (i != uChirps) { + if (i != chirps) { free_chirp_list(chirp_list); chirp_list = NULL; } diff --git a/drivers/staging/tidspbridge/core/tiomap3430.c b/drivers/staging/tidspbridge/core/tiomap3430.c index e759349d477b..0fdec3766d29 100644 --- a/drivers/staging/tidspbridge/core/tiomap3430.c +++ b/drivers/staging/tidspbridge/core/tiomap3430.c @@ -1507,7 +1507,7 @@ static int bridge_brd_mem_un_map(struct bridge_dev_context *dev_ctxt, "0x%x\n", paddr, ul_num_bytes); bad_page_dump(paddr, pg); } else { - SetPageDirty(pg); + set_page_dirty(pg); page_cache_release(pg); } paddr += HW_PAGE_SIZE4KB; @@ -1571,7 +1571,7 @@ skip_coarse_page: "0x%x\n", paddr, ul_num_bytes); bad_page_dump(paddr, pg); } else { - SetPageDirty(pg); + set_page_dirty(pg); page_cache_release(pg); } } diff --git a/drivers/staging/tidspbridge/hw/hw_mmu.c b/drivers/staging/tidspbridge/hw/hw_mmu.c index 668fb8a4bb9c..705cbe3d50db 100644 --- a/drivers/staging/tidspbridge/hw/hw_mmu.c +++ b/drivers/staging/tidspbridge/hw/hw_mmu.c @@ -259,7 +259,7 @@ hw_status hw_mmu_fault_addr_read(const void __iomem *base_address, u32 *addr) return status; } -hw_status hw_mmu_ttb_set(const void __iomem *base_address, u32 TTBPhysAddr) +hw_status hw_mmu_ttb_set(const void __iomem *base_address, u32 ttb_phys_addr) { hw_status status = RET_OK; u32 load_ttb; @@ -268,7 +268,7 @@ hw_status hw_mmu_ttb_set(const void __iomem *base_address, u32 TTBPhysAddr) CHECK_INPUT_PARAM(base_address, 0, RET_BAD_NULL_PARAM, RES_MMU_BASE + RES_INVALID_INPUT_PARAM); - load_ttb = TTBPhysAddr & ~0x7FUL; + load_ttb = ttb_phys_addr & ~0x7FUL; /* write values to register */ MMUMMU_TTB_WRITE_REGISTER32(base_address, load_ttb); diff --git a/drivers/staging/tidspbridge/hw/hw_mmu.h b/drivers/staging/tidspbridge/hw/hw_mmu.h index 25f1954ae4c8..554b52eff433 100644 --- a/drivers/staging/tidspbridge/hw/hw_mmu.h +++ b/drivers/staging/tidspbridge/hw/hw_mmu.h @@ -70,7 +70,7 @@ extern hw_status hw_mmu_fault_addr_read(const void __iomem *base_address, /* Set the TT base address */ extern hw_status hw_mmu_ttb_set(const void __iomem *base_address, - u32 TTBPhysAddr); + u32 ttb_phys_addr); extern hw_status hw_mmu_twl_enable(const void __iomem *base_address); diff --git a/drivers/staging/tidspbridge/include/dspbridge/dbdefs.h b/drivers/staging/tidspbridge/include/dspbridge/dbdefs.h index 9462a966ab84..fb168e60a1c9 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dbdefs.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dbdefs.h @@ -94,8 +94,8 @@ #define DSPWORDSIZE sizeof(DSPWORD) /* Success & Failure macros */ -#define DSP_SUCCEEDED(Status) likely((s32)(Status) >= 0) -#define DSP_FAILED(Status) unlikely((s32)(Status) < 0) +#define DSP_SUCCEEDED(status) likely((s32)(status) >= 0) +#define DSP_FAILED(status) unlikely((s32)(status) < 0) /* Power control enumerations */ #define PROC_PWRCONTROL 0x8070 diff --git a/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h b/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h index fa4c99f10688..d2b4fda34291 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dblldefs.h @@ -420,7 +420,7 @@ typedef int(*dbll_open_fxn) (struct dbll_tar_obj *target, char *file, */ typedef int(*dbll_read_sect_fxn) (struct dbll_library_obj *lib, char *name, char *content, - u32 uContentSize); + u32 cont_size); /* * ======== dbll_set_attrs ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/drv.h b/drivers/staging/tidspbridge/include/dspbridge/drv.h index efdc29cd2977..c180a7ceacf6 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/drv.h +++ b/drivers/staging/tidspbridge/include/dspbridge/drv.h @@ -450,7 +450,7 @@ extern void mem_ext_phys_pool_release(void); * Allocate physically contiguous, uncached memory * Parameters: * byte_size: Number of bytes to allocate. - * ulAlign: Alignment Mask. + * align_mask: Alignment Mask. * physical_address: Physical address of allocated memory. * Returns: * Pointer to a block of memory; @@ -463,7 +463,7 @@ extern void mem_ext_phys_pool_release(void); * location of memory. */ extern void *mem_alloc_phys_mem(IN u32 byte_size, - IN u32 ulAlign, OUT u32 *physical_address); + IN u32 align_mask, OUT u32 *physical_address); /* * ======== mem_free_phys_mem ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspapi-ioctl.h b/drivers/staging/tidspbridge/include/dspbridge/dspapi-ioctl.h index cc4e75b819ee..fa3ba6b92287 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dspapi-ioctl.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dspapi-ioctl.h @@ -24,7 +24,7 @@ #include #include -union Trapped_Args { +union trapped_args { /* MGR Module */ struct { diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspapi.h b/drivers/staging/tidspbridge/include/dspbridge/dspapi.h index 765a175a28be..c99c68738b0f 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dspapi.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dspapi.h @@ -50,7 +50,7 @@ * Ensures: */ extern int api_call_dev_ioctl(unsigned int cmd, - union Trapped_Args *args, + union trapped_args *args, u32 *result, void *pr_ctxt); /* @@ -98,70 +98,70 @@ extern int api_init_complete2(void); extern void api_exit(void); /* MGR wrapper functions */ -extern u32 mgrwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt); -extern u32 mgrwrap_enum_proc_info(union Trapped_Args *args, void *pr_ctxt); -extern u32 mgrwrap_register_object(union Trapped_Args *args, void *pr_ctxt); -extern u32 mgrwrap_unregister_object(union Trapped_Args *args, void *pr_ctxt); -extern u32 mgrwrap_wait_for_bridge_events(union Trapped_Args *args, +extern u32 mgrwrap_enum_node_info(union trapped_args *args, void *pr_ctxt); +extern u32 mgrwrap_enum_proc_info(union trapped_args *args, void *pr_ctxt); +extern u32 mgrwrap_register_object(union trapped_args *args, void *pr_ctxt); +extern u32 mgrwrap_unregister_object(union trapped_args *args, void *pr_ctxt); +extern u32 mgrwrap_wait_for_bridge_events(union trapped_args *args, void *pr_ctxt); -extern u32 mgrwrap_get_process_resources_info(union Trapped_Args *args, +extern u32 mgrwrap_get_process_resources_info(union trapped_args *args, void *pr_ctxt); /* CPRC (Processor) wrapper Functions */ -extern u32 procwrap_attach(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_ctrl(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_detach(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_enum_resources(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_get_state(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_get_trace(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_load(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_register_notify(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_start(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_reserve_memory(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_un_reserve_memory(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_map(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_un_map(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_flush_memory(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_stop(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_invalidate_memory(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_begin_dma(union Trapped_Args *args, void *pr_ctxt); -extern u32 procwrap_end_dma(union Trapped_Args *args, void *pr_ctxt); +extern u32 procwrap_attach(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_ctrl(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_detach(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_enum_node_info(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_enum_resources(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_get_state(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_get_trace(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_load(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_register_notify(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_start(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_reserve_memory(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_un_reserve_memory(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_map(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_un_map(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_flush_memory(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_stop(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_invalidate_memory(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_begin_dma(union trapped_args *args, void *pr_ctxt); +extern u32 procwrap_end_dma(union trapped_args *args, void *pr_ctxt); /* NODE wrapper functions */ -extern u32 nodewrap_allocate(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_alloc_msg_buf(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_change_priority(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_connect(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_create(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_delete(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_free_msg_buf(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_get_attr(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_get_message(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_pause(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_put_message(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_register_notify(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_run(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_terminate(union Trapped_Args *args, void *pr_ctxt); -extern u32 nodewrap_get_uuid_props(union Trapped_Args *args, void *pr_ctxt); +extern u32 nodewrap_allocate(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_alloc_msg_buf(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_change_priority(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_connect(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_create(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_delete(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_free_msg_buf(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_get_attr(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_get_message(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_pause(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_put_message(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_register_notify(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_run(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_terminate(union trapped_args *args, void *pr_ctxt); +extern u32 nodewrap_get_uuid_props(union trapped_args *args, void *pr_ctxt); /* STRM wrapper functions */ -extern u32 strmwrap_allocate_buffer(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_close(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_free_buffer(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_get_event_handle(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_get_info(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_idle(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_issue(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_open(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_reclaim(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_register_notify(union Trapped_Args *args, void *pr_ctxt); -extern u32 strmwrap_select(union Trapped_Args *args, void *pr_ctxt); +extern u32 strmwrap_allocate_buffer(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_close(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_free_buffer(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_get_event_handle(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_get_info(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_idle(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_issue(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_open(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_reclaim(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_register_notify(union trapped_args *args, void *pr_ctxt); +extern u32 strmwrap_select(union trapped_args *args, void *pr_ctxt); -extern u32 cmmwrap_calloc_buf(union Trapped_Args *args, void *pr_ctxt); -extern u32 cmmwrap_free_buf(union Trapped_Args *args, void *pr_ctxt); -extern u32 cmmwrap_get_handle(union Trapped_Args *args, void *pr_ctxt); -extern u32 cmmwrap_get_info(union Trapped_Args *args, void *pr_ctxt); +extern u32 cmmwrap_calloc_buf(union trapped_args *args, void *pr_ctxt); +extern u32 cmmwrap_free_buf(union trapped_args *args, void *pr_ctxt); +extern u32 cmmwrap_get_handle(union trapped_args *args, void *pr_ctxt); +extern u32 cmmwrap_get_info(union trapped_args *args, void *pr_ctxt); #endif /* DSPAPI_ */ diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspchnl.h b/drivers/staging/tidspbridge/include/dspbridge/dspchnl.h index cb7e18bfd747..c08cc00ab123 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dspchnl.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dspchnl.h @@ -34,7 +34,7 @@ extern int bridge_chnl_destroy(struct chnl_mgr *hchnl_mgr); extern int bridge_chnl_open(OUT struct chnl_object **chnl, struct chnl_mgr *hchnl_mgr, s8 chnl_mode, - u32 uChnlId, + u32 ch_id, CONST IN OPTIONAL struct chnl_attr *pattrs); @@ -57,7 +57,7 @@ extern int bridge_chnl_get_info(struct chnl_object *chnl_obj, OUT struct chnl_info *channel_info); extern int bridge_chnl_get_mgr_info(struct chnl_mgr *hchnl_mgr, - u32 uChnlID, OUT struct chnl_mgrinfo + u32 ch_id, OUT struct chnl_mgrinfo *mgr_info); extern int bridge_chnl_idle(struct chnl_object *chnl_obj, diff --git a/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h b/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h index ed6388e4cebf..1e4049be968e 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h +++ b/drivers/staging/tidspbridge/include/dspbridge/dspdefs.h @@ -373,7 +373,7 @@ typedef void (*fxn_deh_notify) (struct deh_mgr *hdeh_mgr, * CHNL_GetMgr(). * chnl_mode: One of {CHNL_MODETODSP, CHNL_MODEFROMDSP} specifies * direction of data transfer. - * uChnlId: If CHNL_PICKFREE is specified, the channel manager will + * ch_id: If CHNL_PICKFREE is specified, the channel manager will * select a free channel id (default); * otherwise this field specifies the id of the channel. * pattrs: Channel attributes. Attribute fields are as follows: @@ -411,7 +411,7 @@ typedef int(*fxn_chnl_open) (OUT struct chnl_object **chnl, struct chnl_mgr *hchnl_mgr, s8 chnl_mode, - u32 uChnlId, + u32 ch_id, CONST IN OPTIONAL struct chnl_attr * pattrs); @@ -569,7 +569,7 @@ typedef int(*fxn_chnl_getinfo) (struct chnl_object *chnl_obj, * Retrieve information related to the channel manager. * Parameters: * hchnl_mgr: Handle to a valid channel manager, or NULL. - * uChnlID: Channel ID. + * ch_id: Channel ID. * mgr_info: Location to store channel manager info. * Returns: * 0: Success; @@ -582,7 +582,7 @@ typedef int(*fxn_chnl_getinfo) (struct chnl_object *chnl_obj, */ typedef int(*fxn_chnl_getmgrinfo) (struct chnl_mgr * hchnl_mgr, - u32 uChnlID, + u32 ch_id, OUT struct chnl_mgrinfo *mgr_info); /* diff --git a/drivers/staging/tidspbridge/include/dspbridge/io_sm.h b/drivers/staging/tidspbridge/include/dspbridge/io_sm.h index a7fded7a0ee4..538fbcd9099d 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/io_sm.h +++ b/drivers/staging/tidspbridge/include/dspbridge/io_sm.h @@ -141,20 +141,20 @@ extern void iosm_schedule(struct io_mgr *hio_mgr); * Initialize DSP DMA channel descriptor. * Parameters: * hio_mgr: Handle to a I/O manager. - * uDDMAChnlId: DDMA channel identifier. + * ddma_chnl_id: DDMA channel identifier. * uNumDesc: Number of buffer descriptors(equals # of IOReqs & * Chirps) * dsp: Dsp address; * Returns: * Requires: - * uDDMAChnlId < DDMA_MAXDDMACHNLS + * ddma_chnl_id < DDMA_MAXDDMACHNLS * uNumDesc > 0 * pVa != NULL * pDspPa != NULL * * Ensures: */ -extern void io_ddma_init_chnl_desc(struct io_mgr *hio_mgr, u32 uDDMAChnlId, +extern void io_ddma_init_chnl_desc(struct io_mgr *hio_mgr, u32 ddma_chnl_id, u32 uNumDesc, void *dsp); /* @@ -163,13 +163,13 @@ extern void io_ddma_init_chnl_desc(struct io_mgr *hio_mgr, u32 uDDMAChnlId, * Clear DSP DMA channel descriptor. * Parameters: * hio_mgr: Handle to a I/O manager. - * uDDMAChnlId: DDMA channel identifier. + * ddma_chnl_id: DDMA channel identifier. * Returns: * Requires: - * uDDMAChnlId < DDMA_MAXDDMACHNLS + * ddma_chnl_id < DDMA_MAXDDMACHNLS * Ensures: */ -extern void io_ddma_clear_chnl_desc(struct io_mgr *hio_mgr, u32 uDDMAChnlId); +extern void io_ddma_clear_chnl_desc(struct io_mgr *hio_mgr, u32 ddma_chnl_id); /* * ======== io_ddma_request_chnl ======== @@ -205,7 +205,7 @@ extern void io_ddma_request_chnl(struct io_mgr *hio_mgr, * uZId: zero-copy channel identifier. * Returns: * Requires: - * uDDMAChnlId < DDMA_MAXZCPYCHNLS + * ddma_chnl_id < DDMA_MAXZCPYCHNLS * hio_mgr != Null * Ensures: */ @@ -217,14 +217,14 @@ extern void io_ddzc_init_chnl_desc(struct io_mgr *hio_mgr, u32 uZId); * Clear DSP ZC channel descriptor. * Parameters: * hio_mgr: Handle to a I/O manager. - * uChnlId: ZC channel identifier. + * ch_id: ZC channel identifier. * Returns: * Requires: * hio_mgr is valid - * uChnlId < DDMA_MAXZCPYCHNLS + * ch_id < DDMA_MAXZCPYCHNLS * Ensures: */ -extern void io_ddzc_clear_chnl_desc(struct io_mgr *hio_mgr, u32 uChnlId); +extern void io_ddzc_clear_chnl_desc(struct io_mgr *hio_mgr, u32 ch_id); /* * ======== io_ddzc_request_chnl ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/proc.h b/drivers/staging/tidspbridge/include/dspbridge/proc.h index 5583bd51b45f..e7a95103785d 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/proc.h +++ b/drivers/staging/tidspbridge/include/dspbridge/proc.h @@ -365,18 +365,18 @@ extern int proc_register_notify(void *hprocessor, * Notify the Processor Clients * Parameters: * proc : The processor handle. - * uEvents : Event to be notified about. + * events : Event to be notified about. * Returns: * 0 : Success. * -EFAULT : Invalid processor handle. * -EPERM : Failure to Set or Reset the Event * Requires: - * uEvents is Supported or Valid type of Event + * events is Supported or Valid type of Event * proc is a valid handle * PROC Initialized. * Ensures: */ -extern int proc_notify_clients(void *proc, u32 uEvents); +extern int proc_notify_clients(void *proc, u32 events); /* * ======== proc_notify_all_clients ======== @@ -384,13 +384,13 @@ extern int proc_notify_clients(void *proc, u32 uEvents); * Notify the Processor Clients * Parameters: * proc : The processor handle. - * uEvents : Event to be notified about. + * events : Event to be notified about. * Returns: * 0 : Success. * -EFAULT : Invalid processor handle. * -EPERM : Failure to Set or Reset the Event * Requires: - * uEvents is Supported or Valid type of Event + * events is Supported or Valid type of Event * proc is a valid handle * PROC Initialized. * Ensures: @@ -398,7 +398,7 @@ extern int proc_notify_clients(void *proc, u32 uEvents); * NODE And STRM would use this function to notify their clients * about the state changes in NODE or STRM. */ -extern int proc_notify_all_clients(void *proc, u32 uEvents); +extern int proc_notify_all_clients(void *proc, u32 events); /* * ======== proc_start ======== diff --git a/drivers/staging/tidspbridge/include/dspbridge/pwr.h b/drivers/staging/tidspbridge/include/dspbridge/pwr.h index 63ccf8ca8f42..9f32c896a840 100644 --- a/drivers/staging/tidspbridge/include/dspbridge/pwr.h +++ b/drivers/staging/tidspbridge/include/dspbridge/pwr.h @@ -25,7 +25,7 @@ * Signal the DSP to go to sleep. * * Parameters: - * sleepCode: New sleep state for DSP. (Initially, valid codes + * sleep_code: New sleep state for DSP. (Initially, valid codes * are PWR_DEEPSLEEP or PWR_EMERGENCYDEEPSLEEP; both of * these codes will simply put the DSP in deep sleep.) * @@ -39,13 +39,13 @@ * Returns: * 0: Success. * 0: Success, but the DSP was already asleep. - * -EINVAL: The specified sleepCode is not supported. + * -EINVAL: The specified sleep_code is not supported. * -ETIME: A timeout occured while waiting for DSP sleep * confirmation. * -EPERM: General failure, unable to send sleep command to * the DSP. */ -extern int pwr_sleep_dsp(IN CONST u32 sleepCode, IN CONST u32 timeout); +extern int pwr_sleep_dsp(IN CONST u32 sleep_code, IN CONST u32 timeout); /* * ======== pwr_wake_dsp ======== diff --git a/drivers/staging/tidspbridge/pmgr/dspapi.c b/drivers/staging/tidspbridge/pmgr/dspapi.c index 7597210845ff..7ff2bd07d6ec 100644 --- a/drivers/staging/tidspbridge/pmgr/dspapi.c +++ b/drivers/staging/tidspbridge/pmgr/dspapi.c @@ -69,7 +69,7 @@ /* Device IOCtl function pointer */ struct api_cmd { - u32(*fxn) (union Trapped_Args *args, void *pr_ctxt); + u32(*fxn) (union trapped_args *args, void *pr_ctxt); u32 dw_index; }; @@ -208,10 +208,10 @@ static inline void _cp_to_usr(void __user *to, const void *from, * Purpose: * Call the (wrapper) function for the corresponding API IOCTL. */ -inline int api_call_dev_ioctl(u32 cmd, union Trapped_Args *args, +inline int api_call_dev_ioctl(u32 cmd, union trapped_args *args, u32 *result, void *pr_ctxt) { - u32(*ioctl_cmd) (union Trapped_Args *args, void *pr_ctxt) = NULL; + u32(*ioctl_cmd) (union trapped_args *args, void *pr_ctxt) = NULL; int i; if (_IOC_TYPE(cmd) != DB) { @@ -411,7 +411,7 @@ int api_init_complete2(void) /* * ======== mgrwrap_enum_node_info ======== */ -u32 mgrwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt) +u32 mgrwrap_enum_node_info(union trapped_args *args, void *pr_ctxt) { u8 *pndb_props; u32 num_nodes; @@ -443,7 +443,7 @@ u32 mgrwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt) /* * ======== mgrwrap_enum_proc_info ======== */ -u32 mgrwrap_enum_proc_info(union Trapped_Args *args, void *pr_ctxt) +u32 mgrwrap_enum_proc_info(union trapped_args *args, void *pr_ctxt) { u8 *processor_info; u8 num_procs; @@ -477,7 +477,7 @@ u32 mgrwrap_enum_proc_info(union Trapped_Args *args, void *pr_ctxt) /* * ======== mgrwrap_register_object ======== */ -u32 mgrwrap_register_object(union Trapped_Args *args, void *pr_ctxt) +u32 mgrwrap_register_object(union trapped_args *args, void *pr_ctxt) { u32 ret; struct dsp_uuid uuid_obj; @@ -517,7 +517,7 @@ func_end: /* * ======== mgrwrap_unregister_object ======== */ -u32 mgrwrap_unregister_object(union Trapped_Args *args, void *pr_ctxt) +u32 mgrwrap_unregister_object(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_uuid uuid_obj; @@ -537,7 +537,7 @@ func_end: /* * ======== mgrwrap_wait_for_bridge_events ======== */ -u32 mgrwrap_wait_for_bridge_events(union Trapped_Args *args, void *pr_ctxt) +u32 mgrwrap_wait_for_bridge_events(union trapped_args *args, void *pr_ctxt) { int status = 0, real_status = 0; struct dsp_notification *anotifications[MAX_EVENTS]; @@ -572,7 +572,7 @@ u32 mgrwrap_wait_for_bridge_events(union Trapped_Args *args, void *pr_ctxt) /* * ======== MGRWRAP_GetProcessResourceInfo ======== */ -u32 __deprecated mgrwrap_get_process_resources_info(union Trapped_Args * args, +u32 __deprecated mgrwrap_get_process_resources_info(union trapped_args * args, void *pr_ctxt) { pr_err("%s: deprecated dspbridge ioctl\n", __func__); @@ -582,7 +582,7 @@ u32 __deprecated mgrwrap_get_process_resources_info(union Trapped_Args * args, /* * ======== procwrap_attach ======== */ -u32 procwrap_attach(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_attach(union trapped_args *args, void *pr_ctxt) { void *processor; int status = 0; @@ -608,7 +608,7 @@ func_end: /* * ======== procwrap_ctrl ======== */ -u32 procwrap_ctrl(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_ctrl(union trapped_args *args, void *pr_ctxt) { u32 cb_data_size, __user * psize = (u32 __user *) args->args_proc_ctrl.pargs; @@ -645,7 +645,7 @@ func_end: /* * ======== procwrap_detach ======== */ -u32 __deprecated procwrap_detach(union Trapped_Args * args, void *pr_ctxt) +u32 __deprecated procwrap_detach(union trapped_args * args, void *pr_ctxt) { /* proc_detach called at bridge_release only */ pr_err("%s: deprecated dspbridge ioctl\n", __func__); @@ -655,7 +655,7 @@ u32 __deprecated procwrap_detach(union Trapped_Args * args, void *pr_ctxt) /* * ======== procwrap_enum_node_info ======== */ -u32 procwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_enum_node_info(union trapped_args *args, void *pr_ctxt) { int status; void *node_tab[MAX_NODES]; @@ -678,7 +678,7 @@ u32 procwrap_enum_node_info(union Trapped_Args *args, void *pr_ctxt) return status; } -u32 procwrap_end_dma(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_end_dma(union trapped_args *args, void *pr_ctxt) { int status; @@ -692,7 +692,7 @@ u32 procwrap_end_dma(union Trapped_Args *args, void *pr_ctxt) return status; } -u32 procwrap_begin_dma(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_begin_dma(union trapped_args *args, void *pr_ctxt) { int status; @@ -709,7 +709,7 @@ u32 procwrap_begin_dma(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_flush_memory ======== */ -u32 procwrap_flush_memory(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_flush_memory(union trapped_args *args, void *pr_ctxt) { int status; @@ -727,7 +727,7 @@ u32 procwrap_flush_memory(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_invalidate_memory ======== */ -u32 procwrap_invalidate_memory(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_invalidate_memory(union trapped_args *args, void *pr_ctxt) { int status; @@ -741,7 +741,7 @@ u32 procwrap_invalidate_memory(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_enum_resources ======== */ -u32 procwrap_enum_resources(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_enum_resources(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_resourceinfo resource_info; @@ -767,7 +767,7 @@ u32 procwrap_enum_resources(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_get_state ======== */ -u32 procwrap_get_state(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_get_state(union trapped_args *args, void *pr_ctxt) { int status; struct dsp_processorstate proc_state; @@ -788,7 +788,7 @@ u32 procwrap_get_state(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_get_trace ======== */ -u32 procwrap_get_trace(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_get_trace(union trapped_args *args, void *pr_ctxt) { int status; u8 *pbuf; @@ -814,7 +814,7 @@ u32 procwrap_get_trace(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_load ======== */ -u32 procwrap_load(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_load(union trapped_args *args, void *pr_ctxt) { s32 i, len; int status = 0; @@ -930,7 +930,7 @@ func_cont: /* * ======== procwrap_map ======== */ -u32 procwrap_map(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_map(union trapped_args *args, void *pr_ctxt) { int status; void *map_addr; @@ -957,7 +957,7 @@ u32 procwrap_map(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_register_notify ======== */ -u32 procwrap_register_notify(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_register_notify(union trapped_args *args, void *pr_ctxt) { int status; struct dsp_notification notification; @@ -979,7 +979,7 @@ u32 procwrap_register_notify(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_reserve_memory ======== */ -u32 procwrap_reserve_memory(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_reserve_memory(union trapped_args *args, void *pr_ctxt) { int status; void *prsv_addr; @@ -1004,7 +1004,7 @@ u32 procwrap_reserve_memory(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_start ======== */ -u32 procwrap_start(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_start(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1015,7 +1015,7 @@ u32 procwrap_start(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_un_map ======== */ -u32 procwrap_un_map(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_un_map(union trapped_args *args, void *pr_ctxt) { int status; @@ -1027,7 +1027,7 @@ u32 procwrap_un_map(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_un_reserve_memory ======== */ -u32 procwrap_un_reserve_memory(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_un_reserve_memory(union trapped_args *args, void *pr_ctxt) { int status; @@ -1040,7 +1040,7 @@ u32 procwrap_un_reserve_memory(union Trapped_Args *args, void *pr_ctxt) /* * ======== procwrap_stop ======== */ -u32 procwrap_stop(union Trapped_Args *args, void *pr_ctxt) +u32 procwrap_stop(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1052,7 +1052,7 @@ u32 procwrap_stop(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_allocate ======== */ -u32 nodewrap_allocate(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_allocate(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_uuid node_uuid; @@ -1111,7 +1111,7 @@ func_cont: /* * ======== nodewrap_alloc_msg_buf ======== */ -u32 nodewrap_alloc_msg_buf(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_alloc_msg_buf(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_bufferattr *pattr = NULL; @@ -1141,7 +1141,7 @@ u32 nodewrap_alloc_msg_buf(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_change_priority ======== */ -u32 nodewrap_change_priority(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_change_priority(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1154,7 +1154,7 @@ u32 nodewrap_change_priority(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_connect ======== */ -u32 nodewrap_connect(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_connect(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_strmattr attrs; @@ -1204,7 +1204,7 @@ func_cont: /* * ======== nodewrap_create ======== */ -u32 nodewrap_create(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_create(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1216,7 +1216,7 @@ u32 nodewrap_create(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_delete ======== */ -u32 nodewrap_delete(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_delete(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1228,7 +1228,7 @@ u32 nodewrap_delete(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_free_msg_buf ======== */ -u32 nodewrap_free_msg_buf(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_free_msg_buf(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_bufferattr *pattr = NULL; @@ -1255,7 +1255,7 @@ u32 nodewrap_free_msg_buf(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_get_attr ======== */ -u32 nodewrap_get_attr(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_get_attr(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_nodeattr attr; @@ -1270,7 +1270,7 @@ u32 nodewrap_get_attr(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_get_message ======== */ -u32 nodewrap_get_message(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_get_message(union trapped_args *args, void *pr_ctxt) { int status; struct dsp_msg msg; @@ -1286,7 +1286,7 @@ u32 nodewrap_get_message(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_pause ======== */ -u32 nodewrap_pause(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_pause(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1298,7 +1298,7 @@ u32 nodewrap_pause(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_put_message ======== */ -u32 nodewrap_put_message(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_put_message(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_msg msg; @@ -1317,7 +1317,7 @@ u32 nodewrap_put_message(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_register_notify ======== */ -u32 nodewrap_register_notify(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_register_notify(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_notification notification; @@ -1343,7 +1343,7 @@ u32 nodewrap_register_notify(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_run ======== */ -u32 nodewrap_run(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_run(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1355,7 +1355,7 @@ u32 nodewrap_run(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_terminate ======== */ -u32 nodewrap_terminate(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_terminate(union trapped_args *args, void *pr_ctxt) { int status; int tempstatus; @@ -1370,7 +1370,7 @@ u32 nodewrap_terminate(union Trapped_Args *args, void *pr_ctxt) /* * ======== nodewrap_get_uuid_props ======== */ -u32 nodewrap_get_uuid_props(union Trapped_Args *args, void *pr_ctxt) +u32 nodewrap_get_uuid_props(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_uuid node_uuid; @@ -1397,7 +1397,7 @@ func_cont: /* * ======== strmwrap_allocate_buffer ======== */ -u32 strmwrap_allocate_buffer(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_allocate_buffer(union trapped_args *args, void *pr_ctxt) { int status; u8 **ap_buffer = NULL; @@ -1428,7 +1428,7 @@ u32 strmwrap_allocate_buffer(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_close ======== */ -u32 strmwrap_close(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_close(union trapped_args *args, void *pr_ctxt) { return strm_close(args->args_strm_close.hstream, pr_ctxt); } @@ -1436,7 +1436,7 @@ u32 strmwrap_close(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_free_buffer ======== */ -u32 strmwrap_free_buffer(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_free_buffer(union trapped_args *args, void *pr_ctxt) { int status = 0; u8 **ap_buffer = NULL; @@ -1464,7 +1464,7 @@ u32 strmwrap_free_buffer(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_get_event_handle ======== */ -u32 __deprecated strmwrap_get_event_handle(union Trapped_Args * args, +u32 __deprecated strmwrap_get_event_handle(union trapped_args * args, void *pr_ctxt) { pr_err("%s: deprecated dspbridge ioctl\n", __func__); @@ -1474,7 +1474,7 @@ u32 __deprecated strmwrap_get_event_handle(union Trapped_Args * args, /* * ======== strmwrap_get_info ======== */ -u32 strmwrap_get_info(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_get_info(union trapped_args *args, void *pr_ctxt) { int status = 0; struct stream_info strm_info; @@ -1501,7 +1501,7 @@ u32 strmwrap_get_info(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_idle ======== */ -u32 strmwrap_idle(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_idle(union trapped_args *args, void *pr_ctxt) { u32 ret; @@ -1514,7 +1514,7 @@ u32 strmwrap_idle(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_issue ======== */ -u32 strmwrap_issue(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_issue(union trapped_args *args, void *pr_ctxt) { int status = 0; @@ -1536,7 +1536,7 @@ u32 strmwrap_issue(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_open ======== */ -u32 strmwrap_open(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_open(union trapped_args *args, void *pr_ctxt) { int status = 0; struct strm_attr attr; @@ -1565,7 +1565,7 @@ u32 strmwrap_open(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_reclaim ======== */ -u32 strmwrap_reclaim(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_reclaim(union trapped_args *args, void *pr_ctxt) { int status = 0; u8 *buf_ptr; @@ -1590,7 +1590,7 @@ u32 strmwrap_reclaim(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_register_notify ======== */ -u32 strmwrap_register_notify(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_register_notify(union trapped_args *args, void *pr_ctxt) { int status = 0; struct dsp_notification notification; @@ -1612,7 +1612,7 @@ u32 strmwrap_register_notify(union Trapped_Args *args, void *pr_ctxt) /* * ======== strmwrap_select ======== */ -u32 strmwrap_select(union Trapped_Args *args, void *pr_ctxt) +u32 strmwrap_select(union trapped_args *args, void *pr_ctxt) { u32 mask; struct strm_object *strm_tab[MAX_STREAMS]; @@ -1636,7 +1636,7 @@ u32 strmwrap_select(union Trapped_Args *args, void *pr_ctxt) /* * ======== cmmwrap_calloc_buf ======== */ -u32 __deprecated cmmwrap_calloc_buf(union Trapped_Args * args, void *pr_ctxt) +u32 __deprecated cmmwrap_calloc_buf(union trapped_args * args, void *pr_ctxt) { /* This operation is done in kernel */ pr_err("%s: deprecated dspbridge ioctl\n", __func__); @@ -1646,7 +1646,7 @@ u32 __deprecated cmmwrap_calloc_buf(union Trapped_Args * args, void *pr_ctxt) /* * ======== cmmwrap_free_buf ======== */ -u32 __deprecated cmmwrap_free_buf(union Trapped_Args * args, void *pr_ctxt) +u32 __deprecated cmmwrap_free_buf(union trapped_args * args, void *pr_ctxt) { /* This operation is done in kernel */ pr_err("%s: deprecated dspbridge ioctl\n", __func__); @@ -1656,7 +1656,7 @@ u32 __deprecated cmmwrap_free_buf(union Trapped_Args * args, void *pr_ctxt) /* * ======== cmmwrap_get_handle ======== */ -u32 cmmwrap_get_handle(union Trapped_Args *args, void *pr_ctxt) +u32 cmmwrap_get_handle(union trapped_args *args, void *pr_ctxt) { int status = 0; struct cmm_object *hcmm_mgr; @@ -1671,7 +1671,7 @@ u32 cmmwrap_get_handle(union Trapped_Args *args, void *pr_ctxt) /* * ======== cmmwrap_get_info ======== */ -u32 cmmwrap_get_info(union Trapped_Args *args, void *pr_ctxt) +u32 cmmwrap_get_info(union trapped_args *args, void *pr_ctxt) { int status = 0; struct cmm_info cmm_info_obj; diff --git a/drivers/staging/tidspbridge/rmgr/drv.c b/drivers/staging/tidspbridge/rmgr/drv.c index dc0c6292714b..03a231705a4e 100644 --- a/drivers/staging/tidspbridge/rmgr/drv.c +++ b/drivers/staging/tidspbridge/rmgr/drv.c @@ -1012,14 +1012,15 @@ static void *mem_ext_phys_mem_alloc(u32 bytes, u32 align, OUT u32 * phys_addr) * Purpose: * Allocate physically contiguous, uncached memory */ -void *mem_alloc_phys_mem(u32 byte_size, u32 ulAlign, OUT u32 * physical_address) +void *mem_alloc_phys_mem(u32 byte_size, u32 align_mask, + OUT u32 *physical_address) { void *va_mem = NULL; dma_addr_t pa_mem; if (byte_size > 0) { if (ext_phys_mem_pool_enabled) { - va_mem = mem_ext_phys_mem_alloc(byte_size, ulAlign, + va_mem = mem_ext_phys_mem_alloc(byte_size, align_mask, (u32 *) &pa_mem); } else va_mem = dma_alloc_coherent(NULL, byte_size, &pa_mem, diff --git a/drivers/staging/tidspbridge/rmgr/drv_interface.c b/drivers/staging/tidspbridge/rmgr/drv_interface.c index b0fd38e7ee51..dae16f83ffa7 100644 --- a/drivers/staging/tidspbridge/rmgr/drv_interface.c +++ b/drivers/staging/tidspbridge/rmgr/drv_interface.c @@ -561,7 +561,7 @@ static long bridge_ioctl(struct file *filp, unsigned int code, { int status; u32 retval = 0; - union Trapped_Args buf_in; + union trapped_args buf_in; DBC_REQUIRE(filp != NULL); #ifdef CONFIG_TIDSPBRIDGE_RECOVERY @@ -581,8 +581,8 @@ static long bridge_ioctl(struct file *filp, unsigned int code, goto err; } - status = copy_from_user(&buf_in, (union Trapped_Args *)args, - sizeof(union Trapped_Args)); + status = copy_from_user(&buf_in, (union trapped_args *)args, + sizeof(union trapped_args)); if (!status) { status = api_call_dev_ioctl(code, &buf_in, &retval, diff --git a/drivers/staging/tidspbridge/rmgr/nldr.c b/drivers/staging/tidspbridge/rmgr/nldr.c index 198b69856635..46fc76535e0a 100644 --- a/drivers/staging/tidspbridge/rmgr/nldr.c +++ b/drivers/staging/tidspbridge/rmgr/nldr.c @@ -296,7 +296,7 @@ static s32 fake_ovly_write(void *handle, u32 dsp_address, void *buf, u32 bytes, static void free_sects(struct nldr_object *nldr_obj, struct ovly_sect *phase_sects, u16 alloc_num); static bool get_symbol_value(void *handle, void *parg, void *rmm_handle, - char *symName, struct dbll_sym_val **sym); + char *sym_name, struct dbll_sym_val **sym); static int load_lib(struct nldr_nodeobject *nldr_node_obj, struct lib_node *root, struct dsp_uuid uuid, bool root_prstnt, @@ -306,7 +306,7 @@ static int load_ovly(struct nldr_nodeobject *nldr_node_obj, enum nldr_phase phase); static int remote_alloc(void **ref, u16 mem_sect_type, u32 size, u32 align, u32 *dsp_address, - OPTIONAL s32 segmentId, + OPTIONAL s32 segmnt_id, OPTIONAL s32 req, bool reserve); static int remote_free(void **ref, u16 space, u32 dsp_address, u32 size, bool reserve); @@ -1625,7 +1625,7 @@ func_end: */ static int remote_alloc(void **ref, u16 space, u32 size, u32 align, u32 *dsp_address, - OPTIONAL s32 segmentId, OPTIONAL s32 req, + OPTIONAL s32 segmnt_id, OPTIONAL s32 req, bool reserve) { struct nldr_nodeobject *hnode = (struct nldr_nodeobject *)ref; @@ -1651,9 +1651,9 @@ static int remote_alloc(void **ref, u16 space, u32 size, /* Modify memory 'align' to account for DSP cache line size */ align = find_lcm(GEM_CACHE_LINE_SIZE, align); dev_dbg(bridge, "%s: memory align to 0x%x\n", __func__, align); - if (segmentId != -1) { - rmm_addr_obj->segid = segmentId; - segid = segmentId; + if (segmnt_id != -1) { + rmm_addr_obj->segid = segmnt_id; + segid = segmnt_id; mem_load_req = req; } else { switch (hnode->phase) { diff --git a/drivers/staging/tidspbridge/rmgr/proc.c b/drivers/staging/tidspbridge/rmgr/proc.c index eb8164527d87..aa48fa8502bb 100644 --- a/drivers/staging/tidspbridge/rmgr/proc.c +++ b/drivers/staging/tidspbridge/rmgr/proc.c @@ -111,7 +111,7 @@ DEFINE_MUTEX(proc_lock); /* For critical sections */ static int proc_monitor(struct proc_object *hprocessor); static s32 get_envp_count(char **envp); static char **prepend_envp(char **new_envp, char **envp, s32 envp_elems, - s32 cnew_envp, char *szVar); + s32 cnew_envp, char *sz_var); /* remember mapping information */ static struct dmm_map_object *add_mapping_info(struct process_context *pr_ctxt, @@ -1848,14 +1848,14 @@ static s32 get_envp_count(char **envp) * copy in the existing var=value pairs in the old envp array. */ static char **prepend_envp(char **new_envp, char **envp, s32 envp_elems, - s32 cnew_envp, char *szVar) + s32 cnew_envp, char *sz_var) { char **pp_envp = new_envp; DBC_REQUIRE(new_envp); /* Prepend new environ var=value string */ - *new_envp++ = szVar; + *new_envp++ = sz_var; /* Copy user's environment into our own. */ while (envp_elems--) @@ -1873,20 +1873,20 @@ static char **prepend_envp(char **new_envp, char **envp, s32 envp_elems, * Purpose: * Notify the processor the events. */ -int proc_notify_clients(void *proc, u32 uEvents) +int proc_notify_clients(void *proc, u32 events) { int status = 0; struct proc_object *p_proc_object = (struct proc_object *)proc; DBC_REQUIRE(p_proc_object); - DBC_REQUIRE(IS_VALID_PROC_EVENT(uEvents)); + DBC_REQUIRE(IS_VALID_PROC_EVENT(events)); DBC_REQUIRE(refs > 0); if (!p_proc_object) { status = -EFAULT; goto func_end; } - ntfy_notify(p_proc_object->ntfy_obj, uEvents); + ntfy_notify(p_proc_object->ntfy_obj, events); func_end: return status; } @@ -1897,12 +1897,12 @@ func_end: * Notify the processor the events. This includes notifying all clients * attached to a particulat DSP. */ -int proc_notify_all_clients(void *proc, u32 uEvents) +int proc_notify_all_clients(void *proc, u32 events) { int status = 0; struct proc_object *p_proc_object = (struct proc_object *)proc; - DBC_REQUIRE(IS_VALID_PROC_EVENT(uEvents)); + DBC_REQUIRE(IS_VALID_PROC_EVENT(events)); DBC_REQUIRE(refs > 0); if (!p_proc_object) { @@ -1910,7 +1910,7 @@ int proc_notify_all_clients(void *proc, u32 uEvents) goto func_end; } - dev_notify_clients(p_proc_object->hdev_obj, uEvents); + dev_notify_clients(p_proc_object->hdev_obj, events); func_end: return status; diff --git a/drivers/staging/tidspbridge/rmgr/pwr.c b/drivers/staging/tidspbridge/rmgr/pwr.c index ec6d18171f95..2d81743a52c0 100644 --- a/drivers/staging/tidspbridge/rmgr/pwr.c +++ b/drivers/staging/tidspbridge/rmgr/pwr.c @@ -36,7 +36,7 @@ * ======== pwr_sleep_dsp ======== * Send command to DSP to enter sleep state. */ -int pwr_sleep_dsp(IN CONST u32 sleepCode, IN CONST u32 timeout) +int pwr_sleep_dsp(IN CONST u32 sleep_code, IN CONST u32 timeout) { struct bridge_drv_interface *intf_fxns; struct bridge_dev_context *dw_context; @@ -59,9 +59,9 @@ int pwr_sleep_dsp(IN CONST u32 sleepCode, IN CONST u32 timeout) &intf_fxns))) { continue; } - if (sleepCode == PWR_DEEPSLEEP) + if (sleep_code == PWR_DEEPSLEEP) ioctlcode = BRDIOCTL_DEEPSLEEP; - else if (sleepCode == PWR_EMERGENCYDEEPSLEEP) + else if (sleep_code == PWR_EMERGENCYDEEPSLEEP) ioctlcode = BRDIOCTL_EMERGENCYSLEEP; else status = -EINVAL; -- cgit v1.2.3-55-g7522