[PATCH 1/5] staging: bcm: Convert BCM_DEBUG_PRINT(..., DBG_TYPE_PRINTK to pr_info

Joe Perches joe at perches.com
Mon Jan 9 18:06:52 UTC 2012


Use normal logging styles.

Add pr_fmt to modified files to prefix bcm_wimax: to logging output.

Signed-off-by: Joe Perches <joe at perches.com>
---
 drivers/staging/bcm/Adapter.h           |    3 -
 drivers/staging/bcm/Bcmchar.c           |  191 +++++++++++----------
 drivers/staging/bcm/CmHost.c            |   32 ++--
 drivers/staging/bcm/DDRInit.c           |   15 +-
 drivers/staging/bcm/Debug.h             |   51 +++---
 drivers/staging/bcm/InterfaceDld.c      |    6 +-
 drivers/staging/bcm/InterfaceIdleMode.c |   23 ++-
 drivers/staging/bcm/InterfaceInit.c     |   16 +-
 drivers/staging/bcm/InterfaceMisc.c     |   10 +-
 drivers/staging/bcm/InterfaceRx.c       |    6 +-
 drivers/staging/bcm/InterfaceTx.c       |    6 +-
 drivers/staging/bcm/Misc.c              |   45 +++--
 drivers/staging/bcm/PHSModule.c         |    6 +-
 drivers/staging/bcm/nvm.c               |  280 ++++++++++++++++++-------------
 14 files changed, 391 insertions(+), 299 deletions(-)

diff --git a/drivers/staging/bcm/Adapter.h b/drivers/staging/bcm/Adapter.h
index 20cca24..2e8382c 100644
--- a/drivers/staging/bcm/Adapter.h
+++ b/drivers/staging/bcm/Adapter.h
@@ -1,6 +1,3 @@
-/***********************************
-*	Adapter.h
-************************************/
 #ifndef	__ADAPTER_H__
 #define	__ADAPTER_H__
 
diff --git a/drivers/staging/bcm/Bcmchar.c b/drivers/staging/bcm/Bcmchar.c
index 179707b..89f66ee 100644
--- a/drivers/staging/bcm/Bcmchar.c
+++ b/drivers/staging/bcm/Bcmchar.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include <linux/fs.h>
 
 #include "headers.h"
@@ -50,8 +52,7 @@ static int bcm_char_release(struct inode *inode, struct file *filp)
 	pTarang = (PPER_TARANG_DATA)filp->private_data;
 
 	if (pTarang == NULL) {
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-				"ptarang is null\n");
+		pr_info("ptarang is null\n");
 		return 0;
 	}
 
@@ -139,8 +140,7 @@ static ssize_t bcm_char_read(struct file *filp, char __user *buf, size_t size,
 				   min_t(size_t, PktLen, size));
 		if (ret) {
 			dev_kfree_skb(Packet);
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-					"Returning from copy to user failure\n");
+			pr_info("Returning from copy to user failure\n");
 			return -EFAULT;
 		}
 		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL,
@@ -269,7 +269,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 				(uiTempVar == EEPROM_REJECT_REG_3) ||
 				(uiTempVar == EEPROM_REJECT_REG_4))) {
 
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "EEPROM Access Denied, not in VSG Mode\n");
+			pr_info("EEPROM Access Denied, not in VSG Mode\n");
 			return -EFAULT;
 		}
 
@@ -294,7 +294,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 			(Adapter->bShutStatus == TRUE) ||
 			(Adapter->bPreparingForLowPowerMode == TRUE)) {
 
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Device in Idle Mode, Blocking Rdms\n");
+			pr_info("Device in Idle Mode, Blocking Rdms\n");
 			return -EACCES;
 		}
 
@@ -320,8 +320,8 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 		if ((((ULONG)sRdmBuffer.Register & 0x0F000000) != 0x0F000000) ||
 			((ULONG)sRdmBuffer.Register & 0x3)) {
 
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "RDM Done On invalid Address : %x Access Denied.\n",
-					(int)sRdmBuffer.Register);
+			pr_info("RDM Done On invalid Address : %x Access Denied\n",
+				(int)sRdmBuffer.Register);
 
 			kfree(temp_buff);
 			return -EINVAL;
@@ -351,7 +351,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 			(Adapter->bShutStatus == TRUE) ||
 			(Adapter->bPreparingForLowPowerMode == TRUE)) {
 
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Device in Idle Mode, Blocking Wrms\n");
+			pr_info("Device in Idle Mode, Blocking Wrms\n");
 			return -EACCES;
 		}
 
@@ -369,7 +369,8 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 		if ((((ULONG)sWrmBuffer.Register & 0x0F000000) != 0x0F000000) ||
 			((ULONG)sWrmBuffer.Register & 0x3)) {
 
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "WRM Done On invalid Address : %x Access Denied.\n", (int)sWrmBuffer.Register);
+			pr_info("WRM Done On invalid Address : %x Access Denied\n",
+				(int)sWrmBuffer.Register);
 			return -EINVAL;
 		}
 
@@ -381,7 +382,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 				(uiTempVar == EEPROM_REJECT_REG_4)) &&
 				(cmd == IOCTL_BCM_REGISTER_WRITE)) {
 
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "EEPROM Access Denied, not in VSG Mode\n");
+				pr_info("EEPROM Access Denied, not in VSG Mode\n");
 				return -EFAULT;
 		}
 
@@ -389,7 +390,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 					(PUINT)sWrmBuffer.Data, sWrmBuffer.Length);
 
 		if (Status == STATUS_SUCCESS) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, OSAL_DBG, DBG_LVL_ALL, "WRM Done\n");
+			pr_info("WRM Done\n");
 		} else {
 			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL, "WRM Failed\n");
 			Status = -EFAULT;
@@ -542,7 +543,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 
 		if (bytes < 0) {
 			Status = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "RDM Failed\n");
+			pr_info("RDM Failed\n");
 			return Status;
 		} else {
 			Status = STATUS_SUCCESS;
@@ -592,7 +593,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 							(PUINT)ucResetValue, sizeof(ULONG));
 
 			if (Status != STATUS_SUCCESS) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "WRM to BCM_GPIO_OUTPUT_SET_REG Failed.");
+				pr_info("WRM to BCM_GPIO_OUTPUT_SET_REG Failed\n");
 				return Status;
 			}
 
@@ -605,7 +606,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 				Status = wrmaltWithLock(Adapter, BCM_GPIO_OUTPUT_CLR_REG, (PUINT)ucResetValue, sizeof(ULONG));
 
 			if (Status != STATUS_SUCCESS) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "WRM to BCM_GPIO_OUTPUT_CLR_REG Failed.");
+				pr_info("WRM to BCM_GPIO_OUTPUT_CLR_REG Failed\n");
 				return Status;
 			}
 		}
@@ -615,7 +616,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 
 			if (bytes < 0) {
 				Status = bytes;
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "RDM to GPIO_PIN_STATE_REGISTER Failed.");
+				pr_info("RDM to GPIO_PIN_STATE_REGISTER Failed\n");
 				return Status;
 			} else {
 				Status = STATUS_SUCCESS;
@@ -627,8 +628,8 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 
 		Status = copy_to_user(IoBuffer.OutputBuffer, &gpio_multi_info, IoBuffer.OutputLength);
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-					"Failed while copying Content to IOBufer for user space err:%d", Status);
+			pr_info("Failed while copying Content to IOBufer for user space err:%d\n",
+				Status);
 			return -EFAULT;
 		}
 	}
@@ -657,7 +658,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 
 		if (bytes < 0) {
 			Status = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Read of GPIO_MODE_REGISTER failed");
+			pr_info("Read of GPIO_MODE_REGISTER failed\n");
 			return Status;
 		} else {
 			Status = STATUS_SUCCESS;
@@ -691,8 +692,7 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL,
 						"WRM to GPIO_MODE_REGISTER Done");
 			} else {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-						"WRM to GPIO_MODE_REGISTER Failed");
+				pr_info("WRM to GPIO_MODE_REGISTER Failed\n");
 				Status = -EFAULT;
 				break;
 			}
@@ -703,8 +703,8 @@ static long bcm_char_ioctl(struct file *filp, UINT cmd, ULONG arg)
 
 		Status = copy_to_user(IoBuffer.OutputBuffer, &gpio_multi_mode, IoBuffer.OutputLength);
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-					"Failed while copying Content to IOBufer for user space err:%d", Status);
+			pr_info("Failed while copying Content to IOBufer for user space err:%d\n",
+				Status);
 			return -EFAULT;
 		}
 	}
@@ -765,8 +765,8 @@ cntrlEnd:
 			return -EACCES;
 		}
 
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-				"Starting the firmware download PID =0x%x!!!!\n", current->pid);
+		pr_info("Starting the firmware download PID =0x%x!!!!\n",
+			current->pid);
 
 		if (down_trylock(&Adapter->fw_download_sema))
 			return -EBUSY;
@@ -792,11 +792,11 @@ cntrlEnd:
 
 	case IOCTL_BCM_BUFFER_DOWNLOAD: {
 		FIRMWARE_INFO *psFwInfo = NULL;
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Starting the firmware download PID =0x%x!!!!\n", current->pid);
+		pr_info("Starting the firmware download PID =0x%x!!!!\n",
+			current->pid);
 
 		if (!down_trylock(&Adapter->fw_download_sema)) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-					"Invalid way to download buffer. Use Start and then call this!!!\n");
+			pr_info("Invalid way to download buffer. Use Start and then call this!!!\n");
 			up(&Adapter->fw_download_sema);
 			Status = -EINVAL;
 			return Status;
@@ -808,8 +808,7 @@ cntrlEnd:
 			return -EFAULT;
 		}
 
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-				"Length for FW DLD is : %lx\n", IoBuffer.InputLength);
+		pr_info("Length for FW DLD is : %lx\n", IoBuffer.InputLength);
 
 		if (IoBuffer.InputLength > sizeof(FIRMWARE_INFO)) {
 			up(&Adapter->fw_download_sema);
@@ -830,8 +829,8 @@ cntrlEnd:
 		if (!psFwInfo->pvMappedFirmwareAddress ||
 			(psFwInfo->u32FirmwareLength == 0)) {
 
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Something else is wrong %lu\n",
-					psFwInfo->u32FirmwareLength);
+			pr_info("Something else is wrong %lu\n",
+				psFwInfo->u32FirmwareLength);
 			up(&Adapter->fw_download_sema);
 			Status = -EINVAL;
 			return Status;
@@ -841,9 +840,9 @@ cntrlEnd:
 
 		if (Status != STATUS_SUCCESS) {
 			if (psFwInfo->u32StartingAddress == CONFIG_BEGIN_ADDR)
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "IOCTL: Configuration File Upload Failed\n");
+				pr_info("IOCTL: Configuration File Upload Failed\n");
 			else
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,	"IOCTL: Firmware File Upload Failed\n");
+				pr_info("IOCTL: Firmware File Upload Failed\n");
 
 			/* up(&Adapter->fw_download_sema); */
 
@@ -857,7 +856,7 @@ cntrlEnd:
 		if (Status != STATUS_SUCCESS)
 			up(&Adapter->fw_download_sema);
 
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, OSAL_DBG, DBG_LVL_ALL, "IOCTL: Firmware File Uploaded\n");
+		pr_info("IOCTL: Firmware File Uploaded\n");
 		kfree(psFwInfo);
 		return Status;
 	}
@@ -869,8 +868,7 @@ cntrlEnd:
 		}
 
 		if (down_trylock(&Adapter->NVMRdmWrmLock)) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-					"FW download blocked as EEPROM Read/Write is in progress\n");
+			pr_info("FW download blocked as EEPROM Read/Write is in progress\n");
 			up(&Adapter->fw_download_sema);
 			return -EACCES;
 		}
@@ -885,7 +883,7 @@ cntrlEnd:
 		Status = run_card_proc(Adapter);
 
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Firm Download Failed\n");
+			pr_info("Firm Download Failed\n");
 			up(&Adapter->fw_download_sema);
 			up(&Adapter->NVMRdmWrmLock);
 			return Status;
@@ -898,7 +896,7 @@ cntrlEnd:
 
 		/* Wait for MailBox Interrupt */
 		if (StartInterruptUrb((PS_INTERFACE_ADAPTER)Adapter->pvInterfaceAdapter))
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Unable to send interrupt...\n");
+			pr_info("Unable to send interrupt...\n");
 
 		timeout = 5*HZ;
 		Adapter->waiting_to_fw_download_done = FALSE;
@@ -941,7 +939,7 @@ cntrlEnd:
 	case IOCTL_CHIP_RESET: {
 		INT NVMAccess = down_trylock(&Adapter->NVMRdmWrmLock);
 		if (NVMAccess) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, " IOCTL_BCM_CHIP_RESET not allowed as EEPROM Read/Write is in progress\n");
+			pr_info(" IOCTL_BCM_CHIP_RESET not allowed as EEPROM Read/Write is in progress\n");
 			return -EACCES;
 		}
 
@@ -1018,7 +1016,7 @@ cntrlEnd:
 
 		/* Copy Ioctl Buffer structure */
 		if (copy_from_user(&IoBuffer, argp, sizeof(IOCTL_BUFFER))) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "copy_from_user failed..\n");
+			pr_info("copy_from_user failed..\n");
 			return -EFAULT;
 		}
 
@@ -1033,7 +1031,7 @@ cntrlEnd:
 		link_state.ucLinkStatus = Adapter->LinkStatus;
 
 		if (copy_to_user(IoBuffer.OutputBuffer, &link_state, min_t(size_t, sizeof(link_state), IoBuffer.OutputLength))) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy_to_user Failed..\n");
+			pr_info("Copy_to_user Failed..\n");
 			return -EFAULT;
 		}
 		Status = STATUS_SUCCESS;
@@ -1063,9 +1061,9 @@ cntrlEnd:
 			return -EFAULT;
 
 		if (IoBuffer.OutputLength < sizeof(stLocalSFAddIndicationAlt)) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-					"Mismatch req: %lx needed is =0x%zx!!!",
