osi: core: fix coverity issues

Defects/Coding rule violations found : 3 Total
	FORWARD_NULL 	 1 - (Deviation Not approved)
	UNUSED_VALUE 	 2 - (Deviation Not approved)

Bug 200671160

Change-Id: Icabb21606a5758ad79e92d9d67e2be9cb889723e
Signed-off-by: Bhadram Varka <vbhadram@nvidia.com>
This commit is contained in:
Bhadram Varka
2021-03-21 17:20:33 +05:30
parent a57fdb926a
commit 6ca2bcb767
2 changed files with 2 additions and 4 deletions

View File

@@ -3038,7 +3038,7 @@ static nve32_t eqos_adjust_mactime(struct osi_core_priv_data *const osi_core,
} }
/* write seconds value to MAC_System_Time_Seconds_Update register */ /* write seconds value to MAC_System_Time_Seconds_Update register */
osi_writela(osi_core, sec, (nveu8_t *)addr + EQOS_MAC_STSUR); osi_writela(osi_core, sec1, (nveu8_t *)addr + EQOS_MAC_STSUR);
/* write nano seconds value and add_sub to /* write nano seconds value and add_sub to
* MAC_System_Time_Nanoseconds_Update register * MAC_System_Time_Nanoseconds_Update register

View File

@@ -130,8 +130,6 @@ nve32_t osi_init_core_ops(struct osi_core_priv_data *const osi_core)
(osi_core->osd_ops.udelay == OSI_NULL) || (osi_core->osd_ops.udelay == OSI_NULL) ||
(osi_core->osd_ops.msleep == OSI_NULL) || (osi_core->osd_ops.msleep == OSI_NULL) ||
(osi_core->osd_ops.usleep_range == OSI_NULL)) { (osi_core->osd_ops.usleep_range == OSI_NULL)) {
OSI_CORE_ERR(OSI_NULL, OSI_LOG_ARG_INVALID,
"CORE OSD ops not assigned\n", 0ULL);
return -1; return -1;
} }
@@ -282,7 +280,7 @@ nve32_t osi_config_fw_err_pkts(struct osi_core_priv_data *const osi_core,
nve32_t osi_l2_filter(struct osi_core_priv_data *const osi_core, nve32_t osi_l2_filter(struct osi_core_priv_data *const osi_core,
const struct osi_filter *filter) const struct osi_filter *filter)
{ {
nve32_t ret = -1; nve32_t ret;
if ((validate_args(osi_core) < 0) || (filter == OSI_NULL)) { if ((validate_args(osi_core) < 0) || (filter == OSI_NULL)) {
return -1; return -1;