| /linux/block/ |
| H A D | blk-mq.h | 53 bool blk_mq_dispatch_rq_list(struct blk_mq_hw_ctx *hctx, struct list_head *, 55 void blk_mq_flush_busy_ctxs(struct blk_mq_hw_ctx *hctx, struct list_head *list); 56 struct request *blk_mq_dequeue_from_ctx(struct blk_mq_hw_ctx *hctx, 135 extern void blk_mq_hctx_kobj_init(struct blk_mq_hw_ctx *hctx); 174 struct blk_mq_hw_ctx *hctx; member 199 struct blk_mq_hw_ctx *hctx) in bt_wait_ptr() argument 201 if (!hctx) in bt_wait_ptr() 203 return sbq_wait_ptr(bt, &hctx->wait_index); in bt_wait_ptr() 209 static inline void blk_mq_tag_busy(struct blk_mq_hw_ctx *hctx) in blk_mq_tag_busy() argument 211 if (hctx->flags & BLK_MQ_F_TAG_QUEUE_SHARED) in blk_mq_tag_busy() [all …]
|
| H A D | blk-mq-sched.c | 22 void blk_mq_sched_mark_restart_hctx(struct blk_mq_hw_ctx *hctx) in blk_mq_sched_mark_restart_hctx() argument 24 if (test_bit(BLK_MQ_S_SCHED_RESTART, &hctx->state)) in blk_mq_sched_mark_restart_hctx() 27 set_bit(BLK_MQ_S_SCHED_RESTART, &hctx->state); in blk_mq_sched_mark_restart_hctx() 31 void __blk_mq_sched_restart(struct blk_mq_hw_ctx *hctx) in __blk_mq_sched_restart() argument 33 clear_bit(BLK_MQ_S_SCHED_RESTART, &hctx->state); in __blk_mq_sched_restart() 44 blk_mq_run_hw_queue(hctx, true); in __blk_mq_sched_restart() 58 struct blk_mq_hw_ctx *hctx = in blk_mq_dispatch_hctx_list() local 64 if (rq->mq_hctx != hctx) { in blk_mq_dispatch_hctx_list() 72 return blk_mq_dispatch_rq_list(hctx, &hctx_list, false); in blk_mq_dispatch_hctx_list() 85 static int __blk_mq_do_dispatch_sched(struct blk_mq_hw_ctx *hctx) in __blk_mq_do_dispatch_sched() argument [all …]
|
| H A D | blk-mq.c | 52 static void blk_mq_try_issue_list_directly(struct blk_mq_hw_ctx *hctx, 54 static int blk_hctx_poll(struct request_queue *q, struct blk_mq_hw_ctx *hctx, 61 static bool blk_mq_hctx_has_pending(struct blk_mq_hw_ctx *hctx) in blk_mq_hctx_has_pending() argument 63 return !list_empty_careful(&hctx->dispatch) || in blk_mq_hctx_has_pending() 64 sbitmap_any_bit_set(&hctx->ctx_map) || in blk_mq_hctx_has_pending() 65 blk_mq_sched_has_work(hctx); in blk_mq_hctx_has_pending() 71 static void blk_mq_hctx_mark_pending(struct blk_mq_hw_ctx *hctx, in blk_mq_hctx_mark_pending() argument 74 const int bit = ctx->index_hw[hctx->type]; in blk_mq_hctx_mark_pending() 76 if (!sbitmap_test_bit(&hctx->ctx_map, bit)) in blk_mq_hctx_mark_pending() 77 sbitmap_set_bit(&hctx->ctx_map, bit); in blk_mq_hctx_mark_pending() [all …]
|
| H A D | blk-mq-tag.c | 41 void __blk_mq_tag_busy(struct blk_mq_hw_ctx *hctx) in __blk_mq_tag_busy() argument 45 struct blk_mq_tags *tags = hctx->tags; in __blk_mq_tag_busy() 51 if (blk_mq_is_shared_tags(hctx->flags)) { in __blk_mq_tag_busy() 52 struct request_queue *q = hctx->queue; in __blk_mq_tag_busy() 58 if (test_bit(BLK_MQ_S_TAG_ACTIVE, &hctx->state) || in __blk_mq_tag_busy() 59 test_and_set_bit(BLK_MQ_S_TAG_ACTIVE, &hctx->state)) in __blk_mq_tag_busy() 84 void __blk_mq_tag_idle(struct blk_mq_hw_ctx *hctx) in __blk_mq_tag_idle() argument 86 struct blk_mq_tags *tags = hctx->tags; in __blk_mq_tag_idle() 89 if (blk_mq_is_shared_tags(hctx->flags)) { in __blk_mq_tag_idle() 90 struct request_queue *q = hctx->queue; in __blk_mq_tag_idle() [all …]
|
| /linux/samples/hid/ |
| H A D | hid_mouse.bpf.c | 8 static int hid_y_event(struct hid_bpf_ctx *hctx) in hid_y_event() argument 11 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 9 /* size */); in hid_y_event() 16 bpf_printk("event: size: %d", hctx->size); in hid_y_event() 53 static int hid_x_event(struct hid_bpf_ctx *hctx) in hid_x_event() argument 56 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 9 /* size */); in hid_x_event() 71 int BPF_PROG(hid_event, struct hid_bpf_ctx *hctx, enum hid_report_type type) in BPF_PROG() argument 73 int ret = hid_y_event(hctx); in BPF_PROG() 78 return hid_x_event(hctx); in BPF_PROG() 83 int BPF_PROG(hid_rdesc_fixup, struct hid_bpf_ctx *hctx) in BPF_PROG() argument 85 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 4096 /* size */); in BPF_PROG()
|
| H A D | hid_surface_dial.bpf.c | 14 int BPF_PROG(hid_event, struct hid_bpf_ctx *hctx) in BPF_PROG() argument 16 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 9 /* size */); in BPF_PROG() 105 int BPF_PROG(hid_rdesc_fixup, struct hid_bpf_ctx *hctx) in BPF_PROG() argument 107 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 4096 /* size */); in BPF_PROG()
|
| /linux/drivers/hid/bpf/progs/ |
| H A D | XPPen__ACK05.bpf.c | 218 int BPF_PROG(ack05_fix_rdesc, struct hid_bpf_ctx *hctx) in SEC() 220 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, HID_MAX_DESCRIPTOR_SIZE /* size */); in SEC() 221 __s32 rdesc_size = hctx->size; in SEC() 235 hid_set_name(hctx->hid, "Disabled by HID-BPF Hanvon Ugee Shortcut Remote"); in SEC() 265 int BPF_PROG(ack05_fix_events, struct hid_bpf_ctx *hctx) in SEC() 267 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, PAD_REPORT_LENGTH); in SEC() 278 HID_BPF_ASYNC_DELAYED_CALL(switch_to_raw_mode, hctx, 10); in SEC() 315 struct hid_bpf_ctx *hctx = hid_bpf_allocate_context(ctx->hid); in probe() local 317 if (!hctx) { in probe() 323 switch_to_raw_mode(hctx); in probe() [all …]
|
| H A D | XPPen__DecoMini4.bpf.c | 153 int BPF_PROG(hid_rdesc_fixup_xppen_deco_mini_4, struct hid_bpf_ctx *hctx) in SEC() 155 __u8 *data = hid_bpf_get_data(hctx, 0, HID_MAX_DESCRIPTOR_SIZE); in SEC() 160 if (hctx->size == RDESC_SIZE_PAD) { in SEC() 163 } else if (hctx->size == RDESC_SIZE_PEN) { in SEC() 172 int BPF_PROG(hid_device_event_xppen_deco_mini_4, struct hid_bpf_ctx *hctx) in SEC() 174 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 8 /* size */); in SEC()
|
| H A D | FR-TEC__Raptor-Mach-2.bpf.c | 137 int BPF_PROG(hid_fix_rdesc_raptor_mach_2, struct hid_bpf_ctx *hctx) in SEC() 139 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, HID_MAX_DESCRIPTOR_SIZE /* size */); in SEC() 156 int BPF_PROG(raptor_mach_2_fix_hat_switch, struct hid_bpf_ctx *hctx) in SEC() 158 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 64 /* size */); in SEC()
|
| H A D | XPPen__Artist24.bpf.c | 93 int BPF_PROG(hid_fix_rdesc_xppen_artist24, struct hid_bpf_ctx *hctx) in SEC() 95 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 4096 /* size */); in SEC() 154 int BPF_PROG(xppen_24_fix_eraser, struct hid_bpf_ctx *hctx) in SEC() 156 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 10 /* size */); in SEC()
|
| H A D | Thrustmaster__TCA-Yoke-Boeing.bpf.c | 100 int BPF_PROG(hid_fix_rdesc_tca_yoke, struct hid_bpf_ctx *hctx) in SEC() 104 if (hctx->size != expected_length) in SEC() 107 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, HID_MAX_DESCRIPTOR_SIZE /* size */); in SEC()
|
| H A D | HP__Elite-Presenter.bpf.c | 34 int BPF_PROG(hid_fix_rdesc, struct hid_bpf_ctx *hctx) in SEC() 36 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 4096 /* size */); in SEC()
|
| H A D | IOGEAR__Kaliber-MMOmentum.bpf.c | 25 int BPF_PROG(hid_fix_rdesc, struct hid_bpf_ctx *hctx) in SEC() 28 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 4096 /* size */); in SEC()
|
| H A D | Microsoft__Xbox-Elite-2.bpf.c | 96 int BPF_PROG(hid_fix_rdesc, struct hid_bpf_ctx *hctx) in SEC() 98 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 4096 /* size */); in SEC()
|
| H A D | Wacom__ArtPen.bpf.c | 105 int BPF_PROG(artpen_pressure_interpolate, struct hid_bpf_ctx *hctx) in SEC() 107 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, PEN_REPORT_LEN /* size */); in SEC()
|
| /linux/tools/testing/selftests/hid/progs/ |
| H A D | hid.c | 311 int BPF_PROG(hid_test_filter_raw_request, struct hid_bpf_ctx *hctx, unsigned char reportnum, in BPF_PROG() argument 332 int BPF_PROG(hid_test_hidraw_raw_request, struct hid_bpf_ctx *hctx, unsigned char reportnum, in BPF_PROG() argument 335 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 3 /* size */); in BPF_PROG() 345 ret = hid_bpf_hw_request(hctx, data, 2, rtype, reqtype); in BPF_PROG() 363 int BPF_PROG(hid_test_infinite_loop_raw_request, struct hid_bpf_ctx *hctx, unsigned char reportnum, in BPF_PROG() argument 366 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 3 /* size */); in BPF_PROG() 377 ret = hid_bpf_hw_request(hctx, data, 2, rtype, reqtype); in BPF_PROG() 390 int BPF_PROG(hid_test_filter_output_report, struct hid_bpf_ctx *hctx, unsigned char reportnum, in BPF_PROG() argument 402 int BPF_PROG(hid_test_hidraw_output_report, struct hid_bpf_ctx *hctx, __u64 source) in BPF_PROG() argument 404 __u8 *data = hid_bpf_get_data(hctx, 0 /* offset */, 3 /* size */); in BPF_PROG() [all …]
|
| /linux/drivers/char/tpm/ |
| H A D | tpm2-sessions.c | 442 struct hmac_sha256_ctx hctx; in tpm2_KDFa() local 445 hmac_sha256_init_usingrawkey(&hctx, key, key_len); in tpm2_KDFa() 446 hmac_sha256_update(&hctx, (u8 *)&c, sizeof(c)); in tpm2_KDFa() 447 hmac_sha256_update(&hctx, label, strlen(label) + 1); in tpm2_KDFa() 448 hmac_sha256_update(&hctx, u, SHA256_DIGEST_SIZE); in tpm2_KDFa() 449 hmac_sha256_update(&hctx, v, SHA256_DIGEST_SIZE); in tpm2_KDFa() 450 hmac_sha256_update(&hctx, (u8 *)&bits, sizeof(bits)); in tpm2_KDFa() 451 hmac_sha256_final(&hctx, out); in tpm2_KDFa() 593 struct hmac_sha256_ctx hctx; in tpm_buf_fill_hmac_session() local 715 hmac_sha256_init_usingrawkey(&hctx, auth->session_key, in tpm_buf_fill_hmac_session() [all …]
|
| /linux/net/dccp/ccids/ |
| H A D | ccid3.h | |
| /linux/drivers/s390/block/ |
| H A D | scm_blk.c | 281 static blk_status_t scm_blk_request(struct blk_mq_hw_ctx *hctx, in scm_blk_request() argument 284 struct scm_device *scmdev = hctx->queue->queuedata; in scm_blk_request() 286 struct scm_queue *sq = hctx->driver_data; in scm_blk_request() 330 static int scm_blk_init_hctx(struct blk_mq_hw_ctx *hctx, void *data, in scm_blk_init_hctx() argument 339 hctx->driver_data = qd; in scm_blk_init_hctx() 344 static void scm_blk_exit_hctx(struct blk_mq_hw_ctx *hctx, unsigned int idx) in scm_blk_exit_hctx() argument 346 struct scm_queue *qd = hctx->driver_data; in scm_blk_exit_hctx() 349 kfree(hctx->driver_data); in scm_blk_exit_hctx() 350 hctx->driver_data = NULL; in scm_blk_exit_hctx()
|
| /linux/drivers/block/rnbd/ |
| H A D | rnbd-clt.c | 141 if (WARN_ON(!q->hctx)) in rnbd_clt_dev_requeue() 145 blk_mq_run_hw_queue(q->hctx, true); in rnbd_clt_dev_requeue() 1098 struct blk_mq_hw_ctx *hctx, in rnbd_clt_dev_kick_mq_queue() argument 1101 struct rnbd_queue *q = hctx->driver_data; in rnbd_clt_dev_kick_mq_queue() 1104 blk_mq_delay_run_hw_queue(hctx, delay); in rnbd_clt_dev_kick_mq_queue() 1110 blk_mq_delay_run_hw_queue(hctx, 10/*ms*/); in rnbd_clt_dev_kick_mq_queue() 1113 static blk_status_t rnbd_queue_rq(struct blk_mq_hw_ctx *hctx, in rnbd_queue_rq() argument 1128 rnbd_clt_dev_kick_mq_queue(dev, hctx, RNBD_DELAY_IFBUSY); in rnbd_queue_rq() 1142 rnbd_clt_dev_kick_mq_queue(dev, hctx, 10/*ms*/); in rnbd_queue_rq() 1152 rnbd_clt_dev_kick_mq_queue(dev, hctx, 10/*ms*/); in rnbd_queue_rq() [all …]
|
| /linux/drivers/block/ |
| H A D | virtio_blk.c | 131 static inline struct virtio_blk_vq *get_virtio_blk_vq(struct blk_mq_hw_ctx *hctx) in get_virtio_blk_vq() argument 133 struct virtio_blk *vblk = hctx->queue->queuedata; in get_virtio_blk_vq() 134 struct virtio_blk_vq *vq = &vblk->vqs[hctx->queue_num]; in get_virtio_blk_vq() 213 static int virtblk_map_data(struct blk_mq_hw_ctx *hctx, struct request *req, in virtblk_map_data() argument 377 static void virtio_commit_rqs(struct blk_mq_hw_ctx *hctx) in virtio_commit_rqs() argument 379 struct virtio_blk *vblk = hctx->queue->queuedata; in virtio_commit_rqs() 380 struct virtio_blk_vq *vq = &vblk->vqs[hctx->queue_num]; in virtio_commit_rqs() 404 static blk_status_t virtblk_prep_rq(struct blk_mq_hw_ctx *hctx, in virtblk_prep_rq() argument 416 num = virtblk_map_data(hctx, req, vbr); in virtblk_prep_rq() 426 static blk_status_t virtio_queue_rq(struct blk_mq_hw_ctx *hctx, in virtio_queue_rq() argument [all …]
|
| /linux/drivers/nvme/target/ |
| H A D | loop.c | 133 static blk_status_t nvme_loop_queue_rq(struct blk_mq_hw_ctx *hctx, in nvme_loop_queue_rq() argument 136 struct nvme_ns *ns = hctx->queue->queuedata; in nvme_loop_queue_rq() 137 struct nvme_loop_queue *queue = hctx->driver_data; in nvme_loop_queue_rq() 218 static int nvme_loop_init_hctx(struct blk_mq_hw_ctx *hctx, void *data, in nvme_loop_init_hctx() argument 232 blk_mq_hctx_set_fq_lock_class(hctx, &loop_hctx_fq_lock_key); in nvme_loop_init_hctx() 234 hctx->driver_data = queue; in nvme_loop_init_hctx() 238 static int nvme_loop_init_admin_hctx(struct blk_mq_hw_ctx *hctx, void *data, in nvme_loop_init_admin_hctx() argument 246 hctx->driver_data = queue; in nvme_loop_init_admin_hctx()
|
| /linux/drivers/block/null_blk/ |
| H A D | main.c | 1588 static int null_poll(struct blk_mq_hw_ctx *hctx, struct io_comp_batch *iob) in null_poll() argument 1590 struct nullb_queue *nq = hctx->driver_data; in null_poll() 1621 struct blk_mq_hw_ctx *hctx = rq->mq_hctx; in null_timeout_rq() local 1624 if (hctx->type == HCTX_TYPE_POLL) { in null_timeout_rq() 1625 struct nullb_queue *nq = hctx->driver_data; in null_timeout_rq() 1647 if (cmd->fake_timeout || hctx->type == HCTX_TYPE_POLL) in null_timeout_rq() 1652 static blk_status_t null_queue_rq(struct blk_mq_hw_ctx *hctx, in null_queue_rq() argument 1657 struct nullb_queue *nq = hctx->driver_data; in null_queue_rq() 1660 const bool is_poll = hctx->type == HCTX_TYPE_POLL; in null_queue_rq() 1662 might_sleep_if(hctx->flags & BLK_MQ_F_BLOCKING); in null_queue_rq() [all …]
|
| /linux/drivers/infiniband/hw/bnxt_re/ |
| H A D | main.c | 2073 struct bnxt_qplib_ctx *hctx = &rdev->qplib_ctx; in bnxt_re_get_stats_ctx() local 2077 rc = bnxt_qplib_alloc_stats_ctx(res->pdev, res->cctx, &hctx->stats); in bnxt_re_get_stats_ctx() 2081 rc = bnxt_re_net_stats_ctx_alloc(rdev, &hctx->stats); in bnxt_re_get_stats_ctx() 2087 bnxt_qplib_free_stats_ctx(res->pdev, &hctx->stats); in bnxt_re_get_stats_ctx() 2094 struct bnxt_qplib_ctx *hctx = &rdev->qplib_ctx; in bnxt_re_get_stats3_ctx() local 2101 rc = bnxt_qplib_alloc_stats_ctx(res->pdev, res->cctx, &hctx->stats3); in bnxt_re_get_stats3_ctx() 2105 rc = bnxt_re_net_stats_ctx_alloc(rdev, &hctx->stats3); in bnxt_re_get_stats3_ctx() 2111 bnxt_qplib_free_stats_ctx(res->pdev, &hctx->stats3); in bnxt_re_get_stats3_ctx() 2118 struct bnxt_qplib_ctx *hctx = &rdev->qplib_ctx; in bnxt_re_put_stats3_ctx() local 2124 bnxt_re_net_stats_ctx_free(rdev, hctx->stats3.fw_id); in bnxt_re_put_stats3_ctx() [all …]
|
| /linux/Documentation/translations/zh_CN/block/ |
| H A D | blk-mq.rst | 95 如果请求无法直接发送到硬件,它们会被加入到请求的链表(``hctx->dispatch``) 中。
|