-					IoBuffer.OutputLength, sizeof(stLocalSFAddIndicationAlt));
+			pr_info("Mismatch req: %lx needed is =0x%zx!!!\n",
+				IoBuffer.OutputLength,
+				sizeof(stLocalSFAddIndicationAlt));
 			return -EINVAL;
 		}
 
@@ -1085,9 +1083,9 @@ cntrlEnd:
 			return -EFAULT;
 
 		if (IoBuffer.OutputLength != sizeof(S_MIBS_HOST_STATS_MIBS)) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0,
-					"Length Check failed %lu %zd\n",
-					IoBuffer.OutputLength, sizeof(S_MIBS_HOST_STATS_MIBS));
+			pr_info("Length Check failed %lu %zd\n",
+				IoBuffer.OutputLength,
+				sizeof(S_MIBS_HOST_STATS_MIBS));
 			return -EINVAL;
 		}
 
@@ -1128,7 +1126,7 @@ cntrlEnd:
 			(Adapter->bShutStatus == TRUE) ||
 			(Adapter->bPreparingForLowPowerMode == TRUE)) {
 
-			BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "Device in Idle/Shutdown Mode, Blocking Wrms\n");
+			pr_info("Device in Idle/Shutdown Mode, Blocking Wrms\n");
 			Status = -EACCES;
 			break;
 		}
@@ -1155,7 +1153,8 @@ cntrlEnd:
 		if (((ULONG)pBulkBuffer->Register & 0x0F000000) != 0x0F000000 ||
 			((ULONG)pBulkBuffer->Register & 0x3)) {
 			kfree(pvBuffer);
-			BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "WRM Done On invalid Address : %x Access Denied.\n", (int)pBulkBuffer->Register);
+			pr_info("WRM Done On invalid Address : %x Access Denied\n",
+				(int)pBulkBuffer->Register);
 			Status = -EINVAL;
 			break;
 		}
@@ -1169,7 +1168,7 @@ cntrlEnd:
 			(cmd == IOCTL_BCM_REGISTER_WRITE)) {
 
 			kfree(pvBuffer);
-			BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "EEPROM Access Denied, not in VSG Mode\n");
+			pr_info("EEPROM Access Denied, not in VSG Mode\n");
 			Status = -EFAULT;
 			break;
 		}
@@ -1180,7 +1179,7 @@ cntrlEnd:
 			Status = wrmaltWithLock(Adapter, (UINT)pBulkBuffer->Register, (PUINT)pBulkBuffer->Values, IoBuffer.InputLength - 2*sizeof(ULONG));
 
 		if (Status != STATUS_SUCCESS)
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "WRM Failed\n");
+			pr_info("WRM Failed\n");
 
 		kfree(pvBuffer);
 		break;
@@ -1217,7 +1216,7 @@ cntrlEnd:
 						return -EFAULT;
 				} else {
 					if ((TRUE == Adapter->bShutStatus) || (TRUE == Adapter->IdleMode)) {
-						BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Device is in Idle/Shutdown Mode\n");
+						pr_info("Device is in Idle/Shutdown Mode\n");
 						return -EACCES;
 					}
 
@@ -1244,11 +1243,12 @@ cntrlEnd:
 		if (copy_from_user(&sUserDebugState, IoBuffer.InputBuffer, sizeof(USER_BCM_DBG_STATE)))
 			return -EFAULT;
 
-		BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "IOCTL_BCM_SET_DEBUG: OnOff=%d Type = 0x%x ",
-				sUserDebugState.OnOff, sUserDebugState.Type);
 		/* sUserDebugState.Subtype <<= 1; */
 		sUserDebugState.Subtype = 1 << sUserDebugState.Subtype;
-		BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "actual Subtype=0x%x\n", sUserDebugState.Subtype);
+		pr_info("IOCTL_BCM_SET_DEBUG: OnOff=%d Type = 0x%x actual Subtype=0x%x\n",
+			sUserDebugState.OnOff,
+			sUserDebugState.Type,
+			sUserDebugState.Subtype);
 
 		/* Update new 'DebugState' in the Adapter */
 		Adapter->stDebugState.type |= sUserDebugState.Type;
@@ -1276,7 +1276,7 @@ cntrlEnd:
 		memset(&tv0, 0, sizeof(struct timeval));
 		memset(&tv1, 0, sizeof(struct timeval));
 		if ((Adapter->eNVMType == NVM_FLASH) && (Adapter->uiFlashLayoutMajorVersion == 0)) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "The Flash Control Section is Corrupted. Hence Rejection on NVM Read/Write\n");
+			pr_info("The Flash Control Section is Corrupted. Hence Rejection on NVM Read/Write\n");
 			return -EFAULT;
 		}
 
@@ -1285,7 +1285,7 @@ cntrlEnd:
 				(Adapter->eActiveDSD != DSD1) &&
 				(Adapter->eActiveDSD != DSD2)) {
 
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "No DSD is active..hence NVM Command is blocked");
+				pr_info("No DSD is active..hence NVM Command is blocked\n");
 				return STATUS_FAILURE;
 			}
 		}
@@ -1304,7 +1304,11 @@ cntrlEnd:
 		 */
 
 		if ((stNVMReadWrite.uiOffset + stNVMReadWrite.uiNumBytes) > Adapter->uiNVMDSDSize) {
-			/* BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Can't allow access beyond NVM Size: 0x%x 0x%x\n", stNVMReadWrite.uiOffset, stNVMReadWrite.uiNumBytes); */
+			/*
+			pr_info("Can't allow access beyond NVM Size: 0x%x 0x%x\n",
+				stNVMReadWrite.uiOffset,
+				stNVMReadWrite.uiNumBytes);
+			*/
 			return STATUS_FAILURE;
 		}
 
@@ -1422,7 +1426,7 @@ cntrlEnd:
 		void __user *OutPutBuff;
 
 		if (IsFlash2x(Adapter) != TRUE)	{
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Flash Does not have 2.x map");
+			pr_info("Flash Does not have 2.x map\n");
 			return -EINVAL;
 		}
 
@@ -1454,7 +1458,7 @@ cntrlEnd:
 		pReadBuff = (PCHAR)kzalloc(BuffSize , GFP_KERNEL);
 
 		if (pReadBuff == NULL) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Memory allocation failed for Flash 2.x Read Structure");
+			pr_info("Memory allocation failed for Flash 2.x Read Structure\n");
 			return -ENOMEM;
 		}
 		down(&Adapter->NVMRdmWrmLock);
@@ -1513,7 +1517,7 @@ cntrlEnd:
 		UINT WriteBytes = 0;
 
 		if (IsFlash2x(Adapter) != TRUE) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Flash Does not have 2.x map");
+			pr_info("Flash Does not have 2.x map\n");
 			return -EINVAL;
 		}
 
@@ -1580,7 +1584,8 @@ cntrlEnd:
 		do {
 			Status = copy_from_user(pWriteBuff, InputAddr, WriteBytes);
 			if (Status) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy to user failed with status :%d", Status);
+				pr_info("Copy to user failed with status :%d\n",
+					Status);
 				up(&Adapter->NVMRdmWrmLock);
 				kfree(pWriteBuff);
 				return -EFAULT;
@@ -1591,7 +1596,8 @@ cntrlEnd:
 			Status = BcmFlash2xBulkWrite(Adapter, (PUINT)pWriteBuff, sFlash2xWrite.Section, WriteOffset, WriteBytes, sFlash2xWrite.bVerify);
 
 			if (Status) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Flash 2x read err with Status :%d", Status);
+				pr_info("Flash 2x read err with Status :%d\n",
+					Status);
 				break;
 			}
 
@@ -1624,7 +1630,7 @@ cntrlEnd:
 
 		psFlash2xBitMap = kzalloc(sizeof(FLASH2X_BITMAP), GFP_KERNEL);
 		if (psFlash2xBitMap == NULL) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Memory is not available");
+			pr_info("Memory is not available\n");
 			return -ENOMEM;
 		}
 
@@ -1657,19 +1663,19 @@ cntrlEnd:
 		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL, "IOCTL_BCM_SET_ACTIVE_SECTION Called");
 
 		if (IsFlash2x(Adapter) != TRUE) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Flash Does not have 2.x map");
+			pr_info("Flash Does not have 2.x map\n");
 			return -EINVAL;
 		}
 
 		Status = copy_from_user(&IoBuffer, argp, sizeof(IOCTL_BUFFER));
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy of IOCTL BUFFER failed");
+			pr_info("Copy of IOCTL BUFFER failed\n");
 			return -EFAULT;
 		}
 
 		Status = copy_from_user(&eFlash2xSectionVal, IoBuffer.InputBuffer, sizeof(INT));
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy of flash section val failed");
+			pr_info("Copy of flash section val failed\n");
 			return -EFAULT;
 		}
 
@@ -1686,7 +1692,8 @@ cntrlEnd:
 
 		Status = BcmSetActiveSection(Adapter, eFlash2xSectionVal);
 		if (Status)
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Failed to make it's priority Highest. Status %d", Status);
+			pr_info("Failed to make it's priority Highest. Status %d\n",
+				Status);
 
 		up(&Adapter->NVMRdmWrmLock);
 	}
@@ -1707,19 +1714,21 @@ cntrlEnd:
 
 		Adapter->bAllDSDWriteAllow = FALSE;
 		if (IsFlash2x(Adapter) != TRUE) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Flash Does not have 2.x map");
+			pr_info("Flash Does not have 2.x map\n");
 			return -EINVAL;
 		}
 
 		Status = copy_from_user(&IoBuffer, argp, sizeof(IOCTL_BUFFER));
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy of IOCTL BUFFER failed Status :%d", Status);
+			pr_info("Copy of IOCTL BUFFER failed Status :%d\n",
+				Status);
 			return -EFAULT;
 		}
 
 		Status = copy_from_user(&sCopySectStrut, IoBuffer.InputBuffer, sizeof(FLASH2X_COPY_SECTION));
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy of Copy_Section_Struct failed with Status :%d", Status);
+			pr_info("Copy of Copy_Section_Struct failed with Status :%d\n",
+				Status);
 			return -EFAULT;
 		}
 
@@ -1729,12 +1738,14 @@ cntrlEnd:
 		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL, "NOB :%x", sCopySectStrut.numOfBytes);
 
 		if (IsSectionExistInFlash(Adapter, sCopySectStrut.SrcSection) == FALSE) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Source Section<%x> does not exixt in Flash ", sCopySectStrut.SrcSection);
+			pr_info("Source Section<%x> does not exist in Flash\n",
+				sCopySectStrut.SrcSection);
 			return -EINVAL;
 		}
 
 		if (IsSectionExistInFlash(Adapter, sCopySectStrut.DstSection) == FALSE) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Destinatio Section<%x> does not exixt in Flash ", sCopySectStrut.DstSection);
+			pr_info("Destination Section<%x> does not exixt in Flash\n",
+				sCopySectStrut.DstSection);
 			return -EINVAL;
 		}
 
@@ -1756,12 +1767,12 @@ cntrlEnd:
 
 		if (sCopySectStrut.SrcSection == ISO_IMAGE1 || sCopySectStrut.SrcSection == ISO_IMAGE2) {
 			if (IsNonCDLessDevice(Adapter)) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Device is Non-CDLess hence won't have ISO !!");
+				pr_info("Device is Non-CDLess hence won't have ISO !!\n");
 				Status = -EINVAL;
 			} else if (sCopySectStrut.numOfBytes == 0) {
 				Status = BcmCopyISO(Adapter, sCopySectStrut);
 			} else {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Partial Copy of ISO section is not Allowed..");
+				pr_info("Partial Copy of ISO section is not Allowed..\n");
 				Status = STATUS_FAILURE;
 			}
 			up(&Adapter->NVMRdmWrmLock);
@@ -1780,12 +1791,12 @@ cntrlEnd:
 
 		Status = copy_from_user(&IoBuffer, argp, sizeof(IOCTL_BUFFER));
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy of IOCTL BUFFER failed");
+			pr_info("Copy of IOCTL BUFFER failed\n");
 			return -EFAULT;
 		}
 
 		if (Adapter->eNVMType != NVM_FLASH) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Connected device does not have flash");
+			pr_info("Connected device does not have flash\n");
 			Status = -EINVAL;
 			break;
 		}
@@ -1813,18 +1824,18 @@ cntrlEnd:
 		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_OTHERS, OSAL_DBG, DBG_LVL_ALL, "IOCTL_BCM_SELECT_DSD Called");
 
 		if (IsFlash2x(Adapter) != TRUE) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Flash Does not have 2.x map");
+			pr_info("Flash Does not have 2.x map\n");
 			return -EINVAL;
 		}
 
 		Status = copy_from_user(&IoBuffer, argp, sizeof(IOCTL_BUFFER));
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy of IOCTL BUFFER failed");
+			pr_info("Copy of IOCTL BUFFER failed\n");
 			return -EFAULT;
 		}
 		Status = copy_from_user(&eFlash2xSectionVal, IoBuffer.InputBuffer, sizeof(INT));
 		if (Status) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy of flash section val failed");
+			pr_info("Copy of flash section val failed\n");
 			return -EFAULT;
 		}
 
@@ -1833,13 +1844,15 @@ cntrlEnd:
 			(eFlash2xSectionVal != DSD1) &&
 			(eFlash2xSectionVal != DSD2)) {
 
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Passed section<%x> is not DSD section", eFlash2xSectionVal);
+			pr_info("Passed section<%x> is not DSD section\n",
+				eFlash2xSectionVal);
 			return STATUS_FAILURE;
 		}
 
 		SectOfset = BcmGetSectionValStartOffset(Adapter, eFlash2xSectionVal);
 		if (SectOfset == INVALID_OFFSET) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Provided Section val <%d> does not exixt in Flash 2.x", eFlash2xSectionVal);
+			pr_info("Provided Section val <%d> does not exixt in Flash 2.x\n",
+				eFlash2xSectionVal);
 			return -EINVAL;
 		}
 
@@ -1860,13 +1873,13 @@ cntrlEnd:
 		void __user *OutPutBuff;
 
 		if (Adapter->eNVMType != NVM_FLASH) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "NVM TYPE is not Flash");
