About blk_qc_t

blk_qc_t类型是通用块层一个类型,其定义以下:cookie

typedef unsigned int blk_qc_t;

请教了Lei ming两个问题,答复以下:code

  1. qc, 很好奇qc是什么的缩写?queue code?

queue cookie, which is only used by poll code path.it

  1. 下面3个宏定义表明什么含义呢?
#define BLK_QC_T_NONE           -1U
#define BLK_QC_T_SHIFT          16
#define BLK_QC_T_INTERNAL       (1U << 31)

NONE means the submitted bio needn't to be polled. It is used in request_to_qc_t(), and BLK_QC_T_INTERNAL means the tag is a internal tag, which is used for IO scheduler, and if it isn't set, it means the tag is a driver tag, which is for submitting IO to hardware/driver.io

本站公众号
   欢迎关注本站公众号,获取更多信息