Return-Path: Received: from mail-bn3nam01on0133.outbound.protection.outlook.com ([104.47.33.133]:58170 "EHLO NAM01-BN3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753966AbeARVA3 (ORCPT ); Thu, 18 Jan 2018 16:00:29 -0500 From: Sasha Levin To: "stable@vger.kernel.org" , "stable-commits@vger.kernel.org" CC: Alex Hung , "Rafael J . Wysocki" , Sasha Levin Subject: [added to the 4.1 stable tree] ACPI / video: skip evaluating _DOD when it does not exist Date: Thu, 18 Jan 2018 20:59:51 +0000 Message-ID: <20180118205908.3220-53-alexander.levin@microsoft.com> References: <20180118205908.3220-1-alexander.levin@microsoft.com> In-Reply-To: <20180118205908.3220-1-alexander.levin@microsoft.com> Content-Language: en-US Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Sender: stable-owner@vger.kernel.org List-ID: From: Alex Hung This patch has been added to the stable tree. If you have any objections, please let us know. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D [ Upstream commit e34fbbac669de0b7fb7803929d0477f35f6e2833 ] Some system supports hybrid graphics and its discrete VGA does not have any connectors and therefore has no _DOD method. Signed-off-by: Alex Hung Reviewed-by: Aaron Lu Signed-off-by: Rafael J. Wysocki Signed-off-by: Sasha Levin --- drivers/acpi/video.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/acpi/video.c b/drivers/acpi/video.c index cc79d3fedfb2..493811b895bd 100644 --- a/drivers/acpi/video.c +++ b/drivers/acpi/video.c @@ -1276,6 +1276,9 @@ static int acpi_video_device_enumerate(struct acpi_vi= deo_bus *video) union acpi_object *dod =3D NULL; union acpi_object *obj; =20 + if (!video->cap._DOD) + return AE_NOT_EXIST; + status =3D acpi_evaluate_object(video->device->handle, "_DOD", NULL, &buf= fer); if (!ACPI_SUCCESS(status)) { ACPI_EXCEPTION((AE_INFO, status, "Evaluating _DOD")); --=20 2.11.0