mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
Fix the last two CFI callback prototype mismatches
There was the series from me a year ago which fixed most of the callback vs implementation prototype mismatches. It was based on running the CFI-enabled kernel (in permissive mode -- warning instead of panic) and performing a full ZTS cycle, and then fixing all of the problems caught by CFI. Now, Clang 16-dev has new warning flag, -Wcast-function-type-strict, which detect such mismatches at compile-time. It allows to find the remaining issues missed by the first series. There are only two of them left: one for the secpolicy_vnode_setattr() callback and one for taskq_dispatch(). The fix is easy, since they are not used anywhere else. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: Alexander Lobakin <alobakin@pm.me> Closes #14207
This commit is contained in:
+2
-2
@@ -429,7 +429,7 @@ txg_quiesce(dsl_pool_t *dp, uint64_t txg)
|
||||
}
|
||||
|
||||
static void
|
||||
txg_do_callbacks(list_t *cb_list)
|
||||
txg_do_callbacks(void *cb_list)
|
||||
{
|
||||
dmu_tx_do_callbacks(cb_list, 0);
|
||||
|
||||
@@ -479,7 +479,7 @@ txg_dispatch_callbacks(dsl_pool_t *dp, uint64_t txg)
|
||||
|
||||
list_move_tail(cb_list, &tc->tc_callbacks[g]);
|
||||
|
||||
(void) taskq_dispatch(tx->tx_commit_cb_taskq, (task_func_t *)
|
||||
(void) taskq_dispatch(tx->tx_commit_cb_taskq,
|
||||
txg_do_callbacks, cb_list, TQ_SLEEP);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user