Commit 7333549b authored by Peter Huewe's avatar Peter Huewe Committed by Kent Yoder

char/tpm/tpm_i2c_stm_st33: drop temporary variable for return value

We don't need a temporary variable just to store the return value which
gets return in the next statement.
Signed-off-by: default avatarPeter Huewe <peterhuewe@gmx.de>
Signed-off-by: default avatarKent Yoder <key@linux.vnet.ibm.com>
parent 07d72168
......@@ -96,16 +96,14 @@ enum tis_defaults {
static int write8_reg(struct i2c_client *client, u8 tpm_register,
u8 *tpm_data, u16 tpm_size)
{
int value = 0;
struct st33zp24_platform_data *pin_infos;
pin_infos = client->dev.platform_data;
pin_infos->tpm_i2c_buffer[0][0] = tpm_register;
memcpy(&pin_infos->tpm_i2c_buffer[0][1], tpm_data, tpm_size);
value = i2c_master_send(client, pin_infos->tpm_i2c_buffer[0],
return i2c_master_send(client, pin_infos->tpm_i2c_buffer[0],
tpm_size + 1);
return value;
} /* write8_reg() */
/*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment