Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

mfd: intel_soc_pmic_bxtwc: Use temporary variable for struct device

Use a temporary variable for the struct device pointers to avoid
dereferencing. This makes code a bit neater.

Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Link: https://lore.kernel.org/r/20241016105201.757024-4-andriy.shevchenko@linux.intel.com
Signed-off-by: Lee Jones <lee@kernel.org>

authored by

Andy Shevchenko and committed by
Lee Jones
3d6b7374 d2e77347

+3 -3
+3 -3
drivers/mfd/intel_soc_pmic_bxtwc.c
··· 434 434 const struct regmap_irq_chip *chip, 435 435 struct regmap_irq_chip_data **data) 436 436 { 437 + struct device *dev = pmic->dev; 437 438 int irq; 438 439 439 440 irq = regmap_irq_get_virq(pdata, pirq); 440 441 if (irq < 0) 441 - return dev_err_probe(pmic->dev, irq, "Failed to get parent vIRQ(%d) for chip %s\n", 442 + return dev_err_probe(dev, irq, "Failed to get parent vIRQ(%d) for chip %s\n", 442 443 pirq, chip->name); 443 444 444 - return devm_regmap_add_irq_chip(pmic->dev, pmic->regmap, irq, irq_flags, 445 - 0, chip, data); 445 + return devm_regmap_add_irq_chip(dev, pmic->regmap, irq, irq_flags, 0, chip, data); 446 446 } 447 447 448 448 static int bxtwc_add_chained_devices(struct intel_soc_pmic *pmic,