Call chainevh callback when we are invoked with neither MOD_LOAD nor
MOD_UNLOAD. This makes it possible to add custom hooks for other module events. Return EOPNOTSUPP when there is no callback available. Pointed out by: jhb Reviewed by: jhb MFC after: 1 month
This commit is contained in:
parent
283e21dd32
commit
5e5fd037d6
@ -181,7 +181,9 @@ syscall_module_handler(struct module *mod, int what, void *arg)
|
||||
error = syscall_deregister(data->offset, &data->old_sysent);
|
||||
return (error);
|
||||
default:
|
||||
return EOPNOTSUPP;
|
||||
if (data->chainevh)
|
||||
return (data->chainevh(mod, what, data->chainarg));
|
||||
return (EOPNOTSUPP);
|
||||
}
|
||||
|
||||
/* NOTREACHED */
|
||||
|
Loading…
Reference in New Issue
Block a user