在编写kernel驱动时
fp->f_op->read() unable to handle
pos = 0;
kernel_read(fp, buf, len, &pos); // 改为kernel_read()--ok
//fp->f_op->read(fp, buf, len, &fp->f_pos);
在编写kernel驱动时
fp->f_op->read() unable to handle
pos = 0;
kernel_read(fp, buf, len, &pos); // 改为kernel_read()--ok
//fp->f_op->read(fp, buf, len, &fp->f_pos);