From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754060AbdCPVT2 (ORCPT ); Thu, 16 Mar 2017 17:19:28 -0400 Received: from mga03.intel.com ([134.134.136.65]:14365 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752657AbdCPVT0 (ORCPT ); Thu, 16 Mar 2017 17:19:26 -0400 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.36,173,1486454400"; d="scan'208";a="68165293" Reply-To: sathyanarayanan.kuppuswamy@linux.intel.com Subject: Re: [PATCH v1 1/1] platform/x86: intel_pmc_ipc: fix io mem mapping size References: <1ab8d18dd7f5428869e6e77026ac4206863eea08.1489634924.git.sathyanarayanan.kuppuswamy@linux.intel.com> <20170316145203.GA23198@rajaneesh-OptiPlex-9010> <20170316181356.GA19029@rajaneesh-OptiPlex-9010> To: Andy Shevchenko , Rajneesh Bhardwaj Cc: Andy Shevchenko , Zha Qipeng , "dvhart@infradead.org" , Platform Driver , "linux-kernel@vger.kernel.org" From: sathyanarayanan kuppuswamy Organization: Intel Message-ID: <470f3875-99f1-1bd2-da36-733f8c34d5fa@linux.intel.com> Date: Thu, 16 Mar 2017 14:15:44 -0700 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Andy, On 03/16/2017 01:12 PM, Andy Shevchenko wrote: > On Thu, Mar 16, 2017 at 8:13 PM, Rajneesh Bhardwaj > wrote: >> On Thu, Mar 16, 2017 at 06:05:39PM +0200, Andy Shevchenko wrote: >>> On Thu, Mar 16, 2017 at 4:52 PM, Rajneesh Bhardwaj >>> wrote: >>>> On Wed, Mar 15, 2017 at 08:32:53PM -0700, Kuppuswamy Sathyanarayanan wrote: >>>>> Mapping entire GCR mem region in this driver creates >>>>> mem region request conflict in sub devices that depend >>>>> on PMC. This creates driver probe failure in devices like >>>>> iTC0_wdt and telemetry device. >>>> iTCO_WDT driver needs to check the BIT4 (NO_REBOOT) of PMC_CFG register >>>> (Offset: 0x1008) and this falls in GCR space. >>> Are we talking about ACPI-enabled platform? >> IIUC, you are referring to WDT enumerated by ACPI tables (WDAT, WDRT etc) ? >> >> On APL/BXT i think we pass the resource mapping to iTCO_WDT driver since >> acpi_has_watchdog provides the required protection. For non ACPI-enabled >> platforms we have this issue since iTCO_WDT driver anyway tries resource >> mapping when the iTCO_version >=2. > And driver with necessary stuff should be already in upstream. > > https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git/tree/drivers/mfd/lpc_ich.c?h=watchdog-next#n552 > > Or it's not enough? Can this driver replace intel_pmc_ipc driver ? It seems to be missing IPC related APIs. Regarding iTCO watchdog section, I think this driver also passes GCR region as memory resource to iTCO_WDT device. > -- Sathyanarayanan Kuppuswamy Android kernel developer From mboxrd@z Thu Jan 1 00:00:00 1970 From: sathyanarayanan kuppuswamy Subject: Re: [PATCH v1 1/1] platform/x86: intel_pmc_ipc: fix io mem mapping size Date: Thu, 16 Mar 2017 14:15:44 -0700 Message-ID: <470f3875-99f1-1bd2-da36-733f8c34d5fa@linux.intel.com> References: <1ab8d18dd7f5428869e6e77026ac4206863eea08.1489634924.git.sathyanarayanan.kuppuswamy@linux.intel.com> <20170316145203.GA23198@rajaneesh-OptiPlex-9010> <20170316181356.GA19029@rajaneesh-OptiPlex-9010> Reply-To: sathyanarayanan.kuppuswamy@linux.intel.com Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mga03.intel.com ([134.134.136.65]:14365 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752657AbdCPVT0 (ORCPT ); Thu, 16 Mar 2017 17:19:26 -0400 In-Reply-To: Sender: platform-driver-x86-owner@vger.kernel.org List-ID: To: Andy Shevchenko , Rajneesh Bhardwaj Cc: Andy Shevchenko , Zha Qipeng , "dvhart@infradead.org" , Platform Driver , "linux-kernel@vger.kernel.org" Hi Andy, On 03/16/2017 01:12 PM, Andy Shevchenko wrote: > On Thu, Mar 16, 2017 at 8:13 PM, Rajneesh Bhardwaj > wrote: >> On Thu, Mar 16, 2017 at 06:05:39PM +0200, Andy Shevchenko wrote: >>> On Thu, Mar 16, 2017 at 4:52 PM, Rajneesh Bhardwaj >>> wrote: >>>> On Wed, Mar 15, 2017 at 08:32:53PM -0700, Kuppuswamy Sathyanarayanan wrote: >>>>> Mapping entire GCR mem region in this driver creates >>>>> mem region request conflict in sub devices that depend >>>>> on PMC. This creates driver probe failure in devices like >>>>> iTC0_wdt and telemetry device. >>>> iTCO_WDT driver needs to check the BIT4 (NO_REBOOT) of PMC_CFG register >>>> (Offset: 0x1008) and this falls in GCR space. >>> Are we talking about ACPI-enabled platform? >> IIUC, you are referring to WDT enumerated by ACPI tables (WDAT, WDRT etc) ? >> >> On APL/BXT i think we pass the resource mapping to iTCO_WDT driver since >> acpi_has_watchdog provides the required protection. For non ACPI-enabled >> platforms we have this issue since iTCO_WDT driver anyway tries resource >> mapping when the iTCO_version >=2. > And driver with necessary stuff should be already in upstream. > > https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git/tree/drivers/mfd/lpc_ich.c?h=watchdog-next#n552 > > Or it's not enough? Can this driver replace intel_pmc_ipc driver ? It seems to be missing IPC related APIs. Regarding iTCO watchdog section, I think this driver also passes GCR region as memory resource to iTCO_WDT device. > -- Sathyanarayanan Kuppuswamy Android kernel developer