Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp563393rwd; Wed, 31 May 2023 02:10:59 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6FRj39bDQfXYiUjwesaADObZruDorpON8Da6N/PHRftUGxGCxVIBRaNbtfQDUXZn7lNpaG X-Received: by 2002:a05:6a00:138b:b0:643:9ca:3c7d with SMTP id t11-20020a056a00138b00b0064309ca3c7dmr6738945pfg.4.1685524259309; Wed, 31 May 2023 02:10:59 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1685524259; cv=none; d=google.com; s=arc-20160816; b=PN3XX886GuwYKheTnT8YhfFb5Pac0OcarQbYM74vyd+mYvCpoFL0Qlo6gA1BbUbEeI MvmDlyrrHRpVcJg0wYCQSK723VdMrMxAVbE6UpmEliP15seNcZ6y9hr5zkHG6+UkPgFV L0or2urCd9gTP1/m+hI0Cpjc5H43m63OtJCKwrk0QQBWUs8n2EgLq31BtrqTKKhCMSRT VWn/XWb1UKYvMGMFCMrKPfBJ8h89j73cqu8VP7sXdQnkOqaKbJWsVDvTL+uMlX3vZqFN YjvDTAYFNX5FyIvxIyWpk5lvkK7pteEDW+OFhCRTvuC/C+2LDeLz1GohoBVS5VwUd4LG T+zA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:cc:to:subject :message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=jrtN/2a5JJTprBcYp9jvZ+UGojw4315OmIU8TzujPAw=; b=pAtM4shrVe/4CCzEoPmhW4RNLobpUKsVauZjK76KwVKNFDNq16azejZF4luajLgkwb kQmYURHDzzvUqhpmzKttIptZh9iQXdnf6AUiXdt9VK7nDFq1gRw2cB6hwzYFf5mHwNQL WO9Lxz+LvJi1tVYLClGn7pv5ItobsuXwMo0tIJE7Q1VWm0TgqmdZhF9JqMF48MxmJRpw alOVPdfdF2cVqz0yYFBnYaF+pyDj7UE0YWCwOAx/dQVP2NAbgKpwFavTlH8IaEQigaBk 5d/1seiGUJm/Gq4JOdlEx+/Ushep3x68QDKbY6YTxAH7Q/M3S//OPVMuRqwTySlSpuGj E0xA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=aGDLNuG8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id c6-20020a624e06000000b0063b7b7712a5si3196360pfb.304.2023.05.31.02.10.45; Wed, 31 May 2023 02:10:59 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20221208 header.b=aGDLNuG8; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235281AbjEaJFR (ORCPT + 99 others); Wed, 31 May 2023 05:05:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46026 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235286AbjEaJEw (ORCPT ); Wed, 31 May 2023 05:04:52 -0400 Received: from mail-lj1-x233.google.com (mail-lj1-x233.google.com [IPv6:2a00:1450:4864:20::233]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id EFEA9135; Wed, 31 May 2023 02:04:50 -0700 (PDT) Received: by mail-lj1-x233.google.com with SMTP id 38308e7fff4ca-2af31dc49f9so60311361fa.0; Wed, 31 May 2023 02:04:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1685523889; x=1688115889; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date :message-id:reply-to; bh=jrtN/2a5JJTprBcYp9jvZ+UGojw4315OmIU8TzujPAw=; b=aGDLNuG8w9aRbKs613i2qng0wy6XdphgsO9DC+Qy40A8rrPXO9353ZgHVIohfsrRW6 Y4ZtTXx+79iQm0YUYe89Vqp+5OVVe3+4Xqk2Jgb3dNc5kabutUgM4rsNjvbiuvMk63JL QXAnWJByUDNBgRAXdXmQCPcHzH5Q2bEGNspZwLuEFmy+EFcixV895frB3qBUU/ah+BnC CV1X5sG+lH4+m283ml9QcxW/0SU6vh1rQZTDqxGbuzfroAyrc33I/Zyg841loN91YQFG JmCL4pwEkJfwG2BbIXHG1FbSgpi1tNSY+JAsLI5foOekv+9fsfTF1HndjVO0nfoSUtby 2JtQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1685523889; x=1688115889; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=jrtN/2a5JJTprBcYp9jvZ+UGojw4315OmIU8TzujPAw=; b=hkRK9qBUPEyBlj/JYnQGFcIXrFWGYawxy54kIGdMmyDL8MskH5ICyRHUVBTTVN7ohD cHwafAJqWJFt1iLj6SORx6yp69eoJLekecgptOBgdKmoXVeEv3VDOGhbe6fqHNhvDxXH q+USx5h9U7NTbHSPw+fsasfTdtunBhNcl7zcntxL7JFVr2TpUCDuuN1ifcyaBCmYh+dW 1lJjS55ZUPYSKTLgc7F2S6D1Dickc4XaMrFQ2BcAOT3ES07t1VUmZweKlR0ovhMWxCSe nrGdC3OJNKcq0CM9NvpJqGy7oLfGw8oeJ8+/QZYq5FR/S4a0TxjpfxwLgLtFWH704eXa kOkQ== X-Gm-Message-State: AC+VfDxyLIo6zVCpXU8EVgebjUIj3FY+9Jb0l94d848cy//20YnIrISb 7XnJIuElQ+Z2eymtxo4PLYuJ3CBv4EUWI2H99tBn4/z74Q== X-Received: by 2002:a2e:9e15:0:b0:2ac:8c95:d42b with SMTP id e21-20020a2e9e15000000b002ac8c95d42bmr2183665ljk.4.1685523888771; Wed, 31 May 2023 02:04:48 -0700 (PDT) MIME-Version: 1.0 References: <20230531083828.8009-1-ed.tsai@mediatek.com> In-Reply-To: <20230531083828.8009-1-ed.tsai@mediatek.com> From: Stanley Chu Date: Wed, 31 May 2023 17:04:36 +0800 Message-ID: Subject: Re: blk-mq: check on cpu id when there is only one ctx mapping To: Ed Tsai Cc: axboe@kernel.dk, kbusch@kernel.org, liusong@linux.alibaba.com, linux-block@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, wsd_upstream@mediatek.com, peter.wang@mediatek.com, stanley.chu@mediatek.com, powen.kao@mediatek.com, alice.chao@mediatek.com, naomi.chu@mediatek.com Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, May 31, 2023 at 4:49=E2=80=AFPM Ed Tsai wrot= e: > > commit f168420 ("blk-mq: don't redirect completion for hctx withs only > one ctx mapping") When nvme applies a 1:1 mapping of hctx and ctx, there > will be no remote request. > > But for ufs, the submission and completion queues could be asymmetric. > (e.g. Multiple SQs share one CQ) Therefore, 1:1 mapping of hctx and > ctx won't complete request on the submission cpu. In this situation, > this nr_ctx check could violate the QUEUE_FLAG_SAME_FORCE, as a result, > check on cpu id when there is only one ctx mapping. > > Signed-off-by: Ed Tsai > Signed-off-by: Po-Wen Kao Reviewed-by: Stanley Chu