From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-3.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A0762C433B4 for ; Tue, 18 May 2021 06:58:28 +0000 (UTC) Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 6249361007 for ; Tue, 18 May 2021 06:58:28 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6249361007 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=chromium.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=dri-devel-bounces@lists.freedesktop.org Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 9A93B89C3F; Tue, 18 May 2021 06:58:27 +0000 (UTC) Received: from mail-io1-xd2d.google.com (mail-io1-xd2d.google.com [IPv6:2607:f8b0:4864:20::d2d]) by gabe.freedesktop.org (Postfix) with ESMTPS id 4BBA489C3F for ; Tue, 18 May 2021 06:58:26 +0000 (UTC) Received: by mail-io1-xd2d.google.com with SMTP id c10so4267569iob.1 for ; Mon, 17 May 2021 23:58:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=okFGSzwxy3Xl1EDwrbsZ6bJWGdPaUEKxSezi4/SE71A=; b=KvboTWH6SCfdQ7LLxm6vH9xhTNNbPkylAhr3iqPQWH1QNODKOLIbMt/OYjboWMwVvr +KD/UQeQoUETk6OK7TCWS0Utmt5EvBfWbA4IzzRRuwJkDy5Qi3ICeWOTChp1Py6zaNQt fa1WHS9ymuIo1ivMcIga1N5vVpkmfX46UnGI0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=okFGSzwxy3Xl1EDwrbsZ6bJWGdPaUEKxSezi4/SE71A=; b=ifA7QmSCpZoOcqKy+mEBMP4SWYmcP0zjSNSw2kj+AK6btJtdlu58CItxId/m3asoCI irJ9/7EDxeRmIsDUc4vliGz3Ky5CjGBfqRWDMt7mQ/NCJBkePm2nJB7r+gLgECpBGuiG WpO6Yt8Vh4+4MzILe7XZYPYCD1xtsShfAdf5NARzx7DU9CNgRzZjmN/SBDmDdLXztocT 08l4FAOFJhf/t66y4G6UNJsujT3SI0zsXAHtRzenCWjYi/UdtNdJoMPhmB0jCqWe03kv VWhQZzAfRrs//UhUk9mikdTTsHqcmBfAd8uuCNy9Yk218yYPFvS0w8c5H0qfbEXxpyDc hxhw== X-Gm-Message-State: AOAM530jBFY/cRdx7/4a/avPZzTP7ZRcyvzUUc0VYMma0WLF72GMykcl xByqreKaf2Kn5dC5B2EBLn3ft0RcDek7SA== X-Google-Smtp-Source: ABdhPJw31bSBcEJZ8u44Co/4GDRwc2uqcmBdXN79sJRa61CJYFvjIgcyOkRM8mvguzbjXb4nTA/gUg== X-Received: by 2002:a5e:a704:: with SMTP id b4mr3179625iod.35.1621321105582; Mon, 17 May 2021 23:58:25 -0700 (PDT) Received: from mail-il1-f177.google.com (mail-il1-f177.google.com. [209.85.166.177]) by smtp.gmail.com with ESMTPSA id y15sm10091277ila.3.2021.05.17.23.58.25 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 17 May 2021 23:58:25 -0700 (PDT) Received: by mail-il1-f177.google.com with SMTP id o10so7239511ilm.13 for ; Mon, 17 May 2021 23:58:25 -0700 (PDT) X-Received: by 2002:a05:6e02:1a4d:: with SMTP id u13mr3011800ilv.64.1621320723564; Mon, 17 May 2021 23:52:03 -0700 (PDT) MIME-Version: 1.0 References: <20210518064215.2856977-1-tientzu@chromium.org> <20210518064215.2856977-6-tientzu@chromium.org> In-Reply-To: <20210518064215.2856977-6-tientzu@chromium.org> From: Claire Chang Date: Tue, 18 May 2021 14:51:52 +0800 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH v7 05/15] swiotlb: Add a new get_io_tlb_mem getter To: Rob Herring , mpe@ellerman.id.au, Joerg Roedel , Will Deacon , Frank Rowand , Konrad Rzeszutek Wilk , boris.ostrovsky@oracle.com, jgross@suse.com, Christoph Hellwig , Marek Szyprowski Content-Type: text/plain; charset="UTF-8" X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: heikki.krogerus@linux.intel.com, thomas.hellstrom@linux.intel.com, peterz@infradead.org, dri-devel@lists.freedesktop.org, chris@chris-wilson.co.uk, grant.likely@arm.com, paulus@samba.org, mingo@kernel.org, Jianxiong Gao , sstabellini@kernel.org, Saravana Kannan , xypron.glpk@gmx.de, "Rafael J . Wysocki" , Bartosz Golaszewski , bskeggs@redhat.com, linux-pci@vger.kernel.org, xen-devel@lists.xenproject.org, Thierry Reding , intel-gfx@lists.freedesktop.org, matthew.auld@intel.com, linux-devicetree , airlied@linux.ie, Robin Murphy , Nicolas Boichat , rodrigo.vivi@intel.com, Bjorn Helgaas , Dan Williams , Andy Shevchenko , Greg KH , Randy Dunlap , lkml , Tomasz Figa , "list@263.net:IOMMU DRIVERS" , Jim Quinlan , linuxppc-dev@lists.ozlabs.org, bauerman@linux.ibm.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Still keep this function because directly using dev->dma_io_tlb_mem will cause issues for memory allocation for existing devices. The pool can't support atomic coherent allocation so we need to distinguish the per device pool and the default pool in swiotlb_alloc.