mywiki:linux:linux_code_sparse_test_anaylysis
Differences
This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| mywiki:linux:linux_code_sparse_test_anaylysis [2016/06/23 09:34] – created shaoguoh | mywiki:linux:linux_code_sparse_test_anaylysis [2019/09/15 18:55] (current) – external edit 127.0.0.1 | ||
|---|---|---|---|
| Line 6: | Line 6: | ||
| ====== Sparse ====== | ====== Sparse ====== | ||
| Get sparse | Get sparse | ||
| + | You can get sparse from git:// | ||
| + | |||
| - | You can get sparse from git:// | ||
| - | |||
| Using sparse | Using sparse | ||
| + | |||
| To use sparse for kernel development simply pass on the C=1 argument onto your make command. For example to enable sparse for mac80211 development you would use: | To use sparse for kernel development simply pass on the C=1 argument onto your make command. For example to enable sparse for mac80211 development you would use: | ||
| - | make C=1 M=net/ | + | |
| + | | ||
| Endian checks | Endian checks | ||
| Line 18: | Line 20: | ||
| Endian checks are encouraged. Most endian complaints are typically valid and reflect design issues. These should be reviewed carefully. Some drivers force-enable endian checks with sparse by forcing it through their own driver makefiles upstream. If drivers do not have these you can enable sparse checks yourself by appending to your make command: | Endian checks are encouraged. Most endian complaints are typically valid and reflect design issues. These should be reviewed carefully. Some drivers force-enable endian checks with sparse by forcing it through their own driver makefiles upstream. If drivers do not have these you can enable sparse checks yourself by appending to your make command: | ||
| - | CF=" | + | |
| To enforce endian checks on your driver you can use something as follows on your driver Makefile: | To enforce endian checks on your driver you can use something as follows on your driver Makefile: | ||
| - | ccflags-y += -D__CHECK_ENDIAN__ | + | |
| - | | ||
mywiki/linux/linux_code_sparse_test_anaylysis.1466645690.txt.gz · Last modified: (external edit)
