[P3762/P3783]:Virtual i2c mux support for other Hawks.

Add virtual i2c bus support for 2nd,3rd & 4th Hawks
to read/write EEPROM data while streaming.

Bug 4807682

Change-Id: I76e4a1128a66f22d13f7ee2c04c64d42da519080
Signed-off-by: Praveen AC <pac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/device/hardware/nvidia/t23x-public-dts/+/3210318
Reviewed-by: Ankur Pawar <ankurp@nvidia.com>
Reviewed-by: Bibek Basu <bbasu@nvidia.com>
GVS: buildbot_gerritrpt <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
Praveen AC
2024-09-09 19:00:16 +00:00
committed by mobile promotions
parent 50cd4a94af
commit e96aba03cf
10 changed files with 183 additions and 125 deletions

View File

@@ -1113,6 +1113,8 @@
};
};
};
};
i2c@2 {
ar0234_e@34 {
compatible = "nvidia,ar0234_hawk_owl";
reg = <0x34>;
@@ -1249,6 +1251,8 @@
};
};
};
};
i2c@3 {
ar0234_g@36 {
compatible = "nvidia,ar0234_hawk_owl";
reg = <0x36>;
@@ -1500,7 +1504,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_e@34";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@2/ar0234_e@34";
status = "okay";
};
};
@@ -1511,7 +1515,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_f@35";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@2/ar0234_f@35";
status = "okay";
};
};
@@ -1522,7 +1526,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_g@36";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@3/ar0234_g@36";
status = "okay";
};
};
@@ -1533,7 +1537,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_h@37";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@3/ar0234_h@37";
status = "okay";
};
};

View File

