Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp3682949imm; Thu, 17 May 2018 12:50:23 -0700 (PDT) X-Google-Smtp-Source: AB8JxZoLJdr/rWKqAx/Ry6VNCO0E3iy+kQhv37y14A4VEyebjsnXeoEfTBZCXM4w0LVoxwMaIjzF X-Received: by 2002:a63:7453:: with SMTP id e19-v6mr4892700pgn.87.1526586623730; Thu, 17 May 2018 12:50:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526586623; cv=none; d=google.com; s=arc-20160816; b=RZnXqBJ3OHT51HPQGhPlMitU5UbTJeBMRD5k6zXEYmTlp5e08tkdZGfuBx1hDxolrZ kPmHhc0no0oxnXGSPFw++I3BBAUV7xQpOy5Wjn5FKVuq+JoMHPHigOwAi/xp42DADzMX QocO1EuIGUqLpEQ4o2HoY11uVuyCKsis0/eeDlvWUqzd+6Ctbjko2mMastdSF3JeGdkj 8tm24WJW7J//9OPWqqUdWuRyc4kJ4UYaT3mASh0xPo3hcIEdDriSfaCDqVrUbHp5u3cw EM7grN8u2oyLkTEWRFPEnN7FDkew0ftERD1kv6xacokhtNAqGihfQmofiBorhXFC86up VZmw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject:dmarc-filter :dkim-signature:dkim-signature:arc-authentication-results; bh=BvexvwJ8fdt09BoR7/7RFb5m3QaoUbpQuScT9UVS7JU=; b=egmimZCY4jmdD9vVUq5WRW1Je2WN97ULoJZ8vMw1G9CQMXiXfR78ChpIz9rtZ4FPiE erdxrpNvm4tZU0dn7H/Hj2QGOmZExX6WkDUk/HhuSe0/5nu5LOvDxC1gsMdjjXfBppeQ sXFu83CXoUJIg3HZTNwz3/AH3ztyhVp492YexHVR0BbA5X9XG+QVjJYdCYddJJ/yAFBq nNrskhfypavn9LKIoJq0pIL9Wzm29SaXt8Ckztp86rGxaqSZGhQUR0Uc6UWIbvtGPciZ FID269kRP45Eqkktp4sdu4Rt+IPeWJdJc3Xf1imhZJOdAObCsZHkFMtfo+sSDR8kOEua hmvA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=TnH51Aey; dkim=pass header.i=@codeaurora.org header.s=default header.b=VwcwjFT7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 200-v6si4674859pge.492.2018.05.17.12.50.09; Thu, 17 May 2018 12:50:23 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@codeaurora.org header.s=default header.b=TnH51Aey; dkim=pass header.i=@codeaurora.org header.s=default header.b=VwcwjFT7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752175AbeEQTsp (ORCPT + 99 others); Thu, 17 May 2018 15:48:45 -0400 Received: from smtp.codeaurora.org ([198.145.29.96]:50288 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752130AbeEQTsm (ORCPT ); Thu, 17 May 2018 15:48:42 -0400 Received: by smtp.codeaurora.org (Postfix, from userid 1000) id 3A09F605A8; Thu, 17 May 2018 19:48:41 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1526586521; bh=VI0dZ7zmgfYDqLXmUzJz7dfZaMOpTNbhcgbac6JAWz8=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=TnH51Aeyzy+HVWuDcOv6FudiG/e+fuBwhU0OMQrDl+ER83I2QkJ+BXuww3RS/NNI9 YJH/EHiM24LHcza9sPvT9WNiQIroNzLrAUmDNRPcbmNqCK175/7SQR342eM6G4oFYe mkFCgAo6xrJNh8xtGMtQ/bS87NhHZBUL2rcj/1FU= X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on pdx-caf-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.8 required=2.0 tests=ALL_TRUSTED,BAYES_00, DKIM_SIGNED,T_DKIM_INVALID autolearn=no autolearn_force=no version=3.4.0 Received: from [10.226.58.143] (i-global254.qualcomm.com [199.106.103.254]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) (Authenticated sender: pprakash@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id CDD60605A8; Thu, 17 May 2018 19:48:39 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=codeaurora.org; s=default; t=1526586520; bh=VI0dZ7zmgfYDqLXmUzJz7dfZaMOpTNbhcgbac6JAWz8=; h=Subject:To:Cc:References:From:Date:In-Reply-To:From; b=VwcwjFT79YHLbs9i5bqbrGhWPzz4eu9kbYsRYYXZjQOUbNVZaNkIv0HGHGokJ2CZI 328Pl52mi7FuTuWvW9xpuT+ziaGLJkJ5MLAGJSw3ALpjgPgVPFVUvSfUChM/+kWc5s jZ96ZnF8Cm9tttNlztwAy76DDNlTMPeAi3knj1kA= DMARC-Filter: OpenDMARC Filter v1.3.2 smtp.codeaurora.org CDD60605A8 Authentication-Results: pdx-caf-mail.web.codeaurora.org; dmarc=none (p=none dis=none) header.from=codeaurora.org Authentication-Results: pdx-caf-mail.web.codeaurora.org; spf=none smtp.mailfrom=pprakash@codeaurora.org Subject: Re: [PATCH v4 3/3] mailbox: ACPI: erroneous error message when parsing the ACPI, PCCT To: "Rafael J. Wysocki" , Al Stone Cc: ACPI Devel Maling List , Linux Kernel Mailing List , Jassi Brar , "Rafael J . Wysocki" , Len Brown References: <20180501003907.4322-1-ahs3@redhat.com> <20180501003907.4322-4-ahs3@redhat.com> <17197481-bd76-f2ec-9d6e-4cd0d94b9265@codeaurora.org> From: "Prakash, Prashanth" Message-ID: <85c95aad-fefb-50f4-8a06-eec25415db2a@codeaurora.org> Date: Thu, 17 May 2018 13:48:39 -0600 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/17/2018 4:24 AM, Rafael J. Wysocki wrote: > On Thu, May 17, 2018 at 12:01 AM, Al Stone wrote: >> There have been multiple reports of the following error message: >> >> [ 0.068293] Error parsing PCC subspaces from PCCT >> >> This error message is not correct. In multiple cases examined, the PCCT >> (Platform Communications Channel Table) concerned is actually properly >> constructed; the problem is that acpi_pcc_probe() which reads the PCCT >> is making the assumption that the only valid PCCT is one that contains >> subtables of one of two types: ACPI_PCCT_TYPE_HW_REDUCED_SUBSPACE or >> ACPI_PCCT_TYPE_HW_REDUCED_TYPE2. The number of subtables of these >> types are counted and as long as there is at least one of the desired >> types, the acpi_pcc_probe() succeeds. When no subtables of these types >> are found, regardless of whether or not any other subtable types are >> present, the error mentioned above is reported. >> >> In the cases reported to me personally, the PCCT contains exactly one >> subtable of type ACPI_PCCT_TYPE_GENERIC_SUBSPACE. The function >> acpi_pcc_probe() does not count it as a valid subtable, so believes >> there to be no valid subtables, and hence outputs the error message. >> >> An example of the PCCT being reported as erroneous yet perfectly fine >> is the following: >> >> Signature : "PCCT" >> Table Length : 0000006E >> Revision : 05 >> Checksum : A9 >> Oem ID : "XXXXXX" >> Oem Table ID : "XXXXX " >> Oem Revision : 00002280 >> Asl Compiler ID : "XXXX" >> Asl Compiler Revision : 00000002 >> >> Flags (decoded below) : 00000001 >> Platform : 1 >> Reserved : 0000000000000000 >> >> Subtable Type : 00 [Generic Communications Subspace] >> Length : 3E >> >> Reserved : 000000000000 >> Base Address : 00000000DCE43018 >> Address Length : 0000000000001000 >> >> Doorbell Register : [Generic Address Structure] >> Space ID : 01 [SystemIO] >> Bit Width : 08 >> Bit Offset : 00 >> Encoded Access Width : 01 [Byte Access:8] >> Address : 0000000000001842 >> >> Preserve Mask : 00000000000000FD >> Write Mask : 0000000000000002 >> Command Latency : 00001388 >> Maximum Access Rate : 00000000 >> Minimum Turnaround Time : 0000 >> >> To fix this, we count up all of the possible subtable types for the >> PCCT, and only report an error when there are none (which could mean >> either no subtables, or no valid subtables), or there are too many. >> We also change the logic so that if there is a valid subtable, we >> do try to initialize it per the PCCT subtable contents. This is a >> change in functionality; previously, the probe would have returned >> right after the error message and would not have tried to use any >> other subtable definition. >> >> Tested on my personal laptop which showed the error previously; the >> error message no longer appears and the laptop appears to operate >> normally. > I'd like to know the Prashanth's opinion here. Looks good. Reviewed-by: Prashanth Prakash -- Thanks, Prashanth