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
migrate stock user space build to new build system
[lunaix-os.git]
/
lunaix-os
/
LConfig
diff --git
a/lunaix-os/LConfig
b/lunaix-os/LConfig
index d66375dbb27fa1da91e1d7c7bbb935ff1c91ec63..65cfb07f68eddbdea37fbb89b15ff9b74d7b33e7 100644
(file)
--- a/
lunaix-os/LConfig
+++ b/
lunaix-os/LConfig
@@
-2,6
+2,15
@@
from datetime import datetime, date
from . import kernel, arch, hal
from . import kernel, arch, hal
+@native
+def get_patch_seq():
+ today = date.today()
+ year = today.year
+ start_of_year = datetime(year, 1, 1).date()
+ seq_num = (today - start_of_year).days
+
+ return "%d%d"%(year - 2000, seq_num)
+
@"Kernel Version"
@readonly
def lunaix_ver() -> str:
@"Kernel Version"
@readonly
def lunaix_ver() -> str:
@@
-9,12
+18,7
@@
def lunaix_ver() -> str:
Lunaix kernel version
"""
Lunaix kernel version
"""
- today = date.today()
- year = today.year
- start_of_year = datetime(year, 1, 1).date()
- seq_num = (today - start_of_year).days
-
- return "%s v0.%d%d"%(arch.val, year - 2000, seq_num)
+ return f"{arch.val} v0.0.{get_patch_seq()}"
@"Kernel Debug and Testing"
def debug_and_testing():
@"Kernel Debug and Testing"
def debug_and_testing():
@@
-46,7
+50,7
@@
def debug_and_testing():
Set the maximum time (in seconds) spent in kernel before considered
to be stalled.
"""
Set the maximum time (in seconds) spent in kernel before considered
to be stalled.
"""
- require(check_stall)
+ require
(check_stall)
return 10
return 10
@@
-58,7
+62,7
@@
def debug_and_testing():
Setting it to 0 disable this check
"""
Setting it to 0 disable this check
"""
- require(check_stall)
+ require
(check_stall)
return 0
return 0