[PATCH] leon: substitute printf with printk in driver init

Daniel Hellstrom daniel at gaisler.com
Wed Sep 19 14:13:29 UTC 2018


---
 bsps/sparc/shared/iommu/griommu.c           |  3 ++-
 bsps/sparc/shared/l2c/l2c.c                 |  2 +-
 bsps/sparc/shared/pci/gr_701.c              | 14 +++++++-------
 bsps/sparc/shared/pci/gr_cpci_gr740.c       | 12 ++++++------
 bsps/sparc/shared/pci/gr_leon4_n2x.c        | 12 ++++++------
 bsps/sparc/shared/pci/gr_rasta_adcdac.c     | 14 +++++++-------
 bsps/sparc/shared/pci/gr_rasta_io.c         | 14 +++++++-------
 bsps/sparc/shared/pci/gr_rasta_spw_router.c | 13 ++++++-------
 bsps/sparc/shared/pci/gr_rasta_tmtc.c       | 14 +++++++-------
 bsps/sparc/shared/pci/gr_tmtc_1553.c        | 12 ++++++------
 bsps/sparc/shared/pci/grpci.c               |  2 +-
 bsps/sparc/shared/pci/grpci2.c              |  2 +-
 bsps/sparc/shared/pci/pcif.c                |  4 ++--
 bsps/sparc/shared/spi/spictrl.c             |  2 +-
 14 files changed, 60 insertions(+), 60 deletions(-)

diff --git a/bsps/sparc/shared/iommu/griommu.c b/bsps/sparc/shared/iommu/griommu.c
index c70219a..c6c87df 100644
--- a/bsps/sparc/shared/iommu/griommu.c
+++ b/bsps/sparc/shared/iommu/griommu.c
@@ -15,6 +15,7 @@
 #include <drvmgr/ambapp_bus.h>
 #include <ambapp.h>
 #include <rtems.h>
+#include <rtems/bspIo.h>
 #include <bsp.h>
 #include <bsp/griommu.h>
 
@@ -371,7 +372,7 @@ int griommu_init1(struct drvmgr_dev *dev)
 	/* Initialize GRIOMMU Hardware */
 	status = griommu_init(priv);
 	if (status) {
-		printf("Failed to initialize griommu driver %d\n", status);
+		printk("Failed to initialize griommu driver %d\n", status);
 		return -1;
 	}
 
