git://scm.lunaixsky.com
/
lunaix-os.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
feat: support user-spcae pci rescan
[lunaix-os.git]
/
lunaix-os
/
hal
/
rtc
/
mc146818a.c
diff --git
a/lunaix-os/hal/rtc/mc146818a.c
b/lunaix-os/hal/rtc/mc146818a.c
index e918ffdba83024aa0a578b608d62b3c0fea2b0fc..6b645279e9331def4ba43877f3318caeb83331ce 100644
(file)
--- a/
lunaix-os/hal/rtc/mc146818a.c
+++ b/
lunaix-os/hal/rtc/mc146818a.c
@@
-195,7
+195,7
@@
rtc_init(struct device_def* devdef)
// Make sure the rtc timer is disabled by default
rtc_disable_timer();
// Make sure the rtc timer is disabled by default
rtc_disable_timer();
- struct hwrtc* rtc = hwrtc_alloc_new("mc146818");
+ struct hwrtc* rtc = hwrtc_alloc_new(
devdef,
"mc146818");
struct mc146818* state = valloc(sizeof(struct mc146818));
state->rtc_context = rtc;
struct mc146818* state = valloc(sizeof(struct mc146818));
state->rtc_context = rtc;
@@
-216,8
+216,8
@@
rtc_init(struct device_def* devdef)
}
static struct device_def devrtc_mc146818 = {
}
static struct device_def devrtc_mc146818 = {
- .name = "
rtc_mc146818
",
- .class = DEVCLASS(DEVIF_SOC, DEVFN_TIME, DEV_RTC
, 1
),
+ .name = "
MC146818 RTC
",
+ .class = DEVCLASS(DEVIF_SOC, DEVFN_TIME, DEV_RTC),
.init = rtc_init
};
EXPORT_DEVICE(mc146818, &devrtc_mc146818, load_earlystage);
\ No newline at end of file
.init = rtc_init
};
EXPORT_DEVICE(mc146818, &devrtc_mc146818, load_earlystage);
\ No newline at end of file