+			pr_info("NVM TYPE is not Flash\n");
 			return -EINVAL;
 		}
 
 		/* Copy Ioctl Buffer structure */
 		if (copy_from_user(&IoBuffer, argp, sizeof(IOCTL_BUFFER))) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "copy_from_user 1 failed\n");
+			pr_info("copy_from_user 1 failed\n");
 			return -EFAULT;
 		}
 
@@ -1886,7 +1899,7 @@ cntrlEnd:
 
 		pReadBuff = kzalloc(BuffSize , GFP_KERNEL);
 		if (pReadBuff == NULL) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Memory allocation failed for Flash 2.x Read Structure");
+			pr_info("Memory allocation failed for Flash 2.x Read Structure\n");
 			Status = -ENOMEM;
 			break;
 		}
@@ -1913,7 +1926,8 @@ cntrlEnd:
 			/* Reading the data from Flash 2.x */
 			Status = BeceemNVMRead(Adapter, (PUINT)pReadBuff, ReadOffset, ReadBytes);
 			if (Status) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Flash 2x read err with Status :%d", Status);
+				pr_info("Flash 2x read err with Status :%d\n",
+					Status);
 				break;
 			}
 
@@ -1921,7 +1935,8 @@ cntrlEnd:
 
 			Status = copy_to_user(OutPutBuff, pReadBuff, ReadBytes);
 			if (Status) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Copy to use failed with status :%d", Status);
+				pr_info("Copy to use failed with status :%d\n",
+					Status);
 				up(&Adapter->NVMRdmWrmLock);
 				kfree(pReadBuff);
 				return -EFAULT;
diff --git a/drivers/staging/bcm/CmHost.c b/drivers/staging/bcm/CmHost.c
index c0ee95a..0fed26c 100644
--- a/drivers/staging/bcm/CmHost.c
+++ b/drivers/staging/bcm/CmHost.c
@@ -5,6 +5,8 @@
 ************************************************************/
 
 //#define CONN_MSG
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 typedef enum _E_CLASSIFIER_ACTION
@@ -268,7 +270,7 @@ void ClearTargetDSXBuffer(PMINI_ADAPTER Adapter,B_UINT16 TID,BOOLEAN bFreeAll)
 		if(Adapter->astTargetDsxBuffer[ulIndex].valid)
 			continue;
         if ((bFreeAll) || (Adapter->astTargetDsxBuffer[ulIndex].tid == TID)){
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "ClearTargetDSXBuffer: found tid %d buffer cleared %lx\n",
+			pr_info("ClearTargetDSXBuffer: found tid %d buffer cleared %lx\n",
 				TID, Adapter->astTargetDsxBuffer[ulIndex].ulTargetDsxBuffer);
 			Adapter->astTargetDsxBuffer[ulIndex].valid=1;
 			Adapter->astTargetDsxBuffer[ulIndex].tid=0;
@@ -1931,7 +1933,8 @@ static ULONG GetNextTargetBufferLocation(PMINI_ADAPTER Adapter,B_UINT16 tid)
 
 	if(ulMaxTry==0)
 	{
-		BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "\n GetNextTargetBufferLocation : Error No Free Target DSX Buffers FreeCnt : %lx ",Adapter->ulFreeTargetBufferCnt);
+		pr_info(" GetNextTargetBufferLocation : Error No Free Target DSX Buffers FreeCnt : %lx\n",
+			Adapter->ulFreeTargetBufferCnt);
 		ClearTargetDSXBuffer(Adapter,tid,FALSE);
 		return 0;
 	}
@@ -1947,7 +1950,7 @@ static ULONG GetNextTargetBufferLocation(PMINI_ADAPTER Adapter,B_UINT16 tid)
 	ulTargetDsxBufferIndexToUse =
 		(ulTargetDsxBufferIndexToUse+1)%Adapter->ulTotalTargetBuffersAvailable;
 	Adapter->ulCurrentTargetBuffer = ulTargetDsxBufferIndexToUse;
-	BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "GetNextTargetBufferLocation :Returning address %lx tid %d\n",
+	pr_info("GetNextTargetBufferLocation :Returning address %lx tid %d\n",
 		ulTargetDSXBufferAddress,tid);
 	return ulTargetDSXBufferAddress;
 }
@@ -1993,7 +1996,7 @@ BOOLEAN CmControlResponseMessage(PMINI_ADAPTER Adapter,  /**<Pointer to the Adap
 			== NULL)
 	{
 		ClearTargetDSXBuffer(Adapter,((stLocalSFAddIndication *)pvBuffer)->u16TID, FALSE);
-		BCM_DEBUG_PRINT( Adapter,DBG_TYPE_PRINTK, 0, 0, "Error in restoring Service Flow param structure from DSx message");
+		pr_info("Error in restoring Service Flow param structure from DSx message\n");
 		return FALSE;
 	}
 
@@ -2005,7 +2008,7 @@ BOOLEAN CmControlResponseMessage(PMINI_ADAPTER Adapter,  /**<Pointer to the Adap
 	pLeader->Vcid = 0;
 
 	ClearTargetDSXBuffer(Adapter,pstAddIndication->u16TID,FALSE);
-    BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "### TID RECEIVED %d\n",pstAddIndication->u16TID);
+	pr_info("### TID RECEIVED %d\n", pstAddIndication->u16TID);
 	switch(pstAddIndication->u8Type)
 	{
 		case DSA_REQ:
@@ -2082,7 +2085,7 @@ BOOLEAN CmControlResponseMessage(PMINI_ADAPTER Adapter,  /**<Pointer to the Adap
 
 				if(!psfLocalSet)
 				{
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "No set is valid\n");
+					pr_info("No set is valid\n");
 					Adapter->PackInfo[uiSearchRuleIndex].bActive=FALSE;
                     Adapter->PackInfo[uiSearchRuleIndex].bValid=FALSE;
 					Adapter->PackInfo[uiSearchRuleIndex].usVCID_Value=0;
@@ -2139,7 +2142,7 @@ BOOLEAN CmControlResponseMessage(PMINI_ADAPTER Adapter,  /**<Pointer to the Adap
 			}
 			else
 			{
-				BCM_DEBUG_PRINT( Adapter,DBG_TYPE_PRINTK, 0, 0, "DSA ACK did not get valid SFID");
+				pr_info("DSA ACK did not get valid SFID\n");
 				kfree(pstAddIndication);
 				return FALSE;
 			}
@@ -2174,7 +2177,7 @@ BOOLEAN CmControlResponseMessage(PMINI_ADAPTER Adapter,  /**<Pointer to the Adap
 			uiSearchRuleIndex=SearchSfid(Adapter,ntohl(pstChangeIndication->sfActiveSet.u32SFID));
 			if(uiSearchRuleIndex > NO_OF_QUEUES-1)
 			{
-				BCM_DEBUG_PRINT( Adapter,DBG_TYPE_PRINTK, 0, 0, "SF doesn't exist for which DSC_ACK is received");
+				pr_info("SF doesn't exist for which DSC_ACK is received\n");
 			}
 			if((uiSearchRuleIndex < NO_OF_QUEUES))
 			{
@@ -2215,9 +2218,11 @@ BOOLEAN CmControlResponseMessage(PMINI_ADAPTER Adapter,  /**<Pointer to the Adap
 				{
 					Adapter->PackInfo[uiSearchRuleIndex].usVCID_Value =
 						ntohs(pstChangeIndication->u16VCID);
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "CC field is %d bvalid = %d\n",
-							pstChangeIndication->u8CC, psfLocalSet->bValid);
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "VCID= %d\n", ntohs(pstChangeIndication->u16VCID));
+					pr_info("CC field is %d bvalid = %d\n",
+						pstChangeIndication->u8CC,
+						psfLocalSet->bValid);
+					pr_info("VCID= %d\n",
+						ntohs(pstChangeIndication->u16VCID));
 					Adapter->PackInfo[uiSearchRuleIndex].usCID =
 						ntohs(pstChangeIndication->u16CID);
 					CopyToAdapter(Adapter,psfLocalSet,uiSearchRuleIndex,
@@ -2233,7 +2238,7 @@ BOOLEAN CmControlResponseMessage(PMINI_ADAPTER Adapter,  /**<Pointer to the Adap
 			}
 			else
 			{
-				BCM_DEBUG_PRINT( Adapter,DBG_TYPE_PRINTK, 0, 0, "DSC ACK did not get valid SFID");
+				pr_info("DSC ACK did not get valid SFID\n");
 				kfree(pstAddIndication);
 				return FALSE;
 			}
@@ -2292,7 +2297,8 @@ int get_dsx_sf_data_to_application(PMINI_ADAPTER Adapter, UINT uiSFId, void __us
 	if(psSfInfo->pstSFIndication && copy_to_user(user_buffer,
 		psSfInfo->pstSFIndication, sizeof(stLocalSFAddIndicationAlt)))
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "copy to user failed SFID %d, present in queue !!!", uiSFId );
+		pr_info("copy to user failed SFID %d, present in queue !!!\n",
+			uiSFId);
 		status = -EFAULT;
 		return status;
 	}
diff --git a/drivers/staging/bcm/DDRInit.c b/drivers/staging/bcm/DDRInit.c
index 1c7db81..2885939 100644
--- a/drivers/staging/bcm/DDRInit.c
+++ b/drivers/staging/bcm/DDRInit.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 
@@ -972,7 +974,7 @@ int ddr_init(MINI_ADAPTER *Adapter)
 		}
 		retval = wrmalt(Adapter, psDDRSetting->ulRegAddress, &value, sizeof(value));
 		if(STATUS_SUCCESS != retval) {
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"%s:%d\n", __FUNCTION__, __LINE__);
+			pr_info("%s:%d\n", __func__, __LINE__);
 			break;
 		}
 
@@ -1042,7 +1044,8 @@ int ddr_init(MINI_ADAPTER *Adapter)
 			}
 			retval = rdmalt(Adapter,(UINT)0x0f000c00, &uiResetValue, sizeof(uiResetValue));
 			if(retval < 0) {
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, RDM, DBG_LVL_ALL, "%s:%d RDM failed\n", __FUNCTION__, __LINE__);
+				pr_info("%s:%d RDM failed\n",
+					__func__, __LINE__);
 				return retval;
 			}
 			retval = rdmalt(Adapter,(UINT)0x0f000c00, &uiResetValue, sizeof(uiResetValue));
@@ -1235,7 +1238,7 @@ int download_ddr_settings(PMINI_ADAPTER Adapter)
 	retval = wrmalt(Adapter, ul_ddr_setting_load_addr, &value, sizeof(value));
 	if(retval)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"%s:%d\n", __FUNCTION__, __LINE__);
+		pr_info("%s:%d\n", __func__, __LINE__);
 
 		return retval;
 	}
@@ -1245,7 +1248,7 @@ int download_ddr_settings(PMINI_ADAPTER Adapter)
 	retval = wrmalt(Adapter, ul_ddr_setting_load_addr, &value, sizeof(value));
 	if(retval)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"%s:%d\n", __FUNCTION__, __LINE__);
+		pr_info("%s:%d\n", __func__, __LINE__);
 		return retval;
 	}
 
@@ -1264,7 +1267,7 @@ int download_ddr_settings(PMINI_ADAPTER Adapter)
 				value = (psDDRSetting->ulRegValue |(1<<8));
 				if(STATUS_SUCCESS != wrmalt(Adapter, ul_ddr_setting_load_addr,
 						&value, sizeof(value))){
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"%s:%d\n", __FUNCTION__, __LINE__);
+					pr_info("%s:%d\n", __func__, __LINE__);
 					break;
 				}
 			}
@@ -1274,7 +1277,7 @@ int download_ddr_settings(PMINI_ADAPTER Adapter)
 
 				if(STATUS_SUCCESS != wrmalt(Adapter, ul_ddr_setting_load_addr ,
 							&value, sizeof(value))){
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"%s:%d\n", __FUNCTION__, __LINE__);
+					pr_info("%s:%d\n", __func__, __LINE__);
 					break;
 				}
 			}
diff --git a/drivers/staging/bcm/Debug.h b/drivers/staging/bcm/Debug.h
index 420382d..763e377 100644
--- a/drivers/staging/bcm/Debug.h
+++ b/drivers/staging/bcm/Debug.h
@@ -215,20 +215,20 @@ typedef struct _S_BCM_DEBUG_STATE {
 //--- Only for direct printk's; "hidden" to API.
 #define DBG_TYPE_PRINTK		3
 
-#define BCM_DEBUG_PRINT(Adapter, Type, SubType, dbg_level, string, args...) \
-	do {								\
-		if (DBG_TYPE_PRINTK == Type)				\
-			pr_info("%s:" string, __func__, ##args);	\
-		else if (Adapter &&					\
-			 (dbg_level & DBG_LVL_BITMASK) <= Adapter->stDebugState.debug_level && \
-			 (Type & Adapter->stDebugState.type) &&		\
-			 (SubType & Adapter->stDebugState.subtype[Type])) { \
-			if (dbg_level & DBG_NO_FUNC_PRINT)		\
-				printk(KERN_DEBUG string, ##args);	\
-			else						\
-				printk(KERN_DEBUG "%s:" string, __func__, ##args);	\
-		}							\
-	} while (0)
+#define BCM_DEBUG_PRINT(Adapter, Type, SubType, dbg_level, fmt, ...)	\
+do {									\
+	if (Adapter &&							\
+	    ((dbg_level & DBG_LVL_BITMASK) <=				\
+	     Adapter->stDebugState.debug_level) &&			\
+	    (Type & Adapter->stDebugState.type) &&			\
+	    (SubType & Adapter->stDebugState.subtype[Type])) {		\
+		if (dbg_level & DBG_NO_FUNC_PRINT)			\
+			printk(KERN_DEBUG fmt, ##__VA_ARGS__);		\
+		else							\
+			printk(KERN_DEBUG "%s:" fmt,			\
+			       __func__, ##__VA_ARGS__);		\
+	}								\
+} while (0)
 
 #define BCM_DEBUG_PRINT_BUFFER(Adapter, Type, SubType, dbg_level,  buffer, bufferlen) do { \
 	if (DBG_TYPE_PRINTK == Type ||					\
@@ -243,16 +243,19 @@ typedef struct _S_BCM_DEBUG_STATE {
 } while(0)
 
 
-#define BCM_SHOW_DEBUG_BITMAP(Adapter)	do { \
-	int i;									\
-	for (i=0; i<(NUMTYPES*2)+1; i++) {		\
-		if ((i == 1) || (i == 2) || (i == 4) || (i == 8)) {		\
-		/* CAUTION! Forcefully turn on ALL debug paths and subpaths!	\
-		Adapter->stDebugState.subtype[i] = 0xffffffff;	*/ \
-		BCM_DEBUG_PRINT (Adapter, DBG_TYPE_PRINTK, 0, 0, "subtype[%d] = 0x%08x\n", 	\
-		i, Adapter->stDebugState.subtype[i]);	\
-		}	\
-	}		\
+#define BCM_SHOW_DEBUG_BITMAP(Adapter)					\
+do {									\
+	int i;								\
+	for (i = 0; i < (NUMTYPES * 2) + 1; i++) {			\
+		if ((i == 1) || (i == 2) || (i == 4) || (i == 8)) {	\
+	/* CAUTION! Forcefully turn on ALL debug paths and subpaths! */	\
+			/*						\
+			 *Adapter->stDebugState.subtype[i] = 0xffffffff; \
+			 */						\
+			pr_info("subtype[%d] = 0x%08x\n",		\
+				i, Adapter->stDebugState.subtype[i]);	\
+		}							\
+	}								\
 } while (0)
 
 #endif
