Introduce DEFINE_INIT_FUNC and DEFINE_CLEANUP_FUNC
Use DEFINE_INIT_FUNC() to register callbacks