Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755888AbcC2HYp (ORCPT ); Tue, 29 Mar 2016 03:24:45 -0400 Received: from bombadil.infradead.org ([198.137.202.9]:57332 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751025AbcC2HYo (ORCPT ); Tue, 29 Mar 2016 03:24:44 -0400 Date: Tue, 29 Mar 2016 00:24:43 -0700 From: Christoph Hellwig To: Shaohua Li Cc: linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, axboe@fb.com, hch@infradead.org, Kernel-team@fb.com Subject: Re: [PATCH 1/3] blk-mq: add an API to estimate hardware queue node Message-ID: <20160329072443.GA18920@infradead.org> References: <68fed570910230ce847f8f3b685eeea399640a7f.1458941500.git.shli@fb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <68fed570910230ce847f8f3b685eeea399640a7f.1458941500.git.shli@fb.com> User-Agent: Mutt/1.5.24 (2015-08-30) X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 652 Lines: 11 On Fri, Mar 25, 2016 at 02:36:30PM -0700, Shaohua Li wrote: > we allocate most data structure in device's node, but some data > structures are not for DMA and mostly used by specific cpus/node which > could diff from device's node. Allocating such hot data in device's > node doesn't make sense. Add an API to estimate hardware queue node. > This can be used before blk-mq actually establishes the mapping. This > API runs slow, but it only used in initialization time. I think this is the wrong way around. I've got some proprotype code that just leaves the cpu assignments to the drivers and picks it up in blk-mq. Give me a few days to post it..