diff --git a/drivers/staging/bcm/InterfaceDld.c b/drivers/staging/bcm/InterfaceDld.c
index 65c352f..3bc2adb 100644
--- a/drivers/staging/bcm/InterfaceDld.c
+++ b/drivers/staging/bcm/InterfaceDld.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 int InterfaceFileDownload(PVOID arg, struct file *flp, unsigned int on_chip_loc)
@@ -40,9 +42,7 @@ int InterfaceFileDownload(PVOID arg, struct file *flp, unsigned int on_chip_loc)
 		 */
 		errno = InterfaceWRM(psIntfAdapter, on_chip_loc, buff, len);
 		if (errno) {
-			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,
-					DBG_TYPE_PRINTK, 0, 0,
-					"WRM Failed! status: %d", errno);
+			pr_info("WRM Failed! status: %d\n", errno);
 			break;
 		}
 		on_chip_loc += MAX_TRANSFER_CTRL_BYTE_USB;
diff --git a/drivers/staging/bcm/InterfaceIdleMode.c b/drivers/staging/bcm/InterfaceIdleMode.c
index faeb03e..f4c415f 100644
--- a/drivers/staging/bcm/InterfaceIdleMode.c
+++ b/drivers/staging/bcm/InterfaceIdleMode.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 /*
@@ -60,7 +62,7 @@ int InterfaceIdleModeRespond(PMINI_ADAPTER Adapter, unsigned int* puiBuffer)
 			status = wrmalt (Adapter,SW_ABORT_IDLEMODE_LOC, &uiRegRead, sizeof(uiRegRead));
 			if(status)
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "wrm failed while clearing Idle Mode Reg");
+				pr_info("wrm failed while clearing Idle Mode Reg\n");
 				return status;
 			}
 
@@ -70,7 +72,7 @@ int InterfaceIdleModeRespond(PMINI_ADAPTER Adapter, unsigned int* puiBuffer)
 				status = wrmalt (Adapter,DEBUG_INTERRUPT_GENERATOR_REGISTOR, &uiRegRead, sizeof(uiRegRead));
 				if(status)
 				{
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "wrm failed while clearing Idle Mode	Reg");
+					pr_info("wrm failed while clearing Idle Mode	Reg\n");
 					return status;
 				}
 			}
@@ -81,14 +83,14 @@ int InterfaceIdleModeRespond(PMINI_ADAPTER Adapter, unsigned int* puiBuffer)
 				bytes = rdmalt(Adapter, DEVICE_INT_OUT_EP_REG0, &uiRegRead, sizeof(uiRegRead));
 				if (bytes < 0) {
 					status = bytes;
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "rdm failed while clearing H/W Abort Reg0");
+					pr_info("rdm failed while clearing H/W Abort Reg0\n");
 					return status;
 				}
 				//clear on read Register
 				bytes = rdmalt(Adapter, DEVICE_INT_OUT_EP_REG1, &uiRegRead, sizeof(uiRegRead));
 				if (bytes < 0) {
 					status = bytes;
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "rdm failed while clearing H/W Abort	Reg1");
+					pr_info("rdm failed while clearing H/W Abort	Reg1\n");
 					return status;
 				}
 			}
@@ -131,7 +133,7 @@ int InterfaceIdleModeRespond(PMINI_ADAPTER Adapter, unsigned int* puiBuffer)
 				status = wrmalt (Adapter,HPM_CONFIG_MSW, &uiRegRead, sizeof(uiRegRead));
 				if(status)
 				{
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "wrm failed while clearing Idle Mode Reg\n");
+					pr_info("wrm failed while clearing Idle Mode Reg\n");
 					return status;
 				}
 
@@ -240,7 +242,7 @@ static int InterfaceAbortIdlemode(PMINI_ADAPTER Adapter, unsigned int Pattern)
 		status = wrmalt(Adapter,SW_ABORT_IDLEMODE_LOC, &Pattern, sizeof(status));
 		if(status)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"WRM to Register SW_ABORT_IDLEMODE_LOC failed..");
+			pr_info("WRM to Register SW_ABORT_IDLEMODE_LOC failed..\n");
 			return status;
 		}
 	}
@@ -276,7 +278,8 @@ void InterfaceHandleShutdownModeWakeup(PMINI_ADAPTER Adapter)
 		Status =wrmalt(Adapter,DEBUG_INTERRUPT_GENERATOR_REGISTOR, &uiRegVal, sizeof(uiRegVal));
 		if(Status)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"WRM to DEBUG_INTERRUPT_GENERATOR_REGISTOR Failed with err :%d", Status);
+			pr_info("WRM to DEBUG_INTERRUPT_GENERATOR_REGISTOR Failed with err :%d\n",
+				Status);
 			return;
 		}
 	}
@@ -288,14 +291,16 @@ void InterfaceHandleShutdownModeWakeup(PMINI_ADAPTER Adapter)
 		bytes = rdmalt(Adapter,DEVICE_INT_OUT_EP_REG0, &uiRegVal, sizeof(uiRegVal));
 		if (bytes < 0) {
 			Status = bytes;
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"RDM of DEVICE_INT_OUT_EP_REG0 failed with Err :%d", Status);
+			pr_info("RDM of DEVICE_INT_OUT_EP_REG0 failed with Err :%d\n",
+				Status);
 			return;
 		}
 
 		bytes = rdmalt(Adapter,DEVICE_INT_OUT_EP_REG1, &uiRegVal, sizeof(uiRegVal));
 		if (bytes < 0) {
 			Status = bytes;
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"RDM of DEVICE_INT_OUT_EP_REG1 failed with Err :%d", Status);
+			pr_info("RDM of DEVICE_INT_OUT_EP_REG1 failed with Err :%d\n",
+				Status);
 			return;
 		}
 	}
diff --git a/drivers/staging/bcm/InterfaceInit.c b/drivers/staging/bcm/InterfaceInit.c
index 8e3c586..d3eeedf 100644
--- a/drivers/staging/bcm/InterfaceInit.c
+++ b/drivers/staging/bcm/InterfaceInit.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 static struct usb_device_id InterfaceUsbtable[] = {
@@ -283,8 +285,7 @@ static int AllocUsbCb(PS_INTERFACE_ADAPTER psIntfAdapter)
 		psIntfAdapter->asUsbTcb[i].urb = usb_alloc_urb(0, GFP_KERNEL);
 
 		if (psIntfAdapter->asUsbTcb[i].urb == NULL) {
-			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0,
-				"Can't allocate Tx urb for index %d\n", i);
+			pr_info("Can't allocate Tx urb for index %d\n", i);
 			return -ENOMEM;
 		}
 	}
@@ -293,16 +294,14 @@ static int AllocUsbCb(PS_INTERFACE_ADAPTER psIntfAdapter)
 		psIntfAdapter->asUsbRcb[i].urb = usb_alloc_urb(0, GFP_KERNEL);
 
 		if (psIntfAdapter->asUsbRcb[i].urb == NULL) {
-			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0,
-				"Can't allocate Rx urb for index %d\n", i);
+			pr_info("Can't allocate Rx urb for index %d\n", i);
 			return -ENOMEM;
 		}
 
 		psIntfAdapter->asUsbRcb[i].urb->transfer_buffer = kmalloc(MAX_DATA_BUFFER_SIZE, GFP_KERNEL);
 
 		if (psIntfAdapter->asUsbRcb[i].urb->transfer_buffer == NULL) {
-			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0,
-				"Can't allocate Rx buffer for index %d\n", i);
+			pr_info("Can't allocate Rx buffer for index %d\n", i);
 			return -ENOMEM;
 		}
 		psIntfAdapter->asUsbRcb[i].urb->transfer_buffer_length = MAX_DATA_BUFFER_SIZE;
@@ -443,7 +442,7 @@ static int InterfaceAdapterInit(PS_INTERFACE_ADAPTER psIntfAdapter)
 			(u32 *)&(psIntfAdapter->psAdapter->chip_id), sizeof(u32));
 	if (bytes < 0) {
 		retval = bytes;
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0, "CHIP ID Read Failed\n");
+		pr_info("CHIP ID Read Failed\n");
 		return retval;
 	}
 
@@ -604,8 +603,7 @@ static int InterfaceAdapterInit(PS_INTERFACE_ADAPTER psIntfAdapter)
 	retval = CreateInterruptUrb(psIntfAdapter);
 
 	if (retval) {
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0,
-			"Cannot create interrupt urb\n");
+		pr_info("Cannot create interrupt urb\n");
 		return retval;
 	}
 
diff --git a/drivers/staging/bcm/InterfaceMisc.c b/drivers/staging/bcm/InterfaceMisc.c
index 2218fae..8f96308 100644
--- a/drivers/staging/bcm/InterfaceMisc.c
+++ b/drivers/staging/bcm/InterfaceMisc.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 INT InterfaceRDM(PS_INTERFACE_ADAPTER psIntfAdapter,
@@ -9,12 +11,12 @@ INT InterfaceRDM(PS_INTERFACE_ADAPTER psIntfAdapter,
 	USHORT usRetries = 0;
 
 	if (psIntfAdapter == NULL) {
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0, "Interface Adapter is NULL");
+		pr_info("Interface Adapter is NULL\n");
 		return -EINVAL;
 	}
 
 	if (psIntfAdapter->psAdapter->device_removed == TRUE) {
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0, "Device got removed");
+		pr_info("Device got removed\n");
 		return -ENODEV;
 	}
 
@@ -66,12 +68,12 @@ INT InterfaceWRM(PS_INTERFACE_ADAPTER psIntfAdapter,
 	USHORT usRetries = 0;
 
 	if (psIntfAdapter == NULL) {
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0, "Interface Adapter  is NULL");
+		pr_info("Interface Adapter  is NULL\n");
 		return -EINVAL;
 	}
 
 	if (psIntfAdapter->psAdapter->device_removed == TRUE) {
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter, DBG_TYPE_PRINTK, 0, 0, "Device got removed");
+		pr_info("Device got removed\n");
 		return -ENODEV;
 	}
 
diff --git a/drivers/staging/bcm/InterfaceRx.c b/drivers/staging/bcm/InterfaceRx.c
index d495828..7e6afa0 100644
--- a/drivers/staging/bcm/InterfaceRx.c
+++ b/drivers/staging/bcm/InterfaceRx.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 static int SearchVcid(PMINI_ADAPTER Adapter,unsigned short usVcid)
@@ -115,7 +117,7 @@ static void read_bulk_callback(struct urb *urb)
 	skb = dev_alloc_skb (pLeader->PLength + SKB_RESERVE_PHS_BYTES + SKB_RESERVE_ETHERNET_HEADER);//2   //2 for allignment
 	if(!skb)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "NO SKBUFF!!! Dropping the Packet");
+		pr_info("NO SKBUFF!!! Dropping the Packet\n");
 		atomic_dec(&psIntfAdapter->uNumRcbUsed);
 		return;
 	}
@@ -252,7 +254,7 @@ BOOLEAN InterfaceRx (PS_INTERFACE_ADAPTER psIntfAdapter)
 		pRcb = GetBulkInRcb(psIntfAdapter);
 		if(pRcb == NULL)
 		{
-			BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_PRINTK, 0, 0, "Unable to get Rcb pointer");
+			pr_info("Unable to get Rcb pointer\n");
 			return FALSE;
 		}
 		//atomic_inc(&psIntfAdapter->uNumRcbUsed);
diff --git a/drivers/staging/bcm/InterfaceTx.c b/drivers/staging/bcm/InterfaceTx.c
index a842de9..dc315b0 100644
--- a/drivers/staging/bcm/InterfaceTx.c
+++ b/drivers/staging/bcm/InterfaceTx.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 /*this is transmit call-back(BULK OUT)*/
@@ -138,7 +140,7 @@ static int TransmitTcb(PS_INTERFACE_ADAPTER psIntfAdapter, PUSB_TCB pTcb, PVOID
  						GFP_ATOMIC, &urb->transfer_dma);
 	if (!urb->transfer_buffer)
 	{
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_PRINTK, 0, 0, "Error allocating memory\n");
+		pr_info("Error allocating memory\n");
 		return  -ENOMEM;
 	}
 	memcpy(urb->transfer_buffer, data, len);