diff --git a/bsps/sparc/shared/l2c/l2c.c b/bsps/sparc/shared/l2c/l2c.c
index 0c577f3..7b17f8b 100644
--- a/bsps/sparc/shared/l2c/l2c.c
+++ b/bsps/sparc/shared/l2c/l2c.c
@@ -475,7 +475,7 @@ int l2cache_init1(struct drvmgr_dev *dev)
 	/* Initialize L2CACHE Hardware */
 	status = l2cache_init(priv);
 	if (status) {
-		printf("Failed to initialize l2cache driver %d\n", status);
+		printk("Failed to initialize l2cache driver %d\n", status);
 		return -1;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_701.c b/bsps/sparc/shared/pci/gr_701.c
index a6c9ebc..2350e58 100644
--- a/bsps/sparc/shared/pci/gr_701.c
+++ b/bsps/sparc/shared/pci/gr_701.c
@@ -349,14 +349,14 @@ int gr701_init1(struct drvmgr_dev *dev)
 	bar0_size = devinfo->resources[0].size;
 	bar1 = devinfo->resources[1].address;
 	bar1_size = devinfo->resources[1].size;
-	printf("\n\n--- GR-701[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-701[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n\n\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n\n\n",
 		devinfo->id.vendor, devinfo->id.device);
-	printf(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
-	printf(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
+	printk(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* all neccessary space assigned to GR-701 target? */
 	if ((bar0_size == 0) || (bar1_size == 0))
@@ -379,7 +379,7 @@ int gr701_init1(struct drvmgr_dev *dev)
 		genirq_destroy(priv->genirq);
 		free(priv);
 		dev->priv = NULL;
-		printf(" Failed to initialize GR-701 HW\n");
+		printk(" Failed to initialize GR-701 HW\n");
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_cpci_gr740.c b/bsps/sparc/shared/pci/gr_cpci_gr740.c
index 7ff7206..9b4fbfa 100644
--- a/bsps/sparc/shared/pci/gr_cpci_gr740.c
+++ b/bsps/sparc/shared/pci/gr_cpci_gr740.c
@@ -485,13 +485,13 @@ int gr_cpci_gr740_init1(struct drvmgr_dev *dev)
 
 	priv->devinfo = devinfo = (struct pci_dev_info *)dev->businfo;
 	priv->pcidev = devinfo->pcidev;
-	printf("\n\n--- GR-CPCI-GR740[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-CPCI-GR740[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
 		devinfo->id.vendor, devinfo->id.device);
 	for (i = 0; i < 3; i++) {
-		printf(" PCI BAR[%d]: 0x%08lx - 0x%08lx\n",
+		printk(" PCI BAR[%d]: 0x%08lx - 0x%08lx\n",
 			i, devinfo->resources[i].address,
 			devinfo->resources[i].address +
 			(devinfo->resources[i].size - 1));
@@ -499,7 +499,7 @@ int gr_cpci_gr740_init1(struct drvmgr_dev *dev)
 		if (devinfo->resources[i].size == 0)
 			return DRVMGR_ENORES;
 	}
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* Initialize spin-lock for this PCI perihperal device. This is to
 	 * protect the Interrupt Controller Registers. The genirq layer is
@@ -545,7 +545,7 @@ int gr_cpci_gr740_init1(struct drvmgr_dev *dev)
 
 	if ((status = gr_cpci_gr740_hw_init1(priv)) != 0) {
 		genirq_destroy(priv->genirq);
-		printf(" Failed to initialize GR-CPCI-GR740 HW: %d\n", status);
+		printk(" Failed to initialize GR-CPCI-GR740 HW: %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_leon4_n2x.c b/bsps/sparc/shared/pci/gr_leon4_n2x.c
index cb78de4..c97c0b8 100644
--- a/bsps/sparc/shared/pci/gr_leon4_n2x.c
+++ b/bsps/sparc/shared/pci/gr_leon4_n2x.c
@@ -508,13 +508,13 @@ int gr_cpci_leon4_n2x_init1(struct drvmgr_dev *dev)
 
 	priv->devinfo = devinfo = (struct pci_dev_info *)dev->businfo;
 	priv->pcidev = devinfo->pcidev;
-	printf("\n\n--- GR-CPCI-LEON4-N2X[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-CPCI-LEON4-N2X[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
 		devinfo->id.vendor, devinfo->id.device);
 	for (i = 0; i < 3; i++) {
-		printf(" PCI BAR[%d]: 0x%08lx - 0x%08lx\n",
+		printk(" PCI BAR[%d]: 0x%08lx - 0x%08lx\n",
 			i, devinfo->resources[i].address,
 			devinfo->resources[i].address +
 			(devinfo->resources[i].size - 1));
@@ -522,7 +522,7 @@ int gr_cpci_leon4_n2x_init1(struct drvmgr_dev *dev)
 		if (devinfo->resources[i].size == 0)
 			return DRVMGR_ENORES;
 	}
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* Initialize spin-lock for this PCI perihperal device. This is to
 	 * protect the Interrupt Controller Registers. The genirq layer is
@@ -568,7 +568,7 @@ int gr_cpci_leon4_n2x_init1(struct drvmgr_dev *dev)
 
 	if ((status = gr_cpci_leon4_n2x_hw_init1(priv)) != 0) {
 		genirq_destroy(priv->genirq);
-		printf(" Failed to initialize GR-CPCI-LEON4-N2X HW: %d\n", status);
+		printk(" Failed to initialize GR-CPCI-LEON4-N2X HW: %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_rasta_adcdac.c b/bsps/sparc/shared/pci/gr_rasta_adcdac.c
index 6d1f8f1..4bd0073 100644
--- a/bsps/sparc/shared/pci/gr_rasta_adcdac.c
+++ b/bsps/sparc/shared/pci/gr_rasta_adcdac.c
@@ -414,14 +414,14 @@ int gr_rasta_adcdac_init1(struct drvmgr_dev *dev)
 	bar0_size = devinfo->resources[0].size;
 	bar1 = devinfo->resources[1].address;
 	bar1_size = devinfo->resources[1].size;
-	printf("\n\n--- GR-RASTA-ADCDAC[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-RASTA-ADCDAC[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
 		devinfo->id.vendor, devinfo->id.device);
-	printf(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
-	printf(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
+	printk(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* all neccessary space assigned to GR-RASTA-ADCDAC target? */
 	if ((bar0_size == 0) || (bar1_size == 0))
@@ -457,7 +457,7 @@ int gr_rasta_adcdac_init1(struct drvmgr_dev *dev)
 		genirq_destroy(priv->genirq);
 		free(priv);
 		dev->priv = NULL;
-		printf(" Failed to initialize GR-RASTA-ADCDAC HW: %d\n", status);
+		printk(" Failed to initialize GR-RASTA-ADCDAC HW: %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_rasta_io.c b/bsps/sparc/shared/pci/gr_rasta_io.c
index 1e424f6..02c8b5b 100644
--- a/bsps/sparc/shared/pci/gr_rasta_io.c
+++ b/bsps/sparc/shared/pci/gr_rasta_io.c
@@ -593,14 +593,14 @@ int gr_rasta_io_init1(struct drvmgr_dev *dev)
 	bar0_size = devinfo->resources[0].size;
 	bar1 = devinfo->resources[1].address;
 	bar1_size = devinfo->resources[1].size;
-	printf("\n\n--- GR-RASTA-IO[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-RASTA-IO[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
 		devinfo->id.vendor, devinfo->id.device);
-	printf(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
-	printf(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
+	printk(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* all neccessary space assigned to GR-RASTA-IO target? */
 	if ((bar0_size == 0) || (bar1_size == 0))
@@ -654,7 +654,7 @@ int gr_rasta_io_init1(struct drvmgr_dev *dev)
 		genirq_destroy(priv->genirq);
 		free(priv);
 		dev->priv = NULL;
-		printf(" Failed to initialize GR-RASTA-IO HW: %d\n", status);
+		printk(" Failed to initialize GR-RASTA-IO HW: %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_rasta_spw_router.c b/bsps/sparc/shared/pci/gr_rasta_spw_router.c
index 7f7e350..194d0a9 100644
--- a/bsps/sparc/shared/pci/gr_rasta_spw_router.c
+++ b/bsps/sparc/shared/pci/gr_rasta_spw_router.c
@@ -377,7 +377,6 @@ static int gr_rasta_spw_router_hw_init(struct gr_rasta_spw_router_priv *priv)
 	/* Make sure dirq(0) sampling is enabled */
 	ctrl = priv->grpci2->ctrl;
 	ctrl = (ctrl & 0xFFFFFF0F) | (1 << 4);
-	printf("data: 0x%x\n", ctrl);
 	priv->grpci2->ctrl = ctrl;
 
 	/* Successfully registered the RASTA-SPW-ROUTER board */
@@ -427,13 +426,13 @@ int gr_rasta_spw_router_init1(struct drvmgr_dev *dev)
 	priv->pcidev = devinfo->pcidev;
 	bar0 = devinfo->resources[0].address;
 	bar0_size = devinfo->resources[0].size;
-	printf("\n\n--- GR-RASTA-SPW-ROUTER[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-RASTA-SPW-ROUTER[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
 		devinfo->id.vendor, devinfo->id.device);
-	printf(" PCI BAR[0]: 0x%08lx - 0x%08lx\n", bar0, bar0 + bar0_size - 1);
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" PCI BAR[0]: 0x%08lx - 0x%08lx\n", bar0, bar0 + bar0_size - 1);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* all neccessary space assigned to GR-RASTA-SPW-ROUTER target? */
 	if (bar0_size == 0)
@@ -464,7 +463,7 @@ int gr_rasta_spw_router_init1(struct drvmgr_dev *dev)
 
 	if ((status = gr_rasta_spw_router_hw_init(priv)) != 0) {
 		genirq_destroy(priv->genirq);
-		printf(" Failed to initialize GR-RASTA-SPW-ROUTER HW: %d\n", status);
+		printk(" Failed to initialize GR-RASTA-SPW-ROUTER HW: %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_rasta_tmtc.c b/bsps/sparc/shared/pci/gr_rasta_tmtc.c
index 6ca3c6b..7f49d1d 100644
--- a/bsps/sparc/shared/pci/gr_rasta_tmtc.c
+++ b/bsps/sparc/shared/pci/gr_rasta_tmtc.c
@@ -605,14 +605,14 @@ int gr_rasta_tmtc_init1(struct drvmgr_dev *dev)
 	bar0_size = devinfo->resources[0].size;
 	bar1 = devinfo->resources[1].address;
 	bar1_size = devinfo->resources[1].size;
-	printf("\n\n--- GR-RASTA-TMTC[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-RASTA-TMTC[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
 		devinfo->id.vendor, devinfo->id.device);
-	printf(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
-	printf(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
+	printk(" PCI BAR[1]: 0x%lx - 0x%lx\n", bar1, bar1 + bar1_size - 1);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* all neccessary space assigned to GR-RASTA-IO target? */
 	if ((bar0_size == 0) || (bar1_size == 0))
@@ -657,7 +657,7 @@ int gr_rasta_tmtc_init1(struct drvmgr_dev *dev)
 
 	if ( status != 0 ) {
 		genirq_destroy(priv->genirq);
-		printf(" Failed to initialize GR-RASTA-TMTC HW: %d\n", status);
+		printk(" Failed to initialize GR-RASTA-TMTC HW: %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/gr_tmtc_1553.c b/bsps/sparc/shared/pci/gr_tmtc_1553.c
index ec51ec3..4bbdaff 100644
--- a/bsps/sparc/shared/pci/gr_tmtc_1553.c
+++ b/bsps/sparc/shared/pci/gr_tmtc_1553.c
@@ -331,13 +331,13 @@ int gr_tmtc_1553_init1(struct drvmgr_dev *dev)
 	priv->pcidev = devinfo->pcidev;
 	bar0 = devinfo->resources[0].address;
 	bar0_size = devinfo->resources[0].size;
-	printf("\n\n--- GR-TMTC-1553[%d] ---\n", dev->minor_drv);
-	printf(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
+	printk("\n\n--- GR-TMTC-1553[%d] ---\n", dev->minor_drv);
+	printk(" PCI BUS: 0x%x, SLOT: 0x%x, FUNCTION: 0x%x\n",
 		PCI_DEV_EXPAND(priv->pcidev));
-	printf(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
+	printk(" PCI VENDOR: 0x%04x, DEVICE: 0x%04x\n",
 		devinfo->id.vendor, devinfo->id.device);
-	printf(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
-	printf(" IRQ: %d\n\n\n", devinfo->irq);
+	printk(" PCI BAR[0]: 0x%lx - 0x%lx\n", bar0, bar0 + bar0_size - 1);
+	printk(" IRQ: %d\n\n\n", devinfo->irq);
 
 	/* all neccessary space assigned to GR-TMTC-1553 target? */
 	if (bar0_size == 0)
@@ -361,7 +361,7 @@ int gr_tmtc_1553_init1(struct drvmgr_dev *dev)
 		genirq_destroy(priv->genirq);
 		free(priv);
 		dev->priv = NULL;
-		printf(" Failed to initialize GR-TMTC-1553 HW: %d\n", status);
+		printk(" Failed to initialize GR-TMTC-1553 HW: %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/grpci.c b/bsps/sparc/shared/pci/grpci.c
index 047f1c1..6e35b44 100644
--- a/bsps/sparc/shared/pci/grpci.c
+++ b/bsps/sparc/shared/pci/grpci.c
@@ -627,7 +627,7 @@ int grpci_init1(struct drvmgr_dev *dev)
 	grpcipriv = priv;
 	status = grpci_init(priv);
 	if (status) {
-		printf("Failed to initialize grpci driver %d\n", status);
+		printk("Failed to initialize grpci driver %d\n", status);
 		return DRVMGR_FAIL;
 	}
 
diff --git a/bsps/sparc/shared/pci/grpci2.c b/bsps/sparc/shared/pci/grpci2.c
index 2d8e152..69aa938 100644
--- a/bsps/sparc/shared/pci/grpci2.c
+++ b/bsps/sparc/shared/pci/grpci2.c
@@ -905,7 +905,7 @@ int grpci2_init1(struct drvmgr_dev *dev)
 	/* Initialize GRPCI2 Hardware */
 	status = grpci2_init(priv);
 	if (status) {
-		printf("Failed to initialize grpci2 driver %d\n", status);
+		printk("Failed to initialize grpci2 driver %d\n", status);
 		return -1;
 	}
 
diff --git a/bsps/sparc/shared/pci/pcif.c b/bsps/sparc/shared/pci/pcif.c
index c0b8fc9..8603c99 100644
--- a/bsps/sparc/shared/pci/pcif.c
+++ b/bsps/sparc/shared/pci/pcif.c
@@ -509,7 +509,7 @@ int pcif_init1(struct drvmgr_dev *dev)
 	DBG("PCIF[%d] on bus %s\n", dev->minor_drv, dev->parent->dev->name);
 
 	if ( pcif_minor != 0 ) {
-		printf("Driver only supports one PCI core\n");
+		printk("Driver only supports one PCI core\n");
 		return DRVMGR_FAIL;
 	}
 
@@ -523,7 +523,7 @@ int pcif_init1(struct drvmgr_dev *dev)
 
 	pcifpriv = priv;
 	if ( pcif_init(priv) ) {
-		printf("Failed to initialize PCIF driver\n");
+		printk("Failed to initialize PCIF driver\n");
 		free(priv);
 		dev->priv = NULL;
 		return DRVMGR_FAIL;
diff --git a/bsps/sparc/shared/spi/spictrl.c b/bsps/sparc/shared/spi/spictrl.c
index 2d63988..0c940d3 100644
--- a/bsps/sparc/shared/spi/spictrl.c
+++ b/bsps/sparc/shared/spi/spictrl.c
@@ -719,7 +719,7 @@ STATIC int spictrl_libi2c_read_bytes(rtems_libi2c_bus_t *bushdl,
 	DBG("SPICTRL: spictrl_libi2c_read_bytes %d\n", nbytes);
 	ret = spictrl_read_write(priv, bytes, NULL, nbytes);
 	if ( ret < 0 ) {
-		printf("SPICTRL: Error Reading\n");
+		printk("SPICTRL: Error Reading\n");
 	} 
 #ifdef DEBUG
 	else {
-- 
2.7.4



More information about the devel mailing list