@@ -24,89 +24,89 @@
reg = <0>;
status = "okay";
ar0234_vi_in0: endpoint {
vc-id = <0>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out0>;
vc-id = <0>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out0>;
status = "okay";
};
};
};
port@1 {
reg = <1>;
status = "okay";
ar0234_vi_in1: endpoint {
vc-id = <1>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out1>;
vc-id = <1>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out1>;
status = "okay";
};
};
};
port@2 {
reg = <2>;
status = "okay";
ar0234_vi_in2: endpoint {
vc-id = <0>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out2>;
vc-id = <0>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out2>;
status = "okay";
};
};
};
port@3 {
reg = <3>;
status = "okay";
ar0234_vi_in3: endpoint {
vc-id = <1>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out3>;
vc-id = <1>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out3>;
status = "okay";
};
};
};
port@4 {
reg = <4>;
status = "okay";
ar0234_vi_in4: endpoint {
vc-id = <0>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out4>;
vc-id = <0>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out4>;
status = "okay";
};
};
};
port@5 {
reg = <5>;
status = "okay";
ar0234_vi_in5: endpoint {
vc-id = <1>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out5>;
vc-id = <1>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out5>;
status = "okay";
};
};
};
port@6 {
reg = <6>;
status = "okay";
ar0234_vi_in6: endpoint {
vc-id = <0>;
port-index = <3>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out6>;
vc-id = <0>;
port-index = <3>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out6>;
status = "okay";
};
};
};
port@7 {
reg = <7>;
status = "okay";
ar0234_vi_in7: endpoint {
vc-id = <1>;
vc-id = <1>;
port-index = <3>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_out7>;
status = "okay";
};
};
};
port@8 {
reg = <8>;
@@ -180,9 +180,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out0: endpoint@1 {
remote-endpoint = <&ar0234_vi_in0>;
remote-endpoint = <&ar0234_vi_in0>;
status = "okay";
};
};
};
};
};
@@ -206,9 +206,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out1: endpoint@3 {
remote-endpoint = <&ar0234_vi_in1>;
remote-endpoint = <&ar0234_vi_in1>;
status = "okay";
};
};
};
};
};
@@ -232,9 +232,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out2: endpoint@5 {
remote-endpoint = <&ar0234_vi_in2>;
remote-endpoint = <&ar0234_vi_in2>;
status = "okay";
};
};
};
};
};
@@ -258,9 +258,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out3: endpoint@7 {
remote-endpoint = <&ar0234_vi_in3>;
remote-endpoint = <&ar0234_vi_in3>;
status = "okay";
};
};
};
};
};
@@ -284,9 +284,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out4: endpoint@9 {
remote-endpoint = <&ar0234_vi_in4>;
remote-endpoint = <&ar0234_vi_in4>;
status = "okay";
};
};
};
};
};
@@ -310,9 +310,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out5: endpoint@11 {
remote-endpoint = <&ar0234_vi_in5>;
remote-endpoint = <&ar0234_vi_in5>;
status = "okay";
};
};
};
};
};
@@ -336,9 +336,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out6: endpoint@13 {
remote-endpoint = <&ar0234_vi_in6>;
remote-endpoint = <&ar0234_vi_in6>;
status = "okay";
};
};
};
};
};
@@ -362,9 +362,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out7: endpoint@15 {
remote-endpoint = <&ar0234_vi_in7>;
remote-endpoint = <&ar0234_vi_in7>;
status = "okay";
};
};
};
};
};
@@ -388,9 +388,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out8: endpoint@17 {
remote-endpoint = <&ar0234_vi_in8>;
remote-endpoint = <&ar0234_vi_in8>;
status = "okay";
};
};
};
};
};
@@ -414,9 +414,9 @@
reg = <1>;
status = "okay";
ar0234_csi_out9: endpoint@19 {
remote-endpoint = <&ar0234_vi_in9>;
remote-endpoint = <&ar0234_vi_in9>;
status = "okay";
};
};
};
};
};
@@ -430,19 +430,19 @@
reg = <0>;
status = "okay";
ar0234_csi_in10: endpoint@20 {
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_ar0234_out10>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_ar0234_out10>;
status = "okay";
};
};
};
port@1 {
reg = <1>;
status = "okay";
ar0234_csi_out10: endpoint@21 {
remote-endpoint = <&ar0234_vi_in10>;
remote-endpoint = <&ar0234_vi_in10>;
status = "okay";
};
};
};
};
};
@@ -456,19 +456,19 @@
reg = <0>;
status = "okay";
ar0234_csi_in11: endpoint@22 {
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_ar0234_out11>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_ar0234_out11>;
status = "okay";
};
};
};
port@1 {
reg = <1>;
status = "okay";
ar0234_csi_out11: endpoint@23 {
remote-endpoint = <&ar0234_vi_in11>;
remote-endpoint = <&ar0234_vi_in11>;
status = "okay";
};
};
};
};
};
@@ -535,10 +535,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out8: endpoint {
vc-id = <0>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in8>;
vc-id = <0>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in8>;
};
};
};
@@ -603,10 +603,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out9: endpoint {
vc-id = <1>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in9>;
vc-id = <1>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in9>;
};
};
};
@@ -671,10 +671,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out10: endpoint {
vc-id = <2>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in10>;
vc-id = <2>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in10>;
};
};
};
@@ -739,10 +739,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out11: endpoint {
vc-id = <3>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in11>;
vc-id = <3>;
port-index = <4>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in11>;
};
};
};
@@ -899,10 +899,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out0: endpoint {
vc-id = <0>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in0>;
vc-id = <0>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in0>;
};
};
};
@@ -967,10 +967,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out1: endpoint {
vc-id = <1>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in1>;
vc-id = <1>;
port-index = <0>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in1>;
};
};
};
@@ -1037,10 +1037,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out2: endpoint {
vc-id = <0>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in2>;
vc-id = <0>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in2>;
};
};
};
@@ -1105,14 +1105,16 @@
port@0 {
reg = <0>;
ar0234_ar0234_out3: endpoint {
vc-id = <1>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in3>;
vc-id = <1>;
port-index = <1>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in3>;
};
};
};
};
};
i2c@2 {
ar0234_e@34 {
compatible = "nvidia,ar0234_hawk_owl";
reg = <0x34>;
@@ -1173,10 +1175,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out4: endpoint {
vc-id = <0>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in4>;
vc-id = <0>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in4>;
};
};
};
@@ -1241,14 +1243,16 @@
port@0 {
reg = <0>;
ar0234_ar0234_out5: endpoint {
vc-id = <1>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in5>;
vc-id = <1>;
port-index = <2>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in5>;
};
};
};
};
};
i2c@3 {
ar0234_g@36 {
compatible = "nvidia,ar0234_hawk_owl";
reg = <0x36>;
@@ -1309,10 +1313,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out6: endpoint {
vc-id = <0>;
port-index = <3>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in6>;
vc-id = <0>;
port-index = <3>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in6>;
};
};
};
@@ -1377,10 +1381,10 @@
port@0 {
reg = <0>;
ar0234_ar0234_out7: endpoint {
vc-id = <1>;
port-index = <3>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in7>;
vc-id = <1>;
port-index = <3>;
bus-width = <2>;
remote-endpoint = <&ar0234_csi_in7>;
};
};
};
@@ -1409,6 +1413,7 @@
drivernode0 {
/* Declare PCL support driver (classically known as guid) */
pcl_id = "v4l2_sensor";
/* Declare the device-tree hierarchy to driver instance */
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@3180000/ar0234_i@30";
status = "okay";
};
@@ -1421,6 +1426,7 @@
drivernode0 {
/* Declare PCL support driver (classically known as guid) */
pcl_id = "v4l2_sensor";
/* Declare the device-tree hierarchy to driver instance */
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@3180000/ar0234_j@32";
status = "okay";
};
@@ -1498,7 +1504,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_e@34";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@2/ar0234_e@34";
status = "okay";
};
};
@@ -1509,7 +1515,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_f@35";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@2/ar0234_f@35";
status = "okay";
};
};
@@ -1520,7 +1526,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_g@36";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@3/ar0234_g@36";
status = "okay";
};
};
@@ -1531,7 +1537,7 @@
status = "okay";
drivernode0 {
pcl_id = "v4l2_sensor";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@1/ar0234_h@37";
sysfs-device-tree = "/sys/firmware/devicetree/base/bus@0/i2c@31e0000/virtual_i2c_mux@50/i2c@3/ar0234_h@37";
status = "okay";
};
};

