From mboxrd@z Thu Jan 1 00:00:00 1970 From: Adrian Hunter Subject: Re: [PATCH V5 03/13] mmc: host: Add CQE interface Date: Wed, 23 Aug 2017 09:54:47 +0300 Message-ID: <732e8ebc-9b81-90c4-c719-eab1ca0ac220@intel.com> References: <1502366898-23691-1-git-send-email-adrian.hunter@intel.com> <1502366898-23691-4-git-send-email-adrian.hunter@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Return-path: Received: from mga02.intel.com ([134.134.136.20]:43735 "EHLO mga02.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753238AbdHWHBU (ORCPT ); Wed, 23 Aug 2017 03:01:20 -0400 In-Reply-To: Content-Language: en-US Sender: linux-mmc-owner@vger.kernel.org List-Id: linux-mmc@vger.kernel.org To: Ulf Hansson Cc: linux-mmc , Bough Chen , Alex Lemberg , Mateusz Nowak , Yuliy Izrailov , Jaehoon Chung , Dong Aisheng , Das Asutosh , Zhangfei Gao , Sahitya Tummala , Harjani Ritesh , Venu Byravarasu , Linus Walleij , Shawn Lin On 22/08/17 14:13, Ulf Hansson wrote: > On 10 August 2017 at 14:08, Adrian Hunter wrote: >> + void (*cqe_recovery_notifier)(struct mmc_host *, >> + struct mmc_request *); > > Normally we don't put callbacks in the struct mmc_host that someone > else than the host driver should assign - so this feels a bit upside > down. > > Is there any reason to why you didn't want to add a new API? Something > like mmc_cqe_recover(), which the host driver could call. That would make the host driver dependent on the block driver. There needs to be a function pointer, even if we wrap it in an API.