mirror of
https://github.com/SCST-project/scst.git
synced 2026-10-22 06:02:33 +00:00
scst: Annotate poll masks passed to exit tracing
TRACE_EXIT_HRES converts its argument to unsigned long for logging. Passing an __poll_t directly triggers Sparse's restricted-type warning in both scst_event_poll() and dev_user_poll(). Explicitly remove the bitwise restriction with __force at those two trace calls. Keep the typed mask for event operations and the return value, without weakening the shared trace macro for other callers.
This commit is contained in:
@@ -2484,7 +2484,7 @@ out_unlock:
|
||||
spin_unlock_irq(&dev->udev_cmd_threads.cmd_list_lock);
|
||||
|
||||
out:
|
||||
TRACE_EXIT_HRES(res);
|
||||
TRACE_EXIT_HRES((__force unsigned int)res);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
@@ -1040,7 +1040,7 @@ static __poll_t scst_event_poll(struct file *file, poll_table *wait)
|
||||
out_unlock:
|
||||
mutex_unlock(&scst_event_mutex);
|
||||
|
||||
TRACE_EXIT_HRES(res);
|
||||
TRACE_EXIT_HRES((__force unsigned int)res);
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user