Skip to content

Commit

Permalink
pwm: Remove redundant assignment to pointer pwm
Browse files Browse the repository at this point in the history
The pointer pwm is being initialized with a value that is never read and
it is being updated later with a new value. The initialization is
redundant and can be removed.

Addresses-Coverity: ("Unused value")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
  • Loading branch information
Colin Ian King authored and Thierry Reding committed Jul 7, 2021
1 parent 96e45e5 commit bebedf2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/pwm/core.c
Original file line number Diff line number Diff line change
Expand Up @@ -846,7 +846,7 @@ EXPORT_SYMBOL_GPL(of_pwm_get);
*/
static struct pwm_device *acpi_pwm_get(const struct fwnode_handle *fwnode)
{
struct pwm_device *pwm = ERR_PTR(-ENODEV);
struct pwm_device *pwm;
struct fwnode_reference_args args;
struct pwm_chip *chip;
int ret;
Expand Down

0 comments on commit bebedf2

Please sign in to comment.