From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from todd.t-8ch.de (todd.t-8ch.de [159.69.126.157]) (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 89A99188721 for ; Wed, 22 Jan 2025 08:42:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=159.69.126.157 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1737535355; cv=none; b=TH3dO/dyM2jr7gLMS6AG1WpC0Pxc3/r/fW6jGNpanBeV20iYUwgQHwP8VIJb+XCt+N+PVoUD1v6BMAp8Iy6CgjGlkB56TQgQuSlKao8zFpeLuHcdFU70k4VtwCAKi2x8Di3WGMi5HlEd5CvRVyOPgGaGvFwCm9ta0tBiUx3lVWY= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1737535355; c=relaxed/simple; bh=f9zFFRYixgkzI6kpfxhjvMCO+OLhvzElHyeKP4ha0LQ=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=HFXQgNvrpWKfAzDO3pO93NETs6YdJSFFKzTtHiVuScVLLfp8UqcsDM68Q6N/5ybdFDDZCJBRUe6irb9t9+Q+1cWFVkGU8uHt2IFpS1k+br9st/G2oah06mVBI6EmdTEdfUU6o7+bDhNT3WsSYmJrxQrfO+Pi7pv76xiVb5rn2EU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net; spf=pass smtp.mailfrom=weissschuh.net; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b=A3zQmHUb; arc=none smtp.client-ip=159.69.126.157 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=weissschuh.net Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=weissschuh.net Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=weissschuh.net header.i=@weissschuh.net header.b="A3zQmHUb" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=weissschuh.net; s=mail; t=1737535347; bh=f9zFFRYixgkzI6kpfxhjvMCO+OLhvzElHyeKP4ha0LQ=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=A3zQmHUb5W+/4NiBRoTMUhu+n+USP1CJB5DPIarG+NqGWM1HYJqr9DPU97h740n3K li4OXbuZG5vnPh/r9DksXZUcafMKQUjpuX14C9v6tpQ6qSk1dsUV9EC1IeRcPOeDPJ Cw3MK7IVfin2t8RIpfVKM+XojG3NgSgVtperMzYQ= Date: Wed, 22 Jan 2025 09:42:27 +0100 From: Thomas =?utf-8?Q?Wei=C3=9Fschuh?= To: Billy Tsai Cc: alexandre.belloni@bootlin.com, pgaj@cadence.com, miquel.raynal@bootlin.com, conor.culhane@silvaco.com, aniketmaurya@google.com, Shyam-sundar.S-k@amd.com, jarkko.nikula@linux.intel.com, wsa+renesas@sang-engineering.com, xiaopei01@kylinos.cn, Guruvendra.Punugupati@amd.com, linux-i3c@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v1 1/2] i3c: Remove the const qualifier from i2c_msg pointer in i2c_xfers API Message-ID: <23854752-435e-432e-ba21-caf690c0cecc@t-8ch.de> References: <20250121110756.214714-1-billy_tsai@aspeedtech.com> Precedence: bulk X-Mailing-List: linux-kernel@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: <20250121110756.214714-1-billy_tsai@aspeedtech.com> On 2025-01-21 19:07:55+0800, Billy Tsai wrote: > The change is necessary to enable the use of the > `i2c_get_dma_safe_msg_buf()` API, which requires a non-const > `struct i2c_msg *` to operate. The `i2c_get_dma_safe_msg_buf()` function > ensures safe handling of I2C messages when using DMA, making it essential > for scenarios where DMA transfers are involved. By removing the `const` > qualifier, this patch allows drivers to prepare and manage DMA-safe > buffers directly. Why not modify i2c_get_dma_safe_msg_buf() to accept 'const struct i2c_msg' instead? > Signed-off-by: Billy Tsai > --- > drivers/i3c/master/dw-i3c-master.c | 2 +- > drivers/i3c/master/i3c-master-cdns.c | 2 +- > drivers/i3c/master/mipi-i3c-hci/core.c | 2 +- > drivers/i3c/master/svc-i3c-master.c | 2 +- > include/linux/i3c/master.h | 2 +- > 5 files changed, 5 insertions(+), 5 deletions(-)