by catmaker » Tue Feb 05, 2013 8:09 am
$this->bbcode_second_pass_quote('pepedog', 'I') rebuilt again, I need to know if not built into kernel is ok, ie a regular module
http://myplugbox.com/linux-raspberrypi-withPCF8523.tar.gzIt has 0001 and 0002 patches
I tried the above second rebuild of yours and the kernel boots up OK, but the hctosys.c fails to set the system time in the kernel boot up phase.
$this->bbcode_second_pass_code('', '
root@hagar:~# reboot
øø[22627.549955] Restarting system.
øàøø
Arch Linux 3.6.11-5-ARCH+ (ttyAMA0)
hagar login: root
øPassword:
Last login: Thu Jan 1 07:30:19 SGT 1970 on ttyAMA0
Last login: Tue Feb 5 15:22:09 on ttyAMA0
root@hagar:~# uname -a
Linux hagar 3.6.11-5-ARCH+ #1 PREEMPT Mon Feb 4 15:30:57 CST 2013 armv6l GNU/Linux
root@hagar:~# dmesg | grep -i rtc
[ 2.318229] drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
root@hagar:~#
')
I also tried module loading with
$this->bbcode_second_pass_code('', '
root@hagar:~# cat /etc/modules-load.d/raspberry-i2c.conf
# Load i2c stuff and peripherals at boot.
i2c_bcm2708
i2c_dev
rtc_pcf8523
root@hagar:~#
')
and the relevant dmesg after rebooting gives
$this->bbcode_second_pass_code('', '
root@hagar:~# dmesg | grep rtc
[ 2.318079] drivers/rtc/hctosys.c: unable to open rtc device (rtc0)
[ 3.848388] systemd-modules-load[57]: Inserted module 'rtc_pcf8523'
root@hagar:~#
root@hagar:~# ls /dev/rtc*
ls: cannot access /dev/rtc*: No such file or directory
root@hagar:~# !echo
echo pcf8523 0x68 > /sys/class/i2c-adapter/i2c-0/new_device
root@hagar:~# ls /dev/rtc*
/dev/rtc0
root@hagar:~#
')
The rtc-pcf8523 driver module was inserted
after hctosys.c wanted to set the system time. Even after the module was inserted, i2c-dev failed to register the device on the /dev directory. I had to manually perform a 'new_device' on the bus to do that..
I guess for more10's request of hctosys.c (kernel boot phase of setting system time) to work, all the below stuff has to be compiled as kernel built-in's: i2c-bcm2708, i2c-dev, hctosys.c, rtc-pcf8523 and the device-tree registration patch during board initialisation.
But, I can also understand why we'd need to keep chip drivers as modules instead of built-ins. It's probably for bloat reduction?
Anyway, thanks for the patches insertion.
