DS2482 support for vf61?

There is support for DS2482 for VF61? I’ve found the documentation:

Documentation/w1/masters/DS2482

It says:

General Remarks

Valid addresses are 0x18, 0x19, 0x1a, and 0x1b.
However, the device cannot be detected without writing to the i2c bus, so no
detection is done. You should instantiate the device explicitly.

$ modprobe ds2482
$ echo ds2482 0x18 > /sys/bus/i2c/devices/i2c-0/new_device

But its not working

root@colibri-vf:~# modprobe ds2482
modprobe: FATAL: Module ds2482 not found.

The device is detected on the bus:

root@colibri-vf:~# i2cdetect -y -r 0
0 1 2 3 4 5 6 7 8 9 a b c d e f
00: -- -- -- -- -- -- -- -- -- -- -- -- --
10: -- -- -- -- -- -- -- -- 18 -- -- -- -- -- -- --
20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
60: -- -- -- -- -- -- -- -- UU -- -- -- -- -- -- --
70: -- -- -- -- -- -- -- --

Do I have to put it on Device Tree? How can I do it?

Rodrigo Martins

I guess @sanchayan.maity concluded you being on a Tegra branch due to the h=colibri part in your link URL however it looks like that one is rather bogus and always gets added when clicking on a tag in our cgit web interface. Given the id=Colibri_VF_LinuxImageV2.6Beta1_20160331 part you are indeed on a Vybrid version however using resp. toradex_vf_4.4 or toradex_vf_4.4-next branch is usually preferred.

It should also work similar to the trivial i2c devices which are enabled via device trees.
e.g.:

diff --git a/arch/arm/boot/dts/vf-colibri-eval-v3.dtsi b/arch/arm/boot/dts/vf-colibri-eval-v3.dtsi
index 8392dcd..38fec61 100644
--- a/arch/arm/boot/dts/vf-colibri-eval-v3.dtsi
+++ b/arch/arm/boot/dts/vf-colibri-eval-v3.dtsi
@@ -144,6 +144,11 @@
                compatible = "st,m41t00";
                reg = <0x68>;
        };
+
+       w1: ds2482@18 {
+               compatible = "dallas,ds2482";
+               reg = <0x18>;
+       };
 };

The kernel branch you are referring to in the link is meant for Tegras, the correct one would be here. The driver is here. This driver is not enabled by default. One would have to build the kernel after selecting the option CONFIG_W1_MASTER_2482. A device tree entry like the one here for the RTC driver on Colibri Evaluation board can be added.

Thank you. The modprobe worked. I think there is no support for Device Tree as I haven’t found the binding.

Thanks. I didn’t know the compatible string. In fact I’m using owfs, installed via opkg. With it I don’t need modprobe or Device Tree node.