From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 BFF42B678 for ; Sat, 30 Sep 2023 18:28:33 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 75395C433C8; Sat, 30 Sep 2023 18:28:32 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1696098513; bh=Y9iCNcGGh4nfHDPA28tz0aK7pyM7yVYEhIxnYu0QfG8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=1k1HaUHuIORJNTGPd+sZFi8gkE0zdO5YIja2DkSsvLFPK3pYs55Mobkwz8fLs6rQa hwvyWiSwwBSQYASjE9dZKij+EUA2Fa34mmaJzW6xCgu77gCaDAUE04LiuQTjOpMCrI geP/D2iDqYhIqiZ1P5iV7vt3YGQxYQl12/7T17F4= Date: Sat, 30 Sep 2023 20:28:29 +0200 From: Greg Kroah-Hartman To: Chris Leech 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: <2023093002-unlighted-ragged-c6e1@gregkh> 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: On Sat, Sep 30, 2023 at 11:19:20AM -0700, Chris Leech wrote: > 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. That's horrible, and not what the UIO api is for at all. Configure the device like any other normal kernel device, don't poke at raw memory values directly, that way lies madness. Have a pointer to the userspace tool anywhere? All I found looks like a full IP stack in userspace under that name, and surely that's not what this api is for... thanks, greg k-h