From patchwork Thu Sep 10 07:35:56 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Aaron Lu X-Patchwork-Id: 7151671 Return-Path: X-Original-To: patchwork-linux-acpi@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 2B3659F314 for ; Thu, 10 Sep 2015 07:34:16 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 6FE4E208E1 for ; Thu, 10 Sep 2015 07:34:15 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 9C8EB20618 for ; Thu, 10 Sep 2015 07:34:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753088AbbIJHeN (ORCPT ); Thu, 10 Sep 2015 03:34:13 -0400 Received: from mga14.intel.com ([192.55.52.115]:61907 "EHLO mga14.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751462AbbIJHeN (ORCPT ); Thu, 10 Sep 2015 03:34:13 -0400 Received: from fmsmga003.fm.intel.com ([10.253.24.29]) by fmsmga103.fm.intel.com with ESMTP; 10 Sep 2015 00:34:13 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.17,502,1437462000"; d="scan'208";a="558860256" Received: from aaronlu.sh.intel.com ([10.239.159.104]) by FMSMGA003.fm.intel.com with ESMTP; 10 Sep 2015 00:34:12 -0700 Date: Thu, 10 Sep 2015 15:35:56 +0800 From: Aaron Lu To: Benjamin Tissoires , linux-acpi@vger.kernel.org, "Rafael J. Wysocki" , Mika Westerberg Cc: Bastien Nocera , Yu Chen Subject: Re: New Surface 3 (atom x7) having problems with ACPI regions Message-ID: <20150910073556.GA6863@aaronlu.sh.intel.com> References: <55F0FD2A.7050900@intel.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <55F0FD2A.7050900@intel.com> Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, T_RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP On Thu, Sep 10, 2015 at 11:46:50AM +0800, Aaron Lu wrote: > I'm not so sure of the below part: > " > The failure of executing the _STA control method will cause the device > node not having the acpi_device structure created and then in the SPI > ACPI enumerate function acpi_spi_add_device, it will not be created and > used. > " With the above said, I wonder if the following patch which ignores the error return of the _STA and set status to 0 makes any difference? --- To unsubscribe from this list: send the line "unsubscribe linux-acpi" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/acpi/scan.c b/drivers/acpi/scan.c index ec256352f423..418c8a7cec91 100644 --- a/drivers/acpi/scan.c +++ b/drivers/acpi/scan.c @@ -2293,7 +2293,7 @@ static int acpi_bus_type_and_status(acpi_handle handle, int *type, *type = ACPI_BUS_TYPE_DEVICE; status = acpi_bus_get_status_handle(handle, sta); if (ACPI_FAILURE(status)) - return -ENODEV; + *sta = 0; break; case ACPI_TYPE_PROCESSOR: *type = ACPI_BUS_TYPE_PROCESSOR;