@@ -188,7 +190,7 @@ int InterfaceTransmitPacket(PVOID arg, PVOID data, UINT len)
 	pTcb= GetBulkOutTcb(psIntfAdapter);
 	if(pTcb == NULL)
 	{
-		BCM_DEBUG_PRINT(psIntfAdapter->psAdapter,DBG_TYPE_PRINTK, 0, 0, "No URB to transmit packet, dropping packet");
+		pr_info("No URB to transmit packet, dropping packet\n");
 		return -EFAULT;
 	}
 	return TransmitTcb(psIntfAdapter, pTcb, data, len);
diff --git a/drivers/staging/bcm/Misc.c b/drivers/staging/bcm/Misc.c
index c7725e1..709ba00 100644
--- a/drivers/staging/bcm/Misc.c
+++ b/drivers/staging/bcm/Misc.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 static int BcmFileDownload(PMINI_ADAPTER Adapter, const char *path, unsigned int loc);
@@ -291,7 +293,7 @@ INT CopyBufferToControlPacket(PMINI_ADAPTER Adapter, PVOID ioBuffer)
 	}
 
 	if (TRUE == Adapter->IdleMode) {
-		/* BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Device is in Idle mode ... hence\n"); */
+		/* pr_info("Device is in Idle mode ... hence\n"); */
 		if (pLeader->Status == LINK_UP_CONTROL_REQ || pLeader->Status == 0x80 ||
 			pLeader->Status == CM_CONTROL_NEWDSX_MULTICLASSIFIER_REQ) {
 
@@ -513,7 +515,7 @@ VOID LinkControlResponseMessage(PMINI_ADAPTER Adapter, PUCHAR pucBuffer)
 	if (*pucBuffer == LINK_UP_ACK) {
 		switch (*(pucBuffer+1)) {
 		case PHY_SYNC_ACHIVED: /* SYNCed UP */
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "PHY_SYNC_ACHIVED");
+			pr_info("PHY_SYNC_ACHIVED\n");
 
 				if (Adapter->LinkStatus == LINKUP_DONE)
 					beceem_protocol_reset(Adapter);
@@ -534,7 +536,8 @@ VOID LinkControlResponseMessage(PMINI_ADAPTER Adapter, PUCHAR pucBuffer)
 			Adapter->LinkStatus = LINKUP_DONE;
 			Adapter->bPHSEnabled = *(pucBuffer+3);
 			Adapter->bETHCSEnabled = *(pucBuffer+4) & ETH_CS_MASK;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "PHS Support Status Received In LinkUp Ack : %x\n", Adapter->bPHSEnabled);
+			pr_info("PHS Support Status Received In LinkUp Ack : %x\n",
+				Adapter->bPHSEnabled);
 
 			if ((FALSE == Adapter->bShutStatus) && (FALSE == Adapter->IdleMode)) {
 				if (Adapter->LEDInfo.led_thread_running & BCM_LED_THREAD_RUNNING_ACTIVELY) {
@@ -566,7 +569,8 @@ VOID LinkControlResponseMessage(PMINI_ADAPTER Adapter, PUCHAR pucBuffer)
 		}
 		break;
 		default:
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "default case:LinkResponse %x", *(pucBuffer + 1));
+			pr_info("default case:LinkResponse %x\n",
+				*(pucBuffer + 1));
 			break;
 		}
 	} else if (SET_MAC_ADDRESS_RESPONSE == *pucBuffer) {
@@ -662,7 +666,7 @@ void SendIdleModeResponse(PMINI_ADAPTER Adapter)
 
 	status = CopyBufferToControlPacket(Adapter, &stIdleResponse);
 	if ((status != STATUS_SUCCESS)) {
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "fail to send the Idle mode Request\n");
+		pr_info("fail to send the Idle mode Request\n");
 		Adapter->bPreparingForLowPowerMode = FALSE;
 		StartInterruptUrb((PS_INTERFACE_ADAPTER)(Adapter->pvInterfaceAdapter));
 	}
@@ -835,12 +839,12 @@ int reset_card_proc(PMINI_ADAPTER ps_adapter)
 	Bcm_kill_all_URBs(psIntfAdapter);
 	/* Reset the UMA-B Device */
 	if (ps_adapter->chip_id >= T3LPB) {
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Reseting UMA-B\n");
+		pr_info("Reseting UMA-B\n");
 		retval = usb_reset_device(psIntfAdapter->udev);
 		psIntfAdapter->psAdapter->StopAllXaction = FALSE;
 
 		if (retval != STATUS_SUCCESS) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Reset failed with ret value :%d", retval);
+			pr_info("Reset failed with ret value :%d\n", retval);
 			goto err_exit;
 		}
 
@@ -852,14 +856,16 @@ int reset_card_proc(PMINI_ADAPTER ps_adapter)
 			bytes = rdmalt(ps_adapter, HPM_CONFIG_LDO145, &value, sizeof(value));
 			if (bytes < 0) {
 				retval = bytes;
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "read failed with status :%d", retval);
+				pr_info("read failed with status :%d\n",
+					retval);
 				goto err_exit;
 			}
 			/* setting 0th bit */
 			value |= (1<<0);
 			retval = wrmalt(ps_adapter, HPM_CONFIG_LDO145, &value, sizeof(value));
 			if (retval < 0) {
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "write failed with status :%d", retval);
+				pr_info("write failed with status :%d\n",
+					retval);
 				goto err_exit;
 			}
 		}
@@ -867,13 +873,13 @@ int reset_card_proc(PMINI_ADAPTER ps_adapter)
 		bytes = rdmalt(ps_adapter, 0x0f007018, &value, sizeof(value));
 		if (bytes < 0) {
 			retval = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "read failed with status :%d", retval);
+			pr_info("read failed with status :%d\n", retval);
 			goto err_exit;
 		}
 		value &= (~(1<<16));
 		retval = wrmalt(ps_adapter, 0x0f007018, &value, sizeof(value));
 		if (retval < 0) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "write failed with status :%d", retval);
+			pr_info("write failed with status :%d\n", retval);
 			goto err_exit;
 		}
 
@@ -881,13 +887,13 @@ int reset_card_proc(PMINI_ADAPTER ps_adapter)
 		value = 0;
 		retval = wrmalt(ps_adapter, GPIO_OUTPUT_REGISTER, &value, sizeof(value));
 		if (retval < 0) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "write failed with status :%d", retval);
+			pr_info("write failed with status :%d\n", retval);
 			goto err_exit;
 		}
 		value = 0x300;
 		retval = wrmalt(ps_adapter, GPIO_MODE_REGISTER, &value, sizeof(value));
 		if (retval < 0) {
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "write failed with status :%d", retval);
+			pr_info("write failed with status :%d\n", retval);
 			goto err_exit;
 		}
 		mdelay(50);
@@ -1026,7 +1032,7 @@ int InitCardAndDownloadFirmware(PMINI_ADAPTER ps_adapter)
 
 	status = InitLedSettings(ps_adapter);
 	if (status) {
-		BCM_DEBUG_PRINT(ps_adapter, DBG_TYPE_PRINTK, 0, 0, "INIT LED FAILED\n");
+		pr_info("INIT LED FAILED\n");
 		return status;
 	}
 
@@ -1226,14 +1232,14 @@ static unsigned char *ReadMacAddrEEPROM(PMINI_ADAPTER Adapter, ulong dwAddress)
 	int bytes;
 
 	if (!pucmacaddr) {
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "No Buffers to Read the EEPROM Address\n");
+		pr_info("No Buffers to Read the EEPROM Address\n");
 		return NULL;
 	}
 
 	dwAddress |= 0x5b000000;
 	status = wrmalt(Adapter, EEPROM_COMMAND_Q_REG, (PUINT)&dwAddress, sizeof(UINT));
 	if (status != STATUS_SUCCESS) {
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "wrm Failed..\n");
+		pr_info("wrm Failed..\n");
 		kfree(pucmacaddr);
 		pucmacaddr = NULL;
 		goto OUT;
@@ -1243,7 +1249,7 @@ static unsigned char *ReadMacAddrEEPROM(PMINI_ADAPTER Adapter, ulong dwAddress)
 		bytes = rdmalt(Adapter, EEPROM_READ_DATA_Q_REG, &temp, sizeof(temp));
 		if (bytes < 0) {
 			status = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "rdm Failed..\n");
+			pr_info("rdm Failed..\n");
 			kfree(pucmacaddr);
 			pucmacaddr = NULL;
 			goto OUT;
@@ -1591,7 +1597,7 @@ void update_per_sf_desc_cnts(PMINI_ADAPTER Adapter)
 
 	bytes = rdmaltWithLock(Adapter, TARGET_SFID_TXDESC_MAP_LOC, (PUINT)uibuff, sizeof(UINT) * MAX_TARGET_DSX_BUFFERS);
 	if (bytes < 0) {
-		BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "rdm failed\n");
+		pr_info("rdm failed\n");
 		return;
 	}
 
@@ -1600,7 +1606,8 @@ void update_per_sf_desc_cnts(PMINI_ADAPTER Adapter)
 			if (Adapter->PackInfo[iIndex].usVCID_Value < MAX_TARGET_DSX_BUFFERS)
 				atomic_set(&Adapter->PackInfo[iIndex].uiPerSFTxResourceCount, uibuff[Adapter->PackInfo[iIndex].usVCID_Value]);
 			else
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Invalid VCID : %x\n", Adapter->PackInfo[iIndex].usVCID_Value);
+				pr_info("Invalid VCID : %x\n",
+					Adapter->PackInfo[iIndex].usVCID_Value);
 		}
 	}
 	atomic_set(&Adapter->uiMBupdate, FALSE);
diff --git a/drivers/staging/bcm/PHSModule.c b/drivers/staging/bcm/PHSModule.c
index 4aa2b71..34eb5ab 100644
--- a/drivers/staging/bcm/PHSModule.c
+++ b/drivers/staging/bcm/PHSModule.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 static UINT CreateSFToClassifierRuleMapping(B_UINT16 uiVcid,B_UINT16  uiClsId,S_SERVICEFLOW_TABLE *psServiceFlowTable,S_PHS_RULE *psPhsRule,B_UINT8 u8AssociatedPHSI);
@@ -183,7 +185,7 @@ int PHSTransmit(PMINI_ADAPTER Adapter,
 					{
 						if(skb_cow(Packet, 1))
 						{
-							BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "SKB Cow Failed\n");
+							pr_info("SKB Cow Failed\n");
 							return STATUS_FAILURE;
 						}
 					}
@@ -257,7 +259,7 @@ int PHSReceive(PMINI_ADAPTER Adapter,
 			{
 				if(skb_cow(packet, skb_headroom(packet) + TotalBytesAdded))
 				{
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "cow failed in receive\n");
+					pr_info("cow failed in receive\n");
 					return STATUS_FAILURE;
 				}
 
diff --git a/drivers/staging/bcm/nvm.c b/drivers/staging/bcm/nvm.c
index 7d703cb..6ca3ce0 100644
--- a/drivers/staging/bcm/nvm.c
+++ b/drivers/staging/bcm/nvm.c
@@ -1,3 +1,5 @@
+#define pr_fmt(fmt) KBUILD_MODNAME ": " fmt
+
 #include "headers.h"
 
 #define DWORD unsigned int
@@ -81,7 +83,7 @@ static UCHAR ReadEEPROMStatusRegister( PMINI_ADAPTER Adapter )
 		rdmalt(Adapter, EEPROM_SPI_Q_STATUS1_REG, &uiStatus, sizeof(uiStatus));
 		if(Adapter->device_removed == TRUE)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Modem has got removed hence exiting....");
+			pr_info("Modem has got removed hence exiting....\n");
 			break;
 		}
 
@@ -104,7 +106,9 @@ static UCHAR ReadEEPROMStatusRegister( PMINI_ADAPTER Adapter )
 		{
 			 rdmalt(Adapter, EEPROM_SPI_Q_STATUS1_REG, &value, sizeof(value));
 			 rdmalt(Adapter, EEPROM_SPI_Q_STATUS_REG, &value1, sizeof(value1));
-			 BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"0x3004 = %x 0x3008 = %x, retries = %d failed.\n",value,value1,  MAX_EEPROM_RETRIES*RETRIES_PER_DELAY);
+			 pr_info("0x3004 = %x 0x3008 = %x, retries = %d failed\n",
+				 value, value1,
+				 MAX_EEPROM_RETRIES * RETRIES_PER_DELAY);
 			return uiData;
 		}
 		if( !(dwRetries%RETRIES_PER_DELAY) )
@@ -161,7 +165,7 @@ INT ReadBeceemEEPROMBulk( PMINI_ADAPTER Adapter,
 		rdmalt(Adapter, EEPROM_SPI_Q_STATUS1_REG, &uiStatus, sizeof(uiStatus));
 		if(Adapter->device_removed == TRUE)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Modem has got Removed.hence exiting from loop...");
+			pr_info("Modem has got Removed.hence exiting from loop...\n");
 			return -ENODEV;
 		}
 
@@ -204,7 +208,9 @@ INT ReadBeceemEEPROMBulk( PMINI_ADAPTER Adapter,
 			value1=0;
 			rdmalt(Adapter, EEPROM_SPI_Q_STATUS1_REG, &value, sizeof(value));
 			rdmalt(Adapter, EEPROM_SPI_Q_STATUS_REG, &value1, sizeof(value1));
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "dwNumWords %d 0x3004 = %x 0x3008 = %x  retries = %d failed.\n", dwNumWords, value,  value1,  MAX_EEPROM_RETRIES*RETRIES_PER_DELAY);
+			pr_info("dwNumWords %d 0x3004 = %x 0x3008 = %x  retries = %d failed\n",
+				dwNumWords, value, value1,
+				MAX_EEPROM_RETRIES * RETRIES_PER_DELAY);
 			return STATUS_FAILURE;
 		}
 		if( !(dwRetries%RETRIES_PER_DELAY) )
@@ -449,7 +455,7 @@ static INT BeceemFlashBulkRead(
 
 	if(Adapter->device_removed )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Device Got Removed ");
+		pr_info("Device Got Removed\n");
 		return -ENODEV;
 	}
 
