Function report

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:fs\io_uring.c Create Date:2022-07-28 20:22:14
Last Modify:2020-03-12 14:18:49 Copyright©Brick
home page Tree
Annotation kernel can get tool activityDownload SCCTChinese

Name:io_poll_complete_work

Proto:static void io_poll_complete_work(struct io_wq_work **workptr)

Type:void

Parameter:

TypeParameterName
struct io_wq_work **workptr
2594  work = workptr
2595  req = container_of - cast a member of a structure out to the containing structure*@ptr: the pointer to the member.*@type: the type of the container struct this is embedded in.*@member: the name of the member within the struct.(work, structio_kiocb, work)
2596  poll = poll
2597  struct poll_table_struct pt = {_key = events}
2598  ctx = ctx
2599  struct io_kiocb * nxt = NULL
2600  mask = 0
2601  ret = 0
2603  If flags & IO_WQ_WORK_CANCEL Then
2604  WRITE_ONCE(canceled, true)
2605  ret = -ECANCELED
2606  Else if READ_ONCE(canceled) Then
2607  ret = -ECANCELED
2610  If ret != -ECANCELED Then mask = vfs_poll(file, & pt) & events
2620  spin_lock_irq( & completion_lock)
2621  If Not mask && ret != -ECANCELED Then
2622  add_wait_queue(head, & wait)
2623  spin_unlock_irq( & completion_lock)
2624  Return
2626  hash_del - remove an object from a hashtable*@node: &struct hlist_node of the object to remove
2627  io_poll_complete(req, mask, ret)
2628  spin_unlock_irq( & completion_lock)
2630  io_cqring_ev_posted(ctx)
2632  If ret < 0 Then req_set_fail_links(req)
2634  Drop reference to request, return next in chain (if there is one) if this* was the last reference to this request.
2635  If nxt Then io_wq_assign_next(workptr, nxt)