* [PATCH 2/2] ASoC: codecs: max98390: simplify getting the adapter of a client
[not found] <20210918213553.14514-1-wsa+renesas@sang-engineering.com>
@ 2021-09-18 21:35 ` Wolfram Sang
0 siblings, 0 replies; only message in thread
From: Wolfram Sang @ 2021-09-18 21:35 UTC (permalink / raw)
To: linux-kernel
Cc: alsa-devel, Takashi Iwai, Liam Girdwood, Wolfram Sang, Mark Brown
We have a dedicated pointer for that, so use it. Much easier to read and
less computation involved.
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---
Please apply to your subsystem tree.
sound/soc/codecs/max98390.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/soc/codecs/max98390.c b/sound/soc/codecs/max98390.c
index b392567c2b3e..d1882cbc9381 100644
--- a/sound/soc/codecs/max98390.c
+++ b/sound/soc/codecs/max98390.c
@@ -1021,7 +1021,7 @@ static int max98390_i2c_probe(struct i2c_client *i2c,
int reg = 0;
struct max98390_priv *max98390 = NULL;
- struct i2c_adapter *adapter = to_i2c_adapter(i2c->dev.parent);
+ struct i2c_adapter *adapter = i2c->adapter;
ret = i2c_check_functionality(adapter,
I2C_FUNC_SMBUS_BYTE
--
2.30.2
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2021-09-18 21:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
[not found] <20210918213553.14514-1-wsa+renesas@sang-engineering.com>
2021-09-18 21:35 ` [PATCH 2/2] ASoC: codecs: max98390: simplify getting the adapter of a client Wolfram Sang
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).