Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp658322pxu; Fri, 11 Dec 2020 11:02:10 -0800 (PST) X-Google-Smtp-Source: ABdhPJwTYtxoiV3VNPY1NrlB3qMBn4I4Nr45Qh5RDDhravFX2GcTth9xcai4rEUzIMFi7yPpdtyx X-Received: by 2002:aa7:cfd7:: with SMTP id r23mr13266783edy.298.1607713330096; Fri, 11 Dec 2020 11:02:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1607713330; cv=none; d=google.com; s=arc-20160816; b=iYHEw+OtTgB9p2SoydAt6c5s2fFRzaLjqDBEamN+9L1623sHu+8vBz+9QLfy+Equyl 91ZQuPiR7ywshvuJnbZBoRQajmdgoOq/rUS4jpgkLDcytuOGcihnp4LEEbCSkGuuRJWZ 3JHDubpOKuvV8kc/FKUBBMNOjKcnNU2IJToC3Ekfnlhk3eJ0fhllfktVcGImND9g1RkV 6fuiiziDVdt3d/kJgrzkQemqEZSLoRCFikMby6pA/2LPTF57p6QSa54+LRi69fPc0LRZ NtqCGyMkFdCcs0c9zZp5to4DAoaq3PqlJF+c/GCjQA9/y5h+O6bHyc0tMm2N21D0o4EG Kcog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:date:cc:to:from:subject :message-id:dkim-signature; bh=vOsykB63req6cE/5LoOyLCDL6IQs90px0MUJ01HwVJI=; b=dkjJz/hcGNRLK1Iftetnd1KL0vq/2smbtthKTWFyCgg3/BMbMJdcFoT+ZWM42SHqLX hupRLdaob0dSyAeAmCHsUzTdpT1FMWKY4/wXgHQ91jVJoSxGqY1yPuhpH58kUQ8BzDYs 1WEcvwknzk1JUIwhwD/f6VaCrIDNzJ+Hp5KwFTTBtltH64EidD7OUZdHuda05ycKJZOC OZax6x5aTJfE5QRNrUG1iWjAk1rJFgpfRfUn/SQvLkSmK+ORDRUo43y47L/WgfufUxqc FTc8gKV2R3yRUjrs5aONn9ODwbj0aVYgsGhavGCdIh1Wd4Nom3tlAWH8YeNUdGci8LJ9 Aupg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=gYYJexBP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rk17si5083250ejb.509.2020.12.11.11.01.46; Fri, 11 Dec 2020 11:02:10 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=gYYJexBP; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2391551AbgLKRj3 (ORCPT + 99 others); Fri, 11 Dec 2020 12:39:29 -0500 Received: from us-smtp-delivery-124.mimecast.com ([63.128.21.124]:22077 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2395425AbgLKRjJ (ORCPT ); Fri, 11 Dec 2020 12:39:09 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1607708262; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=vOsykB63req6cE/5LoOyLCDL6IQs90px0MUJ01HwVJI=; b=gYYJexBPQDBsAfUxcNxve9joKX1hnFLvKu6TKGtOyCcCHxubwPJWp6NRKQwIGvJVYYap3H gCZ9KdPAMDbhww7LvIn9k0szfNji5O8GUVZZroigamqMX/wgKhduJqcHzqvC5+/at8Y1OR 1Y3FABdffn0sY9vsA5swBV9/S1QQGRc= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-492-oRLqvIbJPGWTWyZB_yPhDA-1; Fri, 11 Dec 2020 12:37:38 -0500 X-MC-Unique: oRLqvIbJPGWTWyZB_yPhDA-1 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id EDC97107ACE4; Fri, 11 Dec 2020 17:37:36 +0000 (UTC) Received: from localhost.localdomain (unknown [10.10.110.58]) by smtp.corp.redhat.com (Postfix) with ESMTP id 590E96F45B; Fri, 11 Dec 2020 17:37:35 +0000 (UTC) Message-ID: <81dfd08b90f841194237e074aaa3d57cada7afad.camel@redhat.com> Subject: Re: [PATCH v17 3/3] bus: mhi: Add userspace client interface driver From: Dan Williams To: Greg KH , Hemant Kumar Cc: manivannan.sadhasivam@linaro.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, jhugo@codeaurora.org, bbhatt@codeaurora.org, loic.poulain@linaro.org, netdev@vger.kernel.org Date: Fri, 11 Dec 2020 11:37:34 -0600 In-Reply-To: References: <1607670251-31733-1-git-send-email-hemantk@codeaurora.org> <1607670251-31733-4-git-send-email-hemantk@codeaurora.org> Content-Type: text/plain; charset="UTF-8" User-Agent: Evolution 3.36.5 (3.36.5-1.fc32) MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, 2020-12-11 at 08:44 +0100, Greg KH wrote: > On Thu, Dec 10, 2020 at 11:04:11PM -0800, Hemant Kumar wrote: > > This MHI client driver allows userspace clients to transfer > > raw data between MHI device and host using standard file > > operations. > > Driver instantiates UCI device object which is associated to device > > file node. UCI device object instantiates UCI channel object when > > device > > file node is opened. UCI channel object is used to manage MHI > > channels > > by calling MHI core APIs for read and write operations. MHI > > channels > > are started as part of device open(). MHI channels remain in start > > state until last release() is called on UCI device file node. > > Device > > file node is created with format > > > > /dev/ > > > > Currently it supports QMI channel. libqmi is userspace MHI client > > which > > communicates to a QMI service using QMI channel. libqmi is a glib- > > based > > library for talking to WWAN modems and devices which speaks QMI > > protocol. > > For more information about libqmi please refer > > https://www.freedesktop.org/wiki/Software/libqmi/ > > This says _what_ this is doing, but not _why_. > > Why do you want to circumvent the normal user/kernel apis for this > type > of device and move the normal network handling logic out to > userspace? > What does that help with? What does the current in-kernel api lack > that > this userspace interface is going to solve, and why can't the in- > kernel > api solve it instead? > > You are pushing a common user/kernel api out of the kernel here, to > become very device-specific, with no apparent justification as to why > this is happening. > > Also, because you are going around the existing network api, I will > need > the networking maintainers to ack this type of patch. Just to re-iterate: QMI ~= AT commands ~= MBIM (not quite, but same level) We already do QMI-over-USB, or AT-over-CDC-ACM. This is QMI-over-MHI. It's not networking data plane. It's WWAN device configuration. There are no current kernel APIs for this, and I really don't think we want there to be. The API surface is *huge* and we definitely don't want that in-kernel. Dan