From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.remote-ip=185.171.202.116 ARC-Seal: i=1; d=subspace.kernel.org; s=arc20261015; a=rsa-sha256; cv=none; t=1796027801; b=4LztKsDuedHxtNMGtP7e0+K15XSBVvkk20rq/IFyt2kkOcWz5zdfXx1czsQrSwntmWwq Ngk7ZbapzVhPv4wh+hM6W0+mbH/0EV9ZGN0+RCLEdAtAiiui+8rcl4xqQ9uqgSnuvCMA1 aDy3Qu6+ccxObDxH8QVgVM9lEuDDD5anlTvPtSy5fDOj3iTW+yoqPwhMI2Zve94silHJu XSTQYJ9QtB32bEhY3PM/mcG841GHQHkTum0eZi3B2+T79ELzWu9sUYa7jO/oFoR0RaT/u zcaCC0I6u/vYljGge//RhOXLbMgGOaBmGXrLvn/IhRDrzR6rrfxHIebZbKGm1SVpnFA== 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=1SoXINlyFV85KSUd3DJ6VbsosLyeNR6LCdQV6qiYpVPraIVSQJeylxfZQW+VLxv0nuvJ ryPTFoXme1l0N/78DlwMlwULnhTS4kpOc1cmBndUD2JgsffoPdu8U6njzeAvnxILcORSE FOTHdCV0EQ+RDzTetYDRmFvr0zcY/yyS7DeyTtjLFgQX7pzv3wCXHAUIJzdUj+bIfqeB1 SXVo4pGaRUo4c7O2OvgtG7dLGwalBT/Z1+KiMpecWCszTijUNfl2cjBjkJwxtNwSd3SXZ oO9hOQifjGU6um7mNjBDabsQU1fT80Gp4CvZz9G463/9O+AoEKXYyxSFP96VsjY+f+g== 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.171.202.116 Received: from smtpout-04.galae.net (smtpout-04.galae.net [185.171.202.116]) (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 0562F606A320 for ; Mon, 30 Nov 2026 08:36:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.2 smtp.subspace.kernel.org 0562F606A320 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-04.galae.net (Postfix) with ESMTPS id 2A2B1C2AC64 for ; Mon, 30 Nov 2026 08:36:48 +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-spi@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