staging: greybus: pwm: Drop unused gb_connection_set_data()
authorUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Wed, 14 Feb 2024 09:33:25 +0000 (10:33 +0100)
committerUwe Kleine-König <u.kleine-koenig@pengutronix.de>
Thu, 22 Feb 2024 13:39:28 +0000 (14:39 +0100)
The driver never calls gb_connection_get_data(). If there was another
caller (say the greybus core) it cannot use the value because the type
of pwmc (= struct gb_pwm_chip) is only defined in the pwm driver.

So drop the call to gb_connection_set_data().

Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Link: https://lore.kernel.org/r/bd2759c325c295f3d9f990609d97eb83a8ca88b8.1707900770.git.u.kleine-koenig@pengutronix.de
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
drivers/staging/greybus/pwm.c

index 3099c2a3611cabc3e245fb45993275c8363d12e7..c7a2e874a62be3a591a80cd6b9ad34aa0150567b 100644 (file)
@@ -260,7 +260,6 @@ static int gb_pwm_probe(struct gbphy_device *gbphy_dev,
        }
 
        pwmc->connection = connection;
-       gb_connection_set_data(connection, pwmc);
        gb_gbphy_set_data(gbphy_dev, chip);
 
        ret = gb_connection_enable(connection);