linux-i3c.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: <Durai.ManickamKR@microchip.com>
To: <linux-i3c@lists.infradead.org>, <alexandre.belloni@bootlin.com>
Cc: <Hari.PrasathGE@microchip.com>
Subject: [RFC] SAMA7D65 SoC I3C controller driver
Date: Wed, 30 Jul 2025 10:55:19 +0000	[thread overview]
Message-ID: <cbe773d1-f056-49b1-8c64-eea57ca8a9ea@microchip.com> (raw)

Hi All,

We have an I3C controller in SAMA7D65 SoC based on ARM-Cortex A7. I am 
trying to add driver support for I3C controller which is based on 
mipi-hci spec 1.0 version of synopsys IP.  Supported driver for this IP 
is drivers/i3c/master/mipi-i3c-hci/core.c. We are using LSM6DSO IMU 
sensor as I3C slave device for verifying the common command codes (CCC) 
and I3C messages. Enabled the following configs in the kernel and added 
the I3C controller & I3C slave node in the device tree. With this kernel 
image, we are able successfully probe the mipi-i3c-hci driver. The host 
& slave controller devices are created as 0-208006c100b/ & 
e9000000.i3c/. So I hope RSTDAA, DISEC, DAA and configuring the I3C 
slave device by the I3C host controller is fine.

Kernel config:
CONFIG_I3C=y
CONFIG_MIPI_I3C_HCI=y

Device tree:
compatible = "mipi-i3c-hci";

Though we used synopsys IP,  we don't have support for DMA and few other 
register configurations like lets say setting endianess, setting command 
version and so on. So, I have to remove and modify these in the existing 
driver to make it work for our SoC. So, what i did was, i have created a 
copy of core.c file and included all the related dependent functions 
used in other files (pio.c, cmd_v1.c, dat_v1.c etc) in the same file. 
Created as a separate platform driver to support the i3c controller  in 
the path drivers/i3c/master/mchp-i3c-master.c.

So my query here are,

1.
    Whether this approach is correct or not.
2.
    Instead of creating a new driver file, shall we introduce a quirck
    for Microchip I3C and integrate the changes in the existing driver.

Please suggest us the best way to provide support for the SAMA7D65 I3C 
in kernel.

-- 
linux-i3c mailing list
linux-i3c@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-i3c

             reply	other threads:[~2025-07-30 10:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-30 10:55 Durai.ManickamKR [this message]
2025-07-30 11:41 ` [RFC] SAMA7D65 SoC I3C controller driver Wolfram Sang
  -- strict thread matches above, loose matches on Subject: below --
2025-07-30 10:14 Durai.ManickamKR

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cbe773d1-f056-49b1-8c64-eea57ca8a9ea@microchip.com \
    --to=durai.manickamkr@microchip.com \
    --cc=Hari.PrasathGE@microchip.com \
    --cc=alexandre.belloni@bootlin.com \
    --cc=linux-i3c@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).