From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753053AbcAGJzD (ORCPT ); Thu, 7 Jan 2016 04:55:03 -0500 Received: from mga03.intel.com ([134.134.136.65]:49671 "EHLO mga03.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751545AbcAGJy6 (ORCPT ); Thu, 7 Jan 2016 04:54:58 -0500 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.20,532,1444719600"; d="scan'208";a="885500223" Date: Thu, 7 Jan 2016 11:52:38 +0200 From: Mika Westerberg To: "Wang, Annie" Cc: Andy Shevchenko , Vinod Koul , Greg Kroah-Hartman , "Rafael J. Wysocki" , "linux-acpi@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "linux-serial@vger.kernel.org" , "dmaengine@vger.kernel.org" , Borislav Petkov , "Huang, Ray" , "Wan, Vincent" , "Xue, Ken" , Robin Murphy , Graeme Gregory , "Li, Tony" , "Yu, Xiangliang" Subject: Re: [PATCH 3/6] ACPI: add 2 parameters to function acpi dma controller register Message-ID: <20160107095238.GY1770@lahna.fi.intel.com> References: <1451885501-2710-1-git-send-email-annie.wang@amd.com> <1451885501-2710-4-git-send-email-annie.wang@amd.com> <20160104144534.GB1770@lahna.fi.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Organization: Intel Finland Oy - BIC 0357606-4 - Westendinkatu 7, 02160 Espoo User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jan 06, 2016 at 06:46:37AM +0000, Wang, Annie wrote: > Acpi_dma_xlate mainly converts an acpi_dma structure into a dma_chan structure. > Without proper request line, wrong acpi_dma structure may be get. > > And as Andy says in http://article.gmane.org/gmane.linux.kernel.iommu/11675 > How about add a hook into acpi_dma_controller_register? Hmm, you can pass custom data in acpi_dma_controller_register() which will be assigned to adma->data. If you put your request line information there, I think your custom acpi_dma_xlate() should be able to use that information to find proper channel, no?