View File

@@ -154,12 +154,16 @@
ar0234_d@33 {
status = "disabled";
};
};
i2c@2 {
ar0234_e@34 {
status = "disabled";
};
ar0234_f@35 {
status = "disabled";
};
};
i2c@3 {
ar0234_g@36 {
status = "disabled";
};

View File

@@ -154,12 +154,16 @@
ar0234_d@33 {
status = "okay";
};
};
i2c@2 {
ar0234_e@34 {
status = "disabled";
};
ar0234_f@35 {
status = "disabled";
};
};
i2c@3 {
ar0234_g@36 {
status = "disabled";
};

View File

@@ -155,12 +155,16 @@
ar0234_d@33 {
status = "okay";
};
};
i2c@2 {
ar0234_e@34 {
status = "okay";
};
ar0234_f@35 {
status = "okay";
};
};
i2c@3 {
ar0234_g@36 {
status = "disabled";
};

View File

@@ -154,12 +154,16 @@
ar0234_d@33 {
status = "okay";
};
};
i2c@2 {
ar0234_e@34 {
status = "okay";
};
ar0234_f@35 {
status = "okay";
};
};
i2c@3 {
ar0234_g@36 {
status = "okay";
};

View File

@@ -155,12 +155,16 @@
ar0234_d@33 {
status = "disabled";
};
};
i2c@2 {
ar0234_e@34 {
status = "disabled";
};
ar0234_f@35 {
status = "disabled";
};
};
i2c@3 {
ar0234_g@36 {
status = "disabled";
};

View File

@@ -68,12 +68,16 @@
ar0234_d@33 {
status = "okay";
};
};
i2c@2 {
ar0234_e@34 {
status = "okay";
};
ar0234_f@35 {
status = "okay";
};
};
i2c@3 {
ar0234_g@36 {
status = "okay";
};

View File

@@ -215,6 +215,12 @@
pwdn-gpios = <&gpio CAM0_PWDN GPIO_ACTIVE_HIGH>;
pwr-gpios = <&gpio PWR_EN GPIO_ACTIVE_HIGH>;
};
};
i2c@2 {
reg = <2>;
i2c-mux,deselect-on-exit;
#address-cells = <1>;
#size-cells = <0>;
ar0234_e@34 {
status = "disabled";
def-addr = <0x10>;
@@ -247,6 +253,12 @@
pwdn-gpios = <&gpio CAM0_PWDN GPIO_ACTIVE_HIGH>;
pwr-gpios = <&gpio PWR_EN GPIO_ACTIVE_HIGH>;
};
};
i2c@3 {
reg = <3>;
i2c-mux,deselect-on-exit;
#address-cells = <1>;
#size-cells = <0>;
ar0234_g@36 {
status = "disabled";
def-addr = <0x10>;

View File

@@ -221,6 +221,12 @@
pwdn-gpios = <&gpio CAM0_PWDN GPIO_ACTIVE_HIGH>;
pwr-gpios = <&gpio PWR_EN GPIO_ACTIVE_HIGH>;
};
};
i2c@2 {
reg = <2>;
i2c-mux,deselect-on-exit;
#address-cells = <1>;
#size-cells = <0>;
ar0234_e@34 {
status = "okay";
def-addr = <0x10>;
@@ -253,6 +259,12 @@
pwdn-gpios = <&gpio CAM0_PWDN GPIO_ACTIVE_HIGH>;
pwr-gpios = <&gpio PWR_EN GPIO_ACTIVE_HIGH>;
};
};
i2c@3 {
reg = <3>;
i2c-mux,deselect-on-exit;
#address-cells = <1>;
#size-cells = <0>;
ar0234_g@36 {
status = "okay";
def-addr = <0x10>;