amdgpu/dc: remove pointless returns in the i2caux constructor paths. (v2)

There was lots of return true, and error checking that was never used
in these paths.

Just remove it all.

v2: I missed one return true.

Signed-off-by: Dave Airlie <airlied@redhat.com>
Reviewed-by: Harry Wentland <harry.wentland@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
Dave Airlie
2017-09-29 15:44:54 +10:00
committed by Alex Deucher
parent 4179cd8137
commit b08c3ca4e9
28 changed files with 100 additions and 246 deletions

View File

@@ -87,22 +87,16 @@ static const struct dce110_i2c_hw_engine_mask i2c_mask = {
I2C_COMMON_MASK_SH_LIST_DCE110(_MASK)
};
static bool construct(
static void construct(
struct i2caux_dce110 *i2caux_dce110,
struct dc_context *ctx)
{
if (!dal_i2caux_dce110_construct(
i2caux_dce110,
ctx,
dce112_aux_regs,
dce112_hw_engine_regs,
&i2c_shift,
&i2c_mask)) {
ASSERT_CRITICAL(false);
return false;
}
return true;
dal_i2caux_dce110_construct(i2caux_dce110,
ctx,
dce112_aux_regs,
dce112_hw_engine_regs,
&i2c_shift,
&i2c_mask);
}
/*
@@ -129,12 +123,6 @@ struct i2caux *dal_i2caux_dce112_create(
return NULL;
}
if (construct(i2caux_dce110, ctx))
return &i2caux_dce110->base;
ASSERT_CRITICAL(false);
kfree(i2caux_dce110);
return NULL;
construct(i2caux_dce110, ctx);
return &i2caux_dce110->base;
}