Skip to content

Commit fe7d2c2

Browse files
committed
Merge tag 'platform-drivers-x86-v5.4-3' of git://git.infradead.org/linux-platform-drivers-x86
Pull x86 platform driver fixes from Andy Shevchenko: - Users of Intel P-Unit IPC driver might be surprised by harmless warning. Thus, switch to API which doesn't issue a warning at all. - I²C multi-instantiate driver continues to add slave devices even when IRQ resource is not found. For devices in the market IRQ resource is mandatory, so, fail the ->probe() of the parent driver to avoid slaves being probed. - Avoid compiler warning due to unused variable in Classmate laptop driver. * tag 'platform-drivers-x86-v5.4-3' of git://git.infradead.org/linux-platform-drivers-x86: platform/x86: i2c-multi-instantiate: Fail the probe if no IRQ provided platform/x86: intel_punit_ipc: Avoid error message when retrieving IRQ platform/x86: classmate-laptop: remove unused variable
2 parents 7801158 + 832392d commit fe7d2c2

3 files changed

Lines changed: 2 additions & 14 deletions

File tree

‎drivers/platform/x86/classmate-laptop.c‎

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -420,12 +420,6 @@ static int cmpc_accel_add_v4(struct acpi_device *acpi)
420420

421421
static int cmpc_accel_remove_v4(struct acpi_device *acpi)
422422
{
423-
struct input_dev *inputdev;
424-
struct cmpc_accel *accel;
425-
426-
inputdev = dev_get_drvdata(&acpi->dev);
427-
accel = dev_get_drvdata(&inputdev->dev);
428-
429423
device_remove_file(&acpi->dev, &cmpc_accel_sensitivity_attr_v4);
430424
device_remove_file(&acpi->dev, &cmpc_accel_g_select_attr_v4);
431425
return cmpc_remove_acpi_notify_device(acpi);
@@ -656,12 +650,6 @@ static int cmpc_accel_add(struct acpi_device *acpi)
656650

657651
static int cmpc_accel_remove(struct acpi_device *acpi)
658652
{
659-
struct input_dev *inputdev;
660-
struct cmpc_accel *accel;
661-
662-
inputdev = dev_get_drvdata(&acpi->dev);
663-
accel = dev_get_drvdata(&inputdev->dev);
664-
665653
device_remove_file(&acpi->dev, &cmpc_accel_sensitivity_attr);
666654
return cmpc_remove_acpi_notify_device(acpi);
667655
}

‎drivers/platform/x86/i2c-multi-instantiate.c‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ static int i2c_multi_inst_probe(struct platform_device *pdev)
108108
if (ret < 0) {
109109
dev_dbg(dev, "Error requesting irq at index %d: %d\n",
110110
inst_data[i].irq_idx, ret);
111+
goto error;
111112
}
112113
board_info.irq = ret;
113114
break;

‎drivers/platform/x86/intel_punit_ipc.c‎

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -293,9 +293,8 @@ static int intel_punit_ipc_probe(struct platform_device *pdev)
293293

294294
platform_set_drvdata(pdev, punit_ipcdev);
295295

296-
irq = platform_get_irq(pdev, 0);
296+
irq = platform_get_irq_optional(pdev, 0);
297297
if (irq < 0) {
298-
punit_ipcdev->irq = 0;
299298
dev_warn(&pdev->dev, "Invalid IRQ, using polling mode\n");
300299
} else {
301300
ret = devm_request_irq(&pdev->dev, irq, intel_punit_ioc,

0 commit comments

Comments
 (0)