From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A42C641C56; Thu, 9 Feb 2023 23:24:00 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 833D542D51; Thu, 9 Feb 2023 23:23:20 +0100 (CET) Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mails.dpdk.org (Postfix) with ESMTP id 340A642670 for ; Thu, 9 Feb 2023 23:23:10 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1675981390; x=1707517390; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=pvDW38u5DkfxicweyuL0Mv/nHi0tZGPDgHuAh847Tl8=; b=QkKAXwGmtOpLaWEmq+EATDoRXG+1pWWKgAHNf/WutaHmQWVofWMcWBt4 q6MjaMgmT/B5lIiQ7K5D72KFxixC5Q0fwQh1U9agfBhKinA/5gylo7Db5 eQ61B8o48mT/+asQ6R71y+IvM8aXFSs2Dw3Z95Zv8viaWNDMWgbsL0rW5 Irfv7CMKHaaJIjkSft2UN5BkbDBqL2xV2noVXfRorekBM5k7RCkBNpaA9 wlDGW2t5g6Fi+8chwf4EsYUD1qEbKIga0NxPAkWO461LXrN6IGkXJHoPC fCizjAP93QAefSilB1kiW6WLGhjk6MOAdGNtygV4Z8cbDbcJ2DA46lNVu Q==; X-IronPort-AV: E=McAfee;i="6500,9779,10616"; a="331563063" X-IronPort-AV: E=Sophos;i="5.97,285,1669104000"; d="scan'208";a="331563063" Received: from fmsmga004.fm.intel.com ([10.253.24.48]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 09 Feb 2023 14:23:08 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6500,9779,10616"; a="736513289" X-IronPort-AV: E=Sophos;i="5.97,285,1669104000"; d="scan'208";a="736513289" Received: from spr-npg-bds1-eec2.sn.intel.com (HELO spr-npg-bds1-eec2..) ([10.233.181.123]) by fmsmga004.fm.intel.com with ESMTP; 09 Feb 2023 14:23:07 -0800 From: Nicolas Chautru To: dev@dpdk.org, maxime.coquelin@redhat.com Cc: hernan.vargas@intel.com, stable@dpdk.or, Nicolas Chautru Subject: [PATCH v1 9/9] baseband/acc: remove printf from PMD function Date: Thu, 9 Feb 2023 22:19:29 +0000 Message-Id: <20230209221929.265059-10-nicolas.chautru@intel.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230209221929.265059-1-nicolas.chautru@intel.com> References: <20230209221929.265059-1-nicolas.chautru@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Replacing usage of printf in companion function for bbdev-test by rte_log. Signed-off-by: Nicolas Chautru --- drivers/baseband/acc/rte_acc100_pmd.c | 18 +++++++++--------- drivers/baseband/acc/rte_vrb_pmd.c | 2 +- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/drivers/baseband/acc/rte_acc100_pmd.c b/drivers/baseband/acc/rte_acc100_pmd.c index 36f6fec5ad..40b5eaf089 100644 --- a/drivers/baseband/acc/rte_acc100_pmd.c +++ b/drivers/baseband/acc/rte_acc100_pmd.c @@ -4347,7 +4347,7 @@ poweron_cleanup(struct rte_bbdev *bbdev, struct acc_device *d, { int i, template_idx, qg_idx; uint32_t address, status, value; - printf("Need to clear power-on 5GUL status in internal memory\n"); + rte_bbdev_log(WARNING, "Need to clear power-on 5GUL status in internal memory"); /* Reset LDPC Cores */ for (i = 0; i < ACC100_ENGINES_MAX; i++) acc_reg_write(d, HWPfFecUl5gCntrlReg + @@ -4421,7 +4421,7 @@ poweron_cleanup(struct rte_bbdev *bbdev, struct acc_device *d, /* Force each engine which is in unspecified state */ for (i = 0; i < num_failed_engine; i++) { int failed_engine = engines_to_restart[i]; - printf("Force engine %d\n", failed_engine); + rte_bbdev_log(WARNING, "Force engine %d", failed_engine); for (template_idx = ACC100_SIG_UL_5G; template_idx <= ACC100_SIG_UL_5G_LAST; template_idx++) { @@ -4450,7 +4450,7 @@ poweron_cleanup(struct rte_bbdev *bbdev, struct acc_device *d, acc_reg_write(d, HWPfQmgrIngressAq + 0x100, enq_req.val); usleep(ACC_LONG_WAIT * 100); if (desc->req.word0 != 2) - printf("DMA Response %#"PRIx32"\n", desc->req.word0); + rte_bbdev_log(WARNING, "DMA Response %#"PRIx32"\n", desc->req.word0); } /* Reset LDPC Cores */ @@ -4482,7 +4482,7 @@ poweron_cleanup(struct rte_bbdev *bbdev, struct acc_device *d, } else acc_reg_write(d, address, 0); } - printf("Number of 5GUL engines %d\n", numEngines); + rte_bbdev_log(INFO, "Number of 5GUL engines %d", numEngines); rte_free(d->sw_rings_base); usleep(ACC_LONG_WAIT); @@ -4671,7 +4671,7 @@ acc100_configure(const char *dev_name, struct rte_acc_conf *conf) } else acc_reg_write(d, address, 0); } - printf("Number of 5GUL engines %d\n", numEngines); + rte_bbdev_log(INFO, "Number of 5GUL engines %d", numEngines); /* 4GDL */ numQqsAcc += numQgs; numQgs = conf->q_dl_4g.num_qgroups; @@ -4801,7 +4801,7 @@ acc100_configure(const char *dev_name, struct rte_acc_conf *conf) version += acc_reg_read(d, HWPfDdrPhyIdtmFwVersion + 4 * i) << (8 * i); if (version != ACC100_PRQ_DDR_VER) { - printf("* Note: Not on DDR PRQ version %8x != %08x\n", + rte_bbdev_log(ERR, "* Note: Not on DDR PRQ version %8x != %08x", version, ACC100_PRQ_DDR_VER); } else if (firstCfg) { /* ---- DDR configuration at boot up --- */ @@ -4871,7 +4871,7 @@ acc100_configure(const char *dev_name, struct rte_acc_conf *conf) if (value & 1) break; } - printf("DDR Training completed in %d ms", i); + rte_bbdev_log(INFO, "DDR Training completed in %d ms", i); /* Enable Memory Controller */ acc_reg_write(d, HWPfDdrUmmcCtrl, 0x401); /* Release AXI interface reset */ @@ -5047,7 +5047,7 @@ acc101_configure(const char *dev_name, struct rte_acc_conf *conf) } else acc_reg_write(d, address, 0); } - printf("Number of 5GUL engines %d\n", numEngines); + rte_bbdev_log(INFO, "Number of 5GUL engines %d", numEngines); /* 4GDL */ numQqsAcc += numQgs; numQgs = conf->q_dl_4g.num_qgroups; @@ -5185,7 +5185,7 @@ rte_acc_configure(const char *dev_name, struct rte_acc_conf *conf) return -ENODEV; } struct rte_pci_device *pci_dev = RTE_DEV_TO_PCI(bbdev->device); - printf("Configure dev id %x\n", pci_dev->id.device_id); + rte_bbdev_log(INFO, "Configure dev id %x", pci_dev->id.device_id); if (pci_dev->id.device_id == ACC100_PF_DEVICE_ID) return acc100_configure(dev_name, conf); else if (pci_dev->id.device_id == ACC101_PF_DEVICE_ID) diff --git a/drivers/baseband/acc/rte_vrb_pmd.c b/drivers/baseband/acc/rte_vrb_pmd.c index 18b5dab25f..c37f725415 100644 --- a/drivers/baseband/acc/rte_vrb_pmd.c +++ b/drivers/baseband/acc/rte_vrb_pmd.c @@ -3633,7 +3633,7 @@ vrb1_configure(const char *dev_name, struct rte_acc_conf *conf) } else acc_reg_write(d, address, 0); } - printf("Number of 5GUL engines %d\n", numEngines); + rte_bbdev_log(INFO, "Number of 5GUL engines %d", numEngines); /* 4GDL */ numQqsAcc += numQgs; numQgs = conf->q_dl_4g.num_qgroups; -- 2.34.1