From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=185.246.84.56 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796027801; b=1MAspX6t7FmXnhYKjiYy4kpgtfnHRPhGj2XHoQJlxELxOcY+1aj0rsLfvK8yy28hq2Ga Rlt7AlXVClmDichFugYyYWRHqMpfEPXrv9BIMRhDT1A8BUJQ5dyFJApLAY14OwRQqEXI/ o7Zj1HDfVGl8qMhGAGt9+2WOBbEXj8sRMwjyE4HSRZu8dltXRrHfaBBZfTmV6AKBPvuCd vIxbXWMJM5M9fVvt3gARrzMlYN4WhIo/sSz3jxMBnedWmOiVAUpxsLmASTs+ht+5uvRPx Js+0u3QEuBMYfGHytaSUoT17+xp9VgKYK49zgc0Upu2P6SQBIemxuNZNLsUBa3n+CGw== ARC-Message-Signature: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; c=relaxed/relaxed; t=1796027801; h=DMARC-Filter:Received:Received:Received:DKIM-Signature:From:To:Cc: Subject:In-Reply-To:References:User-Agent:Date:Message-ID: MIME-Version:Content-Type:X-Last-TLS-Session-Version; bh=mkVYHn1z+LlYoEAE9gVTb4qftEwNUvp2x+ce5t7EQhU=; b=ONLKEle+y1Vc1uWvUfTeWoTH5jA1LfBYcj/SWGBLINd27n6tGkqhw1D8qXSA9uAupFSE B983JZtCh1nTtHxq3Fze4ZfZMVN7WZMDVM0cgZuNDJmXU3s5nUzgLta3P5AZ+Kg8zzcwT Fot/HpBpmCt4Xhb82+SinR4vAxQbVNgCKHdOS1iTfkg7GX+DMe1ckfQQy/ltZlKk6KF10 KKOzX5MNc1DDyrpKu76bAqQGC4XD1IWqn80Mbffj7wCa1J5BJ8U9nuyYGmwpizjsr8vL0 kSpMbIPfedMKq1xcGhe7q3h9eVmSUoEcquSNvEWBvtSP9IynhorRciOd9FITlt71Kqw== ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass header.d=bootlin.com header.i=@bootlin.com header.a=rsa-sha256 header.s=dkim header.b=bafUyqwL; arc=none smtp.remote-ip=185.246.84.56 Received: from smtpout-02.galae.net (smtpout-02.galae.net [185.246.84.56]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E30D9606A31C for ; Mon, 30 Nov 2026 08:36:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org E30D9606A31C Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.a=rsa-sha256 header.s=dkim header.b=bafUyqwL Received: from smtpout-01.galae.net (smtpout-01.galae.net [212.83.139.233]) by smtpout-02.galae.net (Postfix) with ESMTPS id 59FC51A1888; Mon, 30 Nov 2026 08:36:38 +0000 (UTC) Received: from mail.galae.net (mail.galae.net [212.83.136.155]) by smtpout-01.galae.net (Postfix) with ESMTPS id 298256007C; Mon, 30 Nov 2026 08:36:38 +0000 (UTC) Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 6D7A811EA0271; Mon, 30 Nov 2026 09:36:34 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=dkim; t=1796027797; h=from:subject:date:message-id:to:cc:mime-version:content-type: in-reply-to:references; bh=mkVYHn1z+LlYoEAE9gVTb4qftEwNUvp2x+ce5t7EQhU=; b=bafUyqwL+tLZc9obzkenpti+jfuwV4hViS6vVd01ksZ8GM6AuGmSMO0vxkZnDlUFgQ2Eyo K4L8o+Cmtus8Ud1zDdJkJ5Fuf59lsioqI15QqUL0YtwGnbgpB/5XvhtkSZorsqI1OfoPf1 pM08h6SoVUbbtuEQ5Xbhecwk8pUwNnAVmebEFeEpRjxtKelVInfTIRaK8PcSc6jr3Lqj5q VJaCi7J4+1ATjiXoLr8cdoM1ZV0poOIc0bAn39kMxyQn6PkkCvkKU5oCJfnwApUQD2BjvV BpLmOZLYOm2CxEHYl5m7vPfVrRs4NKe2BdcRgGaBRwfOBdNj7l0ytjQ8xUsELg== From: Miquel Raynal To: Cheng Ming Lin Cc: Mark Brown , linux-spi@vger.kernel.org, linux-api@vger.kernel.org, alvinzhou@mxic.com.tw Subject: Re: [PATCH 0/2] spi: spidev: Allow userspace to request DTR transfers In-Reply-To: <20261130054931.2441438-1-chengminglin@mxic.com.tw> (Cheng Ming Lin's message of "Mon, 30 Nov 2026 13:49:29 +0800") References: <20261130054931.2441438-1-chengminglin@mxic.com.tw> User-Agent: mu4e 1.12.12; emacs 30.2 Date: Mon, 30 Nov 2026 09:36:33 +0100 Message-ID: <87se0i3ecu.fsf@bootlin.com> X-Mailing-List: linux-api@vger.kernel.org List-Id: List-Post: List-Help: List-Subscribe: List-Unsubscribe: List-Owner: Precedence: list MIME-Version: 1.0 Content-Type: text/plain X-Last-TLS-Session-Version: TLSv1.3 On 30/11/2026 at 13:49:29 +08, Cheng Ming Lin wrote: > The SPI core can perform Double Transfer Rate transfers through > spi_transfer.dtr_mode on controllers advertising dtr_caps, but there > is currently no way for userspace to request them through spidev. > > The first patch turns the last padding byte of struct spi_ioc_transfer > into a flags field and adds SPI_IOC_XFER_DTR to set dtr_mode on the > corresponding transfer. The struct size and layout are unchanged. > > The second patch adds a matching -x/--dtr option to spidev_test. I don't know much this backend, but looks fine, besides the fact that we are naturally running out of extra bytes in the structure. Maybe you mentioned it, but it is worth repeating that these padding bytes are expected to be 0 already. Reviewed-by: Miquel Raynal