首先定义一个指向hello_device_t的结构体指针变量dev,分配大小为sizeof(struct hello_device_t)的内存并返回指向首地址的指针
struct hello_device_t* dev;
dev = (struct hello_device_t*)malloc(sizeof(struct hello_device_t));
首先定义一个指向hello_device_t的结构体指针变量dev,分配大小为sizeof(struct hello_device_t)的内存并返回指向首地址的指针
struct hello_device_t* dev;
dev = (struct hello_device_t*)malloc(sizeof(struct hello_device_t));