18c2ecf20Sopenharmony_ci// SPDX-License-Identifier: GPL-2.0 28c2ecf20Sopenharmony_ci/* 38c2ecf20Sopenharmony_ci * Sample HCK 48c2ecf20Sopenharmony_ci * 58c2ecf20Sopenharmony_ci */ 68c2ecf20Sopenharmony_ci#include <linux/module.h> 78c2ecf20Sopenharmony_ci#include <linux/init.h> 88c2ecf20Sopenharmony_ci#include <linux/hck/lite_hck_sample.h> 98c2ecf20Sopenharmony_ci 108c2ecf20Sopenharmony_civoid get_boot_power_config(int* info) 118c2ecf20Sopenharmony_ci{ 128c2ecf20Sopenharmony_ci pr_info("hck sample: intf-2 run\n"); 138c2ecf20Sopenharmony_ci *info = 2; 148c2ecf20Sopenharmony_ci} 158c2ecf20Sopenharmony_ci 168c2ecf20Sopenharmony_cistatic int __init samplehckone_init(void) 178c2ecf20Sopenharmony_ci{ 188c2ecf20Sopenharmony_ci pr_info("hck sample register_one\n"); 198c2ecf20Sopenharmony_ci REGISTER_HCK_LITE_HOOK(get_boot_config_lhck, get_boot_power_config); 208c2ecf20Sopenharmony_ci 218c2ecf20Sopenharmony_ci return 0; 228c2ecf20Sopenharmony_ci} 238c2ecf20Sopenharmony_ci 248c2ecf20Sopenharmony_cistatic void __exit samplehckone_exit(void) 258c2ecf20Sopenharmony_ci{ 268c2ecf20Sopenharmony_ci} 278c2ecf20Sopenharmony_ci 288c2ecf20Sopenharmony_cimodule_init(samplehckone_init); 298c2ecf20Sopenharmony_cimodule_exit(samplehckone_exit); 308c2ecf20Sopenharmony_ciMODULE_LICENSE("GPL v2"); 318c2ecf20Sopenharmony_ciMODULE_AUTHOR("zhujiaxin <zhujiaxin@huawei.com>"); 32