Commit fb6aabb7 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:
========================================
pMemStatBuf to mem_stat_buf
pMgrAttrs to mgr_attrts
pMgrInfo to mgr_info
pNodeEnv to node_env
pNodeId to node_uuid
pNodeInfo to node_info
pNumLibs to num_libs
pNumPersLibs to num_pers_libs
pObjDef to obj_def
pObjUuid to obj_uuid
poolPhysBase to pool_phys_base
poolSize to pool_size
pPctxt to pctxt
ppDevContext to dev_cntxt
ppDrvInterface to drv_intf
pPersistentDepLibs to prstnt_dep_libs
pPhyAddr to phy_addr
========================================

Signed-off-by: default avatarRene Sapiens <rene.sapiens@ti.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent daa89e6c
Loading
Loading
Loading
Loading
+14 −14
Original line number Diff line number Diff line
@@ -382,7 +382,7 @@ int bridge_chnl_close(struct chnl_object *chnl_obj)
 */
int bridge_chnl_create(OUT struct chnl_mgr **channel_mgr,
			      struct dev_object *hdev_obj,
			      IN CONST struct chnl_mgrattrs *pMgrAttrs)
			      IN CONST struct chnl_mgrattrs *mgr_attrts)
{
	int status = 0;
	struct chnl_mgr *chnl_mgr_obj = NULL;
@@ -390,10 +390,10 @@ int bridge_chnl_create(OUT struct chnl_mgr **channel_mgr,

	/* Check DBC requirements: */
	DBC_REQUIRE(channel_mgr != NULL);
	DBC_REQUIRE(pMgrAttrs != NULL);
	DBC_REQUIRE(pMgrAttrs->max_channels > 0);
	DBC_REQUIRE(pMgrAttrs->max_channels <= CHNL_MAXCHANNELS);
	DBC_REQUIRE(pMgrAttrs->word_size != 0);
	DBC_REQUIRE(mgr_attrts != NULL);
	DBC_REQUIRE(mgr_attrts->max_channels > 0);
	DBC_REQUIRE(mgr_attrts->max_channels <= CHNL_MAXCHANNELS);
	DBC_REQUIRE(mgr_attrts->word_size != 0);

	/* Allocate channel manager object */
	chnl_mgr_obj = kzalloc(sizeof(struct chnl_mgr), GFP_KERNEL);
@@ -401,10 +401,10 @@ int bridge_chnl_create(OUT struct chnl_mgr **channel_mgr,
		/*
		 * The max_channels attr must equal the # of supported chnls for
		 * each transport(# chnls for PCPY = DDMA = ZCPY): i.e.
		 *      pMgrAttrs->max_channels = CHNL_MAXCHANNELS =
		 *      mgr_attrts->max_channels = CHNL_MAXCHANNELS =
		 *                       DDMA_MAXDDMACHNLS = DDMA_MAXZCPYCHNLS.
		 */
		DBC_ASSERT(pMgrAttrs->max_channels == CHNL_MAXCHANNELS);
		DBC_ASSERT(mgr_attrts->max_channels == CHNL_MAXCHANNELS);
		max_channels = CHNL_MAXCHANNELS + CHNL_MAXCHANNELS * CHNL_PCPY;
		/* Create array of channels */
		chnl_mgr_obj->ap_channel = kzalloc(sizeof(struct chnl_object *)
@@ -412,7 +412,7 @@ int bridge_chnl_create(OUT struct chnl_mgr **channel_mgr,
		if (chnl_mgr_obj->ap_channel) {
			/* Initialize chnl_mgr object */
			chnl_mgr_obj->dw_type = CHNL_TYPESM;
			chnl_mgr_obj->word_size = pMgrAttrs->word_size;
			chnl_mgr_obj->word_size = mgr_attrts->word_size;
			/* Total # chnls supported */
			chnl_mgr_obj->max_channels = max_channels;
			chnl_mgr_obj->open_channels = 0;
@@ -710,22 +710,22 @@ int bridge_chnl_get_ioc(struct chnl_object *chnl_obj, u32 timeout,
 *      Retrieve information related to the channel manager.
 */
int bridge_chnl_get_mgr_info(struct chnl_mgr *hchnl_mgr, u32 uChnlID,
				 OUT struct chnl_mgrinfo *pMgrInfo)
				 OUT struct chnl_mgrinfo *mgr_info)
{
	int status = 0;
	struct chnl_mgr *chnl_mgr_obj = (struct chnl_mgr *)hchnl_mgr;

	if (pMgrInfo != NULL) {
	if (mgr_info != NULL) {
		if (uChnlID <= CHNL_MAXCHANNELS) {
			if (hchnl_mgr) {
				/* Return the requested information: */
				pMgrInfo->chnl_obj =
				mgr_info->chnl_obj =
				    chnl_mgr_obj->ap_channel[uChnlID];
				pMgrInfo->open_channels =
				mgr_info->open_channels =
				    chnl_mgr_obj->open_channels;
				pMgrInfo->dw_type = chnl_mgr_obj->dw_type;
				mgr_info->dw_type = chnl_mgr_obj->dw_type;
				/* total # of chnls */
				pMgrInfo->max_channels =
				mgr_info->max_channels =
				    chnl_mgr_obj->max_channels;
			} else {
				status = -EFAULT;
+4 −4
Original line number Diff line number Diff line
@@ -163,7 +163,7 @@ static int register_shm_segs(struct io_mgr *hio_mgr,
 */
int bridge_io_create(OUT struct io_mgr **io_man,
			    struct dev_object *hdev_obj,
			    IN CONST struct io_attrs *pMgrAttrs)
			    IN CONST struct io_attrs *mgr_attrts)
{
	int status = 0;
	struct io_mgr *pio_mgr = NULL;
@@ -174,7 +174,7 @@ int bridge_io_create(OUT struct io_mgr **io_man,
	u8 dev_type;

	/* Check requirements */
	if (!io_man || !pMgrAttrs || pMgrAttrs->word_size == 0) {
	if (!io_man || !mgr_attrts || mgr_attrts->word_size == 0) {
		status = -EFAULT;
		goto func_end;
	}
@@ -214,7 +214,7 @@ int bridge_io_create(OUT struct io_mgr **io_man,
	pio_mgr->pmsg = NULL;
#endif
	pio_mgr->hchnl_mgr = hchnl_mgr;
	pio_mgr->word_size = pMgrAttrs->word_size;
	pio_mgr->word_size = mgr_attrts->word_size;
	pio_mgr->shared_mem = shared_mem;

	if (dev_type == DSP_UNIT) {
@@ -233,7 +233,7 @@ int bridge_io_create(OUT struct io_mgr **io_man,

	if (DSP_SUCCEEDED(status)) {
		pio_mgr->hbridge_context = hbridge_context;
		pio_mgr->shared_irq = pMgrAttrs->irq_shared;
		pio_mgr->shared_irq = mgr_attrts->irq_shared;
		if (dsp_wdt_init())
			status = -EPERM;
	} else {
+5 −5
Original line number Diff line number Diff line
@@ -103,7 +103,7 @@ static int bridge_brd_mem_map(struct bridge_dev_context *dev_ctxt,
static int bridge_brd_mem_un_map(struct bridge_dev_context *dev_ctxt,
				     u32 ulVirtAddr, u32 ul_num_bytes);
static int bridge_dev_create(OUT struct bridge_dev_context
					**ppDevContext,
					**dev_cntxt,
					struct dev_object *hdev_obj,
					IN struct cfg_hostres *config_param);
static int bridge_dev_ctrl(struct bridge_dev_context *dev_context,
@@ -236,7 +236,7 @@ static void bad_page_dump(u32 pa, struct page *pg)
 *  purpose:
 *      Bridge Driver entry point.
 */
void bridge_drv_entry(OUT struct bridge_drv_interface **ppDrvInterface,
void bridge_drv_entry(OUT struct bridge_drv_interface **drv_intf,
		   IN CONST char *driver_file_name)
{

@@ -245,7 +245,7 @@ void bridge_drv_entry(OUT struct bridge_drv_interface **ppDrvInterface,
	io_sm_init();		/* Initialization of io_sm module */

	if (strcmp(driver_file_name, "UMA") == 0)
		*ppDrvInterface = &drv_interface_fxns;
		*drv_intf = &drv_interface_fxns;
	else
		dev_dbg(bridge, "%s Unknown Bridge file name", __func__);

@@ -792,7 +792,7 @@ static int bridge_brd_write(struct bridge_dev_context *dev_ctxt,
 *      Creates a driver object. Puts DSP in self loop.
 */
static int bridge_dev_create(OUT struct bridge_dev_context
					**ppDevContext,
					**dev_cntxt,
					struct dev_object *hdev_obj,
					IN struct cfg_hostres *config_param)
{
@@ -930,7 +930,7 @@ static int bridge_dev_create(OUT struct bridge_dev_context
		dev_context->dw_brd_state = BRD_STOPPED;
		dev_context->resources = resources;
		/* Return ptr to our device state to the DSP API for storage */
		*ppDevContext = dev_context;
		*dev_cntxt = dev_context;
	} else {
		if (pt_attrs != NULL) {
			kfree(pt_attrs->pg_info);
+7 −7
Original line number Diff line number Diff line
@@ -53,11 +53,11 @@ extern int chnl_close(struct chnl_object *chnl_obj);
 *  Parameters:
 *      channel_mgr:    Location to store a channel manager object on output.
 *      hdev_obj:     Handle to a device object.
 *      pMgrAttrs:      Channel manager attributes.
 *      pMgrAttrs->max_channels:   Max channels
 *      pMgrAttrs->birq:        Channel's I/O IRQ number.
 *      pMgrAttrs->irq_shared:     TRUE if the IRQ is shareable.
 *      pMgrAttrs->word_size:   DSP Word size in equivalent PC bytes..
 *      mgr_attrts:      Channel manager attributes.
 *      mgr_attrts->max_channels:   Max channels
 *      mgr_attrts->birq:        Channel's I/O IRQ number.
 *      mgr_attrts->irq_shared:     TRUE if the IRQ is shareable.
 *      mgr_attrts->word_size:   DSP Word size in equivalent PC bytes..
 *  Returns:
 *      0:                Success;
 *      -EFAULT:            hdev_obj is invalid.
@@ -71,7 +71,7 @@ extern int chnl_close(struct chnl_object *chnl_obj);
 *  Requires:
 *      chnl_init(void) called.
 *      channel_mgr != NULL.
 *      pMgrAttrs != NULL.
 *      mgr_attrts != NULL.
 *  Ensures:
 *      0:                Subsequent calls to chnl_create() for the same
 *                              board without an intervening call to
@@ -79,7 +79,7 @@ extern int chnl_close(struct chnl_object *chnl_obj);
 */
extern int chnl_create(OUT struct chnl_mgr **channel_mgr,
			      struct dev_object *hdev_obj,
			      IN CONST struct chnl_mgrattrs *pMgrAttrs);
			      IN CONST struct chnl_mgrattrs *mgr_attrts);

/*
 *  ======== chnl_destroy ========
+3 −3
Original line number Diff line number Diff line
@@ -72,7 +72,7 @@ extern void *cmm_calloc_buf(struct cmm_object *hcmm_mgr,
 *      ph_cmm_mgr:	Location to store a communication manager handle on
 *      		output.
 *      hdev_obj: Handle to a device object.
 *      pMgrAttrs:  Comm mem manager attributes.
 *      mgr_attrts: Comm mem manager attributes.
 *  Returns:
 *      0:        Success;
 *      -ENOMEM:    Insufficient memory for requested resources.
@@ -81,13 +81,13 @@ extern void *cmm_calloc_buf(struct cmm_object *hcmm_mgr,
 *  Requires:
 *      cmm_init(void) called.
 *      ph_cmm_mgr != NULL.
 *      pMgrAttrs->ul_min_block_size >= 4 bytes.
 *      mgr_attrts->ul_min_block_size >= 4 bytes.
 *  Ensures:
 *
 */
extern int cmm_create(OUT struct cmm_object **ph_cmm_mgr,
			     struct dev_object *hdev_obj,
			     IN CONST struct cmm_mgrattrs *pMgrAttrs);
			     IN CONST struct cmm_mgrattrs *mgr_attrts);

/*
 *  ======== cmm_destroy ========
Loading