From mboxrd@z Thu Jan 1 00:00:00 1970 From: Arnd Bergmann Subject: Re: [PATCH v6 0/4] Add MMC software queue support Date: Wed, 27 Nov 2019 13:01:06 +0100 Message-ID: References: <20191127090023.GA23040@infradead.org> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Return-path: In-Reply-To: <20191127090023.GA23040@infradead.org> Sender: linux-kernel-owner@vger.kernel.org To: Christoph Hellwig Cc: Hannes Reinecke , "(Exiting) Baolin Wang" , Baolin Wang , Adrian Hunter , Ulf Hansson , Asutosh Das , Orson Zhai , Lyra Zhang , Linus Walleij , Vincent Guittot , linux-mmc , "linux-kernel@vger.kernel.org" , Hannes Reinecke , linux-block , Paolo Valente List-Id: linux-mmc@vger.kernel.org On Wed, Nov 27, 2019 at 10:00 AM Christoph Hellwig wrote: > > On Tue, Nov 26, 2019 at 12:17:15PM +0100, Hannes Reinecke wrote: > If requests are batched enough we could just drain > and switch every time an other partition access comes in. Especially > so if people only use partitions for boot partitions and other rarely > used areas. We only support a single user partition plus up to two boot partitions that are accessed rarely, I don't think there is any reason to optimize switching between them. The only change that I think we need here is to change the partition switch from something that is done synchronously during ->queue_rq() to something that fits better into normal scheme of sending a cmd to the device, returning BLK_STS_RESOURCE from ->queue_rq. Possibly this could even be turned into a standard struct request that is added between two normal requests for different partitions at some point, if this simplifies the logic (I suspect it won't, but it may be worth a try). Arnd