Results 1 to 1 of 1
Hello Everyone,
I would like to know the method to use an i2c rtc like the ds1307 ( driver rtc-ds1307), when you have an other rtc, on the the mother ...
- 03-02-2010 #1Just Joined!
- Join Date
- Mar 2010
- Posts
- 1
use i2c rtc instead of cmos rtc
Hello Everyone,
I would like to know the method to use an i2c rtc like the ds1307 ( driver rtc-ds1307), when you have an other rtc, on the the mother board.
I use vmlinuz-2.6.32-trunk-686 image but i don't want to modify his .config.
During boot, the kernel detect the rtc-cmos and create the device dev/rtc-0
#
# RTC interfaces
#
CONFIG_RTC_INTF_SYSFS=y
CONFIG_RTC_INTF_PROC=y
CONFIG_RTC_INTF_DEV=y
# CONFIG_RTC_INTF_DEV_UIE_EMUL is not set
# CONFIG_RTC_DRV_TEST is not set
#
# I2C RTC drivers
#
CONFIG_RTC_DRV_DS1307=m
CONFIG_RTC_DRV_DS1374=m
CONFIG_RTC_DRV_DS1672=m
CONFIG_RTC_DRV_MAX6900=m
CONFIG_RTC_DRV_RS5C372=m
CONFIG_RTC_DRV_ISL1208=m
CONFIG_RTC_DRV_X1205=m
CONFIG_RTC_DRV_PCF8563=m
CONFIG_RTC_DRV_PCF8583=m
CONFIG_RTC_DRV_M41T80=m
# CONFIG_RTC_DRV_M41T80_WDT is not set
CONFIG_RTC_DRV_S35390A=m
CONFIG_RTC_DRV_FM3130=m
CONFIG_RTC_DRV_RX8581=m
CONFIG_RTC_DRV_RX8025=m
#
# SPI RTC drivers
#
CONFIG_RTC_DRV_M41T94=m
CONFIG_RTC_DRV_DS1305=m
CONFIG_RTC_DRV_DS1390=m
CONFIG_RTC_DRV_MAX6902=m
CONFIG_RTC_DRV_R9701=m
CONFIG_RTC_DRV_RS5C348=m
CONFIG_RTC_DRV_DS3234=m
CONFIG_RTC_DRV_PCF2123=m
#
# Platform RTC drivers
#
CONFIG_RTC_DRV_CMOS=y
CONFIG_RTC_DRV_DS1286=m
CONFIG_RTC_DRV_DS1511=m
CONFIG_RTC_DRV_DS1553=m
CONFIG_RTC_DRV_DS1742=m
CONFIG_RTC_DRV_STK17TA8=m
CONFIG_RTC_DRV_M48T86=m
CONFIG_RTC_DRV_M48T35=m
CONFIG_RTC_DRV_M48T59=m
CONFIG_RTC_DRV_BQ4802=m
CONFIG_RTC_DRV_V3020=m
CONFIG_RTC_DRV_WM831X=m
CONFIG_RTC_DRV_WM8350=m
CONFIG_RTC_DRV_PCF50633=m
CONFIG_RTC_DRV_AB3100=m
#
# on-CPU RTC drivers
#
CONFIG_DMADEVICES=y
[ 1.849472] platform rtc_cmos: registered platform RTC device (no PNP device found)
[ 2.361291] Driver 'rtc_cmos' needs updating - please use bus_type methods
[ 2.369458] rtc_cmos rtc_cmos: rtc core: registered rtc_cmos as rtc0
[ 2.377006] rtc0: alarms up to one day, 114 bytes nvram
[ 2.425866] Using IPI No-Shortcut mode
[ 2.437119] rtc_cmos rtc_cmos: setting system clock to 2010-02-02 00:00:07 UTC (1265068807)When i load the driver rtc-ds1307, none device are created, i can just verify with lsmod command that the module is loadedlrwxrwxrwx 1 root root 4 Feb 2 00:00 rtc -> rtc0
crw-rw---- 1 root audio 254, 0 Feb 2 00:00 rtc0
With an litle program i can access to this rtc with open, ioctl, and i2c_smbus_read_byte_data.Module Size Used by
rtc_ds1307 5354 0
...
i2c_core 12612 6 rtc_ds1307,i2c_isch
But how i can force the kernel to use ds1307 rtc when i use 'date' 'hwclock' commands?
best regards


Reply With Quote