Commit aa09b091 authored by Rene Sapiens's avatar Rene Sapiens Committed by Greg Kroah-Hartman
Browse files

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:
========================================
pArb to arb
pbAlreadyAttached to already_attached
pBaseAddr to base_addr
pbHostBuf to host_buff
pBufVa to buf_va
pChnlInfo to channel_info
pConfig to config_param
pContent to content
pContext to context
pdcdProps to dcd_prop
pDepLibUuids to dep_lib_uuids
pDevNodeString to dev_node_strg
pDispAttrs to disp_attrs
pDsp to dsp
pdwAutoStart to auto_start
pdwChnl to chnl
========================================

Signed-off-by: default avatarRene Sapiens <rene.sapiens@ti.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 95870a88
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -80,7 +80,7 @@ static void free_chirp_list(struct lst_list *pList);
static struct chnl_irp *make_new_chirp(void);

static int search_free_channel(struct chnl_mgr *chnl_mgr_obj,
				      OUT u32 *pdwChnl);
				      OUT u32 *chnl);

/*
 *  ======== bridge_chnl_add_io_req ========
@@ -996,7 +996,7 @@ static struct chnl_irp *make_new_chirp(void)
 *      Search for a free channel slot in the array of channel pointers.
 */
static int search_free_channel(struct chnl_mgr *chnl_mgr_obj,
				      OUT u32 *pdwChnl)
				      OUT u32 *chnl)
{
	int status = -ENOSR;
	u32 i;
@@ -1006,7 +1006,7 @@ static int search_free_channel(struct chnl_mgr *chnl_mgr_obj,
	for (i = 0; i < chnl_mgr_obj->max_channels; i++) {
		if (chnl_mgr_obj->ap_channel[i] == NULL) {
			status = 0;
			*pdwChnl = i;
			*chnl = i;
			break;
		}
	}
+18 −18
Original line number Diff line number Diff line
@@ -76,7 +76,7 @@
/* Forward Declarations: */
static int bridge_brd_monitor(struct bridge_dev_context *dev_context);
static int bridge_brd_read(struct bridge_dev_context *dev_context,
				  OUT u8 *pbHostBuf,
				  OUT u8 *host_buff,
				  u32 dsp_addr, u32 ul_num_bytes,
				  u32 ulMemType);
static int bridge_brd_start(struct bridge_dev_context *dev_context,
@@ -85,7 +85,7 @@ static int bridge_brd_status(struct bridge_dev_context *dev_context,
				    int *pdwState);
static int bridge_brd_stop(struct bridge_dev_context *dev_context);
static int bridge_brd_write(struct bridge_dev_context *dev_context,
				   IN u8 *pbHostBuf,
				   IN u8 *host_buff,
				   u32 dsp_addr, u32 ul_num_bytes,
				   u32 ulMemType);
static int bridge_brd_set_state(struct bridge_dev_context *dev_ctxt,
@@ -94,7 +94,7 @@ static int bridge_brd_mem_copy(struct bridge_dev_context *dev_ctxt,
				   u32 ulDspDestAddr, u32 ulDspSrcAddr,
				   u32 ul_num_bytes, u32 ulMemType);
static int bridge_brd_mem_write(struct bridge_dev_context *dev_context,
				    IN u8 *pbHostBuf, u32 dsp_addr,
				    IN u8 *host_buff, u32 dsp_addr,
				    u32 ul_num_bytes, u32 ulMemType);
static int bridge_brd_mem_map(struct bridge_dev_context *dev_ctxt,
				  u32 ul_mpu_addr, u32 ulVirtAddr,
@@ -105,7 +105,7 @@ static int bridge_brd_mem_un_map(struct bridge_dev_context *dev_ctxt,
static int bridge_dev_create(OUT struct bridge_dev_context
					**ppDevContext,
					struct dev_object *hdev_obj,
					IN struct cfg_hostres *pConfig);
					IN struct cfg_hostres *config_param);
static int bridge_dev_ctrl(struct bridge_dev_context *dev_context,
				  u32 dw_cmd, IN OUT void *pargs);
static int bridge_dev_destroy(struct bridge_dev_context *dev_context);
@@ -304,7 +304,7 @@ static int bridge_brd_monitor(struct bridge_dev_context *dev_ctxt)
 *      Reads buffers for DSP memory.
 */
static int bridge_brd_read(struct bridge_dev_context *dev_ctxt,
				  OUT u8 *pbHostBuf, u32 dsp_addr,
				  OUT u8 *host_buff, u32 dsp_addr,
				  u32 ul_num_bytes, u32 ulMemType)
{
	int status = 0;
@@ -321,12 +321,12 @@ static int bridge_brd_read(struct bridge_dev_context *dev_ctxt,
	    dev_context->dw_internal_size) {
		offset = dsp_addr - dev_context->dw_dsp_start_add;
	} else {
		status = read_ext_dsp_data(dev_context, pbHostBuf, dsp_addr,
		status = read_ext_dsp_data(dev_context, host_buff, dsp_addr,
					   ul_num_bytes, ulMemType);
		return status;
	}
	/* copy the data from  DSP memory, */
	memcpy(pbHostBuf, (void *)(dsp_base_addr + offset), ul_num_bytes);
	memcpy(host_buff, (void *)(dsp_base_addr + offset), ul_num_bytes);
	return status;
}

@@ -765,7 +765,7 @@ static int bridge_brd_status(struct bridge_dev_context *dev_ctxt,
 *      Copies the buffers to DSP internal or external memory.
 */
static int bridge_brd_write(struct bridge_dev_context *dev_ctxt,
				   IN u8 *pbHostBuf, u32 dsp_addr,
				   IN u8 *host_buff, u32 dsp_addr,
				   u32 ul_num_bytes, u32 ulMemType)
{
	int status = 0;
@@ -777,10 +777,10 @@ static int bridge_brd_write(struct bridge_dev_context *dev_ctxt,
	}
	if ((dsp_addr - dev_context->dw_dsp_start_add) <
	    dev_context->dw_internal_size) {
		status = write_dsp_data(dev_ctxt, pbHostBuf, dsp_addr,
		status = write_dsp_data(dev_ctxt, host_buff, dsp_addr,
					ul_num_bytes, ulMemType);
	} else {
		status = write_ext_dsp_data(dev_context, pbHostBuf, dsp_addr,
		status = write_ext_dsp_data(dev_context, host_buff, dsp_addr,
					    ul_num_bytes, ulMemType, false);
	}

@@ -794,12 +794,12 @@ static int bridge_brd_write(struct bridge_dev_context *dev_ctxt,
static int bridge_dev_create(OUT struct bridge_dev_context
					**ppDevContext,
					struct dev_object *hdev_obj,
					IN struct cfg_hostres *pConfig)
					IN struct cfg_hostres *config_param)
{
	int status = 0;
	struct bridge_dev_context *dev_context = NULL;
	s32 entry_ndx;
	struct cfg_hostres *resources = pConfig;
	struct cfg_hostres *resources = config_param;
	struct pg_table_attrs *pt_attrs;
	u32 pg_tbl_pa;
	u32 pg_tbl_va;
@@ -825,10 +825,10 @@ static int bridge_dev_create(OUT struct bridge_dev_context
		    dev_context->atlb_entry[entry_ndx].ul_dsp_va = 0;
	}
	dev_context->dw_dsp_base_addr = (u32) MEM_LINEAR_ADDRESS((void *)
								 (pConfig->
								 (config_param->
								  dw_mem_base
								  [3]),
								 pConfig->
								 config_param->
								 dw_mem_length
								 [3]);
	if (!dev_context->dw_dsp_base_addr)
@@ -1147,7 +1147,7 @@ static int bridge_brd_mem_copy(struct bridge_dev_context *dev_ctxt,

/* Mem Write does not halt the DSP to write unlike bridge_brd_write */
static int bridge_brd_mem_write(struct bridge_dev_context *dev_ctxt,
				    IN u8 *pbHostBuf, u32 dsp_addr,
				    IN u8 *host_buff, u32 dsp_addr,
				    u32 ul_num_bytes, u32 ulMemType)
{
	int status = 0;
@@ -1161,16 +1161,16 @@ static int bridge_brd_mem_write(struct bridge_dev_context *dev_ctxt,
		if (dsp_addr < (dev_context->dw_dsp_start_add +
				 dev_context->dw_internal_size)) {
			status =
			    write_dsp_data(dev_ctxt, pbHostBuf, dsp_addr,
			    write_dsp_data(dev_ctxt, host_buff, dsp_addr,
					   ul_bytes, ulMemType);
		} else {
			status = write_ext_dsp_data(dev_ctxt, pbHostBuf,
			status = write_ext_dsp_data(dev_ctxt, host_buff,
						    dsp_addr, ul_bytes,
						    ulMemType, true);
		}
		ul_remain_bytes -= ul_bytes;
		dsp_addr += ul_bytes;
		pbHostBuf = pbHostBuf + ul_bytes;
		host_buff = host_buff + ul_bytes;
	}
	return status;
}
+8 −8
Original line number Diff line number Diff line
@@ -51,7 +51,7 @@ bool symbols_reloaded = true;
 *      Copies DSP external memory buffers to the host side buffers.
 */
int read_ext_dsp_data(struct bridge_dev_context *dev_ctxt,
			     OUT u8 *pbHostBuf, u32 dsp_addr,
			     OUT u8 *host_buff, u32 dsp_addr,
			     u32 ul_num_bytes, u32 ulMemType)
{
	int status = 0;
@@ -168,7 +168,7 @@ int read_ext_dsp_data(struct bridge_dev_context *dev_ctxt,
	offset = dsp_addr - ul_ext_base;

	if (DSP_SUCCEEDED(status))
		memcpy(pbHostBuf, (u8 *) dw_base_addr + offset, ul_num_bytes);
		memcpy(host_buff, (u8 *) dw_base_addr + offset, ul_num_bytes);

	return status;
}
@@ -179,7 +179,7 @@ int read_ext_dsp_data(struct bridge_dev_context *dev_ctxt,
 *      Copies buffers to the DSP internal/external memory.
 */
int write_dsp_data(struct bridge_dev_context *dev_ctxt,
			  IN u8 *pbHostBuf, u32 dsp_addr, u32 ul_num_bytes,
			  IN u8 *host_buff, u32 dsp_addr, u32 ul_num_bytes,
			  u32 ulMemType)
{
	u32 offset;
@@ -211,9 +211,9 @@ int write_dsp_data(struct bridge_dev_context *dev_ctxt,
		return -EPERM;
	}
	if (ul_num_bytes)
		memcpy((u8 *) (dw_base_addr + offset), pbHostBuf, ul_num_bytes);
		memcpy((u8 *) (dw_base_addr + offset), host_buff, ul_num_bytes);
	else
		*((u32 *) pbHostBuf) = dw_base_addr + offset;
		*((u32 *) host_buff) = dw_base_addr + offset;

	return status;
}
@@ -225,7 +225,7 @@ int write_dsp_data(struct bridge_dev_context *dev_ctxt,
 *
 */
int write_ext_dsp_data(struct bridge_dev_context *dev_context,
			      IN u8 *pbHostBuf, u32 dsp_addr,
			      IN u8 *host_buff, u32 dsp_addr,
			      u32 ul_num_bytes, u32 ulMemType,
			      bool dynamic_load)
{
@@ -371,10 +371,10 @@ int write_ext_dsp_data(struct bridge_dev_context *dev_context,
	}
	if (DSP_SUCCEEDED(ret)) {
		if (ul_num_bytes)
			memcpy((u8 *) dw_base_addr + dw_offset, pbHostBuf,
			memcpy((u8 *) dw_base_addr + dw_offset, host_buff,
			       ul_num_bytes);
		else
			*((u32 *) pbHostBuf) = dw_base_addr + dw_offset;
			*((u32 *) host_buff) = dw_base_addr + dw_offset;
	}
	/* Unmap here to force remap for other Ext loads */
	if ((dynamic_load || trace_load) && dev_context->dw_dsp_ext_base_addr) {
+3 −3
Original line number Diff line number Diff line
@@ -48,14 +48,14 @@
 * is configured by the combination of DSP MMU and shm Memory manager in the CDB
 */
extern int read_ext_dsp_data(struct bridge_dev_context *dev_context,
				    OUT u8 *pbHostBuf, u32 dsp_addr,
				    OUT u8 *host_buff, u32 dsp_addr,
				    u32 ul_num_bytes, u32 ulMemType);

/*
 *  ======== write_dsp_data ========
 */
extern int write_dsp_data(struct bridge_dev_context *dev_context,
				 OUT u8 *pbHostBuf, u32 dsp_addr,
				 OUT u8 *host_buff, u32 dsp_addr,
				 u32 ul_num_bytes, u32 ulMemType);

/*
@@ -65,7 +65,7 @@ extern int write_dsp_data(struct bridge_dev_context *dev_context,
 *  shm Memory manager in the CDB
 */
extern int write_ext_dsp_data(struct bridge_dev_context *dev_context,
				     IN u8 *pbHostBuf, u32 dsp_addr,
				     IN u8 *host_buff, u32 dsp_addr,
				     u32 ul_num_bytes, u32 ulMemType,
				     bool dynamic_load);

+3 −3
Original line number Diff line number Diff line
@@ -40,7 +40,7 @@ extern void cfg_exit(void);
 *      Retreive the autostart mask, if any, for this board.
 *  Parameters:
 *      dev_node_obj:  Handle to the dev_node who's driver we are querying.
 *      pdwAutoStart:   Ptr to location for 32 bit autostart mask.
 *      auto_start:   Ptr to location for 32 bit autostart mask.
 *  Returns:
 *      0:                Success.
 *      -EFAULT:  dev_node_obj is invalid.
@@ -48,10 +48,10 @@ extern void cfg_exit(void);
 *  Requires:
 *      CFG initialized.
 *  Ensures:
 *      0:        *pdwAutoStart contains autostart mask for this devnode.
 *      0:        *auto_start contains autostart mask for this devnode.
 */
extern int cfg_get_auto_start(IN struct cfg_devnode *dev_node_obj,
				     OUT u32 *pdwAutoStart);
				     OUT u32 *auto_start);

/*
 *  ======== cfg_get_cd_version ========
Loading