Haryslee
9547133e64
fix:修复llvm编译环境下内核态内存调测调用栈信息解析有误的问题
...
背景:内核态内存调测调用栈信息在gcc编译环境下是准确的,但是llvm
编译环境下是错误的,分析知,gcc和llvm编译环境下fp和lr的对应关系
是有区别的。
修复:增加llvm编译环境下对lr解析的逻辑,并用编译宏控制。
close #I40TQS
Signed-off-by: Haryslee <lihao189@huawei.com>
Change-Id: If2a7b7a286d91e78dcff2bdeb136fda71e656a79
2021-07-15 19:35:04 +08:00
qidechun
a195aac9fb
feat: add blackbox for liteos_a
...
1、在内核增加BlackBox核心框架,对外提供模块回调接口注册和故障处理接口。
2、增加默认的系统模块适配层,处理通用内核态和用户态故障日志抓取和保存。
3、BBOX特性默认关闭,若想使用此特性,请在内核配置文件中增加如下编译选项:
LOSCFG_BLACKBOX=y
LOSCFG_SAVE_EXCINFO=y
LOSCFG_SAVE_EXCINFO可以帮助抓取更多的故障日志。
4、若已经打开BBOX特性,想快速验证此特性,请添加如下编译选项:
LOSCFG_HIDUMPER=y
Close #I406NP
Signed-off-by: qidechun <qidechun@huawei.com>
2021-07-14 09:37:35 +08:00
openharmony_ci
d7387508e3
!402 消除编译告警
...
Merge pull request !402 from x_xiny/master
2021-07-09 08:37:20 +00:00
x_xiny
e4ff04586f
fix:消除编译告警
...
【背景】
消除编译告警
【修改方案】
消除编译告警
re #I3ZC1R
Change-Id: I594d0f57e4cbbdb246a6bef1c978a38228123a34
Signed-off-by: x-xiny <1301913191@qq.com>
Change-Id: I1d75cdcdcf9d06ec28e541cdfea77300da7c6bb1
2021-07-08 20:30:33 +08:00
openharmony_ci
78906f4a6c
!406 修正最小编译时的错误
...
Merge pull request !406 from Caoruihong/qemu_mini
2021-07-07 08:29:28 +00:00
Denny
55e5e29005
回退 'Pull Request !401 : 【DFX子系统】【BBoxDetector】LiteOS_A死机重启维测框架'
2021-07-07 10:29:43 +08:00
Caoruihong
ac8c2c6d5b
fix: minimal compile
...
fix compile errors in minimal compilation
Signed-off-by: Caoruihong <crh.cao@huawei.com>
Change-Id: I48f4f7b27c684e2c747c1949776c5c4f9e383dec
2021-07-07 00:26:33 +08:00
qidechun
425975e481
feat: add blackbox for liteos_a
...
1、在内核增加BlackBox核心框架,对外提供模块回调接口注册和故障处理接口。
2、增加默认的系统模块适配层,处理通用内核态和用户态故障日志抓取和保存。
Close #I3NN7V
Signed-off-by: qidechun <qidechun@huawei.com>
2021-07-06 07:49:59 +08:00
openharmony_ci
003810284c
!384 对内核中menuconfig开关的宏使用#ifdef/#ifndef来做预编译判断
...
Merge pull request !384 from boxi/upload
2021-07-01 07:11:13 +00:00
boxi
4e4f2d6d7e
refactor: 对LiteOS_a内核中menuconfig开关的宏使用#ifdef/#ifndef做预编译处理
...
LiteOS_a中有部分配置宏进行了重复冗余定义,导致当头文件未被包含时,极易引入错误,
故对menuconfig配置宏进行统一处理,均使用#ifdef/#ifndef作为预编译判断方式
Close #I3YEGS
Change-Id: Ife6db770cc66de1d6199a4f3ba3950e9bfd0e71a
Signed-off-by: boxi <lewis.liulei@huawei.com>
2021-07-01 09:08:18 +08:00
openharmony_ci
abbeca1cb2
!359 sysroot和CPU架构参数通过BUILD.gn传递给Make
...
Merge pull request !359 from Caoruihong/sysroot
2021-06-29 08:14:54 +00:00
Caoruihong
9e45086d19
chore: pass sysroot and arch related cflags by BUILD.gn
...
sysroot and arch related cflags are pass by BUILD.gn now.
Signed-off-by: Caoruihong <crh.cao@huawei.com>
Change-Id: Ia6000dd7ed8a8a37e935ace49d8460a919a16566
2021-06-28 16:31:02 +08:00
Haryslee
9db3407589
feat: 基于汇编实现内核对用户态内存清零的功能
...
背景:LOS_UserMemClear接口原有实现是通过在内核中
申请一块堆内存并对其清零,调用copy_to_user来达到
对用户态内存清零的目的,需要使用堆内存。
修改方案:基于汇编实现内核对用户态内存清零的功能。
close #I3XXT0
Change-Id: I27cb1e45559cb75a9b330799fe427abd54f51c15
Signed-off-by: Haryslee <lihao189@huawei.com>
2021-06-26 15:31:42 +08:00
openharmony_ci
1a3f3f54e7
!302 fix: Codex告警清零
...
Merge pull request !302 from Far/master
2021-06-08 08:48:48 +08:00
openharmony_ci
647f3defcd
!296 支持最小化特性编译,添加了一个针对qemu arm virt的样例config配置
...
Merge pull request !296 from Caoruihong/master
2021-06-07 22:51:46 +08:00
Far
b5370af822
fix: codex clean
...
1. 修复可能对NULL指针解引用的场景
2. 将不修改内容的指针入参修改为const
3. 对getpgrp的返回值进行校验后再使用
4. 修复了局部变量未初始化的问题
Close #I3UOFN
Signed-off-by: Far <yesiyuan2@huawei.com>
2021-06-07 17:08:02 +08:00
Caoruihong
744b2021b2
chore: add a mini config for qemu arm virt
...
support turn off as many features as possible.
current only libc and posix and bsd can not be turned off.
Signed-off-by: Caoruihong <crh.cao@huawei.com>
Change-Id: I1e97570c67593207a56dc11f357eca4b4a018bfd
2021-06-05 17:40:22 +08:00
openharmony_ci
2067b2f648
!256 fix: 解决kill进程时无法保证进程持有的系统资源合理释放
...
Merge pull request !256 from zhushengle/Sig
2021-06-03 17:00:00 +08:00
zhushengle
cf89f016e9
fix: 解决kill进程时无法保证进程的已持有的内核资源合理释放.
...
背景: 当前信号实现原理是在系统调用结束和中断结束时检查是否有信号处理,
如果有信号处理就切去处理信号,信号处理结束后回来继续按原来流程执行。
问题:当用户态线程在执行系统调用或缺页异常时,运行在内核态,如果此时有信
号需要处理,且该线程已经持有了部分内核资源(如:锁,内存等), 此时如
果有中断发生,则在中断结束时,就会去处理该信号,此时用户态线程持有
了内核未释放的资源跑到了用户态去运行,如果该线程在用户态出现问题,
那么它持有的内核资源就无法被释放了。
方案:用户态线程在执行系统调用和缺页异常时暂时屏蔽信号,防止此时有中断去
处理信号,等系统调用结束或缺页异常结束时再去处理信号。
解决的问题:
1. 执行系统调用或缺页异常时屏蔽信号,防止中断去处理信号
2.解决无法kill 因为用户态的锁、ipc等阻塞的用户态线程
3.进程退出方式转变为: 依次通过kill去杀死该进程的所有线程
Close #I3S0N0
Change-Id: I0c48b9c89382826191b8a9326c71b57ba84124c2
2021-05-24 14:29:37 +08:00
openharmony_ci
a3cef3f176
!264 补充TODOList
...
Merge pull request !264 from Denny/DennyShen-master-patch-73167
2021-05-21 15:17:08 +08:00
arvinzzz
8cde768588
refactor: Refactored the kernel boot process and added a init framework
...
close: #I3I768
Change-Id: I4f801df4abe1a9afdf43391c28276e96a5e81513
2021-05-20 16:45:43 +08:00
zhushengle
a89fb57f57
fix: Fix kernel page fault exception handling causing system exception.
...
Close #I3RAN4
Change-Id: Ice9bc67371ad85476ec99b46b7555d41abd93e94
2021-05-14 13:12:57 +08:00
zhushengle
e840188a65
fix:User-mode exception handling runs on the thread's SVC stack.
...
Close #I3QFXL
Change-Id: Iaa036651415d93df231916d7534364ad3a86ed3c
2021-05-11 17:19:10 +08:00
openharmony_ci
ca5555e6a5
!190 fix:solve the coupling between the kernel and the structure under ARCH
...
Merge pull request !190 from zhushengle/Stack
2021-05-11 11:46:40 +08:00
zhushengle
1e308db64e
fix:Fixed exception not saving stack pointer of SVC mode and abnormal signal processing issues
...
Close #I3OAFR
Change-Id: I25b14572809b6fabb9e9d17de89a99047c02a59b
2021-05-11 09:58:54 +08:00
zhushengle
f6c4f6f5da
fix: Solution of conflict
...
Change-Id: If6304999f1dfbcdfbc1670b73ace61b8024336bd
2021-05-06 21:10:22 +08:00
openharmony_ci
be4d8e74cc
!201 系统异常信息保存到存储介质中的功能从shell依赖中剥离
...
Merge pull request !201 from zhangfanfan2/master
2021-05-06 20:44:32 +08:00
YOUR_NAME
d846035f3e
feature:the feature of saving system exception information to the
...
storage medium is separated from the shell module.
Change-Id: Id56939001d70bb92d9cc02bd7c9f55ca8b61cf5b
2021-05-06 15:18:15 +08:00
Haryslee
022768ab58
Delete redundant code
...
Change-Id: Id75a1b146766f448838afc80ad11cfd9d990e94e
2021-04-30 10:21:49 +08:00
openharmony_ci
28df6989f9
!185 多核情况下当系统持有调度锁异常时,无异常信息输出
...
Merge pull request !185 from zhangfanfan2/master
2021-04-28 08:53:15 +08:00
YOUR_NAME
5bf4d1c712
fix: no exception information output, when the system is abnormal
...
after holding the scheduling lock in SMP.
Change-Id: I6f148d7b36d7aa6d0df09300949f53ea3c3d63b7
2021-04-26 20:13:13 +08:00
zhushengle
6d63f75e7f
fix:Solve the coupling between the kernel and the structure under ARCH.
...
Close #I3OAFR
Change-Id: Icea238e20adf402d0ec1fc7e47ff4e58124a5e83
2021-04-26 19:54:49 +08:00
boxi
f13b90e430
fix: Provide a separate configuration macro for boot environment in RAM.
...
Provide a separate configuration macro for boot environment in RAM.
Depends on: Need to copy boot environment data to the specified ram by boot.
Closes #I3OADR
Change-Id: Ie36a92c0a44f245482d1602c3a6851395944776d
2021-04-26 19:39:52 +08:00
YOUR_NAME
28aa777191
fix: no exception information output, when the system is abnormal
...
after holding the scheduling lock in SMP.
Change-Id: Ib10128fede9aa3e00269f1265089a917ffd96d88
2021-04-25 20:53:33 +08:00
YOUR_NAME
0ed8adfe3a
fix: no exception information output, when the system is abnormal after holding
...
the scheduling lock in SMP.
Change-Id: Idb793a5446126e638af52ff78b43bb7f8271317c
2021-04-25 20:16:51 +08:00
zhangfanfan2
9ab63a41b3
fix:LR value is incorrectly parsed when the user mode exception stack is backtracked
2021-04-23 11:53:06 +08:00
Caoruihong
18a98d1cb4
move noreturn attribute in front
...
Change-Id: Idce45c48e41b6794de21635517cab8a9d2c9ef03
2021-04-21 17:19:56 +08:00
openharmony_ci
7ba0bfa800
!157 删除无用的__cplusplus,移除不必要的文件x权限
...
Merge pull request !157 from Caoruihong/cplusplus
2021-04-20 09:01:45 +08:00
Caoruihong
7e73c929a2
remove __cplusplus guards in .c files
...
Change-Id: I052d930d54e63179b17b77f02c107a015f3cfc3f
2021-04-19 18:28:25 +08:00
Caoruihong
1ea9610ffd
code optimization
...
Change-Id: I8d2e9f96e86f4130474da9898791240b5d42328e
2021-04-19 15:24:00 +08:00
Caoruihong
ea794ac751
add noreturn attribute for LOS_Panic
...
Change-Id: Id2c76e3282d72bce18cf0925e12afaa0c3b06a90
2021-04-16 18:46:05 +08:00
Caoruihong
d2197c801f
use -include option instead of including menuconfig manually
...
Change-Id: Ie48b96fe9c8ab036d7234b56a169d6668171a895
2021-04-14 17:56:48 +08:00
openharmony_ci
b9a4f8b3f1
!115 kernel platform目录整改
...
Merge pull request !115 from SimonLi/master
2021-04-10 10:31:37 +08:00
zhangfanfan2
ee8ae574ec
回退IsValidFP的修改提交
2021-04-09 19:36:29 +08:00
YOUR_NAME
cd9c1d9789
[Desc] Modify IsValidFP to IsValidVaddr for issues I3HWYP
...
Change-Id: I0580a9328f8824869f1744f31cbfc2bf85516f66
2021-04-09 17:14:32 +08:00
SimonLi
3d3f0710f9
Merge branch 'master' of https://gitee.com/kkup180/kernel_liteos_a
2021-04-09 14:30:22 +08:00
openharmony_ci
cf5baa29f2
!127 clang编译的系统镜像内核栈回溯功能失效
...
Merge pull request !127 from zhangfanfan2/master
2021-04-08 14:53:13 +08:00
SimonLi
91b3d9f744
Merge branch 'master' of https://gitee.com/kkup180/kernel_liteos_a
2021-04-08 09:10:16 +08:00
Caoruihong
c2e7879dbc
fix accuracy of LOS_CurrNanosec
...
Change-Id: I5612d54d3cb92a119baaec396c723734c27a9d0c
2021-04-07 22:51:03 +08:00
YOUR_NAME
03a64228ed
[Desc] Solve the problem of exception stack traceback for clang.
...
Change-Id: Ifdca9a23ba788fa66f3815203514c9034680df49
2021-04-07 15:43:57 +08:00