Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:lib\test_printf.c Create Date:2022-07-28 06:32:29
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:test_number

Proto:static void __init test_number(void)

Type:void

Parameter:Nothing

152  test("0x1234abcd ", "%#-12x", 0x1234abcd)
153  test(" 0x1234abcd", "%#12x", 0x1234abcd)
154  test("0|001| 12|+123| 1234|-123|-1234", "%d|%03d|%3d|%+d|% d|%+d|% d", 0, 1, 12, 123, 1234, - 123, - 1234)
155  test("0|1|1|128|255", "%hhu|%hhu|%hhu|%hhu|%hhu", 0, 1, 257, 128, - 1)
156  test("0|1|1|-128|-1", "%hhd|%hhd|%hhd|%hhd|%hhd", 0, 1, 257, 128, - 1)
157  test("2015122420151225", "%ho%ho%#ho", 1037, 5282, - 11627)
166  test("00|0|0|0|0", "%.2d|%.1d|%.0d|%.*d|%1.0d", 0, 0, 0, 0, 0, 0)
175  val = -16
176  test("0xfffffff0|0xf0|0xf0", "%#02x|%#02x|%#02x", val, val & 0xff, (u8)val)
Caller
NameDescribe
selftest