From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net [23.128.96.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 54DEEB678 for ; Sat, 30 Sep 2023 18:19:30 +0000 (UTC) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0B6C6E1 for ; Sat, 30 Sep 2023 11:19:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1696097968; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=8gv73ytAfKviSPiQIHeC0hOen5aE24T4EuTj3zfm6kg=; b=iNKrzqac58PCKLXoJlNR860t9O4pRK4gJKwR6nwmnUfso/Ph+EIOl+Jcs4dHb2TEZNnAN8 zMH76iXBENkZZY2b1zjaIdMZZpNIr+8GC6epVR0J05src+aEgGiRax3b74Y7LVxOJ5cFLj RB8mi5m5AW74lC9lwZp7ii1Ee8Zwfz0= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-591-v3BXl96tM-m7aKMVceXfLA-1; Sat, 30 Sep 2023 14:19:24 -0400 X-MC-Unique: v3BXl96tM-m7aKMVceXfLA-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id F3182185A78E; Sat, 30 Sep 2023 18:19:23 +0000 (UTC) Received: from rhel-developer-toolbox (unknown [10.2.16.53]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 6C8C62156A27; Sat, 30 Sep 2023 18:19:22 +0000 (UTC) Date: Sat, 30 Sep 2023 11:19:20 -0700 From: Chris Leech To: Greg Kroah-Hartman Cc: Christoph Hellwig , Rasesh Mody , Ariel Elior , Sudarsana Kalluru , Manish Chopra , Nilesh Javali , Manish Rangankar , Jerry Snitselaar , John Meneghini , Lee Duncan , Mike Christie , Hannes Reinecke , netdev@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 3/3] cnic,bnx2,bnx2x: use UIO_MEM_DMA_COHERENT Message-ID: References: <20230929170023.1020032-1-cleech@redhat.com> <20230929170023.1020032-4-cleech@redhat.com> <2023093055-gotten-astronomy-a98b@gregkh> Precedence: bulk X-Mailing-List: netdev@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <2023093055-gotten-astronomy-a98b@gregkh> X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H4,RCVD_IN_MSPIKE_WL, SPF_HELO_NONE,SPF_NONE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net On Sat, Sep 30, 2023 at 09:06:51AM +0200, Greg Kroah-Hartman wrote: > On Fri, Sep 29, 2023 at 10:00:23AM -0700, Chris Leech wrote: > > Make use of the new UIO_MEM_DMA_COHERENT type to properly handle mmap > > for dma_alloc_coherent buffers. > > Why are ethernet drivers messing around with UIO devices? That's not > what UIO is for, unless you are trying to do kernel bypass for these > devices without anyone noticing? > > confused, It's confusing. The bnx2 driver stack included a cnic (converged nic?) module that sits between the ethernet drivers (bnx2, bnx2x) and protocol offload drivers (iscsi, fcoe, rdma). The iscsi module (bnx2i) uses a passthrough interface from cnic to handle some network configuration that the device firmware doesn't do. It uses a uio device and a userspace component called iscsiuio to do that. Questions beyond that will probably need to be answer by one of the many Marvell engineers copied on this thread. - Chris