@@ -630,14 +636,14 @@ static INT FlashSectorErase(PMINI_ADAPTER Adapter,
 			value = (FLASH_CMD_STATUS_REG_READ << 24);
 			if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG, &value, sizeof(value)) < 0)
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Programing of FLASH_SPI_CMDQ_REG fails");
+				pr_info("Programming of FLASH_SPI_CMDQ_REG fails\n");
 				return STATUS_FAILURE;
 			}
 
 			bytes = rdmalt(Adapter, FLASH_SPI_READQ_REG, &uiStatus, sizeof(uiStatus));
 			if (bytes < 0) {
 				uiStatus = bytes;
-				BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Reading status of FLASH_SPI_READQ_REG fails");
+				pr_info("Reading status of FLASH_SPI_READQ_REG fails\n");
 				return uiStatus;
 			}
 			iRetries++;
@@ -649,7 +655,7 @@ static INT FlashSectorErase(PMINI_ADAPTER Adapter,
 
 		if(uiStatus & 0x1)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"iRetries crossing the limit of 80000\n");
+			pr_info("iRetries crossing the limit of 80000\n");
 			return STATUS_FAILURE;
 		}
 
@@ -698,18 +704,18 @@ static INT flashByteWrite(
 	value = (FLASH_CMD_WRITE_ENABLE << 24);
 	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG,&value, sizeof(value)) < 0)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Write enable in FLASH_SPI_CMDQ_REG register fails");
+		pr_info("Write enable in FLASH_SPI_CMDQ_REG register fails\n");
 		return STATUS_FAILURE;
 	}
 	if(wrm(Adapter,FLASH_SPI_WRITEQ_REG, (PCHAR)&ulData, 4) < 0 )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"DATA Write on FLASH_SPI_WRITEQ_REG fails");
+		pr_info("DATA Write on FLASH_SPI_WRITEQ_REG fails\n");
 		return STATUS_FAILURE;
 	}
 	value = (0x02000000 | (uiOffset & 0xFFFFFF));
 	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG,&value, sizeof(value)) < 0 )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Programming of FLASH_SPI_CMDQ_REG fails");
+		pr_info("Programming of FLASH_SPI_CMDQ_REG fails\n");
 		return STATUS_FAILURE;
 	}
 
@@ -720,14 +726,14 @@ static INT flashByteWrite(
 		value = (FLASH_CMD_STATUS_REG_READ << 24);
 	  	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG, &value, sizeof(value)) < 0)
 	  	{
-	  		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Programing of FLASH_SPI_CMDQ_REG fails");
+			pr_info("Programing of FLASH_SPI_CMDQ_REG fails\n");
 			return STATUS_FAILURE;
 	  	}
 	  	//__udelay(1);
 		bytes = rdmalt(Adapter, FLASH_SPI_READQ_REG, &uiStatus, sizeof(uiStatus));
 		if (bytes < 0) {
 			uiStatus = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Reading status of FLASH_SPI_READQ_REG fails");
+			pr_info("Reading status of FLASH_SPI_READQ_REG fails\n");
 			return uiStatus;
 		}
 	  	iRetries--;
@@ -738,7 +744,7 @@ static INT flashByteWrite(
 
 	if(uiStatus & 0x1)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Flash Write fails even after checking status for 200 times.");
+		pr_info("Flash Write fails even after checking status for 200 times\n");
 		return STATUS_FAILURE ;
 	}
 
@@ -790,12 +796,12 @@ static INT flashWrite(
 
 	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG,&value, sizeof(value)) < 0 )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Write Enable of FLASH_SPI_CMDQ_REG fails");
+		pr_info("Write Enable of FLASH_SPI_CMDQ_REG fails\n");
 		return STATUS_FAILURE;
 	}
 	if(wrm(Adapter, uiOffset, (PCHAR)pData, MAX_RW_SIZE) < 0)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Data write fails...");
+		pr_info("Data write fails...\n");
 		return STATUS_FAILURE;
 	}
 
@@ -805,14 +811,14 @@ static INT flashWrite(
 		value = (FLASH_CMD_STATUS_REG_READ << 24);
 	  	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG, &value, sizeof(value)) < 0)
 	  	{
-	  		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Programing of FLASH_SPI_CMDQ_REG fails");
+			pr_info("Programing of FLASH_SPI_CMDQ_REG fails\n");
 			return STATUS_FAILURE;
 	  	}
 	  	//__udelay(1);
 		bytes = rdmalt(Adapter, FLASH_SPI_READQ_REG, &uiStatus, sizeof(uiStatus));
 		if (bytes < 0) {
 			uiStatus = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Reading status of FLASH_SPI_READQ_REG fails");
+			pr_info("Reading status of FLASH_SPI_READQ_REG fails\n");
 			return uiStatus;
 		}
 
@@ -827,7 +833,7 @@ static INT flashWrite(
 
 	if(uiStatus & 0x1)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Flash Write fails even after checking status for 200 times.");
+		pr_info("Flash Write fails even after checking status for 200 times\n");
 		return STATUS_FAILURE ;
 	}
 
@@ -873,18 +879,18 @@ static INT flashByteWriteStatus(
 	value = (FLASH_CMD_WRITE_ENABLE << 24);
 	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG,&value, sizeof(value)) < 0)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Write enable in FLASH_SPI_CMDQ_REG register fails");
+		pr_info("Write enable in FLASH_SPI_CMDQ_REG register fails\n");
 		return STATUS_SUCCESS;
 	}
 	if(wrm(Adapter,FLASH_SPI_WRITEQ_REG, (PCHAR)&ulData, 4) < 0)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"DATA Write on FLASH_SPI_WRITEQ_REG fails");
+		pr_info("DATA Write on FLASH_SPI_WRITEQ_REG fails\n");
 		return STATUS_FAILURE;
 	}
 	value = (0x02000000 | (uiOffset & 0xFFFFFF));
 	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG,&value, sizeof(value)) < 0)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Programming of FLASH_SPI_CMDQ_REG fails");
+		pr_info("Programming of FLASH_SPI_CMDQ_REG fails\n");
 		return STATUS_FAILURE;
 	}
 
@@ -895,14 +901,14 @@ static INT flashByteWriteStatus(
 		value = (FLASH_CMD_STATUS_REG_READ << 24);
 		if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG, &value, sizeof(value)) < 0)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Programing of FLASH_SPI_CMDQ_REG fails");
+			pr_info("Programing of FLASH_SPI_CMDQ_REG fails\n");
 			return STATUS_FAILURE;
 		}
 		//__udelay(1);
 		bytes = rdmalt(Adapter, FLASH_SPI_READQ_REG, &uiStatus, sizeof(uiStatus));
 		if (bytes < 0) {
 			uiStatus = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Reading status of FLASH_SPI_READQ_REG fails");
+			pr_info("Reading status of FLASH_SPI_READQ_REG fails\n");
 			return uiStatus;
 		}
 
@@ -913,7 +919,7 @@ static INT flashByteWriteStatus(
 
 	if(uiStatus & 0x1)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Flash Write fails even after checking status for 200 times.");
+		pr_info("Flash Write fails even after checking status for 200 times\n");
 		return STATUS_FAILURE ;
 	}
 
@@ -958,12 +964,12 @@ static INT flashWriteStatus(
 	value = (FLASH_CMD_WRITE_ENABLE << 24);
 	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG,&value, sizeof(value)) < 0)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Write Enable of FLASH_SPI_CMDQ_REG fails");
+		pr_info("Write Enable of FLASH_SPI_CMDQ_REG fails\n");
 		return STATUS_FAILURE;
 	}
 	if(wrm(Adapter, uiOffset, (PCHAR)pData, MAX_RW_SIZE) < 0)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Data write fails...");
+		pr_info("Data write fails...\n");
 		return STATUS_FAILURE;
 	}
    // __udelay(1);
@@ -973,14 +979,14 @@ static INT flashWriteStatus(
 		value = (FLASH_CMD_STATUS_REG_READ << 24);
 	  	if(wrmalt(Adapter, FLASH_SPI_CMDQ_REG, &value, sizeof(value)) < 0)
 	  	{
-	  		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Programing of FLASH_SPI_CMDQ_REG fails");
+			pr_info("Programming of FLASH_SPI_CMDQ_REG fails\n");
 			return STATUS_FAILURE;
 	  	}
 	  	//__udelay(1);
 		bytes = rdmalt(Adapter, FLASH_SPI_READQ_REG, &uiStatus, sizeof(uiStatus));
 		if (bytes < 0) {
 			uiStatus = bytes;
-			BCM_DEBUG_PRINT(Adapter, DBG_TYPE_PRINTK, 0, 0, "Reading status of FLASH_SPI_READQ_REG fails");
+			pr_info("Reading status of FLASH_SPI_READQ_REG fails\n");
 			return uiStatus;
 		}
 	  	iRetries--;
@@ -994,7 +1000,7 @@ static INT flashWriteStatus(
 
 	if(uiStatus & 0x1)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Flash Write fails even after checking status for 200 times.");
+		pr_info("Flash Write fails even after checking status for 200 times\n");
 		return STATUS_FAILURE ;
 	}
 
@@ -1211,8 +1217,9 @@ static INT BeceemFlashBulkWrite(
 		{
 			 if(IsOffsetWritable(Adapter, uiOffsetFromSectStart + index * Adapter->uiSectorSize ) == FALSE)
 			 {
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Sector Starting at offset <0X%X> is not writable",
-											(uiOffsetFromSectStart + index * Adapter->uiSectorSize));
+				pr_info("Sector Starting at offset <0X%X> is not writable\n",
+					uiOffsetFromSectStart +
+					index * Adapter->uiSectorSize);
 				Status = SECTOR_IS_NOT_WRITABLE;
 				goto BeceemFlashBulkWrite_EXIT;
 			 }
@@ -1224,7 +1231,10 @@ static INT BeceemFlashBulkWrite(
 	while(uiNumSectTobeRead)
 	{
 		//do_gettimeofday(&tv1);
-		//BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "\nTime In start of write :%ld ms\n",(tv1.tv_sec *1000 + tv1.tv_usec /1000));
+		/*
+		pr_info("\nTime In start of write :%ld ms\n",
+			(tv1.tv_sec *1000 + tv1.tv_usec /1000));
+		*/
 		uiPartOffset = (uiSectAlignAddr & (FLASH_PART_SIZE - 1)) + GetFlashBaseAddr(Adapter);
 
 		BcmDoChipSelect(Adapter,uiSectAlignAddr);
@@ -1239,7 +1249,11 @@ static INT BeceemFlashBulkWrite(
 		}
 
 		//do_gettimeofday(&tr);
-		//BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Total time taken by Read :%ld ms\n", (tr.tv_sec *1000 + tr.tv_usec/1000) - (tv1.tv_sec *1000 + tv1.tv_usec/1000));
+		/*
+		pr_info("Total time taken by Read :%ld ms\n",
+			(tr.tv_sec *1000 + tr.tv_usec/1000) -
+			(tv1.tv_sec *1000 + tv1.tv_usec/1000));
+		*/
 
 		ulStatus = BcmFlashUnProtectBlock(Adapter,uiSectAlignAddr,Adapter->uiSectorSize);
 
@@ -1263,8 +1277,11 @@ static INT BeceemFlashBulkWrite(
 
 		FlashSectorErase(Adapter,uiPartOffset,1);
 		//do_gettimeofday(&te);
-		//BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Total time taken by Erase :%ld ms\n", (te.tv_sec *1000 + te.tv_usec/1000) - (tr.tv_sec *1000 + tr.tv_usec/1000));
-
+		/*
+		pr_info("Total time taken by Erase :%ld ms\n",
+			(te.tv_sec *1000 + te.tv_usec/1000) -
+			(tr.tv_sec *1000 + tr.tv_usec/1000));
+		*/
 		for(uiIndex = 0; uiIndex < Adapter->uiSectorSize; uiIndex +=Adapter->ulFlashWriteSize)
 		{
 			if(Adapter->device_removed)
@@ -1280,7 +1297,11 @@ static INT BeceemFlashBulkWrite(
 		}
 
 		//do_gettimeofday(&tw);
-		//BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Total time taken in Write  to Flash :%ld ms\n", (tw.tv_sec *1000 + tw.tv_usec/1000) - (te.tv_sec *1000 + te.tv_usec/1000));
+		/*
+		pr_info("Total time taken in Write  to Flash :%ld ms\n",
+			(tw.tv_sec *1000 + tw.tv_usec/1000) -
+			(te.tv_sec *1000 + te.tv_usec/1000));
+		*/
 		for(uiIndex = 0;uiIndex < Adapter->uiSectorSize;uiIndex += MAX_RW_SIZE)
 		{
 			if(STATUS_SUCCESS == BeceemFlashBulkRead(Adapter,(PUINT)ucReadBk,uiOffsetFromSectStart+uiIndex,MAX_RW_SIZE))
@@ -1314,8 +1335,11 @@ static INT BeceemFlashBulkWrite(
 			}
 		}
 		//do_gettimeofday(&twv);
-		//BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Total time taken in Write  to Flash verification :%ld ms\n", (twv.tv_sec *1000 + twv.tv_usec/1000) - (tw.tv_sec *1000 + tw.tv_usec/1000));
-
+		/*
+		pr_info("Total time taken in Write  to Flash verification :%ld ms\n",
+			(twv.tv_sec *1000 + twv.tv_usec/1000) -
+			(tw.tv_sec *1000 + tw.tv_usec/1000));
+		*/
 
 		if(ulStatus)
 		{
@@ -1330,8 +1354,13 @@ static INT BeceemFlashBulkWrite(
 		uiNumSectTobeRead--;
 	}
 	//do_gettimeofday(&tv2);
-	//BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Time after Write :%ld ms\n",(tv2.tv_sec *1000 + tv2.tv_usec/1000));
-	//BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Total time taken by in Write is :%ld ms\n", (tv2.tv_sec *1000 + tv2.tv_usec/1000) - (tv1.tv_sec *1000 + tv1.tv_usec/1000));
+	/*
+	pr_info("Time after Write :%ld ms\n",
+		(tv2.tv_sec *1000 + tv2.tv_usec/1000));
+	pr_info("Total time taken by in Write is :%ld ms\n",
+		(tv2.tv_sec *1000 + tv2.tv_usec/1000) -
+		(tv1.tv_sec *1000 + tv1.tv_usec/1000));
+	*/
 //
 // Cleanup.
 //
@@ -1425,8 +1454,9 @@ static INT BeceemFlashBulkWriteStatus(
 		{
 			 if(IsOffsetWritable(Adapter,uiOffsetFromSectStart + index * Adapter->uiSectorSize ) == FALSE)
 			 {
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Sector Starting at offset <0X%x> is not writable",
-											(uiOffsetFromSectStart + index * Adapter->uiSectorSize));
+				pr_info("Sector Starting at offset <0X%x> is not writable\n",
+					uiOffsetFromSectStart +
+					index * Adapter->uiSectorSize);
 				Status = SECTOR_IS_NOT_WRITABLE;
 				goto BeceemFlashBulkWriteStatus_EXIT;
 			 }
@@ -1668,7 +1698,7 @@ INT PropagateCalParamsFromFlashToMemory(PMINI_ADAPTER Adapter)
 		Status = wrm(Adapter,uiMemoryLoc,(PCHAR)pPtr,uiBytesToCopy);
 		if(Status)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"wrm failed with status :%d",Status);
+			pr_info("wrm failed with status :%d\n", Status);
 			break;
 		}
 
@@ -1858,7 +1888,9 @@ static INT BeceemEEPROMWritePage( PMINI_ADAPTER Adapter, UINT uiData[], UINT uiO
 		uiRetries--;
 		if ( uiRetries == 0 )
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "0x0f003004 = %x, %d retries failed.\n", uiStatus, MAX_EEPROM_RETRIES *RETRIES_PER_DELAY);
+			pr_info("0x0f003004 = %x, %d retries failed\n",
+				uiStatus,
+				MAX_EEPROM_RETRIES * RETRIES_PER_DELAY);
 			return STATUS_FAILURE ;
 		}
 
@@ -1869,7 +1901,7 @@ static INT BeceemEEPROMWritePage( PMINI_ADAPTER Adapter, UINT uiData[], UINT uiO
 		rdmalt(Adapter, EEPROM_SPI_Q_STATUS1_REG, &uiStatus, sizeof(uiStatus));
 		if(Adapter->device_removed == TRUE)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Modem got removed hence exiting from loop....");
+			pr_info("Modem got removed hence exiting from loop....\n");
 			return -ENODEV;
 		}
 
@@ -1894,18 +1926,23 @@ static INT BeceemEEPROMWritePage( PMINI_ADAPTER Adapter, UINT uiData[], UINT uiO
 		uiEpromStatus = ReadEEPROMStatusRegister( Adapter) ;
 		if(Adapter->device_removed == TRUE)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Modem has got removed hence exiting from loop...");
+			pr_info("Modem has got removed hence exiting from loop...\n");
 			return -ENODEV;
 		}
 		if ( ( EEPROM_STATUS_REG_WRITE_BUSY & uiEpromStatus ) == 0 )
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "EEPROM status register = %x tries = %d\n", uiEpromStatus, (MAX_EEPROM_RETRIES * RETRIES_PER_DELAY- uiRetries) );
+			pr_info("EEPROM status register = %x tries = %d\n",
+				uiEpromStatus,
+				MAX_EEPROM_RETRIES * RETRIES_PER_DELAY -
+				uiRetries);
 			return STATUS_SUCCESS ;
 		}
 		uiRetries--;
 		if ( uiRetries == 0 )
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "0x0f003004 = %x, for EEPROM status read %d retries failed.\n", uiEpromStatus, MAX_EEPROM_RETRIES *RETRIES_PER_DELAY);
+			pr_info("0x0f003004 = %x, for EEPROM status read %d retries failed\n",
+				uiEpromStatus,
+				MAX_EEPROM_RETRIES * RETRIES_PER_DELAY);
 			return STATUS_FAILURE ;
 		}
 		uiEpromStatus = 0;
@@ -2423,7 +2460,7 @@ INT BcmInitNVM(PMINI_ADAPTER ps_adapter)
 		ps_adapter->eNVMType = BcmGetNvmType(ps_adapter);
 		if(ps_adapter->eNVMType == NVM_UNKNOWN)
 		{
-			BCM_DEBUG_PRINT(ps_adapter,DBG_TYPE_PRINTK, 0, 0, "NVM Type is unknown!!\n");
+			pr_info("NVM Type is unknown!!\n");
 		}
 	}
 	else if(ps_adapter->eNVMType == NVM_FLASH)
@@ -2522,20 +2559,20 @@ INT BcmAllocFlashCSStructure(PMINI_ADAPTER psAdapter)
 {
 	if(psAdapter == NULL)
 	{
-		BCM_DEBUG_PRINT(psAdapter,DBG_TYPE_PRINTK, 0, 0, "Adapter structure point is NULL");
+		pr_info("Adapter structure point is NULL\n");
 		return -EINVAL;
 	}
 	psAdapter->psFlashCSInfo = (PFLASH_CS_INFO)kzalloc(sizeof(FLASH_CS_INFO), GFP_KERNEL);
 	if(psAdapter->psFlashCSInfo == NULL)
 	{
-		BCM_DEBUG_PRINT(psAdapter,DBG_TYPE_PRINTK, 0, 0,"Can't Allocate memory for Flash 1.x");
+		pr_info("Can't Allocate memory for Flash 1.x\n");
 		return -ENOMEM;
 	}
 
 	psAdapter->psFlash2xCSInfo = (PFLASH2X_CS_INFO)kzalloc(sizeof(FLASH2X_CS_INFO), GFP_KERNEL);
 	if(psAdapter->psFlash2xCSInfo == NULL)
 	{
-		BCM_DEBUG_PRINT(psAdapter,DBG_TYPE_PRINTK, 0, 0,"Can't Allocate memory for Flash 2.x");
+		pr_info("Can't Allocate memory for Flash 2.x\n");
 		kfree(psAdapter->psFlashCSInfo);
 		return -ENOMEM;
 	}
@@ -2543,7 +2580,7 @@ INT BcmAllocFlashCSStructure(PMINI_ADAPTER psAdapter)
 	psAdapter->psFlash2xVendorInfo = (PFLASH2X_VENDORSPECIFIC_INFO)kzalloc(sizeof(FLASH2X_VENDORSPECIFIC_INFO), GFP_KERNEL);
 	if(psAdapter->psFlash2xVendorInfo == NULL)
 	{
-		BCM_DEBUG_PRINT(psAdapter,DBG_TYPE_PRINTK, 0, 0,"Can't Allocate Vendor Info Memory for Flash 2.x");
+		pr_info("Can't Allocate Vendor Info Memory for Flash 2.x\n");
 		kfree(psAdapter->psFlashCSInfo);
 		kfree(psAdapter->psFlash2xCSInfo);
 		return -ENOMEM;
@@ -2556,7 +2593,7 @@ INT BcmDeAllocFlashCSStructure(PMINI_ADAPTER psAdapter)
 {
 	if(psAdapter == NULL)
 	{
-		BCM_DEBUG_PRINT(psAdapter,DBG_TYPE_PRINTK, 0, 0," Adapter structure point is NULL");
+		pr_info(" Adapter structure point is NULL\n");
 		return -EINVAL;
 	}
 	kfree(psAdapter->psFlashCSInfo);
@@ -2902,7 +2939,7 @@ static INT BcmGetFlashCSInfo(PMINI_ADAPTER Adapter)
 		if(BcmFlash2xBulkRead(Adapter,(PUINT)Adapter->psFlash2xCSInfo,NO_SECTION_VAL,
 				Adapter->ulFlashControlSectionStart,sizeof(FLASH2X_CS_INFO)))
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Unable to read CS structure \n");
+			pr_info("Unable to read CS structure\n");
 			return STATUS_FAILURE;
 		}
 		ConvertEndianOf2XCSStructure(Adapter->psFlash2xCSInfo);
@@ -3082,7 +3119,7 @@ INT BcmGetSectionValStartOffset(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlas
   				  SectStartOffset =  (Adapter->psFlash2xCSInfo->OffsetISOImage2Part3Start);
   			  break;
 		default :
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section Does not exist in Flash 2.x");
+			pr_info("Section Does not exist in Flash 2.x\n");
 			SectStartOffset =  INVALID_OFFSET;
 	}
 	return SectStartOffset;
@@ -3201,12 +3238,12 @@ INT BcmFlash2xBulkRead(
 	UINT uiTemp =0, value =0 ;
 	if(Adapter == NULL)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Adapter structure is NULL");
+		pr_info("Adapter structure is NULL\n");
 		return -EINVAL;
 	}
 	if(Adapter->device_removed )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Device has been removed");
+		pr_info("Device has been removed\n");
 		return -ENODEV;
 	}
 
@@ -3218,7 +3255,8 @@ INT BcmFlash2xBulkRead(
 
 	if(SectionStartOffset == STATUS_FAILURE )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"This Section<%d> does not exixt in Flash 2.x Map ",eFlash2xSectionVal);
+		pr_info("This Section<%d> does not exixt in Flash 2.x Map\n",
+			eFlash2xSectionVal);
 		return -EINVAL;
 	}
 
@@ -3236,7 +3274,7 @@ INT BcmFlash2xBulkRead(
 	wrmalt(Adapter, 0x0f000C80, &uiTemp, sizeof(uiTemp));
 	if(Status)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Flash Read Failed with Status :%d", Status);
+		pr_info("Flash Read Failed with Status :%d\n", Status);
 		return Status ;
 	}
 
@@ -3270,12 +3308,12 @@ INT BcmFlash2xBulkWrite(
 	UINT uiTemp = 0, value = 0;
 	if(Adapter == NULL)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Adapter structure is NULL");
+		pr_info("Adapter structure is NULL\n");
 		return -EINVAL;
 	}
 	if(Adapter->device_removed )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Device has been removed");
+		pr_info("Device has been removed\n");
 		return -ENODEV;
 	}
 
@@ -3287,7 +3325,8 @@ INT BcmFlash2xBulkWrite(
 
 	if(FlashSectValStartOffset == STATUS_FAILURE )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"This Section<%d> does not exixt in Flash Map 2.x",eFlash2xSectVal);
+		pr_info("This Section<%d> does not exixt in Flash Map 2.x\n",
+			eFlash2xSectVal);
 		return -EINVAL;
 	}
 
@@ -3306,7 +3345,7 @@ INT BcmFlash2xBulkWrite(
 	wrmalt(Adapter, 0x0f000C80, &uiTemp, sizeof(uiTemp));
 	if(Status)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Flash Write failed with Status :%d", Status);
+		pr_info("Flash Write failed with Status :%d\n", Status);
 		return Status ;
 	}
 
@@ -3767,7 +3806,8 @@ INT BcmSetActiveSection(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSectV
 	Status = IsSectionWritable(Adapter,eFlash2xSectVal) ;
 	if(Status != TRUE )
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Provided Section <%d> is not writable",eFlash2xSectVal);
+		pr_info("Provided Section <%d> is not writable\n",
+			eFlash2xSectVal);
 		return STATUS_FAILURE;
 	}
 
@@ -3805,7 +3845,7 @@ INT BcmSetActiveSection(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSectV
 
 					if(Status)
 					{
-						BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Priority has not been written properly");
+						pr_info("Priority has not been written properly\n");
 						Status = STATUS_FAILURE;
 						break ;
 					}
@@ -3833,13 +3873,13 @@ INT BcmSetActiveSection(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSectV
 								TRUE);
 				if(Status)
 				{
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Priority has not been written properly");
+					pr_info("Priority has not been written properly\n");
 					break ;
 				}
 			}
 			else
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Signature is currupted. Hence can't increase the priority");
+				pr_info("Signature is corrupted. Hence can't increase the priority\n");
 				Status = STATUS_FAILURE ;
 				break;
 			}
@@ -3864,7 +3904,8 @@ INT BcmSetActiveSection(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSectV
 					// This is a SPECIAL Case which will only happen if the current highest priority DSD has priority value = 0x7FFFFFFF.
 					// We will write 1 to the current Highest priority DSD And then shall increase the priority of the requested DSD
 					// by user
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, NVM_RW, DBG_LVL_ALL, "SectImagePriority wraparound happened, eFlash2xSectVal: 0x%x\n",eFlash2xSectVal);
+					pr_info("SectImagePriority wraparound happened, eFlash2xSectVal: 0x%x\n",
+						eFlash2xSectVal);
 					SectImagePriority = htonl(0x1);
 
 					Status = BcmFlash2xBulkWrite(Adapter,
@@ -3876,7 +3917,7 @@ INT BcmSetActiveSection(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSectV
 
 					if(Status)
 					{
-						BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Priority has not been written properly");
+						pr_info("Priority has not been written properly\n");
 						break ;
 					}
 
@@ -3899,7 +3940,7 @@ INT BcmSetActiveSection(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSectV
 
 					if(Status)
 					{
-						BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Priority has not been written properly");
+						pr_info("Priority has not been written properly\n");
 						break ;
 					}
 
@@ -3922,14 +3963,14 @@ INT BcmSetActiveSection(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSectV
 								TRUE);
 				if(Status)
 				{
-					BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Priority has not been written properly");
+					pr_info("Priority has not been written properly\n");
 					Status = STATUS_FAILURE ;
 					break ;
 				}
 			}
 			else
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Signature is currupted. Hence can't increase the priority");
+				pr_info("Signature is corrupted. Hence can't increase the priority\n");
 				Status = STATUS_FAILURE ;
 				break;
 			}
@@ -3974,7 +4015,7 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 	if(ReadISOSignature(Adapter,sCopySectStrut.SrcSection) != ISO_IMAGE_MAGIC_NUMBER)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "error as Source ISO Section does not have valid signature");
+		pr_info("error as Source ISO Section does not have valid signature\n");
 		return STATUS_FAILURE;
 	}
 
@@ -3986,7 +4027,7 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 	if(Status)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Read failed while copying ISO\n");
+		pr_info("Read failed while copying ISO\n");
 		return Status;
 	}
 
@@ -4003,7 +4044,7 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 	if(Buff == NULL)
 	{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Memory allocation failed for section size");
+			pr_info("Memory allocation failed for section size\n");
 			return -ENOMEM;
 	}
 
@@ -4023,7 +4064,7 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 		if(uiTotalDataToCopy < ISOLength)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"error as Source ISO Section does not have valid signature");
+			pr_info("error as Source ISO Section does not have valid signature\n");
 			Status = STATUS_FAILURE;
 			goto out;
 		}
@@ -4037,7 +4078,7 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 		if(uiTotalDataToCopy < ISOLength)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"error as Dest ISO Section does not have enough section size");
+			pr_info("error as Dest ISO Section does not have enough section size\n");
 			Status = STATUS_FAILURE;
 			goto out;
 		}
@@ -4095,7 +4136,8 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 			if(Status)
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Read failed while copying ISO: Part: %x, OffsetWithinPart: %x\n", eISOReadPart, uiReadOffsetWithinPart);
+				pr_info("Read failed while copying ISO: Part: %x, OffsetWithinPart: %x\n",
+					eISOReadPart, uiReadOffsetWithinPart);
 				break;
 			}
 
@@ -4117,7 +4159,8 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 								 TRUE);
 			if(Status)
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Write failed while copying ISO: Part: %x, OffsetWithinPart: %x\n", eISOWritePart, uiWriteOffsetWithinPart);
+				pr_info("Write failed while copying ISO: Part: %x, OffsetWithinPart: %x\n",
+					eISOWritePart, uiWriteOffsetWithinPart);
 				break;
 			}
 
@@ -4155,7 +4198,7 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 		if(uiTotalDataToCopy < ISOLength)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"error as Source ISO Section does not have valid signature");
+			pr_info("error as Source ISO Section does not have valid signature\n");
 			Status = STATUS_FAILURE;
 			goto out;
 		}
@@ -4169,7 +4212,7 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 		if(uiTotalDataToCopy < ISOLength)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"error as Dest ISO Section does not have enough section size");
+			pr_info("error as Dest ISO Section does not have enough section size\n");
 			Status = STATUS_FAILURE;
 			goto out;
 		}
@@ -4226,7 +4269,8 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 								);
 			if(Status)
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Read failed while copying ISO: Part: %x, OffsetWithinPart: %x\n", eISOReadPart, uiReadOffsetWithinPart);
+				pr_info("Read failed while copying ISO: Part: %x, OffsetWithinPart: %x\n",
+					eISOReadPart, uiReadOffsetWithinPart);
 				break;
 			}
 
@@ -4249,7 +4293,8 @@ INT BcmCopyISO(PMINI_ADAPTER Adapter, FLASH2X_COPY_SECTION sCopySectStrut)
 
 			if(Status)
 			{
-				BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Write failed while copying ISO: Part: %x, OffsetWithinPart: %x\n", eISOWritePart, uiWriteOffsetWithinPart);
+				pr_info("Write failed while copying ISO: Part: %x, OffsetWithinPart: %x\n",
+					eISOWritePart, uiWriteOffsetWithinPart);
 				break;
 			}
 
@@ -4293,7 +4338,7 @@ INT BcmFlash2xCorruptSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSect
 {
 
 	INT Status = STATUS_SUCCESS ;
-	BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Section Value :%x \n", eFlash2xSectionVal);
+	pr_info("Section Value :%x\n", eFlash2xSectionVal);
 
 	if((eFlash2xSectionVal == DSD0) || (eFlash2xSectionVal == DSD1) || (eFlash2xSectionVal == DSD2))
 	{
@@ -4337,7 +4382,7 @@ INT BcmFlash2xWriteSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlashSectionV
 	{
 		if(IsSectionWritable(Adapter,eFlashSectionVal) == FALSE)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section is not Writable...Hence can't Write signature");
+			pr_info("Section is not Writable...Hence can't Write signature\n");
 			return SECTOR_IS_NOT_WRITABLE;
 		}
 	}
@@ -4350,7 +4395,7 @@ INT BcmFlash2xWriteSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlashSectionV
 
 		if((ReadDSDSignature(Adapter,eFlashSectionVal) & 0xFF000000) != CORRUPTED_PATTERN)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Corrupted Pattern is not there. Hence won't write sig");
+			pr_info("Corrupted Pattern is not there. Hence won't write sig\n");
 			return STATUS_FAILURE;
 		}
 
@@ -4362,13 +4407,14 @@ INT BcmFlash2xWriteSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlashSectionV
 		uiOffset = FIELD_OFFSET_IN_HEADER(PISO_HEADER,ISOImageMagicNumber);
 		if((ReadISOSignature(Adapter,eFlashSectionVal) & 0xFF000000) != CORRUPTED_PATTERN)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Currupted Pattern is not there. Hence won't write sig");
+			pr_info("Currupted Pattern is not there. Hence won't write sig\n");
 			return STATUS_FAILURE;
 		}
 	}
 	else
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"GIVEN SECTION< %d > IS NOT VALID FOR SIG WRITE...", eFlashSectionVal);
+		pr_info("GIVEN SECTION< %d > IS NOT VALID FOR SIG WRITE...\n",
+			eFlashSectionVal);
 		return STATUS_FAILURE;
 	}
 
@@ -4403,7 +4449,8 @@ INT	validateFlash2xReadWrite(PMINI_ADAPTER Adapter, PFLASH2X_READWRITE psFlash2x
 
 	if(IsSectionExistInFlash(Adapter,psFlash2xReadWrite->Section) != TRUE)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section<%x> does not exixt in Flash",psFlash2xReadWrite->Section);
+		pr_info("Section<%x> does not exixt in Flash\n",
+			psFlash2xReadWrite->Section);
 		return FALSE;
 	}
 	uiSectStartOffset = BcmGetSectionValStartOffset(Adapter,psFlash2xReadWrite->Section);
@@ -4445,7 +4492,7 @@ INT	validateFlash2xReadWrite(PMINI_ADAPTER Adapter, PFLASH2X_READWRITE psFlash2x
 		return TRUE;
 	else
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Invalid Request....");
+		pr_info("Invalid Request....\n");
 		return FALSE;
 	}
 
@@ -4537,17 +4584,17 @@ INT	BcmCopySection(PMINI_ADAPTER Adapter,
 	INT Status = STATUS_SUCCESS ;
 	if(SrcSection == DstSection)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Source and Destination should be different ...try again");
+		pr_info("Source and Destination should be different ...try again\n");
 		return -EINVAL;
 	}
 	if((SrcSection != DSD0) && (SrcSection != DSD1) && (SrcSection != DSD2))
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Source should be DSD subsection");
+		pr_info("Source should be DSD subsection\n");
 		return  -EINVAL;
 	}
 	if((DstSection != DSD0) && (DstSection != DSD1) && (DstSection != DSD2))
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Destination should be DSD subsection");
+		pr_info("Destination should be DSD subsection\n");
 		return  -EINVAL;
 	}
 
@@ -4564,16 +4611,16 @@ INT	BcmCopySection(PMINI_ADAPTER Adapter,
 	if((offset + numOfBytes) > BcmGetSectionValEndOffset(Adapter,SrcSection)
 				  - BcmGetSectionValStartOffset(Adapter,SrcSection))
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0," Input parameters going beyond the section offS: %x numB: %x of Source Section\n",
-						offset, numOfBytes);
+		pr_info(" Input parameters going beyond the section offS: %x numB: %x of Source Section\n",
+			offset, numOfBytes);
 		return -EINVAL;
 	}
 
 	if((offset + numOfBytes) > BcmGetSectionValEndOffset(Adapter,DstSection)
 				  - BcmGetSectionValStartOffset(Adapter,DstSection))
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0," Input parameters going beyond the section offS: %x numB: %x of Destination Section\n",
-						offset, numOfBytes);
+		pr_info(" Input parameters going beyond the section offS: %x numB: %x of Destination Section\n",
+			offset, numOfBytes);
 		return -EINVAL;
 	}
 
@@ -4586,7 +4633,7 @@ INT	BcmCopySection(PMINI_ADAPTER Adapter,
 	pBuff = (PCHAR)kzalloc(BuffSize, GFP_KERNEL);
 	if(pBuff == NULL)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Memory allocation failed.. ");
+		pr_info("Memory allocation failed..\n");
 		return -ENOMEM;
 	}
 
@@ -4606,13 +4653,15 @@ INT	BcmCopySection(PMINI_ADAPTER Adapter,
 		Status = BcmFlash2xBulkRead(Adapter, (PUINT)pBuff, SrcSection , offset,BytesToBeCopied);
 		if(Status)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Read failed at offset :%d for NOB :%d", SrcSection,BytesToBeCopied);
+			pr_info("Read failed at offset :%d for NOB :%d\n",
+				SrcSection, BytesToBeCopied);
 			break;
 		}
 		Status = BcmFlash2xBulkWrite(Adapter,(PUINT)pBuff,DstSection,offset,BytesToBeCopied,FALSE);
 		if(Status)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Write failed at offset :%d for NOB :%d", DstSection,BytesToBeCopied);
+			pr_info("Write failed at offset :%d for NOB :%d\n",
+				DstSection, BytesToBeCopied);
 			break;
 		}
 		offset = offset + BytesToBeCopied;
@@ -4678,7 +4727,7 @@ INT SaveHeaderIfPresent(PMINI_ADAPTER Adapter, PUCHAR pBuff, UINT uiOffset)
 		pTempBuff = (PUCHAR)kzalloc(HeaderSizeToProtect, GFP_KERNEL);
 		if(pTempBuff == NULL)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Memory allocation failed ");
+			pr_info("Memory allocation failed\n");
 			return -ENOMEM;
 		}
 		//Read header
@@ -4802,7 +4851,7 @@ INT ReadDSDSignature(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL dsd)
 
 		if(dsd != DSD0 && dsd != DSD1 && dsd != DSD2)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"passed section value is not for DSDs");
+			pr_info("passed section value is not for DSDs\n");
 			return STATUS_FAILURE;
 		}
 		BcmFlash2xBulkRead(Adapter,
@@ -4884,7 +4933,7 @@ INT ReadISOSignature(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL iso)
 
 		if(iso != ISO_IMAGE1 && iso != ISO_IMAGE2)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"passed section value is not for ISOs");
+			pr_info("passed section value is not for ISOs\n");
 			return STATUS_FAILURE;
 		}
 		BcmFlash2xBulkRead(Adapter,
@@ -4962,7 +5011,8 @@ INT WriteToFlashWithoutSectorErase(PMINI_ADAPTER Adapter,
 
 	if(uiNumBytes % Adapter->ulFlashWriteSize)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Writing without Sector Erase for non-FlashWriteSize number of bytes 0x%x\n", uiNumBytes);
+		pr_info("Writing without Sector Erase for non-FlashWriteSize number of bytes 0x%x\n",
+			uiNumBytes);
 		return STATUS_FAILURE;
 	}
 
@@ -5057,7 +5107,7 @@ BOOLEAN IsSectionExistInFlash(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL section
 					 SectionPresent = TRUE ;
 				break;
 		default :
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section Does not exist in Flash 2.x");
+			pr_info("Section Does not exist in Flash 2.x\n");
 			SectionPresent =  FALSE;
 	}
 	return SectionPresent ;
@@ -5068,13 +5118,13 @@ INT IsSectionWritable(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL Section)
 		INT Status = FALSE;
 		if(IsSectionExistInFlash(Adapter,Section) == FALSE)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section <%d> does not exixt", Section);
+			pr_info("Section <%d> does not exist\n", Section);
 			return FALSE;
 		}
 		offset = BcmGetSectionValStartOffset(Adapter,Section);
 		if(offset == INVALID_OFFSET)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section<%d> does not exixt", Section);
+			pr_info("Section<%d> does not exist\n", Section);
 			return FALSE;
 		}
 
@@ -5102,7 +5152,7 @@ static INT CorruptDSDSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSect
 	{
 		if(IsSectionWritable(Adapter,eFlash2xSectionVal) != TRUE)
 		{
-			BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section is not Writable...Hence can't Corrupt signature");
+			pr_info("Section is not Writable...Hence can't Corrupt signature\n");
 			return SECTOR_IS_NOT_WRITABLE;
 		}
 	}
@@ -5110,7 +5160,7 @@ static INT CorruptDSDSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSect
 	pBuff = (PUCHAR)kzalloc(MAX_RW_SIZE, GFP_KERNEL);
 	if(pBuff == NULL)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0, "Can't allocate memorey");
+		pr_info("Can't allocate memory\n");
 		return -ENOMEM ;
 	}
 
@@ -5150,7 +5200,7 @@ static INT CorruptDSDSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSect
 	}
 	else
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"BCM Signature is not present in header");
+		pr_info("BCM Signature is not present in header\n");
 		kfree(pBuff);
 		return STATUS_FAILURE;
 	}
@@ -5171,14 +5221,14 @@ static INT CorruptISOSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSect
 
 	if(IsSectionWritable(Adapter,eFlash2xSectionVal) != TRUE)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Section is not Writable...Hence can't Corrupt signature");
+		pr_info("Section is not Writable...Hence can't Corrupt signature\n");
 		return SECTOR_IS_NOT_WRITABLE;
 	}
 
 	pBuff = (PUCHAR)kzalloc(MAX_RW_SIZE, GFP_KERNEL);
 	if(pBuff == NULL)
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"Can't allocate memorey");
+		pr_info("Can't allocate memory\n");
 		return -ENOMEM ;
 	}
 
@@ -5200,7 +5250,7 @@ static INT CorruptISOSig(PMINI_ADAPTER Adapter, FLASH2X_SECTION_VAL eFlash2xSect
 	}
 	else
 	{
-		BCM_DEBUG_PRINT(Adapter,DBG_TYPE_PRINTK, 0, 0,"BCM Signature is not present in header");
+		pr_info("BCM Signature is not present in header\n");
 		kfree(pBuff);
 		return STATUS_FAILURE;
 	}
-- 
1.7.8.111.gad25c.dirty




More information about the devel mailing list