Skip to content

Commit

Permalink
i2c: rcar: optimize cacheline to minimize HW race condition
Browse files Browse the repository at this point in the history
[ Upstream commit 25c2e0f ]

'flags' and 'io' are needed first, so they should be at the beginning of
the private struct.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
Reviewed-by: Niklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Signed-off-by: Wolfram Sang <wsa@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
  • Loading branch information
Wolfram Sang authored and gregkh committed Mar 17, 2021
1 parent 1e1aace commit 5f04f97
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/i2c/busses/i2c-rcar.c
Expand Up @@ -116,6 +116,7 @@ enum rcar_i2c_type {
};

struct rcar_i2c_priv {
u32 flags;
void __iomem *io;
struct i2c_adapter adap;
struct i2c_msg *msg;
Expand All @@ -126,7 +127,6 @@ struct rcar_i2c_priv {

int pos;
u32 icccr;
u32 flags;
u8 recovery_icmcr; /* protected by adapter lock */
enum rcar_i2c_type devtype;
struct i2c_client *slave;
Expand Down

0 comments on commit 5f04f97

Please sign in to comment.