---
01)TP
file_operations:
{
1.
static struct file_operations tpd_fops = { // .owner = THIS_MODULE, .open = tpd_misc_open, .release = tpd_misc_release, .unlocked_ioctl = tpd_unlocked_ioctl, };
2.
static const struct file_operations gt_upgrade_proc_fops = { .write = gt91xx_config_write_proc, .read = gt91xx_config_read_proc };
3.
static const struct file_operations ctp_version_proc_fops = { .write = ctp_version_write_proc, .read = ctp_version_read_proc };
}
①
module_init(tpd_driver_init);
module_exit(tpd_driver_exit);
②
static int __init tpd_driver_init(void) { GTP_INFO("MediaTek gt91xx touch panel driver init "); tpd_get_dts_info(); if (tpd_driver_add(&tpd_device_driver) < 0) GTP_INFO("add generic driver failed "); return 0; }
③
static struct tpd_driver_t tpd_device_driver = { .tpd_device_name = "gt9xx", .tpd_local_init = tpd_local_init, .suspend = tpd_suspend, .resume = tpd_resume, };
④
-----