Not able to detect a new adxl345 i2c device with driver

Hi all,

I am stuck at this,
4.4.92-bone-rt-r19

/home/nikhil/bbblatest/bb-kernel/KERNEL/drivers/iio/accel/adxl345_core.c

/home/nikhil/bbblatest/bb-kernel/KERNEL/drivers/iio/accel/adxl345_i2c.c

I compiled this driver as a module, and

echo adxl345_i2c 0x53 > /sys/bus/i2c/devices/i2c-2/new_device

so now I can see

root@arm:/sys/devices/platform/ocp/4819c000.i2c/i2c-2/2-0053# cat name
adxl345_i2c

lsmod output

snd_timer 19390 1 snd_pcm
snd 60164 3 snd_soc_core,snd_timer,snd_pcm
tda998x 11384 0
soundcore 7620 1 snd
uio_pdrv_genirq 3981 0
uio 9208 1 uio_pdrv_genirq
leds_gpio 3740 0
adxl345_i2c 2359 0
adxl345_core 2660 1 adxl345_i2c
ip_tables 12312 3 iptable_filter,iptable_mangle,iptable_nat
x_tables 17789 3 ip_tables,iptable_filter,iptable_mangle

So my driver is working. I have put a print in probe function inside driver but I can’t see that print function to be printing.That means the driver is not probing for my i2c device.
What else need to be done in order to associate this device and driver?

I got this,

my driver name was
adxl_i2c

my device name was
adxl345

instantiating correct device made my probe function work right away.
Now I will try to do it device tree way.