X-Git-Url: http://git.monstr.eu/?a=blobdiff_plain;f=Documentation%2Fcore-api%2Fprintk-formats.rst;h=4346ae17a72c356ee640406636cc0db709e8dbf8;hb=cc396d27d8d5884bbb555efd7783b9e9e2b41dc2;hp=7b6bfd8a78d35feee819c34dc8acbef636560ba6;hpb=94f2be50badfa88e96033e77621c6711d58f84d3;p=linux-2.6-microblaze.git diff --git a/Documentation/core-api/printk-formats.rst b/Documentation/core-api/printk-formats.rst index 7b6bfd8a78d3..4346ae17a72c 100644 --- a/Documentation/core-api/printk-formats.rst +++ b/Documentation/core-api/printk-formats.rst @@ -37,14 +37,13 @@ Integer types u64 %llu or %llx -If is dependent on a config option for its size (e.g., sector_t, -blkcnt_t) or is architecture-dependent for its size (e.g., tcflag_t), use a -format specifier of its largest possible type and explicitly cast to it. +If is architecture-dependent for its size (e.g., cycles_t, tcflag_t) or +is dependent on a config option for its size (e.g., blk_status_t), use a format +specifier of its largest possible type and explicitly cast to it. Example:: - printk("test: sector number/total blocks: %llu/%llu\n", - (unsigned long long)sector, (unsigned long long)blockcount); + printk("test: latency: %llu cycles\n", (unsigned long long)time); Reminder: sizeof() returns type size_t. @@ -596,6 +595,24 @@ For printing netdev_features_t. Passed by reference. +V4L2 and DRM FourCC code (pixel format) +--------------------------------------- + +:: + + %p4cc + +Print a FourCC code used by V4L2 or DRM, including format endianness and +its numerical value as hexadecimal. + +Passed by reference. + +Examples:: + + %p4cc BG12 little-endian (0x32314742) + %p4cc Y10 little-endian (0x20303159) + %p4cc NV12 big-endian (0xb231564e) + Thanks ======