Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp1397046pxu; Fri, 27 Nov 2020 06:25:53 -0800 (PST) X-Google-Smtp-Source: ABdhPJwXUTjBlASfW2WiO6U2k7A9yOi0xUcea4NXgWoBGAH27nvy1fjJiQ5LxG1sv/ayYDH5kWd5 X-Received: by 2002:a17:906:d81:: with SMTP id m1mr7989169eji.552.1606487153273; Fri, 27 Nov 2020 06:25:53 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606487153; cv=none; d=google.com; s=arc-20160816; b=LENYt2qNQjJf4RPajPKSHil26OX83S7GFAh4jvS/laYMq0Upj4kfwLwHZdv4wis6D3 PFnZXyPqfhcBYitAGhWZVy6yYX9DTp+aSd292bn3MfoMIhH2wLldRITwFS6Gxh2crsLN +K2fSw3OQ2HALI6hooPQ9cx0PAfI7BgdpnUvSOiG6kkGUmRNZSQyIUoY/ANMdDkumuJL M7GGirDQGnf8ZYGKIvuJLzS0kxGruc0Qc3lEYrloowB8l2zdL7PHzuKpTAhHuyRkh8Jx kRL+tTrKg4cjMrawZbVB7mDCu0ElG+msLh+L77SHieY3/OCX0x7yM2C85+nINBtELSk9 eEzQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:from:in-reply-to :references:mime-version:dkim-signature; bh=ZJts5wluJiBEaxB7Ztt7ndMRPjti6kLXkg//zytMNbc=; b=apUlmVAPVT+jn8qdV1ix0O3Mgv4VLH9yHpbiuJYeA5eVtbHU9CYjeH85qXZoesNdkZ u5HE7DJY8XESu0Qd2jwAwknt5p48Oupc3es0dScim3r7h7nlWwsv6/Sd1HTlzKKnt/RT jVEXA6rq6DbE+5fWCe7rRKeZ+rNBftGqGQV1mXCd3Kb66ORga/Hb9gO/ko3Cmv/Ce012 M2W4W9kOhTvxKzDdm+wCVrPHZvWtCVBvxRYzgrWSGRt7rytIfjnIoG+w1hMYz+SjXIRT G6JVD7II5CqAideeqZkFUZ6vb3FcEt9yFwm6xl1/YDRh60rkNwyGuuwfNKfjhQ3cB0WO vanQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=rWnXfdMY; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dr10si6049758ejc.306.2020.11.27.06.25.30; Fri, 27 Nov 2020 06:25:53 -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=@gmail.com header.s=20161025 header.b=rWnXfdMY; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730931AbgK0OWw (ORCPT + 99 others); Fri, 27 Nov 2020 09:22:52 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60500 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1730911AbgK0OWw (ORCPT ); Fri, 27 Nov 2020 09:22:52 -0500 Received: from mail-pg1-x542.google.com (mail-pg1-x542.google.com [IPv6:2607:f8b0:4864:20::542]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id E91BDC0613D1; Fri, 27 Nov 2020 06:22:51 -0800 (PST) Received: by mail-pg1-x542.google.com with SMTP id m9so4479276pgb.4; Fri, 27 Nov 2020 06:22:51 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=ZJts5wluJiBEaxB7Ztt7ndMRPjti6kLXkg//zytMNbc=; b=rWnXfdMYvvCo4dPYTLeZwozP2G3PeJzqwNOIINXOk2fYFFmKsbqZxN7GJuM4cqs7An E94+kJE9azUr18AZpbev1qK8rg4aow0tePKyatJHw56e6SxkyyYqOAAia97h0+aCKCvw GQecPXi28Trtogoe7Kwe2yoE6MAO+fircNe+gHNvSqsVwa/lXHKJwG7hcIq4q/x+3YBG W/nsTlJlYO7gPi15ifTTz8y8WMFOSDkr35GFuZ7MXo1mGoj19fe522NzVU+fLZ+1B5Cm LRGEo3O8dBJLpLKn3O3gW8z2LOX/uZthWQXuDOVY8fd2erwFYLOzV5IOmNoZhlkqkOdx fgEA== 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=ZJts5wluJiBEaxB7Ztt7ndMRPjti6kLXkg//zytMNbc=; b=JyK0KVmTRwnkIz84pgvKMmSuRtYPo7QJ3ZrhSKIHWuUQyz1a5dD3DPyu4wq2LyrXa7 360zPze5UR/yvoKliSxEzPFEN+5p3hk4M1414mhppDHn/zAAEwkiYrF/RTsbAJmZflrG OnfWgVj+kS/UpI9KqlprlcbXHDt2foxjo8wKz7GmL59syS5+FgoxMipz209EWPyTQLB0 xQw3fCFZQIqy4TedBIA1Jog5Aaan41LsQ0bNzPPZanU6T/mn5iLE+gX82AczIPYHko+t vFxFLGOGkqlZMUn5BTGTtpk1iEiblHzcraB4CF4IIF0258JZ+oqM9fvN2QyC54zDQRAW L93w== X-Gm-Message-State: AOAM533KH7c1zboUfYhdnDVzkkHjwuN6J+4/mETJ7Jti3zQmzXZwMqWx JCZrJYwyLn9nXB+fae5YUwwVInLXK5SITknor5TaCO2r2MA= X-Received: by 2002:a17:90a:34cb:: with SMTP id m11mr10062134pjf.181.1606486971566; Fri, 27 Nov 2020 06:22:51 -0800 (PST) MIME-Version: 1.0 References: <20201127130834.136348-1-alexandru.ardelean@analog.com> <20201127130834.136348-2-alexandru.ardelean@analog.com> In-Reply-To: From: Andy Shevchenko Date: Fri, 27 Nov 2020 16:23:40 +0200 Message-ID: Subject: Re: [PATCH v3 2/3] spi: Add SPI_NO_TX/RX support To: Alexandru Ardelean Cc: linux-spi , devicetree , Linux Kernel Mailing List , Rob Herring , Mark Brown , "Bogdan, Dragos" Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Nov 27, 2020 at 4:22 PM Andy Shevchenko wrote: > On Fri, Nov 27, 2020 at 3:08 PM Alexandru Ardelean > wrote: ... > > --- a/include/uapi/linux/spi/spi.h > > +++ b/include/uapi/linux/spi/spi.h > > @@ -43,5 +43,7 @@ > > #define SPI_TX_OCTAL 0x2000 /* transmit with 8 wires */ > > #define SPI_RX_OCTAL 0x4000 /* receive with 8 wires */ > > #define SPI_3WIRE_HIZ 0x8000 /* high impedance turnaround */ > > +#define SPI_NO_TX 0x10000 /* no transmit wire */ > > +#define SPI_NO_RX 0x20000 /* no receive wire */ > > Is it really material for uAPI? > Perhaps we may have something like > SPI_MODE_USER_MASK in uAPI and > in internal headers > > SPI_MODE_KERNEL_MASK with > static_assert(_USER_MASK & _KERNEL_MASK); // check conditional > > ? And logically start bits for the kernel from the end (31, 30, ...). -- With Best Regards, Andy Shevchenko