From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mika Westerberg Subject: Re: [PATCH 3/6] ACPI: add 2 parameters to function acpi dma controller register Date: Thu, 7 Jan 2016 11:52:38 +0200 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 Return-path: 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 Content-Disposition: inline In-Reply-To: Sender: linux-acpi-owner@vger.kernel.org List-Id: linux-acpi@vger.kernel.